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

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

Control.Morphism.Meta.Gibbons

Description

A very basic Jeremy Gibbons metamorphism, without all the productive stream stuff. See: http://www.comlab.ox.ac.uk/oucl/work/jeremy.gibbons/publications/metamorphisms-scp.pdf TODO: Add some support for spigot algorithms over streams/lists.

Synopsis

Documentation

meta :: (Functor f, Functor g) => Coalgebra f b -> (a -> b) -> Algebra g a -> FixF g -> FixF fSource

g_meta :: (Monad m, Functor f, Comonad w, Functor g) => Dist m f -> Dist g w -> GCoalgebra f m b -> (a -> b) -> GAlgebra g w a -> FixF g -> FixF fSource

Generalized Jeremy Gibbons metamorphism