Closed
Bug 1646772
Opened 5 years ago
Closed 5 years ago
Add a variant of nsClassHashtable::LookupOrAdd that accepts a factory function
Categories
(Core :: XPCOM, task)
Core
XPCOM
Tracking
()
RESOLVED
FIXED
mozilla79
Tracking | Status | |
---|---|---|
firefox79 | --- | fixed |
People
(Reporter: sg, Assigned: sg)
References
Details
Attachments
(1 file)
nsClassHashtable::LookupOrAdd
cannot be used when the arguments are not trivial, because they would be evaluated even if no element is added. A variant that uses a function argument that produces the new value and which is called only when a new element must be added would be handy.
Assignee | ||
Comment 1•5 years ago
|
||
Pushed by sgiesecke@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/39272eb97a4c
Add nsClassHashtable::LookupOrAddFromFactory and missing tests for nsClassHashtable::LookupForAdd. r=froydnj
Comment 3•5 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 5 years ago
status-firefox79:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla79
You need to log in
before you can comment on or make changes to this bug.
Description
•