Index: src/parsing/parser.h |
diff --git a/src/parsing/parser.h b/src/parsing/parser.h |
index e2f6b6e739255866a74d6a87f490b669579b4915..a3f51c5cd062cab4380d3c5b2584e01acd320503 100644 |
--- a/src/parsing/parser.h |
+++ b/src/parsing/parser.h |
@@ -339,6 +339,7 @@ class ParserTraits { |
// Return types for traversing functions. |
typedef const AstRawString* Identifier; |
+ typedef ZoneList<const AstRawString*>* IdentifierList; |
typedef v8::internal::Expression* Expression; |
typedef Yield* YieldExpression; |
typedef v8::internal::FunctionLiteral* FunctionLiteral; |
@@ -511,6 +512,8 @@ class ParserTraits { |
V8_INLINE ZoneList<typesystem::TypeParameter*>* EmptyTypeParameters() const; |
V8_INLINE ZoneList<typesystem::FormalParameter*>* EmptyFormalParameters() |
const; |
+ static ZoneList<const AstRawString*>* NullIdentifierList() { return nullptr; } |
+ V8_INLINE ZoneList<const AstRawString*>* EmptyIdentifierList() const; |
// Used in error return values. |
static ZoneList<Expression*>* NullExpressionList() { |
@@ -1128,6 +1131,12 @@ ZoneList<typesystem::FormalParameter*>* ParserTraits::EmptyFormalParameters() |
} |
+ZoneList<const AstRawString*>* ParserTraits::EmptyIdentifierList() const { |
+ return new (parser_->zone()) |
+ ZoneList<const AstRawString*>(1, parser_->zone()); |
+} |
+ |
+ |
const AstRawString* ParserTraits::EmptyIdentifierString() { |
return parser_->ast_value_factory()->empty_string(); |
} |