diff options
| author | eileencodes <eileencodes@gmail.com> | 2023-10-24 13:17:18 -0400 |
|---|---|---|
| committer | Aaron Patterson <aaron.patterson@gmail.com> | 2023-10-26 11:11:52 -0700 |
| commit | a082e560bb3b875dfcce5ff4743a04e76e008d46 (patch) | |
| tree | 2792062e7e4971bd07bee7bd2813d88a04baae19 /test/ruby | |
| parent | 2573d568848f1dc54e6fb4d9ce203d75cc31fc3d (diff) | |
[PRISM] Implement regex encoding flags
Added the correct encoding to the allocated regex. This required making
a new method to set the encoding and pass that to `rb_enc_reg_new`
instead of `rb_reg_new`. The former `rb_reg_new` would set the encoding
to ASCII8BIT regardless of encoding flag.
Diffstat (limited to 'test/ruby')
| -rw-r--r-- | test/ruby/test_compile_prism.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/ruby/test_compile_prism.rb b/test/ruby/test_compile_prism.rb index b62bac4132..60b669eb0e 100644 --- a/test/ruby/test_compile_prism.rb +++ b/test/ruby/test_compile_prism.rb @@ -390,6 +390,14 @@ module Prism assert_prism_eval('/pit/mx') assert_prism_eval('/pit/xi') assert_prism_eval('/pit/ixm') + + assert_prism_eval('/pit/u') + assert_prism_eval('/pit/e') + assert_prism_eval('/pit/s') + assert_prism_eval('/pit/n') + + assert_prism_eval('/pit/me') + assert_prism_eval('/pit/ne') end def test_StringConcatNode |
