[Haskell-cafe] can someone explain monad transformers to me,
or how do you combine maybe and IO?
alfonso.acosta at gmail.com
Mon Nov 12 19:47:36 EST 2007
On Nov 13, 2007 1:08 AM, Luke Palmer <lrpalmer at gmail.com> wrote:
> We want MaybeT!
I third this proposal. It would be nice having MaybeT included in mtl.
Besides, and although it's not exactly the same, you can "emulate" the
Maybe monad by using the Either monad (the instance is defined in
And in this case you want a monad transformer, so ErrorT can do the trick.
Just consider that all the Left values are Nothing and the Right
values are Just.
More information about the Haskell-Cafe