xte ::is_neg ()
Defined in header <xte/math/is_neg.hpp> Checks whether a number is negative. Uses
std ::signbit () for floating-point types.Definition
inline constexpr auto is_neg = [][[nodiscard ]](xte ::is_number auto x )static noexcept ->bool {/* ... */ };
Example
[View in Compiler Explorer]static_assert (xte ::is_neg (-5 ));static_assert (!xte ::is_neg (0.0 ));