Re: variable declarations shadowing named properties on window

On 1/6/12 1:16 PM, Travis Leithead wrote:
> Will moving the object that supports named properties to be in the prototype chain
> mess up anything else? Based on WebIDL's [DefineOwnProperty] algorithm for platform
> objects, it already seems like [ReplaceableNamedProperties] and [OverrideBuiltins]
> are mutually exclusive--so there probably won't be a problem there.

I think that's correct...

Note that Gecko already has element ids (but not frame names) on the 
proto chain, not directly on the window.  Of course it also only has 
them in quirks mode....

> It seems like moving the GSP functionality to the prototype should only happen for
> [ReplaceableNamedProperties] and only for named properties (not indexed properties).

Why not indexed properties, for the window case?  What's the benefit of 
keeping indexed properties on the window itself?  There's at least one 
drawback: it complicates implementation a good bit, at least in Gecko.

-Boris

Received on Friday, 6 January 2012 18:30:06 UTC