[Haskell-cafe] What is MonadPlus good for?
Jacques Carette
carette at mcmaster.ca
Mon Feb 14 10:07:41 EST 2005
Josef Svenningsson <josef.svenningsson at gmail.com> wrote:
> You claimed that monad transformers break the
> mzero-is-right-identity-for-bind law because they can be applied to
> IO. I say, it's not the monad transformers fault. They cannot possibly
> be expected to repair the law if they are given a faulty monad.
Doesn't that argue for allowing proven and unproven Monads in Haskell?
Using the Curry-Howard correspondance, wouldn't it make sense to provide (proof) terms in a Monad's signature that are
witnesses for the monad laws?
One could then have signature-only Monads (ie a rather weak requirement) and signature+laws Monads (much stronger).
Jacques
More information about the Haskell-Cafe
mailing list