category-extras-0.53.6: Various modules and constructs inspired by category theoryContentsIndex
Control.Functor.Fix
Portabilitynon-portable (rank-2 polymorphism)
Stabilityexperimental
MaintainerEdward Kmett <ekmett@gmail.com>
Contents
Functor fixpoint
Bifunctor fixpoint
Description
Since in Hask, Mu = Nu, we don't bother to distinguish them here
Synopsis
newtype FixF f = InF {
outF :: f (FixF f)
}
outM :: (Functor f, Monad m) => GCoalgebra f m (FixF f)
inW :: (Functor f, Comonad w) => GAlgebra f w (FixF f)
identityBialgebraF :: Bialgebra f f (FixF f)
newtype Fix s a = InB {
outB :: s a (Fix s a)
}
identityBialgebraB :: Bialgebra (f a) (f a) (Fix f a)
paugment :: PMonad f => (forall c. (f a c -> c) -> c) -> (a -> Fix f b) -> Fix f b
pcoaugment :: PComonad f => ((Fix f a -> f b (Fix f a)) -> Fix f b) -> (Fix f a -> b) -> Fix f b
Functor fixpoint
newtype FixF f
Constructors
InF
outF :: f (FixF f)
outM :: (Functor f, Monad m) => GCoalgebra f m (FixF f)
inW :: (Functor f, Comonad w) => GAlgebra f w (FixF f)
identityBialgebraF :: Bialgebra f f (FixF f)
Bifunctor fixpoint
newtype Fix s a
Constructors
InB
outB :: s a (Fix s a)
show/hide Instances
Functor f => RunComonadCofree f (Cofree f)
Functor f => ComonadCofree f (Cofree f)
Functor f => RunMonadFree f (Free f)
Functor f => MonadFree f (Free f)
(Bifunctor f Hask Hask Hask, PMonad f) => Monad (Fix f)
Bifunctor s Hask Hask Hask => Functor (Fix s)
(Bifunctor f Hask Hask Hask, PPointed f) => Pointed (Fix f)
(Bifunctor f Hask Hask Hask, PCopointed f) => Copointed (Fix f)
(Bifunctor f Hask Hask Hask, PComonad f) => Comonad (Fix f)
Bizip p => Zip (Fix p)
identityBialgebraB :: Bialgebra (f a) (f a) (Fix f a)
paugment :: PMonad f => (forall c. (f a c -> c) -> c) -> (a -> Fix f b) -> Fix f b
pcoaugment :: PComonad f => ((Fix f a -> f b (Fix f a)) -> Fix f b) -> (Fix f a -> b) -> Fix f b
Produced by Haddock version 2.1.0