Closed Bug 958643 Opened 6 years ago Closed 2 years ago

de-holder XPCConvert::NativeInterface2JSObject

Categories

(Core :: XPConnect, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla58
Tracking Status
firefox58 --- fixed

People

(Reporter: mccr8, Assigned: mccr8)

References

Details

Attachments

(6 files)

With bug 958641 fixed, all callers of XPCConvert::NativeInterface2JSObject pass in null for the nsIXPConnectJSObjectHolder argument, so we can remove that argument and rip out a bunch of gunk in that function.
This is slightly trickier that I thought, because in the case of XPCConvert::NativeInterface2JSObject, it will return an existing wrapped JS, if there is one, so we can't just hoist the holder allocation out without fixing the weird holder stuff in storage/. I don't know if it actually matters, but it seems better to be cautious here.
The storage weirdness is gone now thanks to jandem, so this can proceed.
Assignee: nobody → continuation
Comment on attachment 8910825 [details]
Bug 958643, part 1 - Remove the unused nsXPConnect::WrapNativeHolder.

https://reviewboard.mozilla.org/r/182302/#review188286
Attachment #8910825 - Flags: review?(gkrizsanits) → review+
Comment on attachment 8910825 [details]
Bug 958643, part 1 - Remove the unused nsXPConnect::WrapNativeHolder.

https://reviewboard.mozilla.org/r/182302/#review188288
Comment on attachment 8910826 [details]
Bug 958643, part 2 - Remove always-null last argument to NativeInterface2JSObject.

https://reviewboard.mozilla.org/r/182304/#review188290
Attachment #8910826 - Flags: review?(gkrizsanits) → review+
Comment on attachment 8910827 [details]
Bug 958643, part 3 - Remove always-null second second argument to XPCConvert::NativeInterface2JSObject.

https://reviewboard.mozilla.org/r/182306/#review188292
Attachment #8910827 - Flags: review?(gkrizsanits) → review+
Comment on attachment 8910828 [details]
Bug 958643, part 4 - Inline CreateHolderIfNeeded.

https://reviewboard.mozilla.org/r/182308/#review188294
Attachment #8910828 - Flags: review?(gkrizsanits) → review+
Comment on attachment 8910829 [details]
Bug 958643, part 5 - Eliminate XPCJSObjectHolder.

https://reviewboard.mozilla.org/r/182310/#review188296
Attachment #8910829 - Flags: review?(gkrizsanits) → review+
Comment on attachment 8910830 [details]
Bug 958643, part 6 - Remove some unused forward decls.

https://reviewboard.mozilla.org/r/182312/#review188298
Attachment #8910830 - Flags: review?(gkrizsanits) → review+
Pushed by amccreight@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/a275322b9145
part 1 - Remove the unused nsXPConnect::WrapNativeHolder. r=krizsa
https://hg.mozilla.org/integration/autoland/rev/f89c8e0123a8
part 2 - Remove always-null last argument to NativeInterface2JSObject. r=krizsa
https://hg.mozilla.org/integration/autoland/rev/1660b35ac2a4
part 3 - Remove always-null second second argument to XPCConvert::NativeInterface2JSObject. r=krizsa
https://hg.mozilla.org/integration/autoland/rev/05bc96d4a5f9
part 4 - Inline CreateHolderIfNeeded. r=krizsa
https://hg.mozilla.org/integration/autoland/rev/0a3096102f10
part 5 - Eliminate XPCJSObjectHolder. r=krizsa
https://hg.mozilla.org/integration/autoland/rev/1ece772039cd
part 6 - Remove some unused forward decls. r=krizsa
Duplicate of this bug: 1180038
Duplicate of this bug: 1180040
You need to log in before you can comment on or make changes to this bug.