|
inlineconstexpr |
Computes the opposite of the parameter that must be signed.
Defined in Header
Parameters
Return value
x if this value is representable in the type of x.- is supported, the - operator on standard scalar type is the original one and so can lead to automatic promotion.Masked Call
The call eve::minus[mask](x) provides a masked version of eve::minus which is equivalent to if_else (mask, eve::minus(x), x).
Example
The call eve::saturated(eve::minus)(x) computes a saturated version of eve::minus.
More specifically, for any signed integer value x, the expression eve::saturated(eve::minus)(eve::valmin(as(x))) evaluates to eve::valmax(as(x)).
Example