half  1.12
IEEE 754-based half-precision floating point library
 All Classes Namespaces Files Functions Variables Typedefs Macros Pages
numeric_limits< half_float::half > Struct Template Reference

Numeric limits for half-precision floats. More...

Inherits numeric_limits< float >.

Static Public Member Functions

static constexpr half_float::half min () noexcept
 Smallest positive normal value.
static constexpr half_float::half lowest () noexcept
 Smallest finite value.
static constexpr half_float::half max () noexcept
 Largest finite value.
static constexpr half_float::half epsilon () noexcept
 Difference between one and next representable value.
static constexpr half_float::half round_error () noexcept
 Maximum rounding error.
static constexpr half_float::half infinity () noexcept
 Positive infinity.
static constexpr half_float::half quiet_NaN () noexcept
 Quiet NaN.
static constexpr half_float::half signaling_NaN () noexcept
 Signalling NaN.
static constexpr half_float::half denorm_min () noexcept
 Smallest positive subnormal value.

Static Public Attributes

static constexpr bool is_signed = true
 Supports signed values.
static constexpr bool is_exact = false
 Is not exact.
static constexpr bool is_modulo = false
 Doesn't provide modulo arithmetic.
static constexpr bool is_iec559 = true
 IEEE conformant.
static constexpr bool has_infinity = true
 Supports infinity.
static constexpr bool has_quiet_NaN = true
 Supports quiet NaNs.
static constexpr
has_denorm = std::denorm_present
 Supports subnormal values.
static constexpr
round_style =
 Rounding mode.
static constexpr int digits = 11
 Significant digits.
static constexpr int digits10 = 3
 Significant decimal digits.
static constexpr int max_digits10 = 5
 Required decimal digits to represent all possible values.
static constexpr int radix = 2
 Number base.
static constexpr int min_exponent = -13
 One more than smallest exponent.
static constexpr int min_exponent10 = -4
 Smallest normalized representable power of 10.
static constexpr int max_exponent = 16
 One more than largest exponent.
static constexpr int max_exponent10 = 4
 Largest finitely representable power of 10.

Detailed Description

struct std::numeric_limits< half_float::half >

Numeric limits for half-precision floats.

Because of the underlying single-precision implementation of many operations, it inherits some properties from std::numeric_limits<float>.

See also: Documentation for std::numeric_limits

Member Data Documentation

constexpr std::float_round_style round_style =

Rounding mode.

Due to the mix of internal single-precision computations (using the rounding mode of the underlying single-precision implementation) with the rounding mode of the single-to-half conversions, the actual rounding mode might be std::round_indeterminate if the default half-precision rounding mode doesn't match the single-precision rounding mode.

The documentation for this struct was generated from the following file: