diff --git a/libc/src/__support/float_to_string.h b/libc/src/__support/float_to_string.h --- a/libc/src/__support/float_to_string.h +++ b/libc/src/__support/float_to_string.h @@ -389,8 +389,8 @@ cpp::UInt val(large); // TODO: Find a better way to force __uint128_t to be UInt<128> cpp::UInt wide_mant(0); - wide_mant[0] = static_cast(mantissa & (uint64_t(-1))); - wide_mant[1] = static_cast(mantissa >> 64); + wide_mant[0] = static_cast(mantissa & UINT64_MAX); + wide_mant[1] = static_cast(mantissa >> 64); val = (val * wide_mant) >> shift_amount; return static_cast(