Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: PowerPC Numerics / Part 2 - The PowerPC Numerics C Implementation
Chapter 8 - Environmental Control Functions / Controlling the Exception Flags


fegetexcept

You can use the fegetexcept function to save the current value of one or more floating-point exception flags.

void fegetexcept (fexcept_t *flagp, int excepts);
flagp
A pointer to where the exception flag values are to be stored.
excepts
A mask indicating which exception flags to save.
DESCRIPTION
The fegetexcept function saves the values of the floating-point exception flags specified by the argument excepts to the area pointed to by the argument flagp. The excepts argument may be one of the constants in Table 8-2 on page 8-6, two or more of these constants ORed together, or the constant FE_ALL_EXCEPT.

EXAMPLES
fegetexcept(flagp, FE_INVALID);     /* saves the invalid flag */
fegetexcept(flagp, FE_INVALID|FE_OVERFLOW|FE_DIVBYZERO);
      /* saves the invalid, overflow, and divide-by-zero flags */
fegetexcept(flagp, FE_ALL_EXCEPT);        /* saves all flags */

Previous Book Contents Book Index Next

© Apple Computer, Inc.
13 JUL 1996