diff --git a/include/boost/int128/string.hpp b/include/boost/int128/string.hpp index b75d3332..eba64a0f 100644 --- a/include/boost/int128/string.hpp +++ b/include/boost/int128/string.hpp @@ -20,9 +20,9 @@ namespace int128 { template auto to_string(const T& value) -> std::enable_if_t<(std::is_same::value || std::is_same::value), std::string> { - char buffer[64U] {}; + char buffer[64]; const auto last {detail::mini_to_chars(buffer, value, 10, false)}; - return std::string{last}; + return std::string{last, buffer + sizeof(buffer)}; } } // namespace int128