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

Unified Diff: src/prettyprinter.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/preparser.h ('k') | src/typing.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/prettyprinter.cc
diff --git a/src/prettyprinter.cc b/src/prettyprinter.cc
index e71489fa7f2c401111468f7de94d55bf24075a4a..bf28cc6378749a94217a0949bd04da43a01fc11b 100644
--- a/src/prettyprinter.cc
+++ b/src/prettyprinter.cc
@@ -360,6 +360,11 @@ void CallPrinter::VisitSpread(Spread* node) {
}
+void CallPrinter::VisitEmptyParentheses(EmptyParentheses* node) {
+ UNREACHABLE();
+}
+
+
void CallPrinter::VisitThisFunction(ThisFunction* node) {}
@@ -845,6 +850,11 @@ void PrettyPrinter::VisitSpread(Spread* node) {
}
+void PrettyPrinter::VisitEmptyParentheses(EmptyParentheses* node) {
+ Print("()");
+}
+
+
void PrettyPrinter::VisitThisFunction(ThisFunction* node) {
Print("<this-function>");
}
@@ -1565,6 +1575,11 @@ void AstPrinter::VisitSpread(Spread* node) {
}
+void AstPrinter::VisitEmptyParentheses(EmptyParentheses* node) {
+ IndentedScope indent(this, "()");
+}
+
+
void AstPrinter::VisitThisFunction(ThisFunction* node) {
IndentedScope indent(this, "THIS-FUNCTION");
}
« no previous file with comments | « src/preparser.h ('k') | src/typing.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698