"var" declarations shadowing properties from Window.prototype

Cameron McCormack cam at mcc.id.au
Sun Aug 12 17:15:31 PDT 2012

Boris Zbarsky:
> Per the current spec proposal, the GSP lives on the proto chain and
> exposes the various id/name stuff as own properties on itself, with the
> usual caveats about checking up the proto chain first that DOM named
> access has.  See
> http://dev.w3.org/2006/webapi/WebIDL/#NamedPropertiesObject (which
> Window uses).  There was a bunch of previous discussion about this at
> http://lists.w3.org/Archives/Public/public-script-coord/2012JanMar/0010.html
> and following, though it's not clear to me now whether the solution we
> decided on allows var to shadow these named props as desired after all...

I think it should, since they're exposed as data properties on the named 
properties object.

More information about the es-discuss mailing list