diff options
| author | gingerBill <bill@gingerbill.org> | 2022-02-04 22:45:13 +0000 |
|---|---|---|
| committer | gingerBill <bill@gingerbill.org> | 2022-02-04 22:45:13 +0000 |
| commit | d5384c5aa4d823fbd527fb82e9eb5559b4266dfd (patch) | |
| tree | 8886c71e94e1ceebef74b88aa7a4b3fa3f1ec601 /src/check_expr.cpp | |
| parent | 3a81f2ab898d537bba51b9ea81e047652112574e (diff) | |
Only check idents in the alias (of alias)+ problem
Diffstat (limited to 'src/check_expr.cpp')
| -rw-r--r-- | src/check_expr.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/check_expr.cpp b/src/check_expr.cpp index e1c9bde84..d51444b4d 100644 --- a/src/check_expr.cpp +++ b/src/check_expr.cpp @@ -4082,11 +4082,11 @@ bool is_entity_declared_for_selector(Entity *entity, Scope *import_scope, bool * } // NOTE(bill, 2022-02-03): see `check_const_decl` for why it exists reasoning -Entity *check_entity_from_ident_or_selector(CheckerContext *c, Ast *node) { +Entity *check_entity_from_ident_or_selector(CheckerContext *c, Ast *node, bool ident_only) { if (node->kind == Ast_Ident) { String name = node->Ident.token.string; return scope_lookup(c->scope, name); - } else if (node->kind == Ast_SelectorExpr) { + } else if (!ident_only) if (node->kind == Ast_SelectorExpr) { ast_node(se, SelectorExpr, node); if (se->token.kind == Token_ArrowRight) { return nullptr; |