mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Modify ci->nregs.
This commit is contained in:
@@ -718,7 +718,12 @@ mrb_run(mrb_state *mrb, struct RProc *proc, mrb_value self)
|
||||
mrb->stack += a;
|
||||
|
||||
if (MRB_PROC_CFUNC_P(m)) {
|
||||
ci->nregs = n + 1;
|
||||
if (n == CALL_MAXARGS) {
|
||||
ci->nregs = 3;
|
||||
}
|
||||
else {
|
||||
ci->nregs = n + 2;
|
||||
}
|
||||
mrb->stack[0] = m->body.func(mrb, recv);
|
||||
mrb->arena_idx = ai;
|
||||
if (mrb->exc) goto L_RAISE;
|
||||
|
||||
Reference in New Issue
Block a user