On 22 Feb 2014 08:02, "Andrew Barnert" <abarnert@yahoo.com> wrote:
>
> I think the best answer is the one I suggested above—and which I think Nick implicitly assumed because he's smart enough to get there directly: At least initially, just do 0-argument and 1-argument lambdas. As long as you leave the door open for extended syntaxes in a future proposal, we don't need to figure them out yet.

Yep, the implicit assumption was that the shorthand syntax could get away with handling just zero-argument functions (for simple callbacks and lazy evaluation) and one-positional-argument functions (for single object callbacks, sorting keys and filtering predicates).

More complex cases don't need to be handled, as users have the option to revert to using an explicit lambda or a named function.

This helps the proposal achieve one of useful heuristics to apply when judging a new piece of syntactic sugar: in the cases where it applies, it should be clearly superior to the existing alternatives. Once you get to 2+ arguments, it's hard to be clear without giving them names.

Cheers,
Nick.