From 9b5b6b110bb80f8530dd7ca4e0cc9eb3236d8ad7 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Sun, 5 Oct 2025 16:30:21 -0400 Subject: Fix typechecking issue --- src/compile/expressions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/compile') diff --git a/src/compile/expressions.c b/src/compile/expressions.c index 4e6c720f..5ec90191 100644 --- a/src/compile/expressions.c +++ b/src/compile/expressions.c @@ -12,7 +12,7 @@ public Text_t compile_maybe_incref(env_t *env, ast_t *ast, type_t *t) { if (is_idempotent(ast) && can_be_mutated(env, ast)) { - type_t *actual = get_type(env, ast); + type_t *actual = get_type(with_enum_scope(env, t), ast); if (t->tag == ListType && type_eq(t, actual)) return Texts("LIST_COPY(", compile_to_type(env, ast, t), ")"); else if (t->tag == TableType && type_eq(t, actual)) return Texts("TABLE_COPY(", compile_to_type(env, ast, t), ")"); -- cgit v1.2.3