Back to index

glibc  2.9
Functions
fclrexcpt.c File Reference
#include <fenv_libc.h>
#include <fpu_control.h>

Go to the source code of this file.

Functions

int feclearexcept (int excepts)

Function Documentation

int feclearexcept ( int  excepts)

Definition at line 24 of file fclrexcpt.c.

{
  fexcept_t temp;

  /* Mask out unsupported bits/exceptions.  */
  excepts &= FE_ALL_EXCEPT;

  _FPU_GETCW (temp);
  /* Clear the relevant bits.  */
  temp &= ~((excepts << FPC_DXC_SHIFT)|(excepts << FPC_FLAGS_SHIFT));

  /* Put the new data in effect.  */
  _FPU_SETCW (temp);

  /* Success.  */
  return 0;
}