diff options
Diffstat (limited to 'vm_insnhelper.c')
-rw-r--r-- | vm_insnhelper.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/vm_insnhelper.c b/vm_insnhelper.c index a65ba9129d..84c2ca2ae6 100644 --- a/vm_insnhelper.c +++ b/vm_insnhelper.c @@ -1531,17 +1531,16 @@ vm_call_opt_send(rb_thread_t *th, rb_control_frame_t *reg_cfp, rb_call_info_t *c VALUE exc = make_no_method_exception(rb_eNoMethodError, NULL, ci->recv, rb_long2int(ci->argc), &TOPN(i)); rb_exc_raise(exc); } - ci->mid = idMethodMissing; - th->method_missing_reason = ci->aux.missing_reason = NOEX_VCALL; - } else { - /* shift arguments */ - if (i > 0) { - MEMMOVE(&TOPN(i), &TOPN(i-1), VALUE, i); - } - ci->argc -= 1; - DEC_SP(1); + ci->mid = rb_to_id(sym); + } + + /* shift arguments */ + if (i > 0) { + MEMMOVE(&TOPN(i), &TOPN(i-1), VALUE, i); } ci->me = rb_method_entry_without_refinements(CLASS_OF(ci->recv), ci->mid, &ci->defined_class); + ci->argc -= 1; + DEC_SP(1); ci->flag = VM_CALL_FCALL | VM_CALL_OPT_SEND; |