Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(933)

Unified Diff: src/parsing/parser-base.h

Issue 1582783004: [es6] add SetFunctionName() behaviour to AssignmentExpression (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Add a bunch more tests Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/parsing/parser-base.h
diff --git a/src/parsing/parser-base.h b/src/parsing/parser-base.h
index faea8b581b4703f01ff7624d73ae977c56ba6e95..760035dc7e6b7851de2264803910e703b8b7725f 100644
--- a/src/parsing/parser-base.h
+++ b/src/parsing/parser-base.h
@@ -2126,6 +2126,10 @@ ParserBase<Traits>::ParseAssignmentExpression(bool accept_IN, int flags,
}
}
+ if (op == Token::ASSIGN && allow_harmony_function_name()) {
+ Traits::SetFunctionNameFromIdentifierRef(right, expression);
+ }
+
ExpressionT result = factory()->NewAssignment(op, expression, right, pos);
if (is_destructuring_assignment) {

Powered by Google App Engine
This is Rietveld 408576698