diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2024-02-17 17:29:56 -0500 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2024-02-17 17:29:56 -0500 |
| commit | dbd7502a1dcee6b99434f39393cb356efa542ddc (patch) | |
| tree | b8ae469719326ba2c3daf019e545c4713ab0235f /builtins/types.c | |
| parent | 5c49314ed4380f4e12a05888f635caa9af4a7cf4 (diff) | |
Fix up some builtins
Diffstat (limited to 'builtins/types.c')
| -rw-r--r-- | builtins/types.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/builtins/types.c b/builtins/types.c index a33c17f2..24c4de92 100644 --- a/builtins/types.c +++ b/builtins/types.c @@ -19,9 +19,9 @@ public CORD Type__cord(void *type_namespace, bool colorize, const TypeInfo *type { (void)type_namespace; if (!colorize) - return CORD_from_char_star(type->name); + return type->TypeInfoInfo.type_str; CORD c; - CORD_sprintf(&c, "\x1b[36;1m%s\x1b[m", type->name); + CORD_sprintf(&c, "\x1b[36;1m%s\x1b[m", type->TypeInfoInfo.type_str); return c; } @@ -29,7 +29,6 @@ public struct { TypeInfo type; } TypeInfo_type = { .type={ - .name="TypeInfo", .size=sizeof(TypeInfo), .align=alignof(TypeInfo), .tag=CustomInfo, @@ -39,15 +38,15 @@ public struct { public struct { TypeInfo type; -} Void_type = {.type={.name="Void", .size=0, .align=0}}; +} Void_type = {.type={.size=0, .align=0}}; public struct { TypeInfo type; -} Abort_type = {.type={.name="Abort", .size=0, .align=0}}; +} Abort_type = {.type={.size=0, .align=0}}; public CORD Func__cord(const void *fn, bool colorize, const TypeInfo *type) { (void)fn; - CORD c = type->name; + CORD c = type->TypeInfoInfo.type_str; if (colorize) CORD_sprintf(&c, "\x1b[32;1m%r\x1b[m", c); return c; |
