Safe Haskell | Trustworthy |
---|---|
Language | Haskell2010 |
Documentation
Regular-expressions for which ==
is equivalent
.
>>>
let re1 = star "a" <> "a" :: RE Char
>>>
let re2 = "a" <> star "a" :: RE Char
>>>
re1 == re2
False
>>>
Equiv re1 == Equiv re2
True
Equiv
is also a PartialOrd
(but not Ord
!)
>>>
Equiv "a" `leq` Equiv (star "a" :: RE Char)
True
Not all regular expessions are comparable
:
>>>
let reA = Equiv "a" :: Equiv RE Char
>>>
let reB = Equiv "b" :: Equiv RE Char
>>>
(leq reA reB, leq reB reA)
(False,False)
Equiv (r c) |
Complement c (r c) => Complement c (Equiv r c) Source # | |
Equivalent c (r c) => Equivalent c (Equiv r c) Source # | |
Match c (r c) => Match c (Equiv r c) Source # | |
Derivate c (r c) => Derivate c (Equiv r c) Source # | |
Kleene c (r c) => Kleene c (Equiv r c) Source # | |
Equivalent c (r c) => Eq (Equiv r c) Source # | |
Show (r c) => Show (Equiv r c) Source # | |
Semigroup (r c) => Semigroup (Equiv r c) Source # | |
Monoid (r c) => Monoid (Equiv r c) Source # | |
JoinSemiLattice (r c) => JoinSemiLattice (Equiv r c) Source # | |
BoundedJoinSemiLattice (r c) => BoundedJoinSemiLattice (Equiv r c) Source # | |
(JoinSemiLattice (r c), Equivalent c (r c)) => PartialOrd (Equiv r c) Source # | \(a \preceq b := a \lor b = b \) |
Pretty (r c) => Pretty (Equiv r c) Source # | |
>>>
import Kleene.RE (RE)