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_PARSER_H_ | 5 #ifndef V8_PARSING_PARSER_H_ |
6 #define V8_PARSING_PARSER_H_ | 6 #define V8_PARSING_PARSER_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/base/compiler-specific.h" | 10 #include "src/base/compiler-specific.h" |
(...skipping 432 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
443 bool* ok_; | 443 bool* ok_; |
444 | 444 |
445 DEFINE_AST_VISITOR_MEMBERS_WITHOUT_STACKOVERFLOW() | 445 DEFINE_AST_VISITOR_MEMBERS_WITHOUT_STACKOVERFLOW() |
446 }; | 446 }; |
447 | 447 |
448 // !%_IsJSReceiver(result = iterator.next()) && | 448 // !%_IsJSReceiver(result = iterator.next()) && |
449 // %ThrowIteratorResultNotAnObject(result) | 449 // %ThrowIteratorResultNotAnObject(result) |
450 Expression* BuildIteratorNextResult(Expression* iterator, Variable* result, | 450 Expression* BuildIteratorNextResult(Expression* iterator, Variable* result, |
451 int pos); | 451 int pos); |
452 | 452 |
453 Expression* GetIterator(Expression* iterable, int pos); | |
454 | |
455 // Initialize the components of a for-in / for-of statement. | 453 // Initialize the components of a for-in / for-of statement. |
456 Statement* InitializeForEachStatement(ForEachStatement* stmt, | 454 Statement* InitializeForEachStatement(ForEachStatement* stmt, |
457 Expression* each, Expression* subject, | 455 Expression* each, Expression* subject, |
458 Statement* body, int each_keyword_pos); | 456 Statement* body, int each_keyword_pos); |
459 Statement* InitializeForOfStatement(ForOfStatement* stmt, Expression* each, | 457 Statement* InitializeForOfStatement(ForOfStatement* stmt, Expression* each, |
460 Expression* iterable, Statement* body, | 458 Expression* iterable, Statement* body, |
461 bool finalize, | 459 bool finalize, |
462 int next_result_pos = kNoSourcePosition); | 460 int next_result_pos = kNoSourcePosition); |
463 Block* RewriteForVarInLegacy(const ForInfo& for_info); | 461 Block* RewriteForVarInLegacy(const ForInfo& for_info); |
464 void DesugarBindingInForEachStatement(ForInfo* for_info, Block** body_block, | 462 void DesugarBindingInForEachStatement(ForInfo* for_info, Block** body_block, |
(...skipping 725 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1190 | 1188 |
1191 private: | 1189 private: |
1192 ParserTarget** variable_; | 1190 ParserTarget** variable_; |
1193 ParserTarget* previous_; | 1191 ParserTarget* previous_; |
1194 }; | 1192 }; |
1195 | 1193 |
1196 } // namespace internal | 1194 } // namespace internal |
1197 } // namespace v8 | 1195 } // namespace v8 |
1198 | 1196 |
1199 #endif // V8_PARSING_PARSER_H_ | 1197 #endif // V8_PARSING_PARSER_H_ |
OLD | NEW |