Index: src/parsing/preparser.cc |
diff --git a/src/parsing/preparser.cc b/src/parsing/preparser.cc |
index 700ebd47fda8cf1fe6ff504f89f9f07b58089289..68372f841a7ea7811129db20ff93046c174dbbf2 100644 |
--- a/src/parsing/preparser.cc |
+++ b/src/parsing/preparser.cc |
@@ -1176,11 +1176,15 @@ PreParserExpression PreParser::ParseClassLiteral( |
bool is_computed_name = false; // Classes do not care about computed |
// property names here. |
Identifier name; |
- ExpressionClassifier classifier(this); |
+ ExpressionClassifier property_classifier(this); |
ParsePropertyDefinition(&checker, in_class, has_extends, is_static, |
&is_computed_name, &has_seen_constructor, |
- &classifier, &name, CHECK_OK); |
- ValidateExpression(&classifier, CHECK_OK); |
+ &property_classifier, &name, CHECK_OK); |
+ ValidateExpression(&property_classifier, CHECK_OK); |
+ if (classifier != nullptr) { |
+ classifier->Accumulate(&property_classifier, |
+ ExpressionClassifier::ExpressionProductions); |
+ } |
} |
Expect(Token::RBRACE, CHECK_OK); |