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/bool.c | |
| parent | 5c49314ed4380f4e12a05888f635caa9af4a7cf4 (diff) | |
Fix up some builtins
Diffstat (limited to 'builtins/bool.c')
| -rw-r--r-- | builtins/bool.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/builtins/bool.c b/builtins/bool.c index 7614113f..e3d1f7ef 100644 --- a/builtins/bool.c +++ b/builtins/bool.c @@ -18,6 +18,7 @@ extern const void *SSS_HASH_VECTOR; static CORD Bool_cord(const bool *b, bool colorize, const TypeInfo *type) { (void)type; + if (!b) return "Bool"; if (colorize) return *b ? "\x1b[35myes\x1b[m" : "\x1b[35mno\x1b[m"; else @@ -28,7 +29,6 @@ public struct { TypeInfo type; } Bool_type = { .type={ - .name="Bool", .size=sizeof(bool), .align=alignof(bool), .tag=CustomInfo, |
