A feature test checks at compile time or configuration time whether an implementation provides a language or library feature. Conditional definitions let portable code adapt to supported floating-point facilities. section 15.1.1
Conditionally recognize floating-point features
A program can define whether INFINITY is available with #ifdef, then test 1.0/0.0 against it. The same pattern conditionally builds an array of supported exceptions such as FE_DIVBYZERO, FE_OVERFLOW, and FE_UNDERFLOW. section 15.1.1
int excepts[] = {
#ifdef FE_DIVBYZERO
FE_DIVBYZERO,
#endif
#ifdef FE_INEXACT
FE_INEXACT,
#endif
#ifdef FE_INVALID
FE_INVALID,
#endif
#ifdef FE_OVERFLOW
FE_OVERFLOW,
#endif
#ifdef FE_UNDERFLOW
FE_UNDERFLOW,
#endif
};
Inspect a conditionally assembled exception list that includes only macros provided by the implementation. section 15.1.1
