[libc-commits] [libc] [libc][math] Remove shadowed math::double_eval::LOG_2 (PR #241230)
Hans Wennborg via libc-commits
libc-commits at lists.llvm.org
Wed Nov 11 03:15:33 PST 2026
https://github.com/zmodem created https://github.com/llvm/llvm-project/pull/241230
After #240167 this was shadowed by the LOG_2 in math::double_eval::logf(), causing -Wshadow warnings.
Since the shadowed variable doesn't seem to be used(?), drop it.
>From 6af306ea9d32324ead6811498a2ebe1ce88421f5 Mon Sep 17 00:00:00 2001
From: Hans Wennborg <hans at chromium.org>
Date: Wed, 11 Nov 2026 12:13:28 +0100
Subject: [PATCH] [libc][math] Remove math::double_eval::LOG_2
After #240167 this was shadowed by the LOG_2 in math::double_eval::logf,
causing -Wshadow warnings.
Since the shadowed variable doesn't seem to be used(?), drop it.
---
libc/src/__support/math/exp_utils.h | 9 ---------
1 file changed, 9 deletions(-)
diff --git a/libc/src/__support/math/exp_utils.h b/libc/src/__support/math/exp_utils.h
index e5e465909edcf8..adce1bac7a9148 100644
--- a/libc/src/__support/math/exp_utils.h
+++ b/libc/src/__support/math/exp_utils.h
@@ -86,15 +86,6 @@ namespace double_eval {
using fputil::DoubleDouble;
using fputil::scale_exp2;
-// log(2) in double-double precision, generated by Sollya with:
-// > display = hexadecimal!;
-// > prec = 500;
-// > hi = round(log(2), D, RN);
-// > lo = round(log(2) - hi, D, RN);
-// > print("{", lo, ",", hi, "};");
-LIBC_INLINE_VAR constexpr DoubleDouble LOG_2 = {0x1.abc9e3b39803fp-56,
- 0x1.62e42fefa39efp-1};
-
// log2(e) in double-double precision, generated by Sollya with:
// > display = hexadecimal!;
// > prec = 500;
More information about the libc-commits
mailing list