Revision: 17271
Author: [email protected]
Date: Fri Oct 18 11:41:17 2013 UTC
Log: Experimental parser: Fix multi-line strings.
BUG=
[email protected]
Review URL: https://codereview.chromium.org/28993002
http://code.google.com/p/v8/source/detail?r=17271
Modified:
/branches/experimental/parser/src/lexer/lexer.re
=======================================
--- /branches/experimental/parser/src/lexer/lexer.re Fri Oct 18 09:01:34
2013 UTC
+++ /branches/experimental/parser/src/lexer/lexer.re Fri Oct 18 11:41:17
2013 UTC
@@ -322,12 +322,16 @@
<DoubleQuoteString> "\\\"" { goto yy0; }
<DoubleQuoteString> '"' { PUSH_TOKEN(Token::STRING);}
+ <DoubleQuoteString> "\\" "\n" "\r"? { goto yy0; }
+ <DoubleQuoteString> "\\" "\r" "\n"? { goto yy0; }
<DoubleQuoteString> line_terminator { TERMINATE_ILLEGAL(); }
<DoubleQuoteString> eof { TERMINATE_ILLEGAL(); }
<DoubleQuoteString> any { goto yy0; }
<SingleQuoteString> "\\'" { goto yy0; }
<SingleQuoteString> "'" { PUSH_TOKEN(Token::STRING);}
+ <SingleQuoteString> "\\" "\n" "\r"? { goto yy0; }
+ <SingleQuoteString> "\\" "\r" "\n"? { goto yy0; }
<SingleQuoteString> line_terminator { TERMINATE_ILLEGAL(); }
<SingleQuoteString> eof { TERMINATE_ILLEGAL(); }
<SingleQuoteString> any { goto yy0; }
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.