From b2033f6d6d8918ed9ac72468aaa5faf96f8157dd Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Sun, 25 May 2025 16:41:43 -0400 Subject: Optimize codegen for enums: no longer bother with a struct wrapper, but just use a C enum type instead. This will make it easier to use externally defined enums in the future. --- src/types.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/types.h') diff --git a/src/types.h b/src/types.h index 33e54ff5..3b789560 100644 --- a/src/types.h +++ b/src/types.h @@ -157,5 +157,6 @@ PUREFUNC type_t *non_optional(type_t *t); type_t *get_field_type(type_t *t, const char *field_name); PUREFUNC type_t *get_iterated_type(type_t *t); type_t *_make_function_type(type_t *ret, int n, arg_t args[n]); +PUREFUNC bool enum_has_fields(type_t *t); // vim: ts=4 sw=0 et cino=L2,l1,(0,W4,m1,\:0 -- cgit v1.2.3