diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2025-09-21 15:14:37 -0400 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2025-09-21 15:14:37 -0400 |
| commit | f5612e38183dc20d18f207f8ab055574a4d93ad0 (patch) | |
| tree | c2caf5a0311b6d9fd0fbd4c08493dac5981088be /src/compile/types.c | |
| parent | 7f6683269ce689a83b9c6e1fae15e0cc60351095 (diff) | |
Bugfixes for anonymous enums, code cleanup to remove type_to_string(),
and changed it so anonymous enums show up in doctests with their full
type instead of `enum$20`
Diffstat (limited to 'src/compile/types.c')
| -rw-r--r-- | src/compile/types.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/compile/types.c b/src/compile/types.c index f6f276a5..6b6f48f8 100644 --- a/src/compile/types.c +++ b/src/compile/types.c @@ -79,7 +79,7 @@ Text_t compile_type(type_t *t) { DeclareMatch(s, nonnull, StructType); return namespace_name(s->env, s->env->namespace->parent, Texts("$Optional", s->name, "$$type")); } - default: compiler_err(NULL, NULL, NULL, "Optional types are not supported for: ", type_to_str(t)); + default: compiler_err(NULL, NULL, NULL, "Optional types are not supported for: ", type_to_text(t)); } } case TypeInfoType: return Text("TypeInfo_t"); @@ -147,7 +147,7 @@ Text_t compile_type_info(type_t *t) { case TypeInfoType: return Texts("Type$info(", quoted_text(type_to_text(Match(t, TypeInfoType)->type)), ")"); case MemoryType: return Text("&Memory$info"); case VoidType: return Text("&Void$info"); - default: compiler_err(NULL, 0, 0, "I couldn't convert to a type info: ", type_to_str(t)); + default: compiler_err(NULL, 0, 0, "I couldn't convert to a type info: ", type_to_text(t)); } return EMPTY_TEXT; } |
