Closed
Bug 1124890
Opened 10 years ago
Closed 10 years ago
Replace LookProperty with GetOwnProperty in ObjectToSource
Categories
(Core :: JavaScript: Standard Library, defect)
Core
JavaScript: Standard Library
Tracking
()
RESOLVED
FIXED
mozilla38
People
(Reporter: evilpie, Assigned: evilpie)
References
(Blocks 1 open bug)
Details
Attachments
(2 files)
3.13 KB,
patch
|
Waldo
:
review+
|
Details | Diff | Splinter Review |
3.79 KB,
patch
|
Details | Diff | Splinter Review |
ObjectToSource only seems to only enumerate own properties.
Attachment #8553361 -
Flags: review?(jwalden+bmo)
Comment 1•10 years ago
|
||
Comment on attachment 8553361 [details] [diff] [review] v1 object-tosource Review of attachment 8553361 [details] [diff] [review]: ----------------------------------------------------------------- ::: js/src/builtin/Object.cpp @@ -255,5 @@ > - * undefined. > - */ > - if (gsop[j] && val[j].isUndefined()) > - continue; > - As I recall, this old code took effect for situations like this: var desc = { get: undefined, set: undefined, configurable: true, enumerable: true }; var obj = Object.defineProperty({}, "prop", desc); obj.toSource(); Please add a stupid test somewhere (in an extensions/ folder if a jstest) that does this, to be sure this works.
Attachment #8553361 -
Flags: review?(jwalden+bmo) → review+
Assignee | ||
Comment 2•10 years ago
|
||
Good catch!
Assignee | ||
Updated•10 years ago
|
Assignee: nobody → evilpies
Assignee | ||
Comment 3•10 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/42d4b2cb18b6
Comment 4•10 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/42d4b2cb18b6
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla38
You need to log in
before you can comment on or make changes to this bug.
Description
•