yjtools-0.9.14: some tools for Monad, List, Tuple and so on.

Control.Monad.Tools

ifM :: Monad m => m Bool -> m a -> m a -> m aSource

whenM, unlessM :: Monad m => m Bool -> m () -> m ()Source

doWhile_, doUntil_ :: Monad m => m Bool -> m ()Source

doWhile, doUntil :: Monad m => a -> (a -> m (a, Bool)) -> m aSource

for_ :: Monad m => a -> (a -> Bool) -> (a -> a) -> (a -> m b) -> m ()Source

for :: Monad m => a -> (a -> Bool) -> (a -> a) -> b -> (a -> b -> m b) -> m bSource

filterM :: Monad m => (a -> m Bool) -> [a] -> m [a]Source

repeatM :: Monad m => m a -> m [a]Source

repeatM_ :: Monad m => m a -> m ()Source

skipRet :: Monad m => m b -> a -> m aSource