diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-07-04 23:08:32 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-07-04 23:08:32 +0000 |
commit | 918fefb7f71487770b538336fca0dca8d442d32e (patch) | |
tree | 19f6fec4fd8e2a420fbf9a06e6d899bdb37a3382 /test/ruby/test_proc.rb | |
parent | a82c5ee48b805333f68b613b8eb76cd05e5a0078 (diff) |
* vm_insnhelper.c (vm_yield_setup_block_args): restores the first
arg where is overwritten at funcall. [ruby-core:24139]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23956 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby/test_proc.rb')
-rw-r--r-- | test/ruby/test_proc.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/ruby/test_proc.rb b/test/ruby/test_proc.rb index 8439f8cd6b..e557f185f2 100644 --- a/test/ruby/test_proc.rb +++ b/test/ruby/test_proc.rb @@ -747,4 +747,11 @@ class TestProc < Test::Unit::TestCase assert_match(/^#{ Regexp.quote(__FILE__) }$/, file) assert_equal(source_location_test - 1, lineno) end + + def test_splat_without_respond_to + def (obj = Object.new).respond_to?(m); false end + [obj].each do |a, b| + assert_equal([obj, nil], [a, b], '[ruby-core:24139]') + end + end end |