diff options
author | Adam Hess <HParker@github.com> | 2023-10-16 05:22:07 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-10-16 05:22:07 -0700 |
commit | 6e88b72d7bdac5d959d525df6e3804f4c1eaf9ce (patch) | |
tree | a1c87fa7be8a197f31cc12cf60d3caf6cb45977f /test | |
parent | 06a4011964e02000f44097b12435b49957a12f02 (diff) | |
download | ruby-6e88b72d7bdac5d959d525df6e3804f4c1eaf9ce.tar.gz |
[PRISM] prevent underflow on popped splatarray (#8657)
prevent underflow on popped splatarray
This only emits the splat array node when not popped
Diffstat (limited to 'test')
-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 f94bd603ca..763ac044ba 100644 --- a/test/ruby/test_compile_prism.rb +++ b/test/ruby/test_compile_prism.rb @@ -325,6 +325,10 @@ module Prism test_prism_eval("[ Prism: [:b, :c]]") end + def test_SplatNode + test_prism_eval("*b = []") + end + ############################################################################ # Jumps # ############################################################################ |