Syntax decision
Pavel Minaev
int19h at gmail.com
Fri Sep 30 18:19:31 PDT 2011
Yes, this would require proper treatment, similar to what is there in CfJ
0.6b.
On Fri, Sep 30, 2011 at 5:58 PM, Neal Gafter <neal at gafter.com> wrote:
> On Fri, Sep 30, 2011 at 3:18 PM, Pavel Minaev <int19h at gmail.com> wrote:
>
>> Note that most such special cases also have 1) a single lambda that 2)
>> occurs in the final argument position. So I think that this is an argument
>> for some kind of syntactic sugar akin to what Ruby has - where you can
>> write:
>>
>> foo.bar(1, 2, 3) {|x,y,z| ...}
>>
>> instead of:
>>
>> foo.bar(1, 2, 3, {|x,y,z| ...})
>>
>> i.e. moving the lambda outside the parentheses, and making it look more
>> like
>> a statement with a body than a function call.
>>
>> I don't think this is something worth pursuing for the first version,
>> though. ()->{} is good enough in practice, and extra syntactic sugar can
>> always be slapped on top when and if needed.
>
>
> Without control transparency <http://www.youtube.com/watch?v=0zVizaCOhME>(which Ruby has), this would create a brand new world of confusion.
>
>
>
More information about the lambda-dev
mailing list