Closed
Bug 906918
Opened 11 years ago
Closed 11 years ago
Use MoveRef's in nsTHashtable
Categories
(Core :: XPCOM, defect)
Core
XPCOM
Tracking
()
RESOLVED
FIXED
mozilla26
People
(Reporter: justin.lebar+bug, Unassigned)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
5.82 KB,
patch
|
benjamin
:
review+
|
Details | Diff | Splinter Review |
See patch in a moment.
Reporter | ||
Comment 1•11 years ago
|
||
This patch adds a move constructor for nsTHashtable and also lets nsTHashtable use its EntryType's move constructor, if one is available. This patch also adds move constructors for nsCharPtrHashKey and nsUnicharPtrHashKey. Using these new constructors, nsTHashtable will be able to avoid strdup()'ing all of its keys whenever it resizes the table.
Attachment #792471 -
Flags: review?(benjamin)
Updated•11 years ago
|
Attachment #792471 -
Flags: review?(benjamin) → review+
Reporter | ||
Comment 2•11 years ago
|
||
Waldo et al., thanks a lot for moving Move into mfbt. This is a really powerful abstraction.
Comment 3•11 years ago
|
||
I see what you did there.
Reporter | ||
Comment 4•11 years ago
|
||
Thanks! https://hg.mozilla.org/integration/mozilla-inbound/rev/7b925807955c
Comment 5•11 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/7b925807955c
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla26
Comment 6•11 years ago
|
||
Hmm, can we use C++11 move() here as well?
You need to log in
before you can comment on or make changes to this bug.
Description
•