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

Unified Diff: src/parsing/scanner.h

Issue 1801203002: Parser: Make skipping HTML comments optional. (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/scanner.h
diff --git a/src/parsing/scanner.h b/src/parsing/scanner.h
index 9f195e3657fae6e90a2417f52ba6e0497c80a504..3e3bb93fb6a59668f8660df2adbe7ac9c0ba4e0c 100644
--- a/src/parsing/scanner.h
+++ b/src/parsing/scanner.h
@@ -340,7 +340,7 @@ class Scanner {
// -1 is outside of the range of any real source code.
static const int kNoOctalLocation = -1;
- explicit Scanner(UnicodeCache* scanner_contants);
+ Scanner(UnicodeCache* scanner_contants, bool ignore_html_comments);
void Initialize(Utf16CharacterStream* source);
@@ -755,6 +755,8 @@ class Scanner {
// Whether there is a multi-line comment that contains a
// line-terminator after the current token, and before the next.
bool has_multiline_comment_before_next_;
+ // Whether to skip HTML comments (or report them as errors).
+ bool ignore_html_comments_;
// Whether this scanner encountered an HTML comment.
bool found_html_comment_;
« src/compiler.cc ('K') | « src/parsing/parser.cc ('k') | src/parsing/scanner.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698