From 5a376f0f71e8ecc8a6cc0b9f35e63a8367275988 Mon Sep 17 00:00:00 2001 From: Kevin Newton Date: Thu, 28 Sep 2023 10:18:43 -0400 Subject: Consolidate regexp options, interpolated match last line --- test/ruby/test_compile_prism.rb | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'test/ruby') 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 -- cgit v1.2.3