From f8aa60e4c1fa5137c18099ba854b148a0f8d6304 Mon Sep 17 00:00:00 2001 From: Gary Talent Date: Fri, 30 Aug 2024 19:44:15 -0500 Subject: [PATCH] [ox/std] Fix itoa result length calculation --- deps/ox/src/ox/std/istring.hpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/deps/ox/src/ox/std/istring.hpp b/deps/ox/src/ox/std/istring.hpp index 8c1d996c..7ffee5e4 100644 --- a/deps/ox/src/ox/std/istring.hpp +++ b/deps/ox/src/ox/std/istring.hpp @@ -234,12 +234,16 @@ constexpr auto itoa(Integer v) noexcept { switch (sizeof(Integer)) { case 1: out = 3; + break; case 2: out = 5; + break; case 4: out = 10; + break; case 8: out = 21; + break; } return out + ox::is_signed_v; }();