diff options
| author | Jeroen van Rijn <Kelimion@users.noreply.github.com> | 2022-09-01 18:30:26 +0200 |
|---|---|---|
| committer | Jeroen van Rijn <Kelimion@users.noreply.github.com> | 2022-09-01 18:30:26 +0200 |
| commit | 01e8668357d0d7399b06a16157ca522f5c1385fa (patch) | |
| tree | 53cbdd701190928c5c1b96c159f463a48d373c76 /src/check_expr.cpp | |
| parent | 0f3cebd2b7dee02368cbdb8f92e6fb21a5a91321 (diff) | |
| parent | 000861cba8ab5c966c60b3a3869d91e98ad09ddc (diff) | |
Merge branch 'master' into sysinfo
Diffstat (limited to 'src/check_expr.cpp')
| -rw-r--r-- | src/check_expr.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/check_expr.cpp b/src/check_expr.cpp index 9c2d20781..54dc081cf 100644 --- a/src/check_expr.cpp +++ b/src/check_expr.cpp @@ -8769,7 +8769,10 @@ ExprKind check_selector_call_expr(CheckerContext *c, Operand *o, Ast *node, Type Ast *first_arg = x.expr->SelectorExpr.expr; GB_ASSERT(first_arg != nullptr); - first_arg->state_flags |= StateFlag_SelectorCallExpr; + Entity *e = entity_of_node(se->expr); + if (!(e != nullptr && (e->kind == Entity_Procedure || e->kind == Entity_ProcGroup))) { + first_arg->state_flags |= StateFlag_SelectorCallExpr; + } Type *pt = base_type(x.type); GB_ASSERT(pt->kind == Type_Proc); |