diff options
author | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-06-02 18:44:33 +0000 |
---|---|---|
committer | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-06-02 18:44:33 +0000 |
commit | 284d7463924b313f12da8de5184af3407c3612ac (patch) | |
tree | 84e55024358897290c86dbadece8253a128fc49e /vm_insnhelper.c | |
parent | 233f7d09e3b5a46917023da7b152b5062036e25a (diff) |
* vm_insnhelper.c (vm_yield_setup_block_args): partially revert r41019.
The code is not useless.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41041 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm_insnhelper.c')
-rw-r--r-- | vm_insnhelper.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/vm_insnhelper.c b/vm_insnhelper.c index 5a3a14d5ac..86f2d07cd8 100644 --- a/vm_insnhelper.c +++ b/vm_insnhelper.c @@ -2211,6 +2211,9 @@ vm_yield_setup_block_args(rb_thread_t *th, const rb_iseq_t * iseq, MEMCPY(argv, RARRAY_PTR(ary), VALUE, argc); } + else { + argv[0] = arg0; /* rb_check_array_type(arg0) may change argv */ + } /* keyword argument */ if (iseq->arg_keyword != -1) { |