Skip to content

Commit a6eaf4b

Browse files
committed
[Parser] Simplify sequence expression parsing
`SequenceExprSyntax` now gurantees that it has odd number elements using `UnresolvedTernaryExpr`/`UnresolvedAsExpr`/`UnresolvedIsExpr`. Factored out the operator parsing into `parseSequenceExpressionOperator()` which returns the operator expresssion, and optionally the RHS, so we can avoid nested loops. Also, `parseSequenceExprssion()` now has a performance optimization that avoids heap `Array` construction unless the expression is actually sequenced.
1 parent fd5b6db commit a6eaf4b

File tree

2 files changed

+179
-182
lines changed

2 files changed

+179
-182
lines changed

0 commit comments

Comments
 (0)