mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-05 07:08:48 +00:00
@@ -201,6 +201,8 @@ gb_internal void lb_open_scope(lbProcedure *p, Scope *s) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
GB_ASSERT(s != nullptr);
|
||||||
|
p->curr_scope = s;
|
||||||
p->scope_index += 1;
|
p->scope_index += 1;
|
||||||
array_add(&p->scope_stack, s);
|
array_add(&p->scope_stack, s);
|
||||||
|
|
||||||
@@ -221,6 +223,10 @@ gb_internal void lb_close_scope(lbProcedure *p, lbDeferExitKind kind, lbBlock *b
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (p->curr_scope) {
|
||||||
|
p->curr_scope = p->curr_scope->parent;
|
||||||
|
}
|
||||||
|
|
||||||
p->scope_index -= 1;
|
p->scope_index -= 1;
|
||||||
array_pop(&p->scope_stack);
|
array_pop(&p->scope_stack);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user