mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
gc.c (mark_context_stack): use SET_NIL_VALUE macro to clear the stack
This commit is contained in:
@@ -538,7 +538,6 @@ static void
|
||||
mark_context_stack(mrb_state *mrb, struct mrb_context *c)
|
||||
{
|
||||
size_t i, e;
|
||||
mrb_value nil;
|
||||
|
||||
if (c->stbase == NULL) return;
|
||||
if (c->ci) {
|
||||
@@ -557,9 +556,8 @@ mark_context_stack(mrb_state *mrb, struct mrb_context *c)
|
||||
}
|
||||
}
|
||||
e = c->stend - c->stbase;
|
||||
nil = mrb_nil_value();
|
||||
for (; i<e; i++) {
|
||||
c->stbase[i] = nil;
|
||||
SET_NIL_VALUE(c->stbase[i]);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user