aboutsummaryrefslogtreecommitdiff
path: root/src/compile/optionals.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/compile/optionals.c')
-rw-r--r--src/compile/optionals.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/compile/optionals.c b/src/compile/optionals.c
index 75dff935..8cb6af2b 100644
--- a/src/compile/optionals.c
+++ b/src/compile/optionals.c
@@ -48,8 +48,6 @@ Text_t compile_none(type_t *t) {
if (t == NULL) compiler_err(NULL, NULL, NULL, "I can't compile a `none` value with no type");
- if (t == PATH_TYPE) return Text("NONE_PATH");
-
switch (t->tag) {
case BigIntType: return Text("NONE_INT");
case IntType: {
@@ -68,6 +66,7 @@ Text_t compile_none(type_t *t) {
case TableType: return Text("NONE_TABLE");
case TextType: return Text("NONE_TEXT");
case CStringType: return Text("NULL");
+ case PathType: return Text("NONE_PATH");
case PointerType: return Texts("((", compile_type(t), ")NULL)");
case ClosureType: return Text("NONE_CLOSURE");
case NumType: return Text("nan(\"none\")");