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_PARSER_H_ | 5 #ifndef V8_PARSER_H_ |
6 #define V8_PARSER_H_ | 6 #define V8_PARSER_H_ |
7 | 7 |
8 #include "src/allocation.h" | 8 #include "src/allocation.h" |
9 #include "src/ast.h" | 9 #include "src/ast.h" |
10 #include "src/compiler.h" // For CachedDataMode | 10 #include "src/compiler.h" // For CachedDataMode |
(...skipping 745 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
756 DebuggerStatement* ParseDebuggerStatement(bool* ok); | 756 DebuggerStatement* ParseDebuggerStatement(bool* ok); |
757 | 757 |
758 // Support for hamony block scoped bindings. | 758 // Support for hamony block scoped bindings. |
759 Block* ParseScopedBlock(ZoneList<const AstRawString*>* labels, bool* ok); | 759 Block* ParseScopedBlock(ZoneList<const AstRawString*>* labels, bool* ok); |
760 | 760 |
761 // Initialize the components of a for-in / for-of statement. | 761 // Initialize the components of a for-in / for-of statement. |
762 void InitializeForEachStatement(ForEachStatement* stmt, | 762 void InitializeForEachStatement(ForEachStatement* stmt, |
763 Expression* each, | 763 Expression* each, |
764 Expression* subject, | 764 Expression* subject, |
765 Statement* body); | 765 Statement* body); |
766 Statement* DesugarLetBindingsInForStatement( | 766 Statement* DesugarLexicalBindingsInForStatement( |
767 Scope* inner_scope, ZoneList<const AstRawString*>* names, | 767 Scope* inner_scope, bool is_const, ZoneList<const AstRawString*>* names, |
768 ForStatement* loop, Statement* init, Expression* cond, Statement* next, | 768 ForStatement* loop, Statement* init, Expression* cond, Statement* next, |
769 Statement* body, bool* ok); | 769 Statement* body, bool* ok); |
770 | 770 |
771 FunctionLiteral* ParseFunctionLiteral( | 771 FunctionLiteral* ParseFunctionLiteral( |
772 const AstRawString* name, Scanner::Location function_name_location, | 772 const AstRawString* name, Scanner::Location function_name_location, |
773 bool name_is_strict_reserved, FunctionKind kind, | 773 bool name_is_strict_reserved, FunctionKind kind, |
774 int function_token_position, FunctionLiteral::FunctionType type, | 774 int function_token_position, FunctionLiteral::FunctionType type, |
775 FunctionLiteral::ArityRestriction arity_restriction, bool* ok); | 775 FunctionLiteral::ArityRestriction arity_restriction, bool* ok); |
776 | 776 |
777 | 777 |
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
941 } | 941 } |
942 | 942 |
943 | 943 |
944 Expression* ParserTraits::CloseTemplateLiteral(TemplateLiteralState* state, | 944 Expression* ParserTraits::CloseTemplateLiteral(TemplateLiteralState* state, |
945 int start, Expression* tag) { | 945 int start, Expression* tag) { |
946 return parser_->CloseTemplateLiteral(state, start, tag); | 946 return parser_->CloseTemplateLiteral(state, start, tag); |
947 } | 947 } |
948 } } // namespace v8::internal | 948 } } // namespace v8::internal |
949 | 949 |
950 #endif // V8_PARSER_H_ | 950 #endif // V8_PARSER_H_ |
OLD | NEW |