Closed
Bug 1012798
Opened 11 years ago
Closed 10 years ago
Remove the expando hackery we have for window.window
Categories
(Core :: DOM: Core & HTML, defect)
Tracking
()
RESOLVED
FIXED
mozilla37
People
(Reporter: bzbarsky, Assigned: bzbarsky)
References
Details
Attachments
(4 files, 2 obsolete files)
4.09 KB,
patch
|
Details | Diff | Splinter Review | |
1.53 KB,
patch
|
jorendorff
:
review+
|
Details | Diff | Splinter Review |
1.79 KB,
patch
|
efaust
:
review+
|
Details | Diff | Splinter Review |
8.46 KB,
patch
|
Details | Diff | Splinter Review |
Right now this is explicitly defined as an expando on Window. We should probably move to using a StoreInSlot property.
Assignee | ||
Comment 1•11 years ago
|
||
We really want to use StoreInSlot here, but need to make that work with our situation in this case, where outerizing while creating the window object will crash. Basically, need to special-case this getter somehow.
Assignee | ||
Comment 2•10 years ago
|
||
Note to self: talked to Peter and there are two options:
1) Just special-case the codegen to not spit out the "get in the wrapping func" bit for window.window.
2) Change window.window to have a self-hosted getter of some sort. We'd need to figure out what sort, and how to have it do (or in Ion not do as needed!) this typechecks.
Comment 3•10 years ago
|
||
BTW, I'd be ok with doing 1 for now if 2 is going to take too long.
Assignee | ||
Comment 4•10 years ago
|
||
Attachment #8524318 -
Flags: review?(jorendorff)
Assignee | ||
Updated•10 years ago
|
Assignee: nobody → bzbarsky
Status: NEW → ASSIGNED
Assignee | ||
Comment 5•10 years ago
|
||
Attachment #8524319 -
Flags: review?(peterv)
Assignee | ||
Comment 6•10 years ago
|
||
This makes things pretty close to as fast as they used to be. The one issue left is a pointless guard on the window's shape; I filed bug 1100757 on that.
Attachment #8524322 -
Flags: review?(efaustbmo)
Comment 7•10 years ago
|
||
Comment on attachment 8524322 [details] [diff] [review]
part 3. When doing a DOM slot get in Ion, check whether we're doing a get of a constant value on a singleton object (e.g. .window) and if so just use the constant value directly
Review of attachment 8524322 [details] [diff] [review]:
-----------------------------------------------------------------
Yeah, this is cute. r=me
Attachment #8524322 -
Flags: review?(efaustbmo) → review+
Comment 8•10 years ago
|
||
Comment on attachment 8524319 [details] [diff] [review]
part 2. Stop defining a value property named "window" on the global
Review of attachment 8524319 [details] [diff] [review]:
-----------------------------------------------------------------
::: dom/base/nsGlobalWindow.cpp
@@ +2597,5 @@
>
> if (!aState) {
> + // Get the "window" property once so it will be cached on our inner. We
> + // have to do this here, not in binding code, because this has to happen
> + // after we've created the GetWrapperPreserveColor() for our outer.
Hmm, that last sentence doesn't make sense, did you mean "after we've created our new outer window proxy"?
Attachment #8524319 -
Flags: review?(peterv) → review+
Assignee | ||
Comment 9•10 years ago
|
||
I meant created it and set it on the outer nsGlobalWindow. I'll adjust the comment to make that clearer.
Assignee | ||
Comment 10•10 years ago
|
||
Assignee | ||
Updated•10 years ago
|
Attachment #8524319 -
Attachment is obsolete: true
Assignee | ||
Comment 11•10 years ago
|
||
Assignee | ||
Updated•10 years ago
|
Attachment #8526022 -
Attachment is obsolete: true
Comment 12•10 years ago
|
||
Comment on attachment 8524318 [details] [diff] [review]
part 1. Add one more available reserved slot on globals, because we need it for Window
Review of attachment 8524318 [details] [diff] [review]:
-----------------------------------------------------------------
All yours.
Attachment #8524318 -
Flags: review?(jorendorff) → review+
Assignee | ||
Comment 13•10 years ago
|
||
Comment 14•10 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/cfeb16066597
https://hg.mozilla.org/mozilla-central/rev/013ca85eaa42
https://hg.mozilla.org/mozilla-central/rev/b58035bdc84f
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla37
Updated•6 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•