On Sun, Sep 4, 2011 at 11:34 AM, Daniel Peebles <pumpkin...@gmail.com> wrote:
> I was wondering what people thought of a smarter do notation.

I'd support it (for both do notation and monad comprehensions) once
Applicative is a superclass of Monad.

To me it looks light a slight complication for an advantage. Parsers
are not the only examples that benefit. Implicitly parallel
computations would be another because the arguments of <*> can be
evaluated in parallel, those of >>= cannot.

I think it's quite reasonable to try to desugar into the most general
form. Something like

    do x <- something
       return (bla x)

could (and, I think, should) be desugared by using only Functor.

Sebastian

_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to