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

Unified Diff: tools/lexer_generator/code_generator.jinja

Issue 91833002: Experimental scanner: keeping track of octal numbers octal escapes. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/parser
Patch Set: Created 7 years, 1 month 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 | « test/lexer/cornercases/strings-and-identifiers-with-escapes.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/lexer_generator/code_generator.jinja
diff --git a/tools/lexer_generator/code_generator.jinja b/tools/lexer_generator/code_generator.jinja
index 8ee95db35be381cccc681d10ce40461f687ab4f3..be3a700e63bfd2425cca4401bec6d8d15e906a1b 100644
--- a/tools/lexer_generator/code_generator.jinja
+++ b/tools/lexer_generator/code_generator.jinja
@@ -114,7 +114,13 @@
{% elif type == 'set_marker' %}
marker_ = cursor_ - {{value}};
{% elif type == 'set_has_escapes' %}
- next_.has_escapes = true;
+ next_.has_escapes = true;
+ {% elif type == 'octal_number' %}
+ last_octal_end_ = cursor_;
+ DO_TOKEN(Token::NUMBER);
+ {% elif type == 'octal_inside_string' %}
+ last_octal_end_ = cursor_;
+ next_.has_escapes = true;
{% else %}
uncompilable code for {{type}}
{% endif -%}
« no previous file with comments | « test/lexer/cornercases/strings-and-identifiers-with-escapes.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698