ghc-6.10.4: The GHC APIContentsIndex
MonadUtils
Description
Utilities related to Monad and Applicative classes Mostly for backwards compatability.
Synopsis
Applicative (pure, <*>)
<$>
MonadFix (mfix)
class Monad m => MonadIO m where
liftIO :: IO a -> m a
mapAndUnzipM
mapAndUnzip3M :: Monad m => (a -> m (b, c, d)) -> [a] -> m ([b], [c], [d])
mapAndUnzip4M :: Monad m => (a -> m (b, c, d, e)) -> [a] -> m ([b], [c], [d], [e])
mapAccumLM :: Monad m => (acc -> x -> m (acc, y)) -> acc -> [x] -> m (acc, [y])
mapSndM :: Monad m => (b -> m c) -> [(a, b)] -> m [(a, c)]
concatMapM :: Monad m => (a -> m [b]) -> [a] -> m [b]
anyM :: Monad m => (a -> m Bool) -> [a] -> m Bool
allM :: Monad m => (a -> m Bool) -> [a] -> m Bool
foldlM :: Monad m => (a -> b -> m a) -> a -> [b] -> m a
foldrM :: Monad m => (b -> a -> m a) -> a -> [b] -> m a
Documentation
Applicative (pure, <*>)
<$>
MonadFix (mfix)
class Monad m => MonadIO m where
Methods
liftIO :: IO a -> m a
show/hide Instances
mapAndUnzipM
mapAndUnzip3M :: Monad m => (a -> m (b, c, d)) -> [a] -> m ([b], [c], [d])
mapAndUnzipM for triples
mapAndUnzip4M :: Monad m => (a -> m (b, c, d, e)) -> [a] -> m ([b], [c], [d], [e])
mapAccumLM
:: Monad m
=> acc -> x -> m (acc, y)combining funcction
-> accinitial state
-> [x]inputs
-> m (acc, [y])final state, outputs
Monadic version of mapAccumL
mapSndM :: Monad m => (b -> m c) -> [(a, b)] -> m [(a, c)]
Monadic version of mapSnd
concatMapM :: Monad m => (a -> m [b]) -> [a] -> m [b]
Monadic version of concatMap
anyM :: Monad m => (a -> m Bool) -> [a] -> m Bool
Monadic version of any, aborts the computation at the first True value
allM :: Monad m => (a -> m Bool) -> [a] -> m Bool
Monad version of all, aborts the computation at the first False value
foldlM :: Monad m => (a -> b -> m a) -> a -> [b] -> m a
Monadic version of foldl
foldrM :: Monad m => (b -> a -> m a) -> a -> [b] -> m a
Monadic version of foldr
Produced by Haddock version 2.4.2