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

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: Fix style 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
« no previous file with comments | « src/parsing/parser-base.h ('k') | src/parsing/preparser.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/parsing/preparser.h
diff --git a/src/parsing/preparser.h b/src/parsing/preparser.h
index 3b6afa7fd0d966ac8e687f53a225d621171d2402..c803928fd8e30582acf74c3657e3f40f05660241 100644
--- a/src/parsing/preparser.h
+++ b/src/parsing/preparser.h
@@ -1019,8 +1019,10 @@ 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 allow_function,
+ bool* ok);
+ Statement ParseSubStatement(AllowLabelledFunctionStatement allow_function,
+ bool* ok);
Statement ParseScopedStatement(bool legacy, bool* ok);
Statement ParseFunctionDeclaration(bool* ok);
Statement ParseClassDeclaration(bool* ok);
@@ -1033,7 +1035,8 @@ class PreParser : public ParserBase<PreParserTraits> {
Scanner::Location* first_initializer_loc,
Scanner::Location* bindings_loc,
bool* ok);
- Statement ParseExpressionOrLabelledStatement(bool* ok);
+ Statement ParseExpressionOrLabelledStatement(
+ AllowLabelledFunctionStatement allow_function, bool* ok);
Statement ParseIfStatement(bool* ok);
Statement ParseContinueStatement(bool* ok);
Statement ParseBreakStatement(bool* ok);
« no previous file with comments | « 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