Closed Bug 811100 Opened 13 years ago Closed 13 years ago

JSObject::global() should use the compartment instead of the parent chain

Categories

(Core :: JavaScript Engine, defect)

x86_64
Linux
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla19

People

(Reporter: mrbkap, Assigned: mrbkap)

Details

Attachments

(1 file)

I happened to notice that we do the parent walk dance in order to get the global for JS objects only to assert that it's the same as the compartment's global. We should do this the other way around to take advantage of CPG.
Attached patch Proposed patchSplinter Review
My pastebin'd patch differs from this by the asterisk on the return value.
Attachment #680803 - Flags: review?(luke)
Comment on attachment 680803 [details] [diff] [review] Proposed patch maybe compiling before committing is a good idea after all...
Attachment #680803 - Flags: review?(luke) → review+
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla19
Oh, good. I noticed then when looking at bug 805052 and then promptly forgot about it.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: