aboutsummaryrefslogtreecommitdiff
path: root/src/check_expr.cpp
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2025-02-21 12:38:40 +0000
committergingerBill <bill@gingerbill.org>2025-02-21 12:38:40 +0000
commit748a771dad72c912b48ad2601e459078c7fd1db7 (patch)
tree0a370be1a34cdae43d803272070bf5296e61635d /src/check_expr.cpp
parent55e0f945a1ece468bedf68737a0cb415c3bc5de9 (diff)
Allow indirection for swizzling on procedure parameters
Diffstat (limited to 'src/check_expr.cpp')
-rw-r--r--src/check_expr.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/check_expr.cpp b/src/check_expr.cpp
index f0021e67f..bd1c34044 100644
--- a/src/check_expr.cpp
+++ b/src/check_expr.cpp
@@ -5509,6 +5509,11 @@ gb_internal Entity *check_selector(CheckerContext *c, Operand *operand, Ast *nod
case Addressing_SwizzleVariable:
operand->mode = Addressing_SwizzleVariable;
break;
+ case Addressing_Value:
+ if (is_type_pointer(original_type)) {
+ operand->mode = Addressing_SwizzleVariable;
+ }
+ break;
}
if (array_type->kind == Type_SimdVector) {