hoisting past catch

Brendan Eich brendan at mozilla.com
Thu Nov 4 12:18:44 PDT 2010

On Nov 4, 2010, at 12:00 PM, Peter van der Zee wrote:

> I guess my confusion came from the notion that catch gets its own scope and
> thinking variables in catch statements wouldn't get hoisted until the code in
> that "scope" was entered. Thanks :)

catch did prefigure let -- lexical scope in ES3 from 1999, but only for catch. Finally we get it everywhere in Harmon, at the price of new syntax.


More information about the es-discuss mailing list