Remove scope field from Ast

This commit is contained in:
gingerBill
2021-11-14 15:22:40 +00:00
parent 3f038428a7
commit f47311f2f6
6 changed files with 67 additions and 30 deletions

View File

@@ -1302,9 +1302,6 @@ void check_proc_body(CheckerContext *ctx_, Token token, DeclInfo *decl, Type *ty
Type *t = base_type(type_deref(e->type));
if (t->kind == Type_Struct) {
Scope *scope = t->Struct.scope;
if (scope == nullptr) {
scope = scope_of_node(t->Struct.node);
}
GB_ASSERT(scope != nullptr);
for_array(i, scope->elements.entries) {
Entity *f = scope->elements.entries[i].value;