stdlib - 0.0.1

Stdlib.Trait.Traversable.Polymorphic

Definitions

trait type Traversable (T : Type -> Type)Source#

A trait for traversing a structure while performing applicative effects

Constructors

mkTraversable@{ {{functorI}} : Functor T; traverse : {F : Type -> Type} -> {{Applicative F}} -> {A B : Type} -> (A -> F B) -> T A -> F (T B); sequenceA : {F : Type -> Type} -> {{Applicative F}} -> {A : Type} -> T (F A) -> F (T A); }

open Traversable public

defaultSequenceA {T : Type -> Type} {F : Type -> Type} {{Applicative F}} {A : Type} (trav : {F : Type -> Type} -> {{Applicative F}} -> {A B : Type} -> (A -> F B) -> T A -> F (T B)) (tfa : T (F A)) : F (T A)Source#

defaultTraverse {T : Type -> Type} {{Functor T}} {F : Type -> Type} {{Applicative F}} {A B : Type} (seqA : {F : Type -> Type} -> {{Applicative F}} -> {A : Type} -> T (F A) -> F (T A)) (f : A -> F B) (ta : T A) : F (T B)Source#