mirror of
https://github.com/Ed94/Odin.git
synced 2026-06-20 04:35:00 -07:00
Number fields within procedures with a depth-first numbering system
This commit is contained in:
@@ -358,6 +358,10 @@ gb_internal void check_open_scope(CheckerContext *c, Ast *node) {
|
||||
scope->flags |= ScopeFlag_Type;
|
||||
break;
|
||||
}
|
||||
if (c->decl && c->decl->proc_lit) {
|
||||
// Number the scopes within a procedure body depth-first
|
||||
scope->index = c->decl->scope_index++;
|
||||
}
|
||||
c->scope = scope;
|
||||
c->state_flags |= StateFlag_bounds_check;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user