Return the next representable value after from toward to.

Synopsis

Declared in <bdldfp_decimalimputil.h>

static
DecimalImpUtil::ValueType32
nexttoward(
    ValueType32 from,
    ValueType128 to);

Description

Return the next representable value of the specified from in the direction of the specified to.

Special value handling: * If from equals to, to is returned. * If either argument is quiet NaN, quiet NaN is returned. * If either argument is signaling NaN, quiet NaN is returned and the value of the macro EDOM is stored into errno. * If from is finite, but the expected result is infinity, infinity is returned and the value of the macro ERANGE is stored into errno. * If from does not equal to and the result is subnormal or zero, the value of the macro ERANGE is stored into errno.

Return Value

the next representable value after from toward to

Parameters

Name

Description

from

starting value

to

direction value

Created with MrDocs