On Sun, Jul 15, 2012 at 6:30 PM, Ross Paterson <r...@soi.city.ac.uk> wrote:
> Silly me -- that code works with the current GHC (module attached).

Aha!  Now I see why the GHC documentation states “the arrows involved
need not be the same” in the section about banana brackets.  After
all, I was wrong in thinking that banana brackets could not be used
here.

As you remarked, the extraction of variable i in your code is a little
bit involved, but it still looks much better than listing the local
variables used in the inner computation, especially when both the
outer computation and the inner computation involve many local
variables.  Thanks a lot.

Best regards,
  Tsuyoshi

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

Reply via email to