Index: src/parsing/parser.cc |
diff --git a/src/parsing/parser.cc b/src/parsing/parser.cc |
index 6c0b58e2b2d2808096fcafe0a40bf606117d84ed..d07bea10e1d5f3d66929bfeee9294cbbe9105073 100644 |
--- a/src/parsing/parser.cc |
+++ b/src/parsing/parser.cc |
@@ -2609,7 +2609,9 @@ void Parser::ParseArrowFunctionFormalParameterList( |
for (int i = 0; i < parameters->Arity(); ++i) { |
auto parameter = parameters->at(i); |
DeclareFormalParameter(parameters->scope, parameter); |
- if (!duplicate_loc->IsValid()) { |
+ if (!this->classifier() |
+ ->is_valid_formal_parameter_list_without_duplicates() && |
+ !duplicate_loc->IsValid()) { |
*duplicate_loc = |
this->classifier()->duplicate_formal_parameter_error().location; |
} |