Instance Property

exponent

The integer part of the base-r logarithm of the magnitude of self, where r is the radix (2 for binary, 10 for decimal). Implements the IEEE 754 logB operation.

Declaration

var exponent: Int { get }

Discussion

Edge cases:

  • If x is zero, then x.exponent is min.

  • If x is +/-infinity or NaN, then x.exponent is max.

Relationships

From Protocol