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/allocation.h" | 8 #include "src/allocation.h" |
9 #include "src/ast/ast.h" | 9 #include "src/ast/ast.h" |
10 #include "src/ast/scopes.h" | 10 #include "src/ast/scopes.h" |
(...skipping 1064 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1075 void InsertShadowingVarBindingInitializers(Block* block); | 1075 void InsertShadowingVarBindingInitializers(Block* block); |
1076 | 1076 |
1077 // Implement sloppy block-scoped functions, ES2015 Annex B 3.3 | 1077 // Implement sloppy block-scoped functions, ES2015 Annex B 3.3 |
1078 void InsertSloppyBlockFunctionVarBindings(DeclarationScope* scope, | 1078 void InsertSloppyBlockFunctionVarBindings(DeclarationScope* scope, |
1079 Scope* complex_params_scope, | 1079 Scope* complex_params_scope, |
1080 bool* ok); | 1080 bool* ok); |
1081 | 1081 |
1082 // Parser support | 1082 // Parser support |
1083 VariableProxy* NewUnresolved(const AstRawString* name, VariableMode mode); | 1083 VariableProxy* NewUnresolved(const AstRawString* name, VariableMode mode); |
1084 Variable* Declare(Declaration* declaration, | 1084 Variable* Declare(Declaration* declaration, |
1085 DeclarationDescriptor::Kind declaration_kind, bool resolve, | 1085 DeclarationDescriptor::Kind declaration_kind, bool* ok, |
1086 bool* ok, Scope* declaration_scope = nullptr); | 1086 Scope* declaration_scope = nullptr); |
1087 void DeclareConstVariable(const AstRawString* name, InitializationFlag init, | 1087 void DeclareConstVariable(const AstRawString* name, InitializationFlag init, |
1088 int pos, bool* ok); | 1088 int pos, bool* ok); |
1089 | 1089 |
1090 bool TargetStackContainsLabel(const AstRawString* label); | 1090 bool TargetStackContainsLabel(const AstRawString* label); |
1091 BreakableStatement* LookupBreakTarget(const AstRawString* label, bool* ok); | 1091 BreakableStatement* LookupBreakTarget(const AstRawString* label, bool* ok); |
1092 IterationStatement* LookupContinueTarget(const AstRawString* label, bool* ok); | 1092 IterationStatement* LookupContinueTarget(const AstRawString* label, bool* ok); |
1093 | 1093 |
1094 Statement* BuildAssertIsCoercible(Variable* var); | 1094 Statement* BuildAssertIsCoercible(Variable* var); |
1095 | 1095 |
1096 // Factory methods. | 1096 // Factory methods. |
(...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1364 | 1364 |
1365 DoExpression* ParserTraits::ParseDoExpression(bool* ok) { | 1365 DoExpression* ParserTraits::ParseDoExpression(bool* ok) { |
1366 return parser_->ParseDoExpression(ok); | 1366 return parser_->ParseDoExpression(ok); |
1367 } | 1367 } |
1368 | 1368 |
1369 | 1369 |
1370 } // namespace internal | 1370 } // namespace internal |
1371 } // namespace v8 | 1371 } // namespace v8 |
1372 | 1372 |
1373 #endif // V8_PARSING_PARSER_H_ | 1373 #endif // V8_PARSING_PARSER_H_ |
OLD | NEW |