Closed
Bug 750104
Opened 14 years ago
Closed 12 years ago
Object.getOwnPropertyNames(window) not listing HTML{tag}Element
Categories
(Firefox :: Untriaged, defect)
Tracking
()
RESOLVED
DUPLICATE
of bug 807222
People
(Reporter: hello, Unassigned)
Details
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:11.0) Gecko/20100101 Firefox/11.0
Build ID: 20120312181643
Steps to reproduce:
HTMLPreElement object is global, i.e.
console.log('HTMLPreElement' in window); //=> true
but running
console.log(Object.getOwnPropertyNames(window));
or even
console.log(Object.getOwnPropertyNames(window.Window.prototype));
returns an array without HTMLPreElement (or any other HTML element objects).
Actual results:
The method returned an array with property names.
Expected results:
MDN states that Object.getOwnPropertyNames should return a list of enumerable and non-enumerable properties, which I would have expected to include HTMLPreElement, HTMLSpanElement etc.
While this may be on purpose, I filed this as a bug because even a simple for (x in window) in WebKit lists all global properties, HTML{tag}Element objects included.
Updated•12 years ago
|
Status: UNCONFIRMED → RESOLVED
Closed: 12 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•