diff options
author | Kevin Newton <kddnewton@gmail.com> | 2023-09-28 10:18:43 -0400 |
---|---|---|
committer | Kevin Newton <kddnewton@gmail.com> | 2023-09-28 14:11:34 -0400 |
commit | 5a376f0f71e8ecc8a6cc0b9f35e63a8367275988 (patch) | |
tree | 0df85eb75767314b37eaf3afaa0cff1c9f17de67 /test | |
parent | d3574c117a637a4456aa3ee78e24d8df510b9355 (diff) | |
download | ruby-5a376f0f71e8ecc8a6cc0b9f35e63a8367275988.tar.gz |
Consolidate regexp options, interpolated match last line
Diffstat (limited to 'test')
-rw-r--r-- | test/ruby/test_compile_prism.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/test/ruby/test_compile_prism.rb b/test/ruby/test_compile_prism.rb index 2116218c69..d5a00a2a8e 100644 --- a/test/ruby/test_compile_prism.rb +++ b/test/ruby/test_compile_prism.rb @@ -245,8 +245,13 @@ module Prism test_prism_eval('$pit = 1; "#$pit"') end + def test_InterpolatedMatchLastLineNode + test_prism_eval("$pit = '.oo'; if /\#$pit/mix; end") + end + def test_InterpolatedRegularExpressionNode test_prism_eval('$pit = 1; /1 #$pit 1/') + test_prism_eval('$pit = 1; /#$pit/i') test_prism_eval('/1 #{1 + 2} 1/') test_prism_eval('/1 #{"2"} #{1 + 2} 1/') end |