concrete functor and monad transformers
#47State.modifyT
I would like to have this function in Monad.Trans.State:
modifyT :: Monad m => (s -> m s) -> StateT s m ()
modifyT f = StateT $ liftM ((,) ()) . f
concrete functor and monad transformers
I would like to have this function in Monad.Trans.State:
modifyT :: Monad m => (s -> m s) -> StateT s m ()
modifyT f = StateT $ liftM ((,) ()) . f