Safe Haskell | Safe |
---|---|
Language | Haskell2010 |
Documentation
class GenMorph db m1 m2 where Source #
A generalized version of Morph
. Can work on different
rulesets, so this should be used if the ruleset is to be extended.
class Morph m1 m2 where Source #
States that m1
can be represented with m2
.
That is because m2
contains more infromation than m1
.
The MMorph
relation defines a natural transformation from m1
to m2
that keeps the following laws:
morph (return x) = return x morph (m >>= f) = morph m >>= morph . f
It is a reflexive and transitive relation.