folds-0.3: Beautiful Folding

Safe HaskellTrustworthy

Data.Fold.L'

Synopsis

Documentation

data L' a b Source

A strict left fold / strict Moore machine

Constructors

forall r . L' (r -> b) (r -> a -> r) r 

Instances

Choice L' 
Profunctor L' 
Folding L'

efficient prefix, leaky postfix

Scan L' 
AsL' L'

We can convert a lazy fold to itself

AsRM L'

We can convert from a strict left folding to a right or monoidal fold

Monad (L' a) 
Functor (L' a) 
Applicative (L' a) 
Comonad (L' a) 
ComonadApply (L' a) 
Apply (L' a) 
Bind (L' a) 
Extend (L' a) 

unfoldL' :: (s -> (b, a -> s)) -> s -> L' a bSource

Construct a strict Moore machine from a state valuation and transition function