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.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/check_expr.cpp b/src/check_expr.cpp
index 09c2edbb3..863e0892b 100644
--- a/src/check_expr.cpp
+++ b/src/check_expr.cpp
@@ -3586,7 +3586,7 @@ bool check_builtin_procedure(CheckerContext *c, Operand *operand, Ast *call, i32
case BuiltinProc_abs: {
// abs :: proc(n: numeric) -> numeric
- if (!is_type_numeric(operand->type)) {
+ if (!(is_type_numeric(operand->type) && !is_type_array(operand->type))) {
gbString type_str = type_to_string(operand->type);
error(call, "Expected a numeric type to 'abs', got '%s'", type_str);
gb_string_free(type_str);