[Haskell-cafe] Re: [Haskell] Re: A MonadPlusT with fair operations and pruning

ajb at spamcop.net ajb at spamcop.net
Thu Jul 21 21:18:49 EDT 2005


G'day all.

Quoting oleg at pobox.com:

> We chose c === (true; true), t' === e' === fail,
> t === e === true. Thus,

Good point.  It becomes even more obvious when you have a monad
transformer.

If e === (lift m), then this:

> mif (mif c t' e') t e

translates to (lift m), but this:

> mif c (\x -> mif (t' x) t e) (mif e' t e)

translates to lift m `mplus` lift m, which is definitely different,
since m may alter the transformed monad.

Cheers,
Andrew Bromage


More information about the Haskell-Cafe mailing list