one-liner-0.2.2: Constraint-based generics

Portabilitynon-portable
Stabilityexperimental
Maintainersjoerd@w3future.com
Safe HaskellNone

Generics.OneLiner.Functions1

Contents

Description

 

Synopsis

For all instances

fmapADT :: (ADT1 t, Constraints t Functor) => (a -> b) -> t a -> t bSource

foldMapADT :: (ADT1 t, Constraints t Foldable, Monoid m) => (a -> m) -> t a -> mSource

traverseADT :: (ADT1 t, Constraints t Traversable, Applicative f) => (a -> f b) -> t a -> f (t b)Source

For datatypes with one constructor

apADT :: (ADT1Record t, Constraints t Applicative) => t (a -> b) -> t a -> t bSource

bindADT :: (ADT1Record t, Constraints t Monad) => t a -> (a -> t b) -> t bSource

mfixADT :: (ADT1Record t, Constraints t MonadFix) => (a -> t a) -> t aSource