diff options
| author | Michael <132351311+perogycook@users.noreply.github.com> | 2023-11-26 00:00:47 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-11-26 00:00:47 -0700 |
| commit | 9300c99d654448e4ee353caeac5825a6995ea28e (patch) | |
| tree | 2c95d759e62e77f120cd21878adaba1bea566610 /src/check_expr.cpp | |
| parent | 9366bf44a69af7a251a8f96938ae5c9931941c25 (diff) | |
| parent | e8e350144374957cb96d4a38411deba434c93a1d (diff) | |
Merge branch 'odin-lang:master' into raylib5
Diffstat (limited to 'src/check_expr.cpp')
| -rw-r--r-- | src/check_expr.cpp | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/check_expr.cpp b/src/check_expr.cpp index 5a8b57df6..71accfb81 100644 --- a/src/check_expr.cpp +++ b/src/check_expr.cpp @@ -2339,7 +2339,7 @@ gb_internal void check_unary_expr(CheckerContext *c, Operand *o, Token op, Ast * ast_node(ue, UnaryExpr, node); if (ast_node_expect(ue->expr, Ast_IndexExpr)) { ast_node(ie, IndexExpr, ue->expr); - Type *soa_type = type_of_expr(ie->expr); + Type *soa_type = type_deref(type_of_expr(ie->expr)); GB_ASSERT(is_type_soa_struct(soa_type)); o->type = alloc_type_soa_pointer(soa_type); } else { @@ -5606,9 +5606,6 @@ gb_internal CallArgumentError check_call_arguments_internal(CheckerContext *c, A for (isize i = 0; i < pt->param_count; i++) { if (!visited[i]) { Entity *e = pt->params->Tuple.variables[i]; - if (is_blank_ident(e->token)) { - continue; - } if (e->kind == Entity_Variable) { if (e->Variable.param_value.kind != ParameterValue_Invalid) { ordered_operands[i].mode = Addressing_Value; @@ -7428,7 +7425,7 @@ gb_internal bool check_set_index_data(Operand *o, Type *t, bool indirection, i64 *max_count = t->Struct.soa_count; } o->type = t->Struct.soa_elem; - if (o->mode == Addressing_SoaVariable || o->mode == Addressing_Variable) { + if (o->mode == Addressing_SoaVariable || o->mode == Addressing_Variable || indirection) { o->mode = Addressing_SoaVariable; } else { o->mode = Addressing_Value; |