summaryrefslogtreecommitdiff
path: root/tnslc/compile/var.tnsl
diff options
context:
space:
mode:
authorKai Gunger <kgunger12@gmail.com>2025-12-08 21:59:55 -0500
committerKai Gunger <kgunger12@gmail.com>2025-12-08 21:59:55 -0500
commit38723762d5e3c61dab16d6e40bc905b53e21baca (patch)
treea8a3211b089f837d78ac5de714cb83b97262c0ea /tnslc/compile/var.tnsl
parent8bb2e3bdb00341dcd8b6fd4d272b2c96a708acb3 (diff)
fix memory issues with type resolution
Diffstat (limited to 'tnslc/compile/var.tnsl')
-rw-r--r--tnslc/compile/var.tnsl6
1 files changed, 5 insertions, 1 deletions
diff --git a/tnslc/compile/var.tnsl b/tnslc/compile/var.tnsl
index 34c101a..69108ce 100644
--- a/tnslc/compile/var.tnsl
+++ b/tnslc/compile/var.tnsl
@@ -122,7 +122,11 @@ struct Var {
_indent(idt)
_printf(" type: \0")
- _printf(self._type`.name)
+ /; if (self._type !== NULL)
+ _printf(self._type`.name)
+ ;; else
+ _printf("(nil)\0")
+ ;/
_printf("\n\0")
_indent(idt)