Movatterモバイル変換


[0]ホーム

URL:


Scala 3
3.7.4
LearnInstallPlaygroundFind A LibraryCommunityBlog
Scala 3
LearnInstallPlaygroundFind A LibraryCommunityBlog
DocsAPI
Generated with
Copyright (c) 2002-2025, LAMP/EPFL
Copyright (c) 2002-2025, LAMP/EPFL
Scala 3/scala/scala.math/Equiv/Float

Float

scala.math.Equiv.Float
objectFloat

Equivs forFloats.

Attributes

Source
Equiv.scala
Graph
Supertypes
classObject
traitMatchable
classAny
Self type
Float.type

Members list

Type members

Classlikes

objectIeeeEquiv extendsIeeeEquiv

Attributes

Companion
trait
Source
Equiv.scala
Supertypes
traitIeeeEquiv
traitEquiv[Float]
classObject
traitMatchable
classAny
Show all
Self type
traitIeeeEquiv extendsEquiv[Float]

An equivalence forFloats which is consistent with IEEE specifications.

An equivalence forFloats which is consistent with IEEE specifications.

Because the behaviour ofFloats specified by IEEE is not consistent with behaviors required of an equivalence relation forNaN (it is not reflexive), there are two equivalences defined forFloat:StrictEquiv, which is reflexive, andIeeeEquiv, which is consistent with IEEE spec and floating point operations defined inscala.math.

This equivalence may be preferable for numeric contexts.

Attributes

See also
Companion
object
Source
Equiv.scala
Supertypes
traitEquiv[Float]
classObject
traitMatchable
classAny
Known subtypes
objectIeeeEquiv

Attributes

Companion
trait
Source
Equiv.scala
Supertypes
traitEquiv[Float]
classObject
traitMatchable
classAny
Show all
Self type
traitStrictEquiv extendsEquiv[Float]

An equivalence forFloats which is reflexive (treats allNaNs as equivalent), and treats-0.0 and0.0 as not equivalent; it behaves the same asjava.lang.Float.compare.

An equivalence forFloats which is reflexive (treats allNaNs as equivalent), and treats-0.0 and0.0 as not equivalent; it behaves the same asjava.lang.Float.compare.

Because the behaviour ofFloats specified by IEEE is not consistent with behaviors required of an equivalence relation forNaN (it is not reflexive), there are two equivalences defined forFloat:StrictEquiv, which is reflexive, andIeeeEquiv, which is consistent with IEEE spec and floating point operations defined inscala.math.

This equivalence may be preferable for collections.

Attributes

See also
Companion
object
Source
Equiv.scala
Supertypes
traitEquiv[Float]
classObject
traitMatchable
classAny
Known subtypes
In this article
Generated with
Copyright (c) 2002-2025, LAMP/EPFL
Copyright (c) 2002-2025, LAMP/EPFL

[8]ページ先頭

©2009-2025 Movatter.jp