Module
Data.Coyoneda
- Package
- purescript-free
- Repository
- purescript/purescript-free
#CoyonedaF Source
data CoyonedaF f a i
Coyoneda
is encoded as an existential type using Data.Exists
.
This type constructor encodes the contents of the existential package.
#Coyoneda Source
newtype Coyoneda f a
The Coyoneda
Functor
.
Coyoneda f
is a Functor
for any type constructor f
. In fact,
it is the free Functor
for f
.
Constructors
Instances
(Functor f, Eq1 f, Eq a) => Eq (Coyoneda f a)
(Functor f, Eq1 f) => Eq1 (Coyoneda f)
(Functor f, Ord1 f, Ord a) => Ord (Coyoneda f a)
(Functor f, Ord1 f) => Ord1 (Coyoneda f)
Functor (Coyoneda f)
(Apply f) => Apply (Coyoneda f)
(Applicative f) => Applicative (Coyoneda f)
(Bind f) => Bind (Coyoneda f)
(Monad f) => Monad (Coyoneda f)
MonadTrans Coyoneda
(Extend w) => Extend (Coyoneda w)
(Comonad w) => Comonad (Coyoneda w)
#unCoyoneda Source
unCoyoneda :: forall a g f. (forall b. (b -> a) -> f b -> g a) -> Coyoneda f a -> g a
Deconstruct a value of Coyoneda a
to retrieve the mapping function and
original value.
#liftCoyoneda Source
liftCoyoneda :: forall f. f ~> (Coyoneda f)
Lift a value described by the type constructor f
to Coyoneda f
.