From 9a6efed42618035a8ab28213f3d9a91fbb19494e Mon Sep 17 00:00:00 2001 From: Maxwell Jeffress Date: Mon, 13 Apr 2026 13:37:42 +1000 Subject: [PATCH 1/2] Band-aid fix for null type --- src/interpreter.c | 3 +++ src/types.c | 3 +++ 2 files changed, 6 insertions(+) diff --git a/src/interpreter.c b/src/interpreter.c index 2b27c01..9d6a5e2 100644 --- a/src/interpreter.c +++ b/src/interpreter.c @@ -225,6 +225,9 @@ void addArgsToGroundFunction(GroundFunction* function, GroundValueType type, cha }; GroundValueType stringToValueType(char* in) { + if (in == NULL) { + return ANY; + } if (strcmp(in, "int") == 0) { return INT; } diff --git a/src/types.c b/src/types.c index 25a03fc..0113943 100644 --- a/src/types.c +++ b/src/types.c @@ -362,6 +362,9 @@ void printGroundArg(GroundArg* ga) { break; } case TYPEREF: { + if (ga->value.refName != NULL) { + printf("-any "); + } printf("-%s", ga->value.refName); break; } From 6bcf9d43c89ed3846c71c5780dea9f352b6e0cb8 Mon Sep 17 00:00:00 2001 From: Maxwell Jeffress Date: Mon, 13 Apr 2026 13:42:08 +1000 Subject: [PATCH 2/2] augh --- src/types.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/types.c b/src/types.c index 0113943..1483cc8 100644 --- a/src/types.c +++ b/src/types.c @@ -362,8 +362,9 @@ void printGroundArg(GroundArg* ga) { break; } case TYPEREF: { - if (ga->value.refName != NULL) { - printf("-any "); + if (ga->value.refName == NULL) { + printf("-any"); + break; } printf("-%s", ga->value.refName); break;