aboutsummaryrefslogtreecommitdiff
path: root/src/check_expr.cpp
diff options
context:
space:
mode:
authorgingerBill <gingerBill@users.noreply.github.com>2025-09-26 14:13:05 +0100
committerGitHub <noreply@github.com>2025-09-26 14:13:05 +0100
commit62a03f118ee77b94319a40bee494494d88e6fc31 (patch)
treef61ab74d8ec008864222a60376bea9c6c72ccbeb /src/check_expr.cpp
parentaf097f6ea1ee48740406594b5407ef4c8c478904 (diff)
parent654c5b2c0662934c5965cef483a23e58a3c8ea3f (diff)
Merge pull request #5689 from slowhei/master
Improve type inferencing of literals when calling proc groups
Diffstat (limited to 'src/check_expr.cpp')
-rw-r--r--src/check_expr.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/check_expr.cpp b/src/check_expr.cpp
index 71d0244d3..fdc3bc181 100644
--- a/src/check_expr.cpp
+++ b/src/check_expr.cpp
@@ -7007,6 +7007,10 @@ gb_internal CallArgumentData check_call_arguments_proc_group(CheckerContext *c,
array_unordered_remove(&procs, proc_index);
continue;
}
+ if (!pt->Proc.variadic && max_arg_count != ISIZE_MAX && param_count < max_arg_count) {
+ array_unordered_remove(&procs, proc_index);
+ continue;
+ }
proc_index++;
}
}