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


Accessing the Floating-Point Environment

MathLib defines four functions that access the entire floating-point environment:
fegetenvReturns the current environment.
feholdexceptSaves the previous environment and clears all exception flags.
fesetenvSets new environmental values.
feupdateenvRestores a previously saved environment.

These functions take parameters of type fenv_t. Type fenv_t is the environment word type. In general, the environmental access functions either take a pointer to a variable of type fenv_t or accept the macro FE_DFL_ENV, which defines the default environment (default rounding direction and all exceptions cleared).


Previous Book Contents Book Index Next

© Apple Computer, Inc.
13 JUL 1996