mirror of
https://github.com/odin-lang/Odin.git
synced 2026-05-25 05:09:53 +00:00
Minor improve to check if the entity was already there
This commit is contained in:
@@ -5492,6 +5492,10 @@ gb_internal Entity *check_entity_from_ident_or_selector(CheckerContext *c, Ast *
|
||||
return e;
|
||||
}
|
||||
} else */if (node->kind == Ast_Ident) {
|
||||
Entity *e = node->Ident.entity.load();
|
||||
if (e != nullptr) {
|
||||
return e;
|
||||
}
|
||||
String name = node->Ident.token.string;
|
||||
return scope_lookup(c->scope, node->Ident.interned, node->Ident.hash);
|
||||
} else if (!ident_only) if (node->kind == Ast_SelectorExpr) {
|
||||
|
||||
Reference in New Issue
Block a user