[libcxx-commits] [libcxx] [libc++][math] Add `constexpr` for `std::signbit()` (PR #105946)

Nikolas Klauser via libcxx-commits libcxx-commits at lists.llvm.org
Fri Aug 30 12:52:07 PDT 2024


================
@@ -28,17 +28,23 @@ namespace __math {
 // signbit
 
 template <class _A1, __enable_if_t<is_floating_point<_A1>::value, int> = 0>
-_LIBCPP_NODISCARD inline _LIBCPP_HIDE_FROM_ABI bool signbit(_A1 __x) _NOEXCEPT {
+_LIBCPP_NODISCARD inline
----------------
philnik777 wrote:

I think it would be better if all overloads have the same constexprness. I'd just define a `_LIBCPP_SIGNBIT_CONSTEXPR` for now.

https://github.com/llvm/llvm-project/pull/105946


More information about the libcxx-commits mailing list