summaryrefslogtreecommitdiff
path: root/vm_insnhelper.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-03-12 02:19:13 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-03-12 02:19:13 +0000
commitc28b5723f6615fa429fc5b2606eb1b5b43bdb197 (patch)
tree9b73c93fbcc68f9b430e0ffe5c8951b2b50697b7 /vm_insnhelper.c
parentab9e4d11a35818b0001f749476f83beee3138da8 (diff)
vm_insnhelper.c: disable fastpath if splat
* vm_insnhelper.c (vm_callee_setup_arg): disable fastpath if splat argument, since argc may differ for each calls. [ruby-core:61422] [Bug #9622] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45321 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm_insnhelper.c')
-rw-r--r--vm_insnhelper.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/vm_insnhelper.c b/vm_insnhelper.c
index a7b137c614..6c050440c7 100644
--- a/vm_insnhelper.c
+++ b/vm_insnhelper.c
@@ -1210,7 +1210,9 @@ vm_callee_setup_arg(rb_thread_t *th, rb_call_info_t *ci, const rb_iseq_t *iseq,
(UNLIKELY(ci->flag & VM_CALL_TAILCALL) ?
vm_call_iseq_setup_tailcall :
vm_call_iseq_setup_normal),
- !is_lambda && !(ci->me->flag & NOEX_PROTECTED));
+ (!is_lambda &&
+ !(ci->flag & VM_CALL_ARGS_SPLAT) && /* argc may differ for each calls */
+ !(ci->me->flag & NOEX_PROTECTED)));
}
else {
ci->aux.opt_pc = vm_callee_setup_arg_complex(th, ci, iseq, argv);