[libc-commits] [libc] [llvm] [libc] Add proxy header for float.h. (PR #93504)
Nick Desaulniers via libc-commits
libc-commits at lists.llvm.org
Tue May 28 10:29:18 PDT 2024
================
@@ -14,9 +14,7 @@
namespace LIBC_NAMESPACE {
LLVM_LIBC_FUNCTION(float128, scalbnf128, (float128 x, int n)) {
-#if !defined(FLT_RADIX)
-#error FLT_RADIX undefined.
-#elif FLT_RADIX != 2
+#if FLT_RADIX != 2
----------------
nickdesaulniers wrote:
Do we need a `#else` here? I suspect not. This could simply be:
```c
#if FLT_RADIX != 2
#error ...
#endif
return fputil::...
```
or even moved outside of the function definition to make the definition crystal clear (1 statement).
https://github.com/llvm/llvm-project/pull/93504
More information about the libc-commits
mailing list