ruby-changes:12570
From: nobu <ko1@a...>
Date: Sun, 26 Jul 2009 18:27:57 +0900 (JST)
Subject: [ruby-changes:12570] Ruby:r24279 (trunk): * vm_insnhelper.c (vm_call_method): fixed indent.
nobu 2009-07-26 18:27:45 +0900 (Sun, 26 Jul 2009) New Revision: 24279 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=24279 Log: * vm_insnhelper.c (vm_call_method): fixed indent. Modified files: trunk/vm_insnhelper.c Index: vm_insnhelper.c =================================================================== --- vm_insnhelper.c (revision 24278) +++ vm_insnhelper.c (revision 24279) @@ -547,46 +547,45 @@ } } case VM_METHOD_TYPE_OPTIMIZED:{ - switch (me->body.optimize_type) { - case OPTIMIZED_METHOD_TYPE_SEND: { - rb_control_frame_t *reg_cfp = cfp; - rb_num_t i = num - 1; - VALUE sym; + switch (me->body.optimize_type) { + case OPTIMIZED_METHOD_TYPE_SEND: { + rb_control_frame_t *reg_cfp = cfp; + rb_num_t i = num - 1; + VALUE sym; - if (num == 0) { - rb_raise(rb_eArgError, "no method name given"); - } - - sym = TOPN(i); - id = SYMBOL_P(sym) ? SYM2ID(sym) : rb_to_id(sym); - /* shift arguments */ - if (i > 0) { - MEMMOVE(&TOPN(i), &TOPN(i-1), VALUE, i); - } - me = rb_method_entry(CLASS_OF(recv), id); - num -= 1; - DEC_SP(1); - flag |= VM_CALL_FCALL_BIT; - - goto start_method_dispatch; + if (num == 0) { + rb_raise(rb_eArgError, "no method name given"); } - break; - case OPTIMIZED_METHOD_TYPE_CALL: { - rb_proc_t *proc; - int argc = num; - VALUE *argv = ALLOCA_N(VALUE, num); - GetProcPtr(recv, proc); - MEMCPY(argv, cfp->sp - num, VALUE, num); - cfp->sp -= num + 1; - val = rb_vm_invoke_proc(th, proc, proc->block.self, argc, argv, blockptr); + sym = TOPN(i); + id = SYMBOL_P(sym) ? SYM2ID(sym) : rb_to_id(sym); + /* shift arguments */ + if (i > 0) { + MEMMOVE(&TOPN(i), &TOPN(i-1), VALUE, i); } - break; - default: - rb_bug("eval_invoke_method: unsupported optimized method type (%d)", - me->body.optimize_type); + me = rb_method_entry(CLASS_OF(recv), id); + num -= 1; + DEC_SP(1); + flag |= VM_CALL_FCALL_BIT; + + goto start_method_dispatch; } - break; + case OPTIMIZED_METHOD_TYPE_CALL: { + rb_proc_t *proc; + int argc = num; + VALUE *argv = ALLOCA_N(VALUE, num); + GetProcPtr(recv, proc); + MEMCPY(argv, cfp->sp - num, VALUE, num); + cfp->sp -= num + 1; + + val = rb_vm_invoke_proc(th, proc, proc->block.self, argc, argv, blockptr); + break; + } + default: + rb_bug("eval_invoke_method: unsupported optimized method type (%d)", + me->body.optimize_type); + } + break; } default:{ rb_bug("eval_invoke_method: unsupported method type (%d)", me->type); -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/