From e2dd379fea09f54a2c61e1f2b61c1652f5ec4488 Mon Sep 17 00:00:00 2001 From: koniifer Date: Tue, 17 Dec 2024 02:10:30 +0000 Subject: [PATCH] minor change --- sysdata/libraries/stn/src/formatters.hb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sysdata/libraries/stn/src/formatters.hb b/sysdata/libraries/stn/src/formatters.hb index cfc418968..c60d2a794 100644 --- a/sysdata/libraries/stn/src/formatters.hb +++ b/sysdata/libraries/stn/src/formatters.hb @@ -90,7 +90,7 @@ format_inner := fn($T: type, v: T, str: ^u8, opts: FormatOptions): uint { return @inline(format_bool, v, str) } else if float(T) { return @inline(format_float, T, v, str, opts.decimal_digits) - } else { + } else if !primitive(T) { i := 0 // name := @nameof(T) // len := string.length(name) @@ -112,8 +112,9 @@ format_inner := fn($T: type, v: T, str: ^u8, opts: FormatOptions): uint { i += 1 } return len + } else { + panic("Unsupported formatter type\0") } - panic("Unsupported formatter type\0") } /* TODO: