Commit 7991362a authored by Toon Verwaest's avatar Toon Verwaest Committed by Commit Bot

[parser] Drop explicit shorthand property LET detection

It's automatically detected in VariableDeclarationParsingScope::Declare.

Change-Id: I2cf406ebd2dcd66eefb3d709289e0a8d162d0251
Reviewed-on: https://chromium-review.googlesource.com/c/1463783Reviewed-by: 's avatarLeszek Swirski <leszeks@chromium.org>
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59512}
parent 93b3c7e0
......@@ -163,11 +163,6 @@ class ExpressionScope {
AsExpressionParsingScope()->RecordExpressionError(loc, message);
}
void RecordLexicalDeclarationError(const Scanner::Location& loc,
MessageTemplate message) {
if (IsLexicalDeclaration()) Report(loc, message);
}
void RecordNonSimpleParameter() {
if (!IsArrowHeadParsingScope()) return;
AsArrowHeadParsingScope()->RecordNonSimpleParameter();
......
......@@ -2333,10 +2333,6 @@ ParserBase<Impl>::ParseObjectPropertyDefinition(ParsePropertyInfo* prop_info,
DCHECK(!prop_info->is_computed_name);
if (name_token == Token::LET) {
expression_scope()->RecordLexicalDeclarationError(
scanner()->location(), MessageTemplate::kLetInLexicalBinding);
}
if (name_token == Token::AWAIT) {
DCHECK(!is_async_function());
expression_scope()->RecordAsyncArrowParametersError(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment