I understand why the normal signature is:
when :: Monad m => Bool -> m () -> m ()
unless :: Monad m => Bool -> m () -> m ()
But why isn't there also:
when_ :: Monad m => Bool -> m a -> m ()
unless_ :: Monad m => Bool -> m a -> m ()
That is, I agree that results shouldn't be discarded "by default", but it should be easy to get rid of them if they are unneeded.
Thanks,
Oren Ben-Kiki