diff options
author | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2017-03-11 11:06:39 +0000 |
---|---|---|
committer | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2017-03-11 11:06:39 +0000 |
commit | 927c116d0c098a28082a22b15d7daa26ed560591 (patch) | |
tree | 7ec3a5d993bafd5d8f9082ec3b52ee7826322851 /vm_eval.c | |
parent | 7b560e31be52b880711204df6992c84185eac6cf (diff) |
merge revision(s) 57194: [Backport #13074]
vm_eval.c: Symbol#to_proc and instance_exec
* vm_eval.c (yield_under): should evaluate the proc on the first
argument. [ruby-core:78839] [Bug #13074]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_4@57834 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm_eval.c')
-rw-r--r-- | vm_eval.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -1591,7 +1591,8 @@ yield_under(VALUE under, VALUE self, int argc, const VALUE *argv) block_handler = vm_proc_to_block_handler(VM_BH_TO_PROC(block_handler)); goto again; case block_handler_type_symbol: - return rb_sym_proc_call(SYM2ID(VM_BH_TO_SYMBOL(block_handler)), 1, &self, VM_BLOCK_HANDLER_NONE); + return rb_sym_proc_call(SYM2ID(VM_BH_TO_SYMBOL(block_handler)), + argc, argv, VM_BLOCK_HANDLER_NONE); } new_captured.self = self; |