From 835eb7e89627eea923bfd57bdacba7065c6b1d4c Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Sun, 15 Sep 2024 16:42:42 -0400 Subject: Add optional:or_exit(...) --- typecheck.c | 1 + 1 file changed, 1 insertion(+) (limited to 'typecheck.c') diff --git a/typecheck.c b/typecheck.c index 933f1f90..5d74a3cd 100644 --- a/typecheck.c +++ b/typecheck.c @@ -845,6 +845,7 @@ type_t *get_type(env_t *env, ast_t *ast) type_t *nonnull = Match(self_value_t, OptionalType)->type; if (streq(call->name, "or_else")) return nonnull; else if (streq(call->name, "or_fail")) return nonnull; + else if (streq(call->name, "or_exit")) return nonnull; code_err(ast, "There is no '%s' method for optional %T values", call->name, nonnull); } default: { -- cgit v1.2.3