On Sep 24, 2011, at 8:05 AM, Axel Rauschmayer wrote:

> I love the paren-free syntax for control structures. But what if you want the 
> control structure to take parameters? However, that might make parsing too 
> complicated.

That's covered by the grammar in the strawman, but you have to curry:
CallWithBlockArguments :
    CallExpression [no LineTerminator here] BlockArguments

BlockArguments :
    BlockLambda
    BlockArguments [no LineTerminator here] BlockLambda
    BlockArguments [no LineTerminator here] ( InitialValue )

Your Subject: line's a.map would return a function that captures arg1 and arg2, 
and takes the block-lambda {|x|...} as its sole parameter.

/be

> 
> -- 
> Dr. Axel Rauschmayer
> 
> [email protected]
> twitter.com/rauschma
> 
> home: rauschma.de
> blog: 2ality.com
> 
> 
> 
> _______________________________________________
> es-discuss mailing list
> [email protected]
> https://mail.mozilla.org/listinfo/es-discuss

_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to