aboutsummaryrefslogtreecommitdiff
path: root/src/check_expr.cpp
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2024-05-16 16:18:21 +0100
committergingerBill <bill@gingerbill.org>2024-05-16 16:18:21 +0100
commit32245e93a106c5cb1ee9b448789f623a4dbef717 (patch)
tree2504e2ff16b5b42b61aedb2844a3dd9dea4eea0e /src/check_expr.cpp
parent330d6117e356fe961fa7688c918e58c7a6917e9e (diff)
Fix #3514 along with `soa.a[i]` bounds checking
Diffstat (limited to 'src/check_expr.cpp')
-rw-r--r--src/check_expr.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/check_expr.cpp b/src/check_expr.cpp
index c44232dab..c9cfb58be 100644
--- a/src/check_expr.cpp
+++ b/src/check_expr.cpp
@@ -7806,8 +7806,8 @@ gb_internal bool check_set_index_data(Operand *o, Type *t, bool indirection, i64
if (is_type_pointer(original_type) && indirection) {
Type *ptr = base_type(original_type);
- if (ptr->kind == Type_Pointer && o->mode == Addressing_SoaVariable) {
- o->type = ptr->Pointer.elem;
+ if (ptr->kind == Type_MultiPointer && o->mode == Addressing_SoaVariable) {
+ o->type = ptr->MultiPointer.elem;
o->mode = Addressing_Value;
return true;
}