Value type of map need not be default copyable
François Dumont
frs.dumont@gmail.com
Mon Aug 13 19:50:00 GMT 2012
On 08/13/2012 02:10 PM, Paolo Carlini wrote:
> On 08/12/2012 10:00 PM, François Dumont wrote:
>> Ok for trunk ?
> Ok, thanks!
>
> Paolo.
>
> PS: you may want to remove the trailing blank line of
> testsuite_counter_type.h
>
Attached patch applied.
2012-08-13 François Dumont <fdumont@gcc.gnu.org>
Ollie Wild <aaw@google.com>
* include/bits/hashtable.h
(_Hashtable<>_M_insert_multi_node(hash_code, node_type*)): New.
(_Hashtable<>_M_insert(_Args&&, false_type)): Use latter.
(_Hashtable<>::_M_emplace(false_type, _Args&&...)): Likewise.
(_Hashtable<>::_M_insert_bucket): Replace by ...
(_Hashtable<>::_M_insert_unique_node(size_type, hash_code,
node_type*)):
... this, new.
(_Hashtable<>::_M_insert(_Args&&, true_type)): Use latter.
(_Hashtable<>::_M_emplace(true_type, _Args&&...)): Likewise.
* include/bits/hashtable_policy.h (_Map_base<>::operator[]): Use
latter, emplace the value_type rather than insert.
* include/std/unordered_map: Include tuple.
* include/std/unordered_set: Likewise.
* testsuite/util/testsuite_counter_type.h: New.
* testsuite/23_containers/unordered_map/operators/2.cc: New.
François
-------------- next part --------------
A non-text attachment was scrubbed...
Name: hashtable.patch
Type: text/x-patch
Size: 19924 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/libstdc++/attachments/20120813/b3d6ccc5/attachment.bin>
More information about the Libstdc++
mailing list