From 076f87361dd4bb6fcafbe5468353dfa7804d3636 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Sun, 29 Sep 2024 20:19:46 -0400 Subject: Support using DateTime() as a constructor --- typecheck.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'typecheck.c') diff --git a/typecheck.c b/typecheck.c index fd0b9d63..fa7ca19c 100644 --- a/typecheck.c +++ b/typecheck.c @@ -756,7 +756,7 @@ type_t *get_type(env_t *env, ast_t *ast) if (fn_type_t->tag == TypeInfoType) { type_t *t = Match(fn_type_t, TypeInfoType)->type; if (t->tag == StructType || t->tag == IntType || t->tag == BigIntType || t->tag == NumType - || t->tag == TextType || t->tag == CStringType) + || t->tag == TextType || t->tag == CStringType || t->tag == DateTimeType) return t; // Constructor code_err(call->fn, "This is not a type that has a constructor"); } -- cgit v1.2.3