Safe Haskell | Safe |
---|---|
Language | Haskell2010 |
Synopsis
- class Semigroup a => Semilattice a
- type BoundedSemilattice a = (Monoid a, Semilattice a)
Documentation
class Semigroup a => Semilattice a Source #
A semilattice.
It may be a join-semilattice, or meet-semilattice, it doesn't matter.
If it matters for you, use package lattices
.
In addition to Semigroup
, Semilattice defines these laws:
- commutativity
x
<>
y == y<>
x- idempotency
x
<>
x == x
Instances
Semilattice a => Semilattice (Maybe a) Source # | |
Defined in RON.Semilattice | |
Ord a => Semilattice (Max a) Source # | |
Defined in RON.Semilattice | |
Ord a => Semilattice (Set a) Source # | |
Defined in RON.Semilattice |
type BoundedSemilattice a = (Monoid a, Semilattice a) Source #
A bounded semilattice.
Bounded semilattice laws are already defined by Monoid
and Semilattice
,
so we don't define an explicit class here.