I've been experimenting with the state monad and with StateT, and
have some questions about how to combine one state with another.
This email is literate Haskell tested on GHCi, version 6.10.1. Also,
sigfpe's post on monad transformers (http://blog.sigfpe.com/2006/05/
grok-haskell-monad-tra
test3 :: MonadState Integer m => String -> m String
Good point. It's interesting that this allows the signature of
test5b to become MonadState Integer m => m Integer (instead of (Monad
m) => StateT Integer (StateT String m) Integer) which is more
general, and (surprisingly to me) does not