| Copyright | (c) 2011 Patrick Bahr |
|---|---|
| License | BSD3 |
| Maintainer | Patrick Bahr <[email protected]> |
| Stability | experimental |
| Portability | non-portable (GHC Extensions) |
| Safe Haskell | Safe-Inferred |
| Language | Haskell98 |
Data.Comp.Multi.HTraversable
Description
This module defines higher-order traversable functors.
Documentation
class HFoldable t => HTraversable t where Source
Methods
hmapM :: Monad m => NatM m a b -> NatM m (t a) (t b) Source
Map each element of a structure to a monadic action, evaluate these actions from left to right, and collect the results.
Alternative type in terms of natural transformations using
functor composition :.::
hmapM :: Monad m => (a :-> m :.: b) -> t a :-> m :.: (t b)
htraverse :: Applicative f => NatM f a b -> NatM f (t a) (t b) Source
Instances
| HTraversable f => HTraversable (Cxt h f) | |
| HTraversable f => HTraversable ((:&:) * f a) | |
| (HTraversable f, HTraversable g) => HTraversable ((:+:) * f g) |