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 1269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1280 } | 1280 } |
1281 | 1281 |
1282 V8_INLINE PreParserStatement | 1282 V8_INLINE PreParserStatement |
1283 InitializeForEachStatement(PreParserStatement stmt, PreParserExpression each, | 1283 InitializeForEachStatement(PreParserStatement stmt, PreParserExpression each, |
1284 PreParserExpression subject, | 1284 PreParserExpression subject, |
1285 PreParserStatement body, int each_keyword_pos) { | 1285 PreParserStatement body, int each_keyword_pos) { |
1286 MarkExpressionAsAssigned(each); | 1286 MarkExpressionAsAssigned(each); |
1287 return stmt; | 1287 return stmt; |
1288 } | 1288 } |
1289 | 1289 |
| 1290 V8_INLINE PreParserStatement InitializeForAwaitOfStatement( |
| 1291 PreParserStatement stmt, PreParserExpression each, |
| 1292 PreParserExpression subject, PreParserStatement body, |
| 1293 int each_keyword_pos) { |
| 1294 return stmt; |
| 1295 } |
| 1296 |
1290 V8_INLINE PreParserStatement RewriteForVarInLegacy(const ForInfo& for_info) { | 1297 V8_INLINE PreParserStatement RewriteForVarInLegacy(const ForInfo& for_info) { |
1291 return PreParserStatement::Null(); | 1298 return PreParserStatement::Null(); |
1292 } | 1299 } |
1293 | 1300 |
1294 V8_INLINE void DesugarBindingInForEachStatement( | 1301 V8_INLINE void DesugarBindingInForEachStatement( |
1295 ForInfo* for_info, PreParserStatement* body_block, | 1302 ForInfo* for_info, PreParserStatement* body_block, |
1296 PreParserExpression* each_variable, bool* ok) { | 1303 PreParserExpression* each_variable, bool* ok) { |
1297 if (track_unresolved_variables_) { | 1304 if (track_unresolved_variables_) { |
1298 DCHECK(for_info->parsing_result.declarations.length() == 1); | 1305 DCHECK(for_info->parsing_result.declarations.length() == 1); |
1299 DeclareAndInitializeVariables( | 1306 DeclareAndInitializeVariables( |
(...skipping 338 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1638 function_state_->NextMaterializedLiteralIndex(); | 1645 function_state_->NextMaterializedLiteralIndex(); |
1639 function_state_->NextMaterializedLiteralIndex(); | 1646 function_state_->NextMaterializedLiteralIndex(); |
1640 } | 1647 } |
1641 return EmptyExpression(); | 1648 return EmptyExpression(); |
1642 } | 1649 } |
1643 | 1650 |
1644 } // namespace internal | 1651 } // namespace internal |
1645 } // namespace v8 | 1652 } // namespace v8 |
1646 | 1653 |
1647 #endif // V8_PARSING_PREPARSER_H | 1654 #endif // V8_PARSING_PREPARSER_H |
OLD | NEW |