Questions re. final fat arrow syntax

Angus Croll anguscroll at
Sat Apr 7 22:08:05 PDT 2012

Apologies if this is not yet nailed down. I'm looking for the following
details re. the arrow function grammar which I was unable to determine from
the strawman proposal:

1. Will the syntax support more than an expression in the function body?
The proposal appeared to be veering towards expression only syntax -
although this could be mitigated by the ES 6 proposed do {} syntax.

2. Will the grammar allow for implicit returns in the manner of Ruby,
CoffeeScript. Seems to be the case for expression bodies. If multiple
statements are allowed (within block syntax) will implicit return apply to
the last statement or does explicit return become necessary?

3. Are parenthese required for zero arguments or will
let a = => doThis();
syntax be permitted (in line with CS)

thank you
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the es-discuss mailing list