should care about the case that given arguments are less then mandatory formal...

should care about the case that given arguments are less then mandatory formal arguments and optional arguments exist; close #2144
parent b1ec92f7
......@@ -1303,7 +1303,7 @@ RETRY_TRY_BLOCK:
if (r) {
regs[m1+o+1] = mrb_ary_new_capa(mrb, 0);
}
if (o == 0) pc++;
if (o == 0 || argc < m1+m2) pc++;
else
pc += argc - m1 - m2 + 1;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment