File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -157,6 +157,10 @@ variableDeclarationList
157157 : varModifier variableDeclaration (' ,' variableDeclaration)*
158158 ;
159159
160+ singleVariableDeclaration
161+ : varModifier variableDeclaration
162+ ;
163+
160164variableDeclaration
161165 : assignable (' =' singleExpression)? // ECMAScript 6: Array & Object Matching
162166 ;
@@ -177,8 +181,8 @@ iterationStatement
177181 : Do statement While ' (' expressionSequence ' )' eos # DoStatement
178182 | While ' (' expressionSequence ' )' statement # WhileStatement
179183 | For ' (' (expressionSequence | variableDeclarationList)? ' ;' expressionSequence? ' ;' expressionSequence? ' )' statement # ForStatement
180- | For ' (' (singleExpression | variableDeclarationList ) In expressionSequence ' )' statement # ForInStatement
181- | For Await? ' (' (singleExpression | variableDeclarationList ) Of expressionSequence ' )' statement # ForOfStatement
184+ | For ' (' (singleExpression | singleVariableDeclaration ) In expressionSequence ' )' statement # ForInStatement
185+ | For Await? ' (' (singleExpression | singleVariableDeclaration ) Of expressionSequence ' )' statement # ForOfStatement
182186 ;
183187
184188varModifier // let, const - ECMAScript 6
@@ -559,7 +563,7 @@ keyword
559563 | Protected
560564 | Static
561565 | Yield
562- | YieldStar
566+ | YieldStar
563567 | Async
564568 | Await
565569 | From
You can’t perform that action at this time.
0 commit comments