Set the floating-point rounding direction
#include <fenv.h> int fesetround( int round );
The fesetround() function sets the current floating-point rounding direction. If the value of round isn't a valid rounding direction macro, the rounding direction isn't changed. The FLT_ROUNDS macro reflects the updated rounding direction.
0 on success, or a nonzero value if an error occurred.
Safety: | |
---|---|
Cancellation point | No |
Interrupt handler | No |
Signal handler | No |
Thread | Yes |