mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
vm.c: vm.c: stack may be reallocated in functions calls; aaa28a5
`mrb_range_new()` also calls VM recursively.
This commit is contained in:
@@ -2819,13 +2819,15 @@ RETRY_TRY_BLOCK:
|
||||
}
|
||||
|
||||
CASE(OP_RANGE_INC, B) {
|
||||
regs[a] = mrb_range_new(mrb, regs[a], regs[a+1], FALSE);
|
||||
mrb_value v = mrb_range_new(mrb, regs[a], regs[a+1], FALSE);
|
||||
regs[a] = v;
|
||||
mrb_gc_arena_restore(mrb, ai);
|
||||
NEXT;
|
||||
}
|
||||
|
||||
CASE(OP_RANGE_EXC, B) {
|
||||
regs[a] = mrb_range_new(mrb, regs[a], regs[a+1], TRUE);
|
||||
mrb_value v = mrb_range_new(mrb, regs[a], regs[a+1], TRUE);
|
||||
regs[a] = v;
|
||||
mrb_gc_arena_restore(mrb, ai);
|
||||
NEXT;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user