category-extras-0.53.1: Various modules and constructs inspired by category theory

Portabilitynon-portable (rank-2 polymorphism)
Stabilityexperimental
MaintainerEdward Kmett <ekmett@gmail.com>

Control.Morphism.Para

Description

 

Synopsis

Documentation

type Para f = (,) (FixF f)Source

type ParaT w f = CoreaderT w (FixF f)Source

distParaT :: (Functor f, Comonad w) => Dist f w -> Dist f (ParaT w f)Source

para :: Functor f => GAlgebra f (Para f) a -> FixF f -> aSource

g_para :: (Functor f, Comonad w) => Dist f w -> GAlgebra f (ParaT w f) a -> FixF f -> aSource

Generalized paramorphisms using a comonad reader transformer to carry the primitive recursive state

prepro_para :: Functor f => GAlgebra f (Para f) a -> (f :~> f) -> FixF f -> aSource

A paramorphic prepromorphism

g_prepro_para :: (Functor f, Comonad w) => Dist f w -> GAlgebra f (ParaT w f) a -> (f :~> f) -> FixF f -> aSource

A generalized paramorphic prepromorphism