Oops, Thanks to Kevin who pointed out:
when :: (Monad m) => Bool -> m () -> m () when p s = if p then s else return () unless :: (Monad m) => Bool -> m () -> m () unless p s = when (not p) s > So now I tend to use: > > doIf :: Monad a => Bool -> [a b] -> a () > doIf b e = if b then sequence_ e else return () Bernie. _______________________________________________ Haskell-Cafe mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell-cafe
