category-extras-0.53.5: Various modules and constructs inspired by category theory
Source code
Contents
Index
Control.Functor.Fix
Portability
non-portable (rank-2 polymorphism)
Stability
experimental
Maintainer
Edward 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
Source
Constructors
InF
outF
:: f (
FixF
f)
outM
:: (
Functor
f,
Monad
m) =>
GCoalgebra
f m (
FixF
f)
Source
inW
:: (
Functor
f,
Comonad
w) =>
GAlgebra
f w (
FixF
f)
Source
identityBialgebraF
::
Bialgebra
f f (
FixF
f)
Source
Bifunctor fixpoint
newtype
Fix
s a
Source
Constructors
InB
outB
:: s a (
Fix
s a)
Instances
Functor
f =>
RunComonadCofree
f (
Cofree
f)
Functor
f =>
ComonadCofree
f (
Cofree
f)
Functor
f =>
MonadFree
f (
Free
f)
Functor
f =>
RunMonadFree
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
,
PCopointed
f) =>
Copointed
(
Fix
f)
(
Bifunctor
f
Hask
Hask
Hask
,
PPointed
f) =>
Pointed
(
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)
Source
paugment
::
PMonad
f => (
forall
c. (f a c -> c) -> c) -> (a ->
Fix
f b) ->
Fix
f b
Source
pcoaugment
::
PComonad
f => ((
Fix
f a -> f b (
Fix
f a)) ->
Fix
f b) -> (
Fix
f a -> b) ->
Fix
f b
Source
Produced by
Haddock
version 2.4.2