Replace idl nsIMutableArray usage with Array<T>
Categories
(MailNews Core :: General, task)
Tracking
(thunderbird_esr78 wontfix)
Tracking | Status | |
---|---|---|
thunderbird_esr78 | --- | wontfix |
People
(Reporter: benc, Assigned: benc)
References
Details
Attachments
(2 files, 2 obsolete files)
88.52 KB,
patch
|
benc
:
review+
|
Details | Diff | Splinter Review |
1.71 KB,
patch
|
benc
:
review+
|
Details | Diff | Splinter Review |
This covers:
mailnews/search/public/nsIMsgFilter.idl
mailnews/search/public/nsIMsgSearchSession.idl
mailnews/base/public/nsIMsgDBView.idl
mailnews/extensions/mailviews/nsIMsgMailView.idl
https://searchfox.org/comm-central/search?q=nsIMutableArray&case=true&path=*.idl
Assignee | ||
Updated•4 years ago
|
Assignee | ||
Comment 1•4 years ago
|
||
The nsIMutableArray use in xpidl interfaces is especially problematic because it means that the caller can mutate the array at any time without the owner being aware of it. In practice, I only found one place which seemed to do that - saveSearchTerms. I'm not too happy with the fix I used there, but without having a bigger-picture view I don't have a feel for what would be the Right Thing(tm). So for now, it'll work and is slightly more explicit than what was already there.
Try run here:
https://treeherder.mozilla.org/jobs?repo=try-comm-central&revision=3f1f608aeb2283704ae5f5483b0e47fdd0bd7b6f
Comment 2•4 years ago
|
||
Assignee | ||
Comment 3•4 years ago
|
||
(In reply to Magnus Melin [:mkmelin] from comment #2)
- @param {Array.<nsIMsgSearchTerms>} aSearchTerms - The search terms to
@param {nsIMsgSearchTerms[]}
... I think is better.
Ahh! Thanks - didn't know about that syntax. Much nicer.
Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/4e7c4249e3b1
Remove nsIMutableArray use from nsIMsgMailView, nsIMsgFilter and nsIMsgSearchSession. r=mkmelin
Updated•4 years ago
|
Comment 6•4 years ago
|
||
Found an unused ref to spoil the stats ;)
Comment 7•4 years ago
|
||
Assignee | ||
Comment 8•4 years ago
|
||
Updated•4 years ago
|
Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/345c1cc51a98
remove stray nsIMutableArray reference in nsIMsgDBView.idl. r=benc
Description
•