[Haskell-cafe] Smarter do notation

Sebastian Fischer fischer at nii.ac.jp
Mon Sep 5 10:37:39 CEST 2011

Hi Max,

thanks for you proposal!

Using the Applicative methods to optimise "do" desugaring is still
> possible, it's just not that easy to have that weaken the generated
> constraint from Monad to Applicative since only degenerate programs
> like this one won't use a Monad method:

Is this still true, once Monad is a subclass of Applicative which defines

I'd still somewhat prefer if return get's merged with the preceding
statement so sometimes only a Functor constraint is generated but I think, I
should adjust your desugaring then..

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20110905/97360b88/attachment.htm>

More information about the Haskell-Cafe mailing list