Closed
Bug 881333
Opened 12 years ago
Closed 12 years ago
Use accessor methods for cx->compartment and cx->runtime
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
RESOLVED
FIXED
mozilla24
People
(Reporter: bhackett1024, Unassigned)
References
Details
Attachments
(1 file)
540.83 KB,
patch
|
luke
:
review+
|
Details | Diff | Splinter Review |
Bug 875661, bug 875125, and other future work want ways to interact with the VM from off the main thread. These will work by adding superclasses of JSContext that have fewer capabilities. One problem though is that JSContext's first fields, as enshrined in jsfriendapi ContextFriendFields, are direct pointers to the context's compartment, zone and runtime. It would be better if these were protected members, so that subclasses of ContextFriendFields could decide what functionality to expose from these in a threadsafe way.
The attached patch changes cx->compartment and cx->runtime into cx->compartment() and cx->runtime(). The only interesting bits are in jspubtd.h and jscntxt.h.
Attachment #760460 -
Flags: review?(luke)
Updated•12 years ago
|
Attachment #760460 -
Flags: review?(luke) → review+
Reporter | ||
Comment 1•12 years ago
|
||
Comment 2•12 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/21e3c2610814
https://hg.mozilla.org/mozilla-central/rev/b0afcbcafb72
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla24
You need to log in
before you can comment on or make changes to this bug.
Description
•