Return a decimal value with the magnitude of the specifed x and the sign of the specified y. If x is NaN, then NaN with the sign of y is returned.

Synopsis

Declared in <bdldfp_decimalutil.h>

static
Decimal32
copySign(
    Decimal32 x,
    Decimal32 y);

Description

Examples: copySign( 5.0, ‐2.0) ==> ‐5.0; copySign(‐5.0, ‐2.0) ==> 5.0

Created with MrDocs