Zafu/Abstract/Applicativesource code:
public dependencies: Zafu/Abstract/Eq
Applicativeap, applicative_from_pure_map_map2,
applicative_specialized,
laws_Applicative, map, map2, product2, product3, product4, product5, product_left, product_right, pure, voidApplicative[f]type Applicative[f: * -> *]
apreferences: Applicative
def ap[a: * -> *, b, c](inst: Applicative[a], ff: a[b -> c], fa: a[b]) -> a[c]
applicative_from_pure_map_map2Minimal constructor. product_left/product_right/void are derived.
references: Applicative
def applicative_from_pure_map_map2[a: * -> *](
pure_fn: forall b: *. b -> a[b],
map_fn: forall b: *, c: *. (a[b], b -> c) -> a[c],
map2_fn: forall b: *, c: *, d: *. (a[b], a[c], (b, c) -> d) -> a[d]
) -> Applicative[a]
applicative_specializedConstructor for fully specialized implementations.
references: Applicative,
Unit
def applicative_specialized[a: * -> *](
pure_fn: forall b: *. b -> a[b],
map_fn: forall b: *, c: *. (a[b], b -> c) -> a[c],
map2_fn: forall b: *, c: *, d: *. (a[b], a[c], (b, c) -> d) -> a[d],
product_left_fn: forall b: *, c: *. (a[b], a[c]) -> a[b],
product_right_fn: forall b: *, c: *. (a[b], a[c]) -> a[c],
void_fn: forall b: *. a[b] -> a[()]
) -> Applicative[a]
laws_Applicativereferences: Applicative,
Test, Zafu/Abstract/Eq::Eq
def laws_Applicative[a: * -> *, b, c, d](
inst: Applicative[a],
eq_fa: Zafu/Abstract/Eq::Eq[a[b]],
eq_fb: Zafu/Abstract/Eq::Eq[a[c]],
eq_fc: Zafu/Abstract/Eq::Eq[a[d]],
fa: a[b],
ff_ab: a[b -> c],
ff_bc: a[c -> d],
fn_ab: b -> c,
x: b
) -> Test
mapreferences: Applicative
def map[a: * -> *, b, c](fa: a[b], inst: Applicative[a], fn: b -> c) -> a[c]
map2references: Applicative
def map2[a: * -> *, b, c, d](inst: Applicative[a], left: a[b], right: a[c], fn: (b, c) -> d) -> a[d]
product2references: Applicative,
Tuple2
def product2[a: * -> *, b, c](inst: Applicative[a], fa: a[b], fb: a[c]) -> a[(b, c)]
product3references: Applicative,
Tuple3
def product3[a: * -> *, b, c, d](inst: Applicative[a], fa: a[b], fb: a[c], fc: a[d]) -> a[(b, c, d)]
product4references: Applicative,
Tuple4
def product4[a: * -> *,
b,
c,
d,
e](inst: Applicative[a], fa: a[b], fb: a[c], fc: a[d], fd: a[e]) -> a[(b, c, d, e)]
product5references: Applicative,
Tuple5
def product5[a: * -> *,
b,
c,
d,
e,
f](inst: Applicative[a], fa: a[b], fb: a[c], fc: a[d], fd: a[e], fe: a[f]) -> a[(b, c, d, e, f)]
product_leftreferences: Applicative
def product_left[a: * -> *, b, c](inst: Applicative[a], left: a[b], right: a[c]) -> a[b]
product_rightreferences: Applicative
def product_right[a: * -> *, b, c](inst: Applicative[a], left: a[b], right: a[c]) -> a[c]
purereferences: Applicative
def pure[a: * -> *, b](inst: Applicative[a], value: b) -> a[b]
voidreferences: Applicative,
Unit
def void[a: * -> *, b](fa: a[b], inst: Applicative[a]) -> a[()]