aboutsummaryrefslogtreecommitdiff
path: root/src/check_expr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/check_expr.cpp')
-rw-r--r--src/check_expr.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/check_expr.cpp b/src/check_expr.cpp
index ac6f22e6d..f23c47a2e 100644
--- a/src/check_expr.cpp
+++ b/src/check_expr.cpp
@@ -4021,6 +4021,9 @@ bool check_builtin_procedure(CheckerContext *c, Operand *operand, Ast *call, i32
mode = Addressing_Value;
}
}
+ if (operand->mode == Addressing_Type && mode != Addressing_Constant) {
+ mode = Addressing_Invalid;
+ }
if (mode == Addressing_Invalid) {
gbString t = type_to_string(operand->type);