prepare for OP_TAILCALL

This commit is contained in:
Yukihiro Matsumoto
2012-07-05 01:40:23 +09:00
parent c4208a413d
commit ca930538ea
2 changed files with 6 additions and 1 deletions
+5
View File
@@ -2149,6 +2149,11 @@ codedump(mrb_state *mrb, int n)
mrb_sym2name(mrb, irep->syms[GETARG_B(c)]),
GETARG_C(c));
break;
case OP_TAILCALL:
printf("OP_TAILCALL\tR%d\t:%s\t%d\n", GETARG_A(c),
mrb_sym2name(mrb, irep->syms[GETARG_B(c)]),
GETARG_C(c));
break;
case OP_SUPER:
printf("OP_SUPER\tR%d\t%d\n", GETARG_A(c),
GETARG_C(c));
+1 -1
View File
@@ -1120,7 +1120,7 @@ mrb_run(mrb_state *mrb, struct RProc *proc, mrb_value self)
/* replace callinfo */
mrb->ci = ci = &mrb->ci[-1];
ci = mrb->ci;
ci->mid = mid;
ci->target_class = m->target_class;
ci->argc = n;