diff options
| author | Jemma Issroff <jemmaissroff@gmail.com> | 2023-11-20 11:47:54 -0500 |
|---|---|---|
| committer | Jemma Issroff <jemmaissroff@gmail.com> | 2023-11-20 12:12:34 -0800 |
| commit | c5d5929443d58d72cb9688a9fac6487ce17c1e9d (patch) | |
| tree | ca54b4b69c9bd62609e2d8a6662b4551cd71be24 /test/ruby | |
| parent | 307a5cb20b3e34f6a3bd240e70ddc26bd268ace3 (diff) | |
[PRISM] Don't pop args to YieldNode
Diffstat (limited to 'test/ruby')
| -rw-r--r-- | test/ruby/test_compile_prism.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/ruby/test_compile_prism.rb b/test/ruby/test_compile_prism.rb index 269b6953ca..81b62cf832 100644 --- a/test/ruby/test_compile_prism.rb +++ b/test/ruby/test_compile_prism.rb @@ -732,6 +732,10 @@ module Prism def test_YieldNode assert_prism_eval("def prism_test_yield_node; yield; end") assert_prism_eval("def prism_test_yield_node; yield 1, 2; end") + + # Test case where there's a call directly after the yield call + assert_prism_eval("def prism_test_yield_node; yield; 1; end") + assert_prism_eval("def prism_test_yield_node; yield 1, 2; 1; end") end ############################################################################ |
