aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenoit Giannangeli <giann008@gmail.com>2017-03-24 15:45:37 +0100
committerBenoit Giannangeli <giann008@gmail.com>2017-03-24 15:45:37 +0100
commit12944ea4d52a330b8b015af296dbbdee3fb4abbd (patch)
treef94b29388c51b196435371099e81f1ec99b3405f
parent92089dcbc59b8c71909386c86e36097f98258f2d (diff)
downloadfengari-12944ea4d52a330b8b015af296dbbdee3fb4abbd.tar.gz
fengari-12944ea4d52a330b8b015af296dbbdee3fb4abbd.tar.bz2
fengari-12944ea4d52a330b8b015af296dbbdee3fb4abbd.zip
Fixed bad \n parsing
-rw-r--r--src/llex.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/llex.js b/src/llex.js
index bf7463c..96e9e00 100644
--- a/src/llex.js
+++ b/src/llex.js
@@ -452,7 +452,7 @@ const read_string = function(ls, del, seminfo) {
case 'x': c = readhexaesc(ls); will = 'read_save'; break;
case 'u': utf8esc(ls); will = 'read_save'; break;
case '\n': case '\r':
- inclinenumber(ls); c = '\n'; will = 'read_save'; break;
+ inclinenumber(ls); c = '\n'; will = 'only_save'; break;
case '\\': case '\"': case '\'':
c = ls.current; will = 'read_save'; break;
case -1: will = 'read_save'; break; /* will raise an error next loop */