Recently I studied monad transformers in Haskell. And I became very curious why there is no IOT
monad transformer. For example, I can add IORef
environment to IO
monad like this
type IORefEnv s = ReaderT (IORef s) IO
But why can't I add IO
effect to my environment in a similar way?
type IOReader r a = IOT (Reader r) a