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

Unified Diff: src/parsing/preparser.h

Issue 1808373003: Implement ES2015 labelled function declaration restrictions (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 9 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/preparser.h
diff --git a/src/parsing/preparser.h b/src/parsing/preparser.h
index 3afaed115a8b8e93222e91412d3dcebd50720cc6..309005271391d28ff0c778a83e340324ef1bdb49 100644
--- a/src/parsing/preparser.h
+++ b/src/parsing/preparser.h
@@ -1009,8 +1009,8 @@ class PreParser : public ParserBase<PreParserTraits> {
Statement ParseStatementListItem(bool* ok);
void ParseStatementList(int end_token, bool* ok,
Scanner::BookmarkScope* bookmark = nullptr);
- Statement ParseStatement(bool* ok);
- Statement ParseSubStatement(bool* ok);
+ Statement ParseStatement(AllowLabelledFunctionStatement, bool* ok);
+ Statement ParseSubStatement(AllowLabelledFunctionStatement, bool* ok);
Statement ParseScopedStatement(bool legacy, bool* ok);
Statement ParseFunctionDeclaration(bool* ok);
Statement ParseClassDeclaration(bool* ok);
@@ -1023,7 +1023,8 @@ class PreParser : public ParserBase<PreParserTraits> {
Scanner::Location* first_initializer_loc,
Scanner::Location* bindings_loc,
bool* ok);
- Statement ParseExpressionOrLabelledStatement(bool* ok);
+ Statement ParseExpressionOrLabelledStatement(AllowLabelledFunctionStatement,
+ bool* ok);
Statement ParseIfStatement(bool* ok);
Statement ParseContinueStatement(bool* ok);
Statement ParseBreakStatement(bool* ok);
« src/parsing/parser.cc ('K') | « src/parsing/parser-base.h ('k') | src/parsing/preparser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698