summaryrefslogtreecommitdiff
path: root/src/compiler/ast-tree.c
diff options
context:
space:
mode:
authorA404M <ahmadmahmoudiprogrammer@gmail.com>2025-04-30 03:00:52 +0330
committerA404M <ahmadmahmoudiprogrammer@gmail.com>2025-04-30 03:00:52 +0330
commit8655602aa44c4ff65b4c6839ba804e4621e10338 (patch)
tree98c4ac4df38811859525624805d927af49510c56 /src/compiler/ast-tree.c
parent141e7fb5fe016bc754d600159b479f7e11b407d8 (diff)
add operators neededHEADmaster
Diffstat (limited to 'src/compiler/ast-tree.c')
-rw-r--r--src/compiler/ast-tree.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/compiler/ast-tree.c b/src/compiler/ast-tree.c
index d85f99d..676fafb 100644
--- a/src/compiler/ast-tree.c
+++ b/src/compiler/ast-tree.c
@@ -4659,7 +4659,6 @@ bool setTypesOperatorInfix(AstTree *tree, AstTreeSetTypesHelper _helper,
AstTreeVariable *variable =
setTypesFindVariable(str, str + str_size, helper, &functionCall);
if (variable == NULL) {
- printError(tree->str_begin, tree->str_end, "Can't find operator");
return false;
}
@@ -5756,6 +5755,11 @@ AstTreeVariable *setTypesFindVariable(const char *name_begin,
CONTINUE_OUTER:
}
}
+ if (variable == NULL) {
+ printError(name_begin, name_end, "No candidates found for %.*s",
+ (int)(name_end - name_begin), name_begin);
+ return NULL;
+ }
return variable;
}