| |||
| Home > Floating-point Support > The math library, mathlib > Determine the type of a floating-point number (fpclassify) | |||
This macro classifies its argument value based on type.
int fpclassify(real-floating x);
where real-floating can be type float, double, or long double.
Here, fpclassify returns one of the following
values:
FP_INFINITE if x is
an infinity
FP_NAN if x is
a NaN
FP_NORMAL if x is
a normal
FP_SUBNORMAL if x is
a subnormal
FP_ZERO if x is
zero.
It does not cause any errors or exceptions.