unordered map design modification

François Dumont frs.dumont@gmail.com
Thu Oct 25 20:15:00 GMT 2012


     Here is the patch to apply the same modification applied to 
unordered_set and unordered_multiset. It also use default implementation 
for unordered_set/unordered_multiset copy/move constructor/assignment 
operators.

2012-10-25  François Dumont  <fdumont@gcc.gnu.org>

     * include/bits/unordered_map.h (unordered_map<>): Prefer
     aggreagation to inheritance with _Hashtable.
     (unordered_multimap<>): Likewise.
     * include/bits/unordered_set.h
     (unordered_set<>(const unordered_set&)):  Use default
     implementation.
     (unordered_set<>(unordered_set&&)): Likewise.
     (unordered_set<>::operator=(const unordered_set&)): Likewise.
     (unordered_set<>::operator=(unordered_set&&)): Likewise.
     (unordered_multiset<>(const unordered_multiset&)): Likewise.
     (unordered_multiset<>(unordered_multiset&&)): Likewise.
     (unordered_multiset<>::operator=(const unordered_multiset&)):
     Likewise.
(unordered_multiset<>::operator=(unordered_multiset&&)): Likewise.
     * include/debug/unordered_map (operator==): Adapt.
     * include/profile/unordered_map (operator==): Adapt.

Tested under Linux x86_64 normal/debug/profile modes.

François

-------------- next part --------------
A non-text attachment was scrubbed...
Name: unordered_containers.patch
Type: text/x-patch
Size: 52740 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/libstdc++/attachments/20121025/2e4ebcaa/attachment.bin>


More information about the Libstdc++ mailing list