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

Unified Diff: src/lexer/lexer_py.re

Issue 101703002: Experimental parser: handle \0 (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/parser
Patch Set: Created 7 years 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/lexer/lexer_py.re
diff --git a/src/lexer/lexer_py.re b/src/lexer/lexer_py.re
index f966230267d54e5fac0fc8c344c4eeb468d1b4ea..c65a0ef3085b86a5453f9f6b5bb83541baaaa753 100644
--- a/src/lexer/lexer_py.re
+++ b/src/lexer/lexer_py.re
@@ -203,7 +203,8 @@ default_action <do_token_and_go_forward(ILLEGAL)>
/\\[u][:hex_digit:]{4}/ <set_has_escapes||continue>
/\\[1-7]/ <octal_inside_string||continue>
/\\[0-7][0-7]+/ <octal_inside_string||continue>
-/\\[^xu1-7:line_terminator:]/ <set_has_escapes||continue>
+"\\0" <set_has_escapes||continue>
+/\\[^xu0-7:line_terminator:]/ <set_has_escapes||continue>
"\\" <|token(ILLEGAL)|>
line_terminator <|token(ILLEGAL)|>
"\"" <|token(STRING)|>
@@ -217,7 +218,8 @@ catch_all <||continue>
/\\[u][:hex_digit:]{4}/ <set_has_escapes||continue>
/\\[1-7]/ <octal_inside_string||continue>
/\\[0-7][0-7]+/ <octal_inside_string||continue>
-/\\[^xu1-7:line_terminator:]/ <set_has_escapes||continue>
+"\\0" <set_has_escapes||continue>
+/\\[^xu0-7:line_terminator:]/ <set_has_escapes||continue>
"\\" <|token(ILLEGAL)|>
line_terminator <|token(ILLEGAL)|>
"'" <|token(STRING)|>
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698