Floating-Point Configuration #
This module defines FloatCfg, the precision and exponent-range parameters that
describe a floating-point format, along with the available RoundingModes and a
Rounding typeclass selecting the mode in scope.
The supported rounding modes for converting a rational to a float.
- nearest : RoundingMode
Round to the nearest representable value (ties to even).
- down : RoundingMode
Round toward negative infinity.
- up : RoundingMode
Round toward positive infinity.
- tozero : RoundingMode
Round toward zero.
- toinf : RoundingMode
Round away from zero (toward infinity in magnitude).
Instances For
A typeclass selecting the RoundingMode in scope.
- mode : RoundingMode
The rounding mode used by the operations in scope.