Closed Bug 699945 Opened 14 years ago Closed 13 years ago

Make __proto__ configurable

Categories

(Core :: JavaScript Engine, defect)

15 Branch
x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 770344
mozilla14

People

(Reporter: jorendorff, Unassigned)

References

()

Details

__proto__ would stop appearing to be an own property of every object that inherits from Object.prototype. (It appears that way now because of the shared-permanent hack, but nobody depends on it. We special-case object literals, like {__proto__: null}, in the parser, turning the property initialization there into an assignment.) Also it would be possible to delete it. I think this is fine and the Caja folks would be thrilled. Actually maybe we should hold out for beer from the Caja team. Nah.
Related strawman (discussion linked in the wiki): http://wiki.ecmascript.org/doku.php?id=strawman:magic_proto_property Based on the discussions, it seems that being able to delete __proto__ would already be a tremendous win.
The one-liner passes all the shell tests. Running mochitests now: https://tbpl.mozilla.org/?tree=Try&rev=18badd3a671a
Target Milestone: --- → mozilla14
Version: Other Branch → 15 Branch
Appears to cause crashes. Awesome.
This got fixed in bug 770344.
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.