From f9cc44f145dd0c165010765791054666f973eff3 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Tue, 20 Feb 2024 13:06:03 -0500 Subject: Fixing up enums --- types.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'types.c') diff --git a/types.c b/types.c index 6a6f15ca..34ef4a33 100644 --- a/types.c +++ b/types.c @@ -486,7 +486,7 @@ type_t *get_field_type(type_t *t, const char *field_name) auto e = Match(t, EnumType); for (tag_t *tag = e->tags; tag; tag = tag->next) { if (streq(field_name, tag->name)) - return tag->type; + return Type(PointerType, .pointed=tag->type, .is_optional=true, .is_readonly=true); } return NULL; } -- cgit v1.2.3