From 0afe6cb08f97a2fdbfb945f8b5685a5fe79fa184 Mon Sep 17 00:00:00 2001 From: ko1 Date: Sat, 7 Jul 2007 06:34:40 +0000 Subject: * insnhelper.ci (vm_yield_setup_args), vm.c, insns.def: fix to pass nil as block parameter to yielded block. [ruby-dev:31147] * bootstraptest/test_block.rb: add a test for above. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12718 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- bootstraptest/test_block.rb | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'bootstraptest/test_block.rb') diff --git a/bootstraptest/test_block.rb b/bootstraptest/test_block.rb index e20f5937d7..21d13439ad 100644 --- a/bootstraptest/test_block.rb +++ b/bootstraptest/test_block.rb @@ -335,3 +335,11 @@ assert_equal %q{[1, nil]}, %q{ [i, j] } } + +# [ruby-dev:31147] +assert_equal 'nil', %q{ + def m + yield + end + m{|&b| b}.inspect +} -- cgit v1.2.3