Call to arms: lambda-case is stuck and needs your help

Mikhail Vorozhtsov mikhail.vorozhtsov at gmail.com
Thu Jul 12 11:25:13 CEST 2012


On 07/12/2012 04:27 AM, Iavor Diatchki wrote:
> Hello,
> I am late to the discussion and this is not entirely on topic, for which
> I apologize, but I like the multi-branch case syntax someone mentioned
> earlier:
>
> Writing:
>
>  > case
>  >   | p1 -> e1
>  >   | p2 -> e2
>  >   | ...
>
> desugars to:
>
>  > case () of
>  >   _ | p1 -> e2
>  >     | p2 -> e2
>  >     | ...
>
> -Iavor
> PS:  I think it also makes sense to use "if" instead of "case" for this.
>   Either way,  I find myself writing these kind of cases quite often, so
> having the sugar would be nice.
See [1]. I plan to implement it after lambda-case goes in.

[1] http://hackage.haskell.org/trac/haskell-prime/wiki/MultiWayIf



More information about the Glasgow-haskell-users mailing list