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

Unified Diff: src/parser.cc

Issue 1315823002: Parse arrow functions at proper precedence level (Closed) Base URL: https://chromium.googlesource.com/v8/v8@master
Patch Set: Fix nits Created 5 years, 4 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
« no previous file with comments | « src/messages.h ('k') | src/pattern-rewriter.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/parser.cc
diff --git a/src/parser.cc b/src/parser.cc
index 57089fad85dc25abaa994ae3ea84179548858bad..46884859f68067e72f0f416b3bb0f4a3a52957d1 100644
--- a/src/parser.cc
+++ b/src/parser.cc
@@ -3969,6 +3969,8 @@ void ParserTraits::ParseArrowFunctionFormalParameterList(
ParserFormalParameters* parameters, Expression* expr,
const Scanner::Location& params_loc,
Scanner::Location* duplicate_loc, bool* ok) {
+ if (expr->IsEmptyParentheses()) return;
+
ParseArrowFunctionFormalParameters(parameters, expr, params_loc,
duplicate_loc, ok);
if (!*ok) return;
« no previous file with comments | « src/messages.h ('k') | src/pattern-rewriter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698