W3C home > Mailing lists > Public > public-script-coord@w3.org > January to March 2012

RE: variable declarations shadowing named properties on window

From: Travis Leithead <travis.leithead@microsoft.com>
Date: Wed, 4 Jan 2012 21:31:36 +0000
To: Boris Zbarsky <bzbarsky@MIT.EDU>
CC: Ojan Vafai <ojan@chromium.org>, Cameron McCormack <cam@mcc.id.au>, "public-script-coord@w3.org" <public-script-coord@w3.org>, Allen Wirfs-Brock <allen@wirfs-brock.com>, Ian Hickson <ian@hixie.ch>
Message-ID: <9768D477C67135458BF978A45BCF9B38381E6215@TK5EX14MBXW604.wingroup.windeploy.ntdev.microsoft.com>
>-----Original Message-----
>From: Boris Zbarsky [mailto:bzbarsky@MIT.EDU]
>That is, is the ES global in IE actually a proxy and not a "native" object?

When you say "proxy" I assume you think that there are actually two objects, a "native object" and a "proxy object". In that sense, the window object is not a proxy--there is only one instance of it hanging around. However, when Trident binds onto it for the purposes of GSP, it replaces some of its default behavior with "window-like" behavior. In that sense it becomes a proxy, but there's no other native object that it is "wrapping". Like [OverrideBuiltins], the augmented object has the ability to consult the GSP before or after a property lookup. In the case of window, GSP lookups are done after the normal lookup. This results in the lookup order that Cameron described at the beginning of this thread.

>It really sounds like the behavior IE has here is not actually
>describable in terms of the ES spec (even with proxies, if I understand
>it correctly) as things stand...

Not having a good understanding of ES proxies, I can't comment on that.
Received on Wednesday, 4 January 2012 21:32:12 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 8 May 2013 19:30:05 UTC