Important: The information in this document is obsolete and should not be used for new development.
fegetenv
You can use thefegetenvfunction to save the current state of the floating-point environment.
void fegetenv (fenv_t *envp);
envp- A pointer to an environment word that will store the current state of the environment upon the function's return.
DESCRIPTION
Thefegetenvfunction saves the current state of the rounding direction modes and the floating-point exception flags in the object pointed to by itsenvpargument.EXAMPLES
double_t func (double_t x, double_t y) { fenv_t *env; x = x + y; /* floating-point op; may raise exceptions */ fegetenv(env); /* save state of env after add */ y = y * x; /* floating-point op; may raise exceptions */ . . . }