Module
Data.Eq
- Package
- purescript-prelude
- Repository
- purescript/purescript-prelude
#Eq Source
class Eq a where
The Eq
type class represents types which support decidable equality.
Eq
instances should satisfy the following laws:
- Reflexivity:
x == x = true
- Symmetry:
x == y = y == x
- Transitivity: if
x == y
andy == z
thenx == z
Note: The Number
type is not an entirely law abiding member of this
class due to the presence of NaN
, since NaN /= NaN
. Additionally,
computing with Number
can result in a loss of precision, so sometimes
values that should be equivalent are not.
Members
Instances
- Modules
- Control.
Applicative - Control.
Apply - Control.
Bind - Control.
Category - Control.
Monad - Control.
Semigroupoid - Data.
Boolean - Data.
BooleanAlgebra - Data.
Bounded - Data.
CommutativeRing - Data.
DivisionRing - Data.
Eq - Data.
EuclideanRing - Data.
Field - Data.
Function - Data.
Functor - Data.
HeytingAlgebra - Data.
Monoid - Data.
Monoid. Additive - Data.
Monoid. Conj - Data.
Monoid. Disj - Data.
Monoid. Dual - Data.
Monoid. Endo - Data.
Monoid. Multiplicative - Data.
NaturalTransformation - Data.
Ord - Data.
Ord. Unsafe - Data.
Ordering - Data.
Ring - Data.
Semigroup - Data.
Semigroup. First - Data.
Semigroup. Last - Data.
Semiring - Data.
Show - Data.
Symbol - Data.
Unit - Data.
Void - Prelude
- Record.
Unsafe - Type.
Data. Row - Type.
Data. RowList