aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuillaume Chatelet <gchatelet@google.com>2023-12-08 18:12:35 +0100
committerGitHub <noreply@github.com>2023-12-08 18:12:35 +0100
commita539a090009378ecfcfbfaaa280eeac8f5b9d695 (patch)
treefe6a129662c627c1b56f33b1ad50ee8bf9fb8e23
parentf7250179e22ce4aab96166493b27223fa28c2181 (diff)
downloadllvm-a539a090009378ecfcfbfaaa280eeac8f5b9d695.zip
llvm-a539a090009378ecfcfbfaaa280eeac8f5b9d695.tar.gz
llvm-a539a090009378ecfcfbfaaa280eeac8f5b9d695.tar.bz2
[libc] Fix missing UInt initialization (#74869)
Fix forward for #74862
-rw-r--r--libc/src/__support/float_to_string.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/libc/src/__support/float_to_string.h b/libc/src/__support/float_to_string.h
index 9f24352..92dd2e8 100644
--- a/libc/src/__support/float_to_string.h
+++ b/libc/src/__support/float_to_string.h
@@ -653,7 +653,7 @@ FloatToString<long double>::get_positive_block(int block_index) {
// shift_amount = -(c0 - exponent) = c_0 + 16 * ceil(exponent/16) - exponent
- cpp::UInt<MID_INT_SIZE> val;
+ cpp::UInt<MID_INT_SIZE> val(0);
#ifdef LIBC_COPT_FLOAT_TO_STR_USE_MEGA_LONG_DOUBLE_TABLE
// ------------------------------ TABLE MODE -------------------------------
const int32_t SHIFT_CONST = TABLE_SHIFT_CONST;