Closed
Bug 1468252
Opened 6 years ago
Closed 6 years ago
Remove JSObject::global()
Categories
(Core :: JavaScript Engine, enhancement)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
mozilla62
Tracking | Status | |
---|---|---|
firefox62 | --- | fixed |
People
(Reporter: jandem, Assigned: jandem)
References
Details
Attachments
(8 files)
3.03 KB,
patch
|
luke
:
review+
|
Details | Diff | Splinter Review |
2.86 KB,
patch
|
evilpie
:
review+
|
Details | Diff | Splinter Review |
5.85 KB,
patch
|
luke
:
review+
|
Details | Diff | Splinter Review |
11.22 KB,
patch
|
luke
:
review+
|
Details | Diff | Splinter Review |
1.74 KB,
patch
|
Waldo
:
review+
|
Details | Diff | Splinter Review |
1.64 KB,
patch
|
evilpie
:
review+
|
Details | Diff | Splinter Review |
3.15 KB,
patch
|
luke
:
review+
|
Details | Diff | Splinter Review |
6.71 KB,
patch
|
luke
:
review+
|
Details | Diff | Splinter Review |
See bug 1466112. Let's start with JSObject::global().
Assignee | ||
Comment 1•6 years ago
|
||
For now this just forwards to JSObject::global, but at some point it will forward to nonCCWGlobal()/maybeGlobal() or something.
Attachment #8984886 -
Flags: review?(luke)
Assignee | ||
Comment 2•6 years ago
|
||
Attachment #8984888 -
Flags: review?(evilpies)
Assignee | ||
Comment 3•6 years ago
|
||
Some places call environment->global() but could just use cx->global() or script->global() instead.
Attachment #8984889 -
Flags: review?(luke)
Updated•6 years ago
|
Attachment #8984886 -
Flags: review?(luke) → review+
Updated•6 years ago
|
Attachment #8984889 -
Flags: review?(luke) → review+
Updated•6 years ago
|
Attachment #8984888 -
Flags: review?(evilpies) → review+
Assignee | ||
Comment 4•6 years ago
|
||
Attachment #8985064 -
Flags: review?(luke)
Assignee | ||
Comment 5•6 years ago
|
||
GetInitialShapeProtoKey is only interested in certain builtin NativeObject protos, so let's just check for that. Then we can also just use NativeObject::global.
Attachment #8985067 -
Flags: review?(jwalden+bmo)
Assignee | ||
Comment 6•6 years ago
|
||
This lets us call obj->zone() instead of obj->global().
Attachment #8985070 -
Flags: review?(evilpies)
Assignee | ||
Comment 7•6 years ago
|
||
Attachment #8985071 -
Flags: review?(luke)
Assignee | ||
Comment 8•6 years ago
|
||
At this point there are a handful of JSObject::global calls left in some APIs and Debugger code. These need to be fixed/audited in follow-up bugs so this renames JSObject::global to deprecatedGlobal.
Attachment #8985072 -
Flags: review?(luke)
Updated•6 years ago
|
Attachment #8985064 -
Flags: review?(luke) → review+
Updated•6 years ago
|
Attachment #8985071 -
Flags: review?(luke) → review+
Comment 9•6 years ago
|
||
Comment on attachment 8985072 [details] [diff] [review]
Part 8 - Rename JSObject::global to deprecatedGlobal
Review of attachment 8985072 [details] [diff] [review]:
-----------------------------------------------------------------
Great idea with the explicit deprecation
Attachment #8985072 -
Flags: review?(luke) → review+
Updated•6 years ago
|
Attachment #8985070 -
Flags: review?(evilpies) → review+
Updated•6 years ago
|
Attachment #8985067 -
Flags: review?(jwalden+bmo) → review+
Comment 10•6 years ago
|
||
Pushed by jandemooij@gmail.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/671e4d24c511
part 1 - Define NativeObject::global(). r=luke
https://hg.mozilla.org/integration/mozilla-inbound/rev/09901c91248b
part 2 - Rename GetOriginalEval to GetRealmOriginalEval, remove scope argument. r=evilpie
https://hg.mozilla.org/integration/mozilla-inbound/rev/4face648a152
part 3 - Remove some environment->global() calls. r=luke
https://hg.mozilla.org/integration/mozilla-inbound/rev/3d767ed287af
part 4 - Add JSObject::nonCCWGlobal() and use it in a few places. r=luke
https://hg.mozilla.org/integration/mozilla-inbound/rev/e9c6358496ff
part 5 - Check for native objects in GetInitialShapeProtoKey. r=jwalden
https://hg.mozilla.org/integration/mozilla-inbound/rev/d2931773b28b
part 6 - Use isSelfHostingZone instead of isSelfHostingGlobal in getNonWrapperObjectForCurrentCompartment. r=evilpie
https://hg.mozilla.org/integration/mozilla-inbound/rev/5a19b871c590
part 7 - Replace more environment->global() calls. r=luke
https://hg.mozilla.org/integration/mozilla-inbound/rev/fc2ffbc36c07
part 8 - Rename JSObject::global to deprecatedGlobal. r=luke
Comment 11•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/671e4d24c511
https://hg.mozilla.org/mozilla-central/rev/09901c91248b
https://hg.mozilla.org/mozilla-central/rev/4face648a152
https://hg.mozilla.org/mozilla-central/rev/3d767ed287af
https://hg.mozilla.org/mozilla-central/rev/e9c6358496ff
https://hg.mozilla.org/mozilla-central/rev/d2931773b28b
https://hg.mozilla.org/mozilla-central/rev/5a19b871c590
https://hg.mozilla.org/mozilla-central/rev/fc2ffbc36c07
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
status-firefox62:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla62
You need to log in
before you can comment on or make changes to this bug.
Description
•