Re: Revenge of the double-curly [Was: return when desugaring to closures]

2008-10-11 Thread Brendan Eich
On Oct 11, 2008, at 7:25 AM, David-Sarah Hopwood wrote: > It is correct to say, though, that: > > function foo() { >... >{ var bar = baz; } >... > } > > is equivalent to > > function foo() { >let bar = undefined; >... >{ bar = baz; } >... > } > > That is, 'var' need

Re: Revenge of the double-curly [Was: return when desugaring to closures]

2008-10-11 Thread David-Sarah Hopwood
Brendan Eich wrote: > On Oct 10, 2008, at 11:58 AM, P T Withington wrote: > >> ? If so, perhaps you can see how I might imagine that: >> >> function foo () {{ >> var bar = ...; >> }} >> >> might be sugar for: >> >> function foo () { >> let bar = ...; >> } > > Nope, not compatible

Re: Revenge of the double-curly [Was: return when desugaring to closures]

2008-10-10 Thread Brendan Eich
On Oct 10, 2008, at 11:58 AM, P T Withington wrote: > ? If so, perhaps you can see how I might imagine that: > > function foo () {{ > var bar = ...; > }} > > might be sugar for: > > function foo () { > let bar = ...; > } Nope, not compatible and not what I meant. Just the functi

Re: Revenge of the double-curly [Was: return when desugaring to closures]

2008-10-10 Thread P T Withington
On 2008-10-10, at 11:55EDT, Brendan Eich wrote: > On Oct 10, 2008, at 5:44 AM, P T Withington wrote: > >> On 2008-10-10, at 02:29EDT, Brendan Eich wrote: >> >>> An agreement from TC39 this past spring was that function >>> definitions >>> directly nested in blocks, not specified by ES3, defined

Re: Revenge of the double-curly [Was: return when desugaring to closures]

2008-10-10 Thread David-Sarah Hopwood
P T Withington wrote: > On 2008-10-10, at 02:29EDT, Brendan Eich wrote: > >> An agreement from TC39 this past sprint was that function definitions >> directly nested in blocks, not specified by ES3, defined block-local >> (let) bindings. > > Holy smokes. Does that mean we are all going to be wri

Re: Revenge of the double-curly [Was: return when desugaring to closures]

2008-10-10 Thread Brendan Eich
On Oct 10, 2008, at 5:44 AM, P T Withington wrote: > On 2008-10-10, at 02:29EDT, Brendan Eich wrote: > >> An agreement from TC39 this past spring was that function definitions >> directly nested in blocks, not specified by ES3, defined block-local >> (let) bindings. > > Holy smokes. Does that mea

Re: Revenge of the double-curly [Was: return when desugaring to closures]

2008-10-10 Thread liorean
> On 2008-10-10, at 02:29EDT, Brendan Eich wrote: >> An agreement from TC39 this past sprint was that function definitions >> directly nested in blocks, not specified by ES3, defined block-local >> (let) bindings. 2008/10/10 P T Withington <[EMAIL PROTECTED]>: > Holy smokes. Does that mean we are

Revenge of the double-curly [Was: return when desugaring to closures]

2008-10-10 Thread P T Withington
On 2008-10-10, at 02:29EDT, Brendan Eich wrote: > An agreement from TC39 this past sprint was that function definitions > directly nested in blocks, not specified by ES3, defined block-local > (let) bindings. Holy smokes. Does that mean we are all going to be writing function ... () {{