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

Control.Monad.Tools

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

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

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

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

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

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

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