isNormal

Determines if x is normalized. This operation is silent, no error flags are set and no exceptions are thrown.

@IEEECompliant("isNormal", 25)
bool
isNormal
(
D
)
(
auto const ref D x
)

Parameters

x D

a _decimal value

Return Value

Type: bool

true if x is normal, false otherwise (NaN, infinity, zero, subnormal)

Examples

assert(isNormal(decimal32.max));
assert(!isNormal(decimal64.nan));
assert(!isNormal(decimal32("0x1p-101")));

Meta