summaryrefslogtreecommitdiff
path: root/test/ripper
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-03-25 01:07:35 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-03-25 01:07:35 +0000
commite5600caf2c5546c3afc78bba33800cfc97e78eee (patch)
tree9d78c61170f3e164636a4dcd753b0409ff15a3fb /test/ripper
parent8d1dacb2290c4a61a3c92769e5cb1814e09858b4 (diff)
keep line number after unterminated string literal
* parse.y (parser_parse_string): keep line number even after an unterminated string literal. it does not matter in the parser, ripper needs this value after this error. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58080 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ripper')
-rw-r--r--test/ripper/test_scanner_events.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/test/ripper/test_scanner_events.rb b/test/ripper/test_scanner_events.rb
index 7ae58bbda8..8cf7ac1220 100644
--- a/test/ripper/test_scanner_events.rb
+++ b/test/ripper/test_scanner_events.rb
@@ -131,6 +131,8 @@ class TestRipper::ScannerEvents < Test::Unit::TestCase
assert_location %Q["a\nb\r\nc"]
assert_location "print(<<""EOS)\nheredoc\nEOS\n"
assert_location "print(<<-\"EOS\")\nheredoc\n EOS\n"
+ assert_location "'foo'"
+ assert_location "'foo"
end
def assert_location(src)