OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef V8_PARSING_PREPARSER_H | 5 #ifndef V8_PARSING_PREPARSER_H |
6 #define V8_PARSING_PREPARSER_H | 6 #define V8_PARSING_PREPARSER_H |
7 | 7 |
8 #include "src/ast/ast.h" | 8 #include "src/ast/ast.h" |
9 #include "src/ast/scopes.h" | 9 #include "src/ast/scopes.h" |
10 #include "src/parsing/parser-base.h" | 10 #include "src/parsing/parser-base.h" |
(...skipping 1264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1275 } | 1275 } |
1276 | 1276 |
1277 V8_INLINE PreParserStatement | 1277 V8_INLINE PreParserStatement |
1278 InitializeForEachStatement(PreParserStatement stmt, PreParserExpression each, | 1278 InitializeForEachStatement(PreParserStatement stmt, PreParserExpression each, |
1279 PreParserExpression subject, | 1279 PreParserExpression subject, |
1280 PreParserStatement body, int each_keyword_pos) { | 1280 PreParserStatement body, int each_keyword_pos) { |
1281 MarkExpressionAsAssigned(each); | 1281 MarkExpressionAsAssigned(each); |
1282 return stmt; | 1282 return stmt; |
1283 } | 1283 } |
1284 | 1284 |
| 1285 V8_INLINE PreParserStatement InitializeForAwaitOfStatement( |
| 1286 PreParserStatement stmt, PreParserExpression each, |
| 1287 PreParserExpression subject, PreParserStatement body, |
| 1288 int each_keyword_pos) { |
| 1289 return stmt; |
| 1290 } |
| 1291 |
1285 V8_INLINE PreParserStatement RewriteForVarInLegacy(const ForInfo& for_info) { | 1292 V8_INLINE PreParserStatement RewriteForVarInLegacy(const ForInfo& for_info) { |
1286 return PreParserStatement::Null(); | 1293 return PreParserStatement::Null(); |
1287 } | 1294 } |
1288 | 1295 |
1289 V8_INLINE void DesugarBindingInForEachStatement( | 1296 V8_INLINE void DesugarBindingInForEachStatement( |
1290 ForInfo* for_info, PreParserStatement* body_block, | 1297 ForInfo* for_info, PreParserStatement* body_block, |
1291 PreParserExpression* each_variable, bool* ok) { | 1298 PreParserExpression* each_variable, bool* ok) { |
1292 if (track_unresolved_variables_) { | 1299 if (track_unresolved_variables_) { |
1293 DCHECK(for_info->parsing_result.declarations.length() == 1); | 1300 DCHECK(for_info->parsing_result.declarations.length() == 1); |
1294 DeclareAndInitializeVariables( | 1301 DeclareAndInitializeVariables( |
(...skipping 338 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1633 function_state_->NextMaterializedLiteralIndex(); | 1640 function_state_->NextMaterializedLiteralIndex(); |
1634 function_state_->NextMaterializedLiteralIndex(); | 1641 function_state_->NextMaterializedLiteralIndex(); |
1635 } | 1642 } |
1636 return EmptyExpression(); | 1643 return EmptyExpression(); |
1637 } | 1644 } |
1638 | 1645 |
1639 } // namespace internal | 1646 } // namespace internal |
1640 } // namespace v8 | 1647 } // namespace v8 |
1641 | 1648 |
1642 #endif // V8_PARSING_PREPARSER_H | 1649 #endif // V8_PARSING_PREPARSER_H |
OLD | NEW |