IeeeEquiv

scala.math.Equiv.Double.IeeeEquiv
See theIeeeEquiv companion object
trait IeeeEquiv extends Equiv[Double]

An equivalence for Doubles which is consistent with IEEE specifications.

Because the behaviour of Doubles specified by IEEE is not consistent with behaviors required of an equivalence relation for NaN (it is not reflexive), there are two equivalences defined for Double: StrictEquiv, which is reflexive, and IeeeEquiv, which is consistent with IEEE spec and floating point operations defined in scala.math.

This equivalence may be preferable for numeric contexts.

Attributes

See also
Companion
object
Source
Equiv.scala
Graph
Supertypes
trait Equiv[Double]
trait Serializable
class Object
trait Matchable
class Any
Known subtypes
object IeeeEquiv

Members list

Value members

Concrete methods

def equiv(x: Double, y: Double): Boolean

Returns true iff x is equivalent to y.

Returns true iff x is equivalent to y.

Attributes

Source
Equiv.scala