summaryrefslogtreecommitdiff
path: root/bootstraptest/test_yjit.rb
diff options
context:
space:
mode:
Diffstat (limited to 'bootstraptest/test_yjit.rb')
-rw-r--r--bootstraptest/test_yjit.rb13
1 files changed, 12 insertions, 1 deletions
diff --git a/bootstraptest/test_yjit.rb b/bootstraptest/test_yjit.rb
index 568cc583b1..b064bcdde7 100644
--- a/bootstraptest/test_yjit.rb
+++ b/bootstraptest/test_yjit.rb
@@ -3585,7 +3585,7 @@ assert_equal 'true', %q{
1.send(:==, 1, *[])
}
-# Test send with splat to a cfunc
+# Test empty splat with cfunc
assert_equal '2', %q{
def foo
Integer.sqrt(4, *[])
@@ -3594,3 +3594,14 @@ assert_equal '2', %q{
foo
foo
}
+
+# Test non-empty splat with cfunc
+assert_equal 'Hello World', %q{
+ def bar
+ args = ["Hello "]
+ greeting = "World"
+ greeting.insert(0, *args)
+ greeting
+ end
+ bar
+}