Module do_foldable

The Foldable Type Class.

This module defines the do_foldable behaviour.
Required callback functions: foldr/3.
Optional callback functions: fold_map/2.

Description

The Foldable Type Class.

Data Types

either()

either(A, B) = {error, A} | {ok, B}

fn()

fn(A, B, C) = fun((A, B) -> C)

foldable()

foldable(A) = [A] | maybe(A) | either(term(), A)

maybe()

maybe(A) = {just, A} | nothing

Function Index

foldr/3

Function Details

foldr/3

foldr(F::fn(A, B, B), B, Foldable::foldable(A)) -> B


Generated by EDoc