record Container : TypeMkContainer : (Shape : Type) -> (Shape -> Type) -> Container.Position : ({rec:0} : Container) -> Shape {rec:0} -> Type.Shape : Container -> TypeFunctor (Extension c).Shape : Container -> TypeShape : Container -> Type.Position : ({rec:0} : Container) -> Shape {rec:0} -> TypePosition : ({rec:0} : Container) -> Shape {rec:0} -> Typerecord Extension : Container -> Type -> TypeMkExtension : (shape : Shape c) -> (Position c shape -> x) -> Extension c x.payloads : ({rec:0} : Extension c x) -> Position c (shape {rec:0}) -> x.shape : Extension c x -> Shape cFunctor (Extension c).shape : Extension c x -> Shape cshape : Extension c x -> Shape c.payloads : ({rec:0} : Extension c x) -> Position c (shape {rec:0}) -> xpayloads : ({rec:0} : Extension c x) -> Position c (shape {rec:0}) -> xrecord Morphism : Container -> Container -> TypeMkMorphism : (shapeMorphism : (Shape c -> Shape d)) -> (Position d (shapeMorphism s) -> Position c s) -> Morphism c d.positionMorphism : ({rec:0} : Morphism c d) -> Position d (shapeMorphism {rec:0} s) -> Position c s.shapeMorphism : Morphism c d -> Shape c -> Shape d.shapeMorphism : Morphism c d -> Shape c -> Shape dshapeMorphism : Morphism c d -> Shape c -> Shape d.positionMorphism : ({rec:0} : Morphism c d) -> Position d (shapeMorphism {rec:0} s) -> Position c spositionMorphism : ({rec:0} : Morphism c d) -> Position d (shapeMorphism {rec:0} s) -> Position c sExtension : Morphism c d -> Extension c x -> Extension d xConst : Type -> ContainertoConst : k -> Extension (Const k) xfromConst : Extension (Const k) x -> kIdentity : ContainertoIdentity : x -> Extension Identity xfromIdentity : Extension Identity x -> xCompose : Container -> Container -> ContainertoCompose : (.) (Extension d) (Extension c) x -> Extension (Compose d c) xfromCompose : Extension (Compose d c) x -> (.) (Extension d) (Extension c) xSum : Container -> Container -> ContainertoSum : Either (Extension c x) (Extension d x) -> Extension (Sum c d) xfromSum : Extension (Sum c d) x -> Either (Extension c x) (Extension d x)Pair : Container -> Container -> ContainertoPair : (Extension c x, Extension d x) -> Extension (Pair c d) xfromPair : Extension (Pair c d) x -> (Extension c x, Extension d x)Exponential : Type -> Container -> ContainertoExponential : (k -> Extension c x) -> Extension (Exponential k c) xfromExponential : Extension (Exponential k c) x -> k -> Extension c xdata W : Container -> TypeMkW : Extension c (W c) -> W cmap : Morphism c d -> W c -> W dfoldr : (Extension c x -> x) -> W c -> xpara : (Extension c (x, W c) -> x) -> W c -> xrecord Free : Container -> Type -> Type@Free@ is a wrapper around @W@ to make it inference friendly.
Without this wrapper, neither @pure@ nor @bind@ are able to infer their @c@ argument.
MkFree : W (Sum c (Const x)) -> Free c x.runFree : Free c x -> W (Sum c (Const x)).runFree : Free c x -> W (Sum c (Const x))runFree : Free c x -> W (Sum c (Const x))pure : x -> Free c x(>>=) : Free c x -> (x -> Free c y) -> Free c yjoin : Free c (Free c x) -> Free c xdata M : Container -> TypeMkM : Extension c (Inf (M c)) -> M cunfoldr : (s -> Extension c s) -> s -> M crecord Cofree : Container -> Type -> Type@Cofree@ is a wrapper around @M@ to make it inference friendly.
Without this wrapper, neither @extract@ nor @extend@ are able to infer their @c@ argument.
MkCofree : M (Pair (Const x) c) -> Cofree c x.runCofree : Cofree c x -> M (Pair (Const x) c).runCofree : Cofree c x -> M (Pair (Const x) c)runCofree : Cofree c x -> M (Pair (Const x) c)extract : Cofree c x -> xextend : (Cofree c a -> b) -> Cofree c a -> Cofree c bduplicate : Cofree c a -> Cofree c (Cofree c a)Derivative : Container -> Containerhole : (v : Extension (Derivative c) x) -> Position c (fst (shape v))unplug : (v : Extension c x) -> Position c (shape v) -> (Extension (Derivative c) x, x)plug : (v : Extension (Derivative c) x) -> DecEq (Position c (fst (shape v))) => x -> Extension c xtoConst : Extension (Const Void) x -> Extension (Derivative (Const k)) xfromConst : Extension (Derivative (Const k)) x -> Extension (Const Void) xtoIdentity : Extension (Derivative Identity) xtoSum : Extension (Sum (Derivative c) (Derivative d)) x -> Extension (Derivative (Sum c d)) xfromSum : Extension (Derivative (Sum c d)) x -> Extension (Sum (Derivative c) (Derivative d)) xtoPair : Extension (Sum (Pair (Derivative c) d) (Pair c (Derivative d))) x -> Extension (Derivative (Pair c d)) xfromPair : Extension (Derivative (Pair c d)) x -> Extension (Sum (Pair (Derivative c) d) (Pair c (Derivative d))) xfromCompose : Extension (Derivative (Compose c d)) x -> Extension (Pair (Derivative d) (Compose (Derivative c) d)) xtoCompose : ((s : c .Shape) -> DecEq (Position c s)) -> ((s : d .Shape) -> DecEq (Position d s)) -> Extension (Pair (Derivative d) (Compose (Derivative c) d)) x -> Extension (Derivative (Compose c d)) x