Copy sign.
The copysignf functions produce a value with the magnitude of x and the sign of y. They produce a NaN (with the sign of y) if x is a NaN. On implementations that represent a signed zero but do not treat negative zero consistently in arithmetic operations, the copysign functions regard the sign of zero as positive.
- Parameters
-
x | Value with the magnitude of the resulting value. |
y | Value with the sign of the resulting value. |
- Returns
- The copysignf functions return a value with the magnitude of x and the sign of y.