with and scope chain augmentation

Jason Orendorff jason.orendorff at gmail.com
Tue Jun 23 14:18:10 PDT 2009

On Mon, Jun 22, 2009 at 2:43 PM, Mike Wilson<mikewse at hotmail.com> wrote:
> I sympathize with the slide "Problem: Can't emulate
> platform objects" (which is addressed by e g getter/setter
> properties), but the removal of with(){} in ES5 strict mode
> would mean it gets harder to emulate the scope chain
> augmentation done by browsers?

Actually, I think we do this by wrapping event handlers in something like

 (function (event) { ... })

so "with" is not involved.  In fact, surely everyone does something
like this, as event handlers have to support stuff like "return


More information about the es-discuss mailing list