8a0436cb79
303 Commits
Author | SHA1 | Message | Date | |
---|---|---|---|---|
François Dumont
|
1c56f7cb72 |
hashtable.h (_Hashtable<>::__rehash_policy(const _RehashPolicy&)): Commit the modification of the policy only if no exception occured.
2011-09-17 François Dumont <fdumont@gcc.gnu.org> * include/bits/hashtable.h (_Hashtable<>::__rehash_policy(const _RehashPolicy&)): Commit the modification of the policy only if no exception occured. * testsuite/23_containers/unordered_set/max_load_factor/robustness.cc: New. From-SVN: r178927 |
||
Paolo Carlini
|
71743a68ec |
less_or_equal.cc: New.
2011-09-16 Paolo Carlini <paolo.carlini@oracle.com> * testsuite/23_containers/array/comparison_operators/ less_or_equal.cc: New. * testsuite/23_containers/array/comparison_operators/ greater_or_equal.cc: Likewise. * testsuite/23_containers/array/comparison_operators/less.cc: Likewise. * testsuite/23_containers/array/comparison_operators/equal.cc: Likewise. * testsuite/23_containers/array/comparison_operators/not_equal.cc: Likewise. * testsuite/23_containers/array/comparison_operators/greater.cc: Likewise. * testsuite/23_containers/array/iterators/end_is_one_past.cc: Likewise. * testsuite/23_containers/array/capacity/empty.cc: Likewise. * testsuite/23_containers/array/capacity/max_size.cc: Likewise. * testsuite/23_containers/array/capacity/size.cc: Likewise. * testsuite/23_containers/array/tuple_interface/tuple_element.cc: Likewise. * testsuite/23_containers/array/tuple_interface/tuple_size.cc: Likewise. * testsuite/23_containers/array/element_access/at_out_of_range.cc: Likewise. * testsuite/23_containers/array/element_access/back.cc: Likewise. * testsuite/23_containers/array/element_access/front.cc: Likewise. * testsuite/23_containers/array/element_access/data.cc: Likewise. * testsuite/23_containers/array/cons/aggregate_initialization.cc: Likewise. * testsuite/23_containers/array/requirements/zero_sized_arrays.cc: Likewise. * testsuite/23_containers/array/requirements/contiguous.cc: Likewise. * testsuite/23_containers/array/requirements/member_swap.cc: Likewise. * testsuite/23_containers/array/specialized_algorithms/swap.cc: Likewise. * testsuite/23_containers/array/constexpr_get.cc: Move... * testsuite/23_containers/array/tuple_interface/constexpr_get.cc: ... here. * testsuite/23_containers/array/requirements/get.cc: Move... * testsuite/23_containers/array/tuple_interface/get: ... here. * testsuite/23_containers/array/at_neg.cc: Move... * testsuite/23_containers/array/element_access: ... here. * testsuite/23_containers/array/requirements/constexpr_functions.cc: Move... * testsuite/23_containers/array/capacity: ... here. * testsuite/23_containers/array/requirements/ constexpr_element_access.cc: Move... * testsuite/23_containers/array/element_access: ... here. * testsuite/20_util/duration/cons/1_neg.cc: Avoid -Wall warnings. * testsuite/20_util/tuple/creation_functions/constexpr.cc: Likewise. * testsuite/20_util/pair/make_pair/constexpr.cc: Likewise. * testsuite/20_util/time_point/nonmember/constexpr.cc: Likewise. * testsuite/23_containers/bitset/operations/constexpr.cc: Likewise. * testsuite/20_util/duration/cons/1_neg.cc: Discard bogus warning. * testsuite/20_util/forward/1_neg.cc: Likewise. From-SVN: r178911 |
||
François Dumont
|
7e5ac0a4f5 |
hashtable.h (_Hashtable<>::_M_rehash): Take and restore hash policy _M_prev_resize on exception.
2011-09-14 François Dumont <fdumont@gcc.gnu.org> Paolo Carlini <paolo.carlini@oracle.com> * include/bits/hashtable.h (_Hashtable<>::_M_rehash): Take and restore hash policy _M_prev_resize on exception. (_Hashtable<>::_M_insert_bucket): Capture hash policy next resize before using it and use latter method to have it restored on exception. (_Hashtable<>::_M_insert(_Arg&& __v, std::false_type): Likewise. (_Hashtable<>::insert(_InputIterator, _InputIterator): Likewise. (_Hashtable<>::rehash): Likewise. * testsuite/23_containers/unordered_set/insert/hash_policy.cc: New. * testsuite/23_containers/unordered_multiset/insert/hash_policy.cc: Likewise. Co-Authored-By: Paolo Carlini <paolo.carlini@oracle.com> From-SVN: r178861 |
||
Daniel Krugler
|
9480716c80 |
tuple (_Head_base<>::_M_head, [...]): Change to static constexpr functions; adjust everywhere.
2011-09-12 Daniel Krugler <daniel.kruegler@googlemail.com> Paolo Carlini <paolo.carlini@oracle.com> * include/std/tuple (_Head_base<>::_M_head, _Head_base<>::_M_tail, _Tuple_impl<>::_M_head, _Tuple_impl<>::_M_tail): Change to static constexpr functions; adjust everywhere. (__get_helper, get): Declare constexpr all three overloads. (tuple_cat): Declare constexpr; use late return type to improve error messages. * include/std/utility (__pair_get<>::__get, __pair_get<>::__move_get, __pair_get<>::__const_get, get): Declare all constexpr. * include/std/array (get): Likewise. * testsuite/20_util/tuple/creation_functions/constexpr.cc: Re-enable tuple_cat test. * testsuite/23_containers/array/constexpr_get.cc: New. * testsuite/20_util/tuple/element_access/constexpr_get.cc: Likewise. * testsuite/20_util/pair/constexpr_get.cc: Likewise. * testsuite/20_util/weak_ptr/comparison/cmp_neg.cc: Adjust dg-error line number. Co-Authored-By: Paolo Carlini <paolo.carlini@oracle.com> From-SVN: r178799 |
||
François Dumont
|
02dce1e99c |
at.cc: Revert to...
2011-09-07 François Dumont <francois.cppdevs@free.fr> * testsuite/23_containers/array/at.cc: Revert to... * testsuite/23_containers/array/at_neg.cc: ...this. From-SVN: r178670 |
||
Benjamin Kosnik
|
a7d0c94ef1 |
tuple (_Tuple_impl::_M_head, _M_tail): Mark constexpr.
2011-09-06 Benjamin Kosnik <bkoz@redhat.com> * include/std/tuple (_Tuple_impl::_M_head, _M_tail): Mark constexpr. (tuple(tuple&&)): Same. (tuple(const tuple<_UElements...>& __in)): Same. (tuple(tuple<_UElements...>&& __in)): Same. (tuple_cat(const tuple<_TElements...>&, const tuple<_UElements...>&)): Same. (get): Same. * include/std/array: Consolidate array::data usage. * testsuite/23_containers/array/requirements/constexpr_functions.cc: Remove extra include. * testsuite/20_util/tuple/creation_functions/constexpr.cc: New. * testsuite/20_util/tuple/cons/constexpr-2.cc: Add tests. * testsuite/20_util/tuple/cons/constexpr-3.cc: Same. * testsuite/20_util/weak_ptr/comparison/cmp_neg.cc: Adjust line numbers. From-SVN: r178620 |
||
Paolo Carlini
|
5da7fa30da |
re PR libstdc++/50268 ([C++0x] bitset doesn't sanitize input)
2011-09-02 Paolo Carlini <paolo.carlini@oracle.com> Marc Glisse <marc.glisse@normalesup.org> PR libstdc++/50268 * include/std/bitset (struct _Sanitize_val): Add. (bitset<>::bitset(unsigned long long)): Fix. * testsuite/23_containers/bitset/cons/50268.cc: New. Co-Authored-By: Marc Glisse <marc.glisse@normalesup.org> From-SVN: r178463 |
||
Paolo Carlini
|
290df23d48 |
hashtable.h (_Hashtable<>::_Hashtable(_Hashtable&&)): Remove noexcept, the move constructor allocates memory...
2011-09-01 Paolo Carlini <paolo.carlini@oracle.com> * include/bits/hashtable.h (_Hashtable<>::_Hashtable(_Hashtable&&)): Remove noexcept, the move constructor allocates memory; rearrange the code in the body to consistently update __ht._M_rehash_policy before using _M_next_bkt on it. * include/debug/unordered_map: Adjust. * include/debug/unordered_set: Likewise. * include/profile/unordered_map: Likewise. * include/profile/unordered_set: Likewise. * testsuite/23_containers/unordered_map/cons/ noexcept_move_construct.cc: Remove. * testsuite/23_containers/unordered_set/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/unordered_multimap/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/unordered_multiset/cons/ noexcept_move_construct.cc: Likewise. From-SVN: r178423 |
||
Paolo Carlini
|
ff15f019e0 |
re PR libstdc++/50118 (node-based containers cannot use allocators with explicit constructor template)
2011-08-29 Paolo Carlini <paolo.carlini@oracle.com> PR libstdc++/50118 * include/bits/stl_list.h (_List_base<>:: _List_base(const allocator_type&)): Remove. (_List_base<>::_List_base(const _Node_alloc_type&)): Add. (list<>:list(const allocator_type&), list(size_type, const value_type&, const allocator_type&), list(initializer_list<, const allocator_type&), list(_InputIterator, _InputIterator, const allocator_type&), insert(iterator, size_type, const value_type&), insert(iterator, _InputIterator, _InputIterator)): Adjust. * include/bits/stl_tree.h (_Rb_tree<>::_Rb_tree(const _Compare&, const allocator_type&)): Fix. * include/bits/stl_map.h (map<>::map(const _Compare&, const allocator_type&), map(initializer_list<>, const _Compare&, const allocator_type&), map(_InputIterator, _InputIterator, const _Compare&, const allocator_type&), get_allocator): Adjust. * include/bits/stl_set.h (set<>::set(const _Compare&, const allocator_type&), set(initializer_list<>, const _Compare&, const allocator_type&), set(_InputIterator, _InputIterator, const _Compare&, const allocator_type&), get_allocator): Likewise. * include/bits/stl_multimap.h (multimap<>::multimap(const _Compare&, const allocator_type&), multimap(initializer_list<>, const _Compare&, const allocator_type&), multimap(_InputIterator, _InputIterator, const _Compare&, const allocator_type&), get_allocator): Likewise. * include/bits/stl_multiset.h (multiset<>::multiset(const _Compare&, const allocator_type&), multiset(initializer_list<>, const _Compare&, const allocator_type&), multiset(_InputIterator, _InputIterator, const _Compare&, const allocator_type&), get_allocator): Likewise. * include/bits/forward_list.h (_Fwd_list_base<>:: _Fwd_list_base(const _Alloc&), _Fwd_list_base(const _Fwd_list_base&, const _Alloc&), _Fwd_list_base(_Fwd_list_base&&, const _Alloc&)): Remove. (_Fwd_list_base<>::_Fwd_list_base(const _Node_alloc_type&), _Fwd_list_base(const _Fwd_list_base&, const _Node_alloc_type&), _Fwd_list_base(_Fwd_list_base&&, const _Node_alloc_type&)): Add. (forward_list<>::forward_list(const _Alloc&), forward_list(const forward_list&, const _Alloc&), forward_list(forward_list&&, const _Alloc&), forward_list(size_type, const _Tp&, const _Alloc&), forward_list(_InputIterator, _InputIterator, const _Alloc&), forward_list(std::initializer_list<>, const _Alloc&), get_allocator): Adjust. * include/bits/forward_list.tcc * testsuite/util/testsuite_allocator.h (ExplicitConsAlloc): Add. * testsuite/23_containers/unordered_map/requirements/ explicit_instantiation/5.cc: New. * testsuite/23_containers/multimap/requirements/ explicit_instantiation/5.cc: Likewise. * testsuite/23_containers/multimap/requirements/ explicit_instantiation/5_c++0x.cc: Likewise. * testsuite/23_containers/set/requirements/explicit_instantiation/ 5.cc: Likewise. * testsuite/23_containers/set/requirements/explicit_instantiation/ 5_c++0x.cc: Likewise. * testsuite/23_containers/unordered_multimap/requirements/ explicit_instantiation/5.cc: Likewise. * testsuite/23_containers/forward_list/requirements/ explicit_instantiation/5.cc: Likewise. * testsuite/23_containers/unordered_set/requirements/ explicit_instantiation/5.cc: Likewise. testsuite/23_containers/multiset/requirements/explicit_instantiation/ 5.cc: Likewise. * testsuite/23_containers/multiset/requirements/ explicit_instantiation/5_c++0x.cc: Likewise. * testsuite/23_containers/list/requirements/explicit_instantiation/ 5_c++0x.cc: Likewise. * testsuite/23_containers/list/requirements/explicit_instantiation/ 5.cc: Likewise. * testsuite/23_containers/unordered_multiset/requirements/ explicit_instantiation/5.cc: Likewise. * testsuite/23_containers/map/requirements/explicit_instantiation/ 5.cc: Likewise. * testsuite/23_containers/map/requirements/explicit_instantiation/ 5_c++0x.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/ assign_neg.cc: Adjust dg-error line number. * testsuite/23_containers/forward_list/requirements/dr438/ insert_neg.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_1_neg.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_2_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/assign_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/insert_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/ constructor_1_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/ constructor_2_neg.cc: Likewise. From-SVN: r178230 |
||
Benjamin Kosnik
|
93c66bc68a |
user.cfg.in (PDF_HYPERLINKS): To NO.
2011-08-06 Benjamin Kosnik <bkoz@redhat.com> * doc/doxygen/user.cfg.in (PDF_HYPERLINKS): To NO. 2011-08-06 Benjamin Kosnik <bkoz@redhat.com> * doc/doxygen/user.cfg.in: Add scoped_allocator. * include/debug/safe_sequence.h: Fix doxygen markup. * include/debug/safe_unordered_base.h: Same. * include/debug/safe_local_iterator.tcc: Same. * include/debug/safe_unordered_container.h: Same. * include/std/valarray: Same. * include/std/iomanip: Same. * include/std/streambuf: Same. * include/std/bitset: Same. * include/std/fstream: Same. * include/std/functional: Same. * include/std/istream: Same. * include/std/ostream: Same. * include/std/scoped_allocator: Same. * include/std/sstream: Same. * include/parallel/multiway_merge.h: Same. * include/parallel/base.h: Same. * include/parallel/for_each_selectors.h: Same. * include/parallel/multiway_mergesort.h: Same. * include/parallel/search.h: Same. * include/parallel/partial_sum.h: Same. * include/parallel/queue.h: Same. * include/parallel/sort.h: Same. * include/parallel/random_number.h: Same. * include/ext/vstring.h: Same. * include/ext/algorithm: Same. * include/ext/pb_ds/assoc_container.h: Same. * include/ext/bitmap_allocator.h: Same. * include/ext/stdio_filebuf.h: Same. * include/ext/memory: Same. * include/ext/functional: Same. * include/bits/basic_ios.h: Same. * include/bits/stl_list.h: Same. * include/bits/stl_map.h: Same. * include/bits/stl_algobase.h: Same. * include/bits/stl_queue.h: Same. * include/bits/gslice.h: Same. * include/bits/locale_classes.h: Same. * include/bits/stl_set.h: Same. * include/bits/locale_facets.h: Same. * include/bits/stl_stack.h: Same. * include/bits/stl_heap.h: Same. * include/bits/forward_list.h: Same. * include/bits/stream_iterator.h: Same. * include/bits/basic_string.h: Same. * include/bits/stl_multimap.h: Same. * include/bits/stl_pair.h: Same. * include/bits/ios_base.h: Same. * include/bits/stl_numeric.h: Same. * include/bits/stl_vector.h: Same. * include/bits/stl_deque.h: Same. * include/bits/codecvt.h: Same. * include/bits/stl_multiset.h: Same. * include/bits/stl_uninitialized.h: Same. * include/bits/ptr_traits.h: Same. * include/bits/slice_array.h: Same. * include/bits/stl_iterator_base_funcs.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/stl_tempbuf.h: Same. * include/bits/regex.h: Same. * include/bits/range_access.h: Same. * include/bits/random.h: Same. * include/bits/alloc_traits.h: Same. * include/bits/regex_error.h: Same. * include/bits/locale_facets_nonio.h: Same. * include/bits/stl_relops.h: Same. * include/backward/auto_ptr.h: Same. * libsupc++/initializer_list: Same. * testsuite/23_containers/list/requirements/dr438/assign_neg.cc: Adjust line numbers. * testsuite/23_containers/list/requirements/dr438/insert_neg.cc: Same. * testsuite/23_containers/list/requirements/dr438/constructor_1_neg.cc: Same. * testsuite/23_containers/list/requirements/dr438/constructor_2_neg.cc: Same. From-SVN: r177542 |
||
Benjamin Kosnik
|
2c4caf0ab9 |
tuple: Mark more constructors constexpr.
2011-08-03 Benjamin Kosnik <bkoz@redhat.com> * include/std/tuple: Mark more constructors constexpr. * testsuite/20_util/tuple/cons/constexpr.cc: Split into and extend as: * testsuite/20_util/tuple/cons/constexpr-2.cc: ...this. * testsuite/20_util/tuple/cons/constexpr-3.cc: ... and this. * testsuite/20_util/weak_ptr/comparison/cmp_neg.cc: Adjust line numbers. 2011-08-03 Benjamin Kosnik <bkoz@redhat.com> François Dumont <francois.cppdevs@free.fr> * testsuite/23_containers/array/at_neg.cc: Move... * testsuite/23_containers/array/at.cc: ...here. Remove -fno-exceptions, call const at member function. Co-Authored-By: François Dumont <francois.cppdevs@free.fr> From-SVN: r177299 |
||
Benjamin Kosnik
|
9bc13c238d |
array (at): Remove constexpr when -fno-exceptions.
2011-07-25 Benjamin Kosnik <bkoz@redhat.com> * include/std/array (at): Remove constexpr when -fno-exceptions. * testsuite/23_containers/array/at_neg.cc: Test. From-SVN: r176780 |
||
Paolo Carlini
|
cc2ba8e30f |
re PR libstdc++/49836 ([C++0x] vector<T>::push_back() should not require T to be (move-)assignable)
2011-07-25 Paolo Carlini <paolo.carlini@oracle.com> Nathan Ridge <zeratul976@hotmail.com> PR libstdc++/49836 * include/bits/stl_vector.h (vector<>::_M_emplace_back_aux): Declare. (vector<>::push_back(const value_type&)): Use it. * include/bits/vector.tcc: Define. (vector<>::emplace_back(_Args&&...)): Use it. * testsuite/util/testsuite_tr1.h (CopyConsOnlyType, MoveConsOnlyType): Add. * testsuite/23_containers/vector/modifiers/push_back/49836.cc: New. * testsuite/23_containers/deque/modifiers/push_back/49836.cc: Likewise. * testsuite/23_containers/deque/modifiers/push_front/49836.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/assign_neg.cc: Adjust dg-error line number. * testsuite/23_containers/vector/requirements/dr438/insert_neg.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/ constructor_1_neg.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/ constructor_2_neg.cc: Likewise. Co-Authored-By: Nathan Ridge <zeratul976@hotmail.com> From-SVN: r176761 |
||
François Dumont
|
4f7b188f20 |
hashtable_policy.h (_Prime_rehash_policy): Use __builtin_floor rather than __builtin_ceil to compute next resize value.
2011-07-24 François Dumont <francois.cppdevs@free.fr> * include/bits/hashtable_policy.h (_Prime_rehash_policy): Use __builtin_floor rather than __builtin_ceil to compute next resize value. * testsuite/23_containers/unordered_set/hash_policy/load_factor.cc: New. From-SVN: r176717 |
||
Benjamin Kosnik
|
bfef3a711a |
array (array::at, [...]): Mark constexpr.
2011-07-20 Benjamin Kosnik <bkoz@redhat.com> Daniel Krugler <daniel.kruegler@googlemail.com> * include/std/array (array::at, array::operator[]): Mark constexpr. * testsuite/23_containers/array/requirements/ constexpr_element_access.cc: Add. Co-Authored-By: Daniel Krugler <daniel.kruegler@googlemail.com> From-SVN: r176550 |
||
Benjamin Kosnik
|
07be61200c |
bitset (operator[]): Make constexpr.
2011-07-20 Benjamin Kosnik <bkoz@redhat.com> * include/std/bitset (operator[]): Make constexpr. * testsuite/23_containers/bitset/operations/constexpr.cc: New. From-SVN: r176519 |
||
François Dumont
|
77e0bf4e07 |
safe_unordered_base.h, [...]: New, support for unordered sequence safe local iterators.
2011-07-19 François Dumont <francois.cppdevs@free.fr> * include/debug/safe_unordered_base.h, safe_unordered_sequence.h, safe_unordered_sequence.tcc, safe_local_iterator.h, safe_local_iterator.tcc: New, support for unordered sequence safe local iterators. * include/Makefile.am: Add previous files. * include/Makefile.in: Regenerate. * include/debug/unordered_map, unordered_set: Implement _Safe_unordered_sequence and expose _Safe_local_iterator. * include/debug/safe_iterator.h, safe_iterator.tcc: Refactor _Safe_iterator::_M_get_distance static method to expose it as __get_distance function and use it in _Safe_local_iterator type. * include/debug/formatter.h: Add __msg_local_iter_compare_bad _Debug_msg_id enum entry to notify invalid comparison between local iterators from different buckets. Add _Parameter constructor from _Safe_local_iterator. * include/debug/functions.h: Add __valid_range overload for _Safe_local_iterator. * src/debug.cc: Add _Safe_unordered_sequence_base and _Safe_local_iterator_base methods implementations. * config/abi/pre/gnu.ver: Add export of some _Safe_unordered_sequence_base and _Safe_local_iterator_base methods. * testsuite/util/debug/checks.h: Add use_invalid_iterator function to simulate use of a singular iterator. * testsuite/util/debug/unordered_checks.h: New, several functions to simulate classic invalid usage of unordered sequence local iterators. * testsuite/23_containers/unordered_map/debug/ use_erased_local_iterator_neg.cc, invalid_local_iterator_range_neg.cc, use_invalid_local_iterator_neg.cc, use_invalid_iterator_neg.cc, invalid_local_iterator_compare_neg.cc: New. * testsuite/23_containers/unordered_multimap/debug/ use_erased_local_iterator_neg.cc, invalid_local_iterator_range_neg.cc, use_invalid_local_iterator_neg.cc, use_invalid_iterator_neg.cc, invalid_local_iterator_compare_neg.cc: New. * testsuite/23_containers/unordered_set/debug/ use_erased_local_iterator_neg.cc, invalid_local_iterator_range_neg.cc, use_invalid_local_iterator_neg.cc, use_invalid_iterator_neg.cc, invalid_local_iterator_compare_neg.cc: New. * testsuite/23_containers/unordered_multiset/debug/ use_erased_local_iterator_neg.cc, invalid_local_iterator_range_neg.cc, use_invalid_local_iterator_neg.cc, use_invalid_iterator_neg.cc, invalid_local_iterator_compare_neg.cc: New. From-SVN: r176487 |
||
Jonathan Wakely
|
bd8485dc9f |
stl_vector.h: Use new allocator model in C++0x mode.
2011-07-09 Jonathan Wakely <jwakely.gcc@gmail.com> * include/bits/stl_vector.h: Use new allocator model in C++0x mode. * include/bits/vector.tcc: Likewise. * testsuite/util/testsuite_allocator.h (propagating_allocator): Define. * testsuite/23_containers/vector/allocator/copy_assign.cc: New. * testsuite/23_containers/vector/allocator/noexcept.cc: New. * testsuite/23_containers/vector/allocator/copy.cc: New. * testsuite/23_containers/vector/allocator/swap.cc: New. * testsuite/23_containers/vector/allocator/move_assign.cc: New. * testsuite/23_containers/vector/requirements/dr438/assign_neg.cc: Adjust dg-error line numbers. * testsuite/23_containers/vector/requirements/dr438/insert_neg.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/constructor_1_neg.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/constructor_2_neg.cc: Likewise. From-SVN: r176078 |
||
François Dumont
|
8a752dfea6 |
allocator.h (__shrink_to_fit): Rename to __shrink_to_fit_aux, fix.
2011-06-12 François Dumont <francois.cppdevs@free.fr> Paolo Carlini <paolo.carlini@oracle.com> * include/bits/allocator.h (__shrink_to_fit): Rename to __shrink_to_fit_aux, fix. * include/bits/stl_vector.h (_M_shrink_to_fit): Declare. (shrink_to_fit): Use the latter. * include/debug/vector (shrink_to_fit): Likewise. * include/bits/vector.tcc (_M_shrink_to_fit): Define. * include/bits/stl_deque.h (_M_shrink_to_fit): Declare. (shrink_to_fit): Use the latter. * include/debug/deque (shrink_to_fit): Likewise. * include/bits/deque.tcc (_M_shrink_to_fit): Define. * include/bits/vector.tcc (vector<bool>::_M_reallocate): Add. * include/bits/stl_bvector.h (_M_shrink_to_fit): Declare. (shrink_to_fit): Use the latter. (reserve): Use _M_reallocate, move inline. (_Bvector_base<>::_S_nword): Add, use it throughout. * include/debug/string (shrink_to_fit): Redo. * include/ext/vstring.h (shrink_to_fit): Optimize. * include/bits/basic_string.h (shrink_to_fit): Likewise. * testsuite/21_strings/debug/shrink_to_fit.cc: New. * testsuite/23_containers/vector/debug/shrink_to_fit.cc: Likewise. * testsuite/23_containers/vector/debug/bool/shrink_to_fit.cc: Likewise. * testsuite/23_containers/vector/bool/capacity/shrink_to_fit.cc: Likewise. * testsuite/23_containers/deque/debug/shrink_to_fit.cc: Likewise. Co-Authored-By: Paolo Carlini <paolo.carlini@oracle.com> From-SVN: r174967 |
||
Jonathan Wakely
|
c51b58dc1f |
extptr_allocator.h (construct, destroy): Fix for C++0x mode by overloading to take allocator's pointer type.
2011-06-11 Jonathan Wakely <jwakely.gcc@gmail.com> * include/ext/extptr_allocator.h (construct, destroy): Fix for C++0x mode by overloading to take allocator's pointer type. * testsuite/23_containers/vector/ext_pointer/types/2.cc: New. * testsuite/23_containers/vector/ext_pointer/explicit_instantiation/ 2.cc: New. From-SVN: r174958 |
||
Jason Merrill
|
377a536430 |
prune.exp (libstdc++-dg-prune): Prune notes.
* testsuite/lib/prune.exp (libstdc++-dg-prune): Prune notes. * testsuite/20_util/duration/cons/1_neg.cc: Remove dg-excess-errors. * testsuite/20_util/duration/requirements/typedefs_neg2.cc: Likewise. * testsuite/20_util/forward/1_neg.cc: Likewise. * testsuite/20_util/function/cmp/cmp_neg.cc: Likewise. * testsuite/20_util/ratio/operations/ops_overflow_neg.cc: Likewise. * testsuite/20_util/reference_wrapper/ref_neg.cc: Likewise. * testsuite/20_util/tuple/comparison_operators/35480_neg.cc: Likewise. * testsuite/tr1/6_containers/tuple/comparison_operators/35480_neg.cc: Likewise. * testsuite/20_util/shared_ptr/assign/auto_ptr_neg.cc: Likewise. * testsuite/20_util/shared_ptr/cons/unique_ptr_neg.cc: Likewise. * testsuite/20_util/shared_ptr/assign/unique_ptr_lvalue_neg.cc: Likewise. * testsuite/20_util/unique_ptr/cons/auto_ptr_neg.cc: Likewise. * testsuite/20_util/unique_ptr/cons/ptr_deleter_neg.cc: Likewise. * testsuite/tr1/2_general_utilities/shared_ptr/assign/auto_ptr_neg.cc: Likewise. * testsuite/tr1/2_general_utilities/shared_ptr/assign/auto_ptr_rvalue_neg.cc: Likewise. * testsuite/tr1/2_general_utilities/shared_ptr/cons/auto_ptr_neg.cc: Likewise. * testsuite/20_util/uses_allocator/cons_neg.cc: Likewise. * testsuite/23_containers/deque/requirements/dr438/assign_neg.cc: Likewise. * testsuite/23_containers/deque/requirements/dr438/constructor_1_neg.cc: Likewise. * testsuite/23_containers/deque/requirements/dr438/insert_neg.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/assign_neg.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/constructor_1_neg.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/constructor_2_neg.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/insert_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/assign_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/constructor_1_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/constructor_2_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/insert_neg.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/assign_neg.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/constructor_1_neg.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/constructor_2_neg.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/insert_neg.cc: Likewise. * testsuite/23_containers/map/operators/1_neg.cc: Likewise. * testsuite/29_atomics/atomic_integral/operators/bitwise_neg.cc: Likewise. * testsuite/decimal/mixed-mode-arith_neg.cc: Likewise. * testsuite/decimal/mixed-mode-cmp_neg.cc: Likewise. * testsuite/decimal/operator_neg.cc: Likewise. From-SVN: r174884 |
||
Paolo Carlini
|
74a2a1b4f6 |
move.h (struct __move_if_noexcept_cond): Add.
2011-06-07 Paolo Carlini <paolo.carlini@oracle.com> * include/bits/move.h (struct __move_if_noexcept_cond): Add. (move_if_noexcept): Use the latter. * include/bits/stl_iterator.h (__make_move_if_noexcept_iterator, _GLIBCXX_MAKE_MOVE_IF_NOEXCEPT_ITERATOR): Add. * include/bits/stl_uninitialized.h (__uninitialized_move_if_noexcept_a): Add. * include/bits/vector.tcc (vector<>::reserve): Use _GLIBCXX_MAKE_MOVE_IF_NOEXCEPT_ITERATOR. (vector<>::_M_insert_aux, _M_fill_insert, _M_default_append, _M_range_insert): Use __uninitialized_move_if_noexcept_a. * testsuite/23_containers/vector/modifiers/moveable2.cc: New. * testsuite/23_containers/vector/capacity/resize/moveable2.cc: Likewise. * testsuite/23_containers/vector/capacity/reserve/moveable2.cc: Likewise. From-SVN: r174756 |
||
Paolo Carlini
|
6f59ea252b |
hashtable.h (_Hashtable<>::_Hashtable(_Hashtable&&)): Use std::move on the allocator, use noexcept.
2011-06-01 Paolo Carlini <paolo.carlini@oracle.com> * include/bits/hashtable.h (_Hashtable<>::_Hashtable(_Hashtable&&)): Use std::move on the allocator, use noexcept. (_Hashtable<>::~_Hashtable): Use noexcept. * include/bits/stl_list.h: Likewise. * include/bits/forward_list.h: Likewise. * include/bits/stl_vector.h: Likewise. * include/bits/stl_bvector.h: Likewise. * include/bits/stl_map.h (map<>::map(map&&)): Use noexcept. * include/bits/stl_set.h: Likewise. * include/bits/stl_multimap.h: Likewise. * include/bits/stl_multiset.h: Likewise. * include/bits/stl_tree.h (_Rb_tree<>::_Rb_tree(_Rb_tree&&)): Use std::move on the allocator. (_Rb_tree<>::~_Rb_tree): Use noexcept. * include/bits/stl_deque.h: Likewise. * include/bits/basic_string.h (basic_string<>::~basic_string): Use noexcept. * include/ext/vstring.h (__versa_string<>::~__versa_string): Likewise. * include/debug/set.h: Adjust. * include/debug/unordered_map: Likewise. * include/debug/multiset.h: Likewise. * include/debug/forward_list: Likewise. * include/debug/vector: Likewise. * include/debug/unordered_set: Likewise. * include/debug/deque: Likewise. * include/debug/map.h: Likewise. * include/debug/string: Likewise. * include/debug/list: Likewise. * include/debug/multimap.h: Likewise. * include/profile/set.h: Likewise. * include/profile/unordered_map: Likewise. * include/profile/multiset.h: Likewise. * include/profile/forward_list: Likewise. * include/profile/unordered_set: Likewise. * include/profile/vector: Likewise. * include/profile/deque: Likewise. * include/profile/map.h: Likewise. * include/profile/list: Likewise. * include/profile/multimap.h: Likewise. * testsuite/21_strings/basic_string/cons/wchar_t/ noexcept_move_construct.cc: New. * testsuite/21_strings/basic_string/cons/char/ noexcept_move_construct.cc: Likewise. * testsuite/ext/vstring/cons/noexcept_move_construct.cc: Likewise. * testsuite/23_containers/unordered_map/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/multimap/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/set/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/unordered_multimap/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/forward_list/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/unordered_set/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/vector/bool/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/vector/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/multiset/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/list/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/unordered_multiset/cons/ noexcept_move_construct.cc: Likewise. * testsuite/23_containers/map/cons/noexcept_move_construct.cc * testsuite/23_containers/forward_list/requirements/dr438/ assign_neg.cc: Adjust dg-error line numbers. * testsuite/23_containers/forward_list/requirements/dr438/ insert_neg.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_1_neg.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_2_neg.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/ assign_neg.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/ insert_neg.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/ constructor_1_neg.cc: Likewise. * testsuite/23_containers/vector/requirements/dr438/ constructor_2_neg.cc: Likewise. * testsuite/23_containers/deque/requirements/dr438/ assign_neg.cc: Likewise. * testsuite/23_containers/deque/requirements/dr438/ insert_neg.cc: Likewise. * testsuite/23_containers/deque/requirements/dr438/ constructor_1_neg.cc: Likewise. * testsuite/23_containers/deque/requirements/dr438/ constructor_2_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/ assign_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/ insert_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/ constructor_1_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/ constructor_2_neg.cc: Likewise. * include/bits/move.h (swap): Use __and_ in the noexcept. * include/bits/algorithmfwd.h: Adjust. From-SVN: r174525 |
||
Paolo Carlini
|
18eeaec47b |
utility (get(std::pair<>&&)): Add.
2011-05-16 Paolo Carlini <paolo.carlini@oracle.com> * include/std/utility (get(std::pair<>&&)): Add. * include/bits/stl_pair.h (pair::swap(pair&), swap(pair<>&, pair<>&)): Use noexcept. * include/bits/random.h (discard_block_engine<>::base, independent_bits_engine<>::base, shuffle_order_engine<>::base, random_device::entropy): Use noexcept. * include/std/array: Use noexcept where appropriate. (get(array<>&&)): Add. * testsuite/23_containers/array/requirements/get.cc: New. * testsuite/20_util/pair/get.cc: Likewise. * testsuite/20_util/weak_ptr/comparison/cmp_neg.cc: Tweak dg-error line number. From-SVN: r173798 |
||
Paolo Carlini
|
a3fa23e44b |
47628.cc: Do not test in C++0x mode.
2011-02-10 Paolo Carlini <paolo.carlini@oracle.com> * testsuite/23_containers/multimap/modifiers/erase/47628.cc: Do not test in C++0x mode. * testsuite/23_containers/map/modifiers/erase/47628.cc: Likewise. * testsuite/20_util/headers/utility/synopsis.cc: Tweak to work in C++0x mode too. From-SVN: r170016 |
||
Paolo Carlini
|
03e38c1a18 |
re PR libstdc++/47628 (non-compliant C++0x erase methods on STL containers)
2011-02-07 Paolo Carlini <paolo.carlini@oracle.com> PR libstdc++/47628 * include/bits/stl_tree.h (_Rb_tree::erase(iterator), erase(iterator, iterator)): Add back in C++03 mode. * testsuite/23_containers/map/modifiers/erase/47628.cc: New. * testsuite/23_containers/multimap/modifiers/erase/47628.cc: Likewise. From-SVN: r169899 |
||
Benjamin Kosnik
|
12ffa22844 |
PR libstdc++/36104 part four
2011-01-30 Benjamin Kosnik <bkoz@redhat.com> PR libstdc++/36104 part four * include/bits/c++config (_GLIBCXX_STD): Remove. (_GLIBCXX_STD_D, _GLIBCXX_PR): Now _GLIBCXX_STD_C. (_GLIBCXX_P): Now _GLIBCXX_STD_A. (_GLIBCXX_NAMESPACE_DEBUG, _GLIBCXX_NAMESPACE_PARALLEL, _GLIBCXX_NAMESPACE_PROFILE, _GLIBCXX_NAMESPACE_VERSION): Remove. (_GLIBCXX_INLINE_DEBUG, _GLIBCXX_INLINE_PARALLEL, _GLIBCXX_INLINE_PROFILE): Remove. (_GLIBCXX_BEGIN_NAMESPACE(X)): Remove. (_GLIBCXX_END_NAMESPACE): Remove. (_GLIBCXX_BEGIN_NESTED_NAMESPACE(X, Y)): Remove. (_GLIBCXX_END_NESTED_NAMESPACE): Remove. (_GLIBCXX_BEGIN_NAMESPACE_ALGO): Add. (_GLIBCXX_END_NAMESPACE_ALGO): Add. (_GLIBCXX_BEGIN_NAMESPACE_CONTAINER): Add. (_GLIBCXX_END_NAMESPACE_CONTAINER): Add. (_GLIBCXX_BEGIN_NAMESPACE_VERSION): Add. (_GLIBCXX_END_NAMESPACE_VERSION): Add. (_GLIBCXX_BEGIN_LDBL_NAMESPACE): To _GLIBCXX_BEGIN_NAMESPACE_LDBL. (_GLIBCXX_END_LDBL_NAMESPACE): To _GLIBCXX_END_NAMESPACE_LDBL. (_GLIBCXX_VISIBILITY_ATTR): Revert to _GLIBCXX_VISIBILITY. * include/*: Use new macros for namespace scope. * config/*: Same. * src/*: Same. * src/Makefile.am (sources): Remove debug_list.cc, add compatibility-debug_list-2.cc. (parallel_sources): Remove parallel_list.cc, add compatibility-parallel_list-2.cc. (compatibility-parallel_list-2.[o,lo]): New rule. * src/Makefile.in: Regenerate. * src/debug_list.cc: Remove. * src/parallel_list.cc: Remove. * src/compatibility-list-2.cc: New. * src/compatibility-debug_list-2.cc: New. * src/compatibility-parallel_list-2.cc: New. * doc/doxygen/user.cfg.in: Adjust macros. * testsuite/20_util/auto_ptr/assign_neg.cc: Adjust line numbers, macros. * testsuite/20_util/declval/requirements/1_neg.cc: Same. * testsuite/20_util/duration/requirements/typedefs_neg1.cc: Same. * testsuite/20_util/duration/requirements/typedefs_neg2.cc: Same. * testsuite/20_util/duration/requirements/typedefs_neg3.cc: Same. * testsuite/20_util/forward/c_neg.cc: Same. * testsuite/20_util/forward/f_neg.cc: Same. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Same. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Same. * testsuite/20_util/ratio/cons/cons_overflow_neg.cc: Same. * testsuite/20_util/ratio/operations/ops_overflow_neg.cc: Same. * testsuite/20_util/shared_ptr/cons/43820_neg.cc: Same. * testsuite/20_util/weak_ptr/comparison/cmp_neg.cc: Same. * testsuite/23_containers/deque/requirements/dr438/assign_neg.cc: Same. * testsuite/23_containers/deque/requirements/dr438/ constructor_1_neg.cc: Same. * testsuite/23_containers/deque/requirements/dr438/ constructor_2_neg.cc: Same. * testsuite/23_containers/deque/requirements/dr438/insert_neg.cc: Same. * testsuite/23_containers/forward_list/capacity/1.cc: Same. * testsuite/23_containers/forward_list/requirements/dr438/ assign_neg.cc: Same. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_1_neg.cc: Same. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_2_neg.cc: Same. * testsuite/23_containers/forward_list/requirements/dr438/ insert_neg.cc: Same. * testsuite/23_containers/list/capacity/29134.cc: Same. * testsuite/23_containers/list/requirements/dr438/assign_neg.cc: Same. * testsuite/23_containers/list/requirements/dr438/ constructor_1_neg.cc: Same. * testsuite/23_containers/list/requirements/dr438/ constructor_2_neg.cc: Same. * testsuite/23_containers/list/requirements/dr438/insert_neg.cc: Same. * testsuite/23_containers/vector/bool/capacity/29134.cc: Same. * testsuite/23_containers/vector/bool/modifiers/insert/31370.cc: Same. * testsuite/23_containers/vector/requirements/dr438/assign_neg.cc: Same. * testsuite/23_containers/vector/requirements/dr438/ constructor_1_neg.cc: Same. * testsuite/23_containers/vector/requirements/dr438/ constructor_2_neg.cc: Same. * testsuite/23_containers/vector/requirements/dr438/insert_neg.cc: Same. * testsuite/25_algorithms/sort/35588.cc: Same. * testsuite/27_io/ios_base/cons/assign_neg.cc: Same. * testsuite/27_io/ios_base/cons/copy_neg.cc: Same. * testsuite/ext/profile/mutex_extensions_neg.cc: Same. * testsuite/ext/profile/profiler_algos.cc: Same. * testsuite/ext/type_traits/add_unsigned_floating_neg.cc: Same. * testsuite/ext/type_traits/add_unsigned_integer_neg.cc: Same. * testsuite/ext/type_traits/remove_unsigned_floating_neg.cc: Same. * testsuite/ext/type_traits/remove_unsigned_integer_neg.cc: Same. * testsuite/tr1/2_general_utilities/shared_ptr/cons/43820_neg.cc: Same. From-SVN: r169421 |
||
François Dumont
|
5b8901caa0 |
erase_after1_neg.cc: Move to this.
2011-01-16 François Dumont <francois.cppdevs@free.fr> * testsuite/23_containers/forward_list/debug/erase_after1_neg.cc: Move to this. Use _neg suffix. * testsuite/23_containers/forward_list/debug/erase_after1.cc: ...from this. * testsuite/23_containers/forward_list/debug/erase_after2_neg.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after2.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after3_neg.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after3.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after4_neg.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after4.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after5_neg.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after5.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after6_neg.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after6.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after7_neg.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after7.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after8_neg.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after8.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after9_neg.cc: Same. * testsuite/23_containers/forward_list/debug/erase_after9.cc: Same. * testsuite/23_containers/forward_list/debug/insert_after1_neg.cc: Same. * testsuite/23_containers/forward_list/debug/insert_after1.cc: Same. * testsuite/23_containers/forward_list/debug/insert_after2_neg.cc: Same. * testsuite/23_containers/forward_list/debug/insert_after2.cc: Same. * testsuite/23_containers/forward_list/debug/insert_after3_neg.cc: Same. * testsuite/23_containers/forward_list/debug/insert_after3.cc: Same. * testsuite/23_containers/forward_list/debug/splice_after1_neg.cc: Same. * testsuite/23_containers/forward_list/debug/splice_after1.cc: Same. * testsuite/23_containers/forward_list/debug/splice_after2_neg.cc: Same. * testsuite/23_containers/forward_list/debug/splice_after2.cc: Same. * testsuite/23_containers/forward_list/debug/splice_after3_neg.cc: Same. * testsuite/23_containers/forward_list/debug/splice_after3.cc: Same. * testsuite/23_containers/forward_list/debug/splice_after4_neg.cc: Same. * testsuite/23_containers/forward_list/debug/splice_after4.cc: Same. From-SVN: r168850 |
||
François Dumont
|
8c9f4dfa9a |
safe_base.h (_Safe_iterator_base::_M_unlink): New.
2011-01-05 François Dumont <francois.cppdevs@free.fr> * include/debug/safe_base.h (_Safe_iterator_base::_M_unlink): New. * include/src/debug.cc: Use latter * include/debug/forward_list (forward_list<>::_M_swap): Fix to correctly handle before_begin iterators. * testsuite/23_containers/forward_list/debug/swap.cc: Remove now useless _GLIBCXX_DEBUG checks. From-SVN: r168528 |
||
Benjamin Kosnik
|
f910786b98 |
*: Use headername alias to associate private includes to public includes.
2010-11-18 Benjamin Kosnik <bkoz@redhat.com> * config/*/*: Use headername alias to associate private includes to public includes. * include/*/*: Same. * scripts/run_doxygen: Update for doxygen 1.7.2. * doc/doxygen/user.cfg.in: Same. * doc/doxygen/TODO: Remove. * testsuite/*/std_c++0x_neg.cc: Adjust line number. From-SVN: r168046 |
||
Benjamin Kosnik
|
cb2168c966 |
testsuite_iterators.h: Guard move.h includes.
2010-11-16 Benjamin Kosnik <bkoz@redhat.com> * testsuite/util/testsuite_iterators.h: Guard move.h includes. * testsuite/util/testsuite_allocator.h: Same. * testsuite/20_util/temporary_buffer.cc: Use typedef, qualify. * testsuite/ext/pb_ds/regression/hash_data_map_rand.cc: Define PB_DS_REGRESSION in the source file. * testsuite/ext/pb_ds/regression/trie_data_map_rand.cc: Same. * testsuite/ext/pb_ds/regression/list_update_no_data_map_rand.cc: Same. * testsuite/ext/pb_ds/regression/tree_no_data_map_rand.cc: Same. * testsuite/ext/pb_ds/regression/list_update_data_map_rand.cc: Same. * testsuite/ext/pb_ds/regression/hash_no_data_map_rand.cc: Same. * testsuite/ext/pb_ds/regression/priority_queue_rand.cc: Same. * testsuite/ext/pb_ds/regression/tree_data_map_rand.cc: Same. * testsuite/ext/pb_ds/regression/trie_no_data_map_rand.cc: Same. * testsuite/21_strings/c_strings/wchar_t/3_neg.cc: Move to this. Use _neg suffix. * testsuite/21_strings/c_strings/wchar_t/3.cc: ...from this. * testsuite/21_strings/c_strings/char/3_neg.cc: Same. * testsuite/21_strings/c_strings/char/3.cc: Same. * testsuite/ext/slist/23781_neg.cc: Same. * testsuite/ext/slist/23781.cc: Same. * testsuite/ext/profile/mutex_extensions.cc: Same. * testsuite/ext/profile/mutex_extensions_neg.cc: Same. * testsuite/tr1/2_general_utilities/shared_ptr/cons/43820.cc: Same. * testsuite/tr1/2_general_utilities/shared_ptr/cons/43820_neg.cc: Same. * testsuite/tr1/6_containers/tuple/comparison_operators/35480_neg.cc: Same. * testsuite/tr1/6_containers/tuple/comparison_operators/35480.cc: Same. * testsuite/23_containers/multimap/23781_neg.cc: Same. * testsuite/23_containers/multimap/23781.cc: Same. * testsuite/23_containers/set/23781_neg.cc: Same. * testsuite/23_containers/set/23781.cc: Same. * testsuite/23_containers/multiset/23781_neg.cc: Same. * testsuite/23_containers/multiset/23781.cc: Same. * testsuite/23_containers/list/23781_neg.cc: Same. * testsuite/23_containers/list/23781.cc: Same. * testsuite/23_containers/map/23781_neg.cc: Same. * testsuite/23_containers/map/23781.cc: Same. * testsuite/20_util/duration/cons/dr974_neg.cc: Same. * testsuite/20_util/duration/cons/dr974.cc: Same. * testsuite/20_util/tuple/comparison_operators/35480_neg.cc: Same. * testsuite/20_util/tuple/comparison_operators/35480.cc: Same. * testsuite/20_util/shared_ptr/cons/43820_neg.cc: Same. * testsuite/20_util/shared_ptr/cons/43820.cc: Same. * testsuite/20_util/unique_ptr/cons/pointer_array_convertible_neg.cc: Same. * testsuite/20_util/unique_ptr/cons/pointer_array_convertible.cc: Same. From-SVN: r167956 |
||
François Dumont
|
f38716953d |
stl_iterator.h: Add move_iterator operators overloads to make it robust to template abuses.
2010-12-07 François Dumont <francois.cppdevs@free.fr> * include/bits/stl_iterator.h: Add move_iterator operators overloads to make it robust to template abuses. * testsuite/util/testsuite_greedy_ops.h: New. * testsuite/23_containers/vector/types/1.cc: Use latter. * testsuite/23_containers/deque/types/1.cc: Likewise. * testsuite/24_iterators/move_iterator/greedy_ops.cc: New. * testsuite/24_iterators/normal_iterator/greedy_ops.cc: New. * testsuite/24_iterators/reverse_iterator/greedy_ops.cc: New. * testsuite/20_util/weak_ptr/comparison/cmp_neg.cc: Adjust dg-error line numbers. From-SVN: r167580 |
||
François Dumont
|
4aa9afb41f |
2.cc: Hide explicit instantiation with non default constructible type ...
2010-12-02 François Dumont <francois.cppdevs@free.fr> * testsuite/23_containers/vector/requirements/explicit_instantiation/ 2.cc: Hide explicit instantiation with non default constructible type in C++0x mode. * testsuite/23_containers/deque/requirements/explicit_instantiation/ 2.cc: Likewise * testsuite/23_containers/list/requirements/explicit_instantiation/ 2.cc: Likewise. From-SVN: r167391 |
||
François Dumont
|
7165791eb5 |
2.cc: Fix to explicitely invoke the copy construtor with or without C++0x mode.
2010-12-01 François Dumont <francois.cppdevs@free.fr> * testsuite/23_containers/deque/cons/2.cc: Fix to explicitely invoke the copy construtor with or without C++0x mode. * testsuite/23_containers/vector/cons/4.cc: Likewise. From-SVN: r167355 |
||
François Dumont
|
d3b8263e20 |
unordered_map (unordered_multimap<>::erase): Fix to erase all elements associated to the key.
2010-11-27 François Dumont <francois.cppdevs@free.fr> * include/debug/unordered_map (unordered_multimap<>::erase): Fix to erase all elements associated to the key. * include/debug/unordered_set (unordered_multiset<>::erase): Likewise. * testsuite/23_containers/unordered_multimap/erase/1.cc: Modify to check for multiple erase. * testsuite/23_containers/unordered_multiset/erase/1.cc: Likewise. From-SVN: r167199 |
||
François Dumont
|
c5589aa7e1 |
bitset (bitset<>::reference): Clean code, use normal reference type in experimental mode.
2010-11-27 François Dumont <francois.cppdevs@free.fr> * include/debug/bitset (bitset<>::reference): Clean code, use normal reference type in experimental mode. * testsuite/23_containers/bitset/debug/invalid/1.cc: Fix for experimental mode. From-SVN: r167196 |
||
François Dumont
|
afe96d415d |
debug.cc: Introduce a mutex pool in get_safe_base_mutex.
2010-11-25 François Dumont <francois.cppdevs@free.fr> * src/debug.cc: Introduce a mutex pool in get_safe_base_mutex. Move code used to manipulate sequence safe iterators from safe iterator methods to safe sequence ones. Remove usage of safe iterator mutex, keep _Safe_iterator_base::_M_get_mutex for library backward binary compatibility. * src/Makefile.am: Build debug.cc in gnu++0x mode for _Hash_impl usage. * src/Makefile.in: Regenerate * include/debug/safe_base.h: Add _Safe_iterator_base _M_invalidate and _M_reset. Add _Safe_sequence_base _M_attach, _M_attach_single, _M_detach and _M_detach_single. * include/debug.safe_iterator.h, safe_iterator.tcc: Remove _Safe_iterator _M_invalidate and _M_invalidate_single. Implement all methods in terms of normal iterators rather than safe ones. * include/debug/safe_sequence.h: Replace _Safe_sequence _M_transfe_iter with _M_transfer_from_if taking the source sequence and a predicate signaling when a safe iterator shall be transfered. Add _Equal_to predicate. * include/debug/safe_sequence.tcc: New. * include/Makefile.am: Adjust. * include/Makefile.in: Regenerate. * include/debug/forward_list: Swap safe iterators in move constructor. Do not invalidate before begin in _M_invalidate_all method. Reimplement safe methods using normal iterators rather than safe ones. * include/debug/set.h, unordered_map, multiset.h, vector, unordered_set, deque, map.h, list, multimap.h: Reimplement safe method using normal iterators rather than safe ones. * testsuite/23_containers/forward_list/debug/clear.cc, swap.cc, move_constructor.cc, splice_after.cc, splice_after1.cc, splice_after2.cc, splice_after3.cc, splice_after4.cc: New. * testsuite/23_containers/vector/debug/multithreaded_swap.cc: New. From-SVN: r167152 |
||
Paolo Carlini
|
e6a054481d |
PR libstdc++/44436 (partial)
2010-11-10 Paolo Carlini <paolo.carlini@oracle.com> PR libstdc++/44436 (partial) PR libstdc++/46148 * include/bits/stl_tree.h (_Rb_tree<>::_M_insert_, _M_insert_lower, _M_insert_equal_lower, _M_insert_unique, _M_insert_equal, _M_insert_unique_, _M_insert_equal_): Templatize in C++0x mode, use _GLIBCXX_FORWARD throughout. * include/bits/stl_map.h (map<>::insert(_Pair&&), insert(const_iterator, _Pair&&), operator[](key_type&&): Add. * include/bits/stl_set.h (set<>::insert(value_type&&), insert(const_iterator, value_type&&)): Likewise. * include/bits/stl_multimap.h (multimap<>::insert(_Pair&&), insert(const_iterator, _Pair&&)): Likewise. * include/bits/stl_multiset.h (multiset<>::insert(value_type&&), insert(const_iterator, value_type&&)): Likewise. * include/debug/set.h: Adjust. * include/debug/multiset.h: Likewise. * include/debug/map.h: Likewise. * include/debug/multimap.h: Likewise. * include/profile/set.h: Likewise. * include/profile/multiset.h: Likewise. * include/profile/map.h: Likewise. * include/profile/multimap.h: Likewise. * testsuite/23_containers/multimap/modifiers/insert/1.cc: New. * testsuite/23_containers/multimap/modifiers/insert/2.cc: Likewise. * testsuite/23_containers/multimap/modifiers/insert/3.cc: Likewise. * testsuite/23_containers/multimap/modifiers/insert/4.cc: Likewise. * testsuite/23_containers/set/modifiers/insert/2.cc: Likewise. * testsuite/23_containers/set/modifiers/insert/3.cc: Likewise. * testsuite/23_containers/multiset/modifiers/insert/3.cc: Likewise. * testsuite/23_containers/multiset/modifiers/insert/4.cc: Likewise. * testsuite/23_containers/map/modifiers/insert/2.cc: Likewise. * testsuite/23_containers/map/modifiers/insert/3.cc: Likewise. * testsuite/23_containers/map/modifiers/insert/4.cc: Likewise. * testsuite/23_containers/map/modifiers/insert/5.cc: Likewise. * testsuite/23_containers/map/element_access/2.cc: Likewise. * testsuite/23_containers/map/element_access/46148.cc: Likewise. * include/bits/hashtable.h: Trivial naming changes. From-SVN: r166551 |
||
Paolo Carlini
|
a9992f7f6b |
syntax_option_type.cc: Avoid -Wall warnings.
2010-11-02 Paolo Carlini <paolo.carlini@oracle.com * testsuite/28_regex/05_constants/syntax_option_type.cc: Avoid -Wall warnings. * testsuite/28_regex/08_basic_regex/requirements/constexpr_data.cc: Likewise. * testsuite/18_support/numeric_limits/requirements/ constexpr_functions.cc: Likewise. * testsuite/18_support/numeric_limits/requirements/ constexpr_data.cc: Likewise. * testsuite/21_strings/char_traits/requirements/ constexpr_functions.cc: Likewise. * testsuite/26_numerics/random/independent_bits_engine/requirements/ constexpr_functions.cc: Likewise. * testsuite/26_numerics/random/subtract_with_carry_engine/ requirements/constexpr_functions.cc: Likewise. * testsuite/26_numerics/random/subtract_with_carry_engine/ requirements/constexpr_data.cc: Likewise. * testsuite/26_numerics/random/discard_block_engine/requirements/ constexpr_functions.cc: Likewise. * testsuite/26_numerics/random/discard_block_engine/requirements/ constexpr_data.cc: Likewise. * testsuite/26_numerics/random/mersenne_twister_engine/ requirements/constexpr_functions.cc: Likewise. * testsuite/26_numerics/random/mersenne_twister_engine/ requirements/constexpr_data.cc: Likewise. * testsuite/26_numerics/random/linear_congruential_engine/ requirements/constexpr_functions.cc: Likewise. * testsuite/26_numerics/random/linear_congruential_engine/ requirements/constexpr_data.cc: Likewise. * testsuite/26_numerics/random/shuffle_order_engine/ requirements/constexpr_functions.cc: Likewise. * testsuite/26_numerics/random/shuffle_order_engine/ requirements/constexpr_data.cc: Likewise. * testsuite/26_numerics/complex/requirements/ constexpr_functions.cc: Likewise. * testsuite/23_containers/bitset/requirements/ constexpr_functions.cc: Likewise. * testsuite/23_containers/array/requirements/ constexpr_functions.cc: Likewise. * testsuite/util/testsuite_common_types.h: Likewise. * testsuite/20_util/duration/requirements/ constexpr_functions.cc: Likewise. * testsuite/20_util/duration_cast/constexpr.cc: Likewise. * testsuite/20_util/time_point/requirements/ constexpr_functions.cc: Likewise. * testsuite/20_util/ratio/requirements/constexpr_data.cc: Likewise. * testsuite/tr1/4_metaprogramming/integral_constant/ requirements/constexpr_data.cc: Remove. From-SVN: r166210 |
||
Benjamin Kosnik
|
94a86be0dd |
libstdc++: N3126 draft support.
* include/std/chrono: Extend constexpr application. * testsuite/util/testsuite_common_types.h (constexpr_default_constructible, constexpr_single_value_constructible) : Add comments about implied constraints. * testsuite/20_util/duration/cons/constexpr.cc: Activate all tests. * testsuite/20_util/time_point/cons/constexpr.cc: Same. * testsuite/20_util/time_point/requirements/constexpr_functions.cc: Same. * testsuite/20_util/ratio/cons/cons_overflow_neg.cc: Adjust line numbers. * testsuite/20_util/time_point_cast/constexpr.cc: New. * include/std/bitset: Use __SIZEOF_* macros to re-create original logic instead of slipshod application of std::numeric_limits<T>::max() macros. * testsuite/util/testsuite_common_types.h (constexpr_default_constructible): Modify. * include/std/chrono: Tested constexpr. * testsuite/20_util/duration_cast/constexpr.cc: New. * testsuite/20_util/time_point/cons/constexpr.cc: New. * testsuite/20_util/duration/cons/constexpr.cc: Add single_value tests. * testsuite/20_util/duration/requirements/typedefs_neg1.cc: Adjust line numbers. * testsuite/20_util/duration/requirements/typedefs_neg2.cc: Same. * testsuite/20_util/duration/requirements/typedefs_neg3.cc: Same. * testsuite/20_util/time_point/cons/constexpr.cc: Add single_value tests. * testsuite/20_util/time_point/requirements/constexpr_functions.cc: Add. * testsuite/util/testsuite_common_types.h: Adjust init. * include/std/chrono (duration): Remove defaulted constructor, replace with mem-init list. * testsuite/20_util/duration/cons/constexpr.cc: Add single value. * testsuite/20_util/duration/requirements/constexpr_functions.cc: Add non-static member functions. * testsuite/20_util/default_delete/cons/constexpr.cc: New, xfail. * testsuite/20_util/enable_shared_from_this/cons/constexpr.cc: Same. * testsuite/20_util/shared_ptr/cons/constexpr.cc: Same. * testsuite/20_util/time_point/requirements/constexpr_functions.cc: Same. * testsuite/20_util/unique_ptr/cons/constexpr.cc: Same. * testsuite/20_util/weak_ptr/cons/constexpr.cc: Same. * include/std/bitset: Add constexpr as per N3126 draft. * testsuite/23_containers/bitset/cons/constexpr.cc: New. * testsuite/23_containers/bitset/requirements/constexpr_functions.cc: New. * testsuite/util/testsuite_common_types.h: Reset condition. * include/bits/random.h: Remove misleading comments. * include/bits/regex.h: Add constexpr. * testsuite/28_regex/05_constants/syntax_option_type.cc: Add tests. * testsuite/28_regex/08_basic_regex/requirements/constexpr_data.cc: New. PR libstdc++/46134 * include/std/chrono: Use default constructor. * testsuite/util/testsuite_common_types.h (constexpr_default_constructible): Adjust condition. PR libstdc++/46133 * include/std/complex: Adjust complex specialization default constructors for constexpr. * testsuite/26_numerics/complex/cons/constexpr.cc: Enable tests. * include/bits/random.h: Adjust for constexpr as per N3126 draft. * testsuite/26_numerics/random/discard_block_engine/requirements/ constexpr_data.cc: New. * testsuite/26_numerics/random/discard_block_engine/requirements/ constexpr_functions.cc: New. * testsuite/26_numerics/random/independent_bits_engine/requirements/ constexpr_functions.cc: New. * testsuite/26_numerics/random/linear_congruential_engine/requirements/ constexpr_data.cc: New. * testsuite/26_numerics/random/linear_congruential_engine/requirements/ constexpr_functions.cc: New. * testsuite/26_numerics/random/mersenne_twister_engine/requirements/ constexpr_data.cc: New. * testsuite/26_numerics/random/mersenne_twister_engine/requirements/ constexpr_functions.cc: New. * testsuite/26_numerics/random/shuffle_order_engine/requirements/ constexpr_data.cc: New. * testsuite/26_numerics/random/shuffle_order_engine/requirements/ constexpr_functions.cc: New. * testsuite/26_numerics/random/subtract_with_carry_engine/requirements/ constexpr_data.cc: New. * testsuite/26_numerics/random/subtract_with_carry_engine/requirements/ constexpr_functions.cc: New. * include/bits/stream_iterator.h: Add constexpr as per N3126 draft. * include/bits/streambuf_iterator.h: Same. * include/std/complex: Same. * testsuite/24_iterators/istream_iterator/cons/constexpr.cc: New. * testsuite/24_iterators/istreambuf_iterator/cons/constexpr.cc: New. * testsuite/26_numerics/complex/cons/constexpr.cc: New. * testsuite/26_numerics/complex/requirements/constexpr_functions.cc: New. * include/bits/char_traits.h: Add constexpr as per N3126 draft. * testsuite/21_strings/char_traits/requirements/constexpr_functions.cc: New. * include/tr1_impl/array: Add constexpr as per N3126 draft. * testsuite/23_containers/array/requirements/ constexpr_functions.cc: New. * include/bits/shared_ptr.h: Revert changes. * include/bits/unique_ptr.h: Same. * include/std/chrono: Adjust. * include/tr1_impl/type_traits: Same. * testsuite/util/testsuite_common_types.h: Add test functors. * testsuite/20_util/duration/cons/constexpr.cc: New. * testsuite/20_util/duration/requirements/constexpr_functions.cc: Same. * testsuite/20_util/pair/cons/constexpr.cc: Same. * testsuite/20_util/ratio/requirements/constexpr_data.cc: Same. * testsuite/27_io/ios_base/types/fmtflags/constexpr_operators.cc: Same. * testsuite/27_io/ios_base/types/iostate/constexpr_operators.cc: Same. * testsuite/27_io/ios_base/types/openmode/constexpr_operators.cc: Same. * testsuite/30_threads/call_once/constexpr.cc: Same. * testsuite/30_threads/mutex/cons/constexpr.cc: Same. * testsuite/30_threads/once_flag/cons/constexpr.cc: Same. * testsuite/tr1/4_metaprogramming/integral_constant/requirements/ constexpr_data.cc: Same. * testsuite/29_atomics/atomic/cons/assign_neg.cc: Adjust line numbers. * testsuite/29_atomics/atomic/cons/copy_neg.cc: Same. * testsuite/29_atomics/atomic_integral/cons/assign_neg.cc: Same. * testsuite/29_atomics/atomic_integral/cons/copy_neg.cc: Same. * testsuite/29_atomics/atomic_integral/operators/bitwise_neg.cc: Same. * include/bits/allocator.h: Add constexpr as per N3126 draft. * include/bits/ios_base.h: Same. * include/bits/shared_ptr.h: Same. * include/bits/unique_ptr.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/stl_pair.h: Same. * include/std/tuple: Same. * include/tr1_impl/type_traits: Same. * include/std/chrono: Same. * include/std/ratio: Same. * include/std/mutex: Same. * src/mutex.cc: Same. * testsuite/20_util/duration/requirements/typedefs_neg1.cc: Adjust. * testsuite/20_util/duration/requirements/typedefs_neg2.cc: Same. * testsuite/20_util/duration/requirements/typedefs_neg3.cc: Same. * testsuite/20_util/weak_ptr/comparison/cmp_neg.cc: Same. * testsuite/27_io/ios_base/cons/assign_neg.cc: Same. * testsuite/27_io/ios_base/cons/copy_neg.cc: Same. * doc/doxygen/user.cfg.in: Replace _GLIBCXX_USE_CONSTEXPR, _GLIBCXX_CONSTEXPR for doxygen generation. * src/limits.cc: Undef. * testsuite/29_atomics/atomic/cons/constexpr.cc: Adjust. * testsuite/29_atomics/atomic_address/cons/constexpr.cc: Same. * testsuite/29_atomics/atomic_integral/cons/constexpr.cc: Same. * testsuite/29_atomics/atomic_integral/operators/bitwise_neg.c: Same. * testsuite/18_support/numeric_limits/constexpr.cc: To... * testsuite/18_support/numeric_limits/requirements/ constexpr_data.cc, constexpr_functions.cc: ...this * testsuite/util/testsuite_common_types.h (constexpr_single_value_constructible): Add. * testsuite/29_atomics/atomic/cons/constexpr.cc: Adjust name. * testsuite/29_atomics/atomic_integral/cons/constexpr.cc: Same. * testsuite/29_atomics/atomic_address/cons/constexpr.cc: New. * testsuite/18_support/numeric_limits/constexpr.cc: New. * testsuite/29_atomics/atomic/cons/assign_neg.cc: Adjust line numbers. * testsuite/29_atomics/atomic/cons/constexpr.cc: Same. * testsuite/29_atomics/atomic/cons/copy_neg.cc: Same. * testsuite/29_atomics/atomic_integral/cons/assign_neg.cc: Same. * testsuite/29_atomics/atomic_integral/cons/constexpr.cc: Same. * testsuite/29_atomics/atomic_integral/cons/copy_neg.cc: Same. * testsuite/29_atomics/atomic_integral/operators/bitwise_neg.cc: Same. * testsuite/29_atomics/atomic_integral/operators/decrement_neg.cc: Same. * testsuite/29_atomics/atomic_integral/operators/increment_neg.cc: Same. * include/bits/c++config (_GLIBCXX_CONSTEXPR): Add. (_GLIBCXX_USE_CONSTEXPR): Add. * include/std/limits: Use it. * src/limits.cc: Adjust. * testsuite/ext/profile/mutex_extensions.cc: Change line number. * include/bits/atomic_0.h: Rework for N3126 draft, add constexpr. * include/bits/atomic_2.h: Same. * include/bits/atomic_base.h: Same. * include/std/atomic: Same. * src/atomic.cc: Same. * include/bits/atomicfwd_c.h: Remove. * include/bits/atomicfwd_cxx.h: Remove. * include/c_compatibility/stdatomic.h: Remove. * include/Makefile.am: Remove atomicfwd_c.h, atomicfwd_cxx.h, stdatomic.h. * include/Makefile.in: Regenerate. * doc/xml/manual/using.xml: Update list of header files for changes. * testsuite/util/testsuite_common_types.h (constexpr_constructible): Add. * testsuite/29_atomics/atomic/cons/constexpr.cc: New. * testsuite/29_atomics/atomic_integral/cons/constexpr.cc: New. * testsuite/17_intro/headers/c++200x/stdc++.cc: Modify. * testsuite/29_atomics/atomic/cons/assign_neg.cc: Same. * testsuite/29_atomics/atomic_address/cons/assign_neg.cc: Same. * testsuite/29_atomics/atomic_flag/cons/1.cc: Same. * testsuite/29_atomics/atomic_integral/cons/assign_neg.cc: Same. * testsuite/29_atomics/headers/atomic/macros.cc: Same. * testsuite/29_atomics/headers/atomic/types_std_c++0x.cc: Same. * testsuite/29_atomics/headers/atomic/types_std_c++0x_neg.cc: Same. * testsuite/29_atomics/atomic_flag/test_and_set/implicit.c: Remove. * testsuite/29_atomics/atomic_flag/test_and_set/explicit.c: Same. * testsuite/29_atomics/atomic_flag/clear/1.c: Same. * testsuite/29_atomics/headers/stdatomic.h/debug_mode.c: Same. * testsuite/29_atomics/headers/stdatomic.h/functions.c: Same. * testsuite/29_atomics/headers/stdatomic.h/macros.c: Same. * testsuite/29_atomics/headers/stdatomic.h/types.c: Same. * testsuite/util/testsuite_abi.cc: Add GLIBCXX_3.4.16. From-SVN: r166171 |
||
Paolo Carlini
|
19fd98331d |
dr1325-2.cc: Fix typo.
2010-10-31 Paolo Carlini <paolo.carlini@oracle.com> * testsuite/23_containers/bitset/cons/dr1325-2.cc: Fix typo. * testsuite/20_util/hash/quality.cc: Avoid -Wall warnings. * testsuite/20_util/hash/chi2_quality.cc: Likewise. From-SVN: r166114 |
||
Paolo Carlini
|
fb7342fd6f |
PR libstdc++/44436 (partial)
2010-10-28 Paolo Carlini <paolo.carlini@oracle.com> PR libstdc++/44436 (partial) * include/bits/hashtable.h (_Hashtable<>::insert(value_type&&), insert(_Pair&&), insert(const_iterator, value_type&&), insert(const_iterator, _Pair&&)): Add. (_M_allocate_node, _M_insert, _M_insert_bucket): Templatize. * include/bits/hashtable_policy.h (__detail::_Select1st): Add; use it throughout. (_Map_base<>::operator[](_Key&&)): Add. * include/bits/unordered_map.h: Use __detail::_Select1st throughout. * include/debug/unordered_map: Update. * include/debug/unordered_set: Likewise. * include/profile/unordered_map: Likewise. * include/profile/unordered_set: Likewise. * testsuite/util/testsuite_rvalref.h (struct hash<rvalstruct>): Add; minor tweaks throughout, use deleted special members. * testsuite/23_containers/unordered_map/insert/map_single_move-1.cc: New. * testsuite/23_containers/unordered_map/insert/map_single_move-2.cc: Likewise. * testsuite/23_containers/unordered_map/insert/array_syntax_move.cc: Likewise. * testsuite/23_containers/unordered_multimap/insert/ multimap_single_move-1.cc: Likewise. * testsuite/23_containers/unordered_multimap/insert/ multimap_single_move-2.cc: Likewise. * testsuite/23_containers/unordered_set/insert/set_single_move.cc: Likewise. * testsuite/23_containers/unordered_multiset/insert/ multiset_single_move.cc: Likewise. * testsuite/23_containers/unordered_map/insert/array_syntax.cc: Minor cosmetic changes. From-SVN: r166030 |
||
Paolo Carlini
|
98fff892cc |
libstdc++.exp ([check_v3_target_normal_mode]): Add.
2010-10-26 Paolo Carlini <paolo.carlini@oracle.com> * testsuite/lib/libstdc++.exp ([check_v3_target_normal_mode]): Add. * testsuite/lib/dg-options.exp ([dg-require-normal-mode]): Likewise. * testsuite/23_containers/headers/forward_list/synopsis.cc: Use the latter. * testsuite/23_containers/headers/vector/synopsis.cc: Likewise. * testsuite/23_containers/headers/deque/synopsis.cc: Likewise. * testsuite/23_containers/headers/bitset/synopsis.cc: Likewise. * testsuite/23_containers/headers/list/synopsis.cc: Likewise. * testsuite/23_containers/headers/set/synopsis.cc: Likewise. * testsuite/23_containers/headers/map/synopsis.cc: Likewise. From-SVN: r165937 |
||
Paolo Carlini
|
deaf7b86cd |
forward_list.h (_Fwd_list_node_base::swap): Remove.
2010-10-25 Paolo Carlini <paolo.carlini@oracle.com> * include/bits/forward_list.h (_Fwd_list_node_base::swap): Remove. (_Fwd_list_base<>::_Fwd_list_base(_Fwd_list_base&&), _Fwd_list_base<>::_Fwd_list_base(_Fwd_list_base&&, const _Alloc&)): Don't use swap. (forward_list<>::swap): Just use std::swap. * include/bits/forward_list.h (_Fwd_list_base<>::_Fwd_list_base(), _Fwd_list_base(const _Alloc&)): Don't zero again _M_next. * testsuite/23_containers/forward_list/requirements/dr438/ assign_neg.cc: Adjust dg-error line number. * testsuite/23_containers/forward_list/requirements/dr438/ insert_neg.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_1_neg.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_2_neg.cc: Likewise. From-SVN: r165915 |
||
Paolo Carlini
|
efb7b45650 |
forward_list.h (forward_list<>::erase_after): Return an iterator.
2010-10-17 Paolo Carlini <paolo.carlini@oracle.com> * include/bits/forward_list.h (forward_list<>::erase_after): Return an iterator. (_M_erase_after): Return _Fwd_list_node_base*. * include/bits/forward_list.tcc: Likewise. * include/debug/forward_list: Likewise. * testsuite/23_containers/forward_list/modifiers/3.cc: Update and extend. * testsuite/util/exception/safety.h (erase_base<forward_list<>>): Adjust. * testsuite/23_containers/forward_list/requirements/dr438/ assign_neg.cc: Adjust dg-error line number. * testsuite/23_containers/forward_list/requirements/dr438/ insert_neg.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_1_neg.cc: Likewise. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_2_neg.cc: Likewise. From-SVN: r165590 |
||
Paolo Carlini
|
88c87359fa |
re PR libstdc++/43554 (profile-mode version of forward_list missing)
2010-10-17 Paolo Carlini <paolo.carlini@oracle.com> PR libstdc++/43554 * include/profile/forward_list: New file. * include/std/forward_list: Include <profile/forward_list>. * include/Makefile.am: Add. * testsuite/23_containers/forward_list/capacity/1.cc: Adjust. * include/Makefile.in: Regenerate. From-SVN: r165587 |
||
Paolo Carlini
|
a0a2a39912 |
[multiple changes]
2010-10-11 Jonathan Wakely <jwakely.gcc@gmail.com> * testsuite/23_containers/bitset/cons/2.cc: Tweak. 2010-10-11 Paolo Carlini <paolo.carlini@oracle.com> * include/std/bitset (bitset<>::bitset(const _CharT*, typename std::basic_string<>::size_type, _CharT, _CharT)): Implement new proposed resolution for DR 1325. * include/debug/bitset: Likewise. * include/profile/bitset: Likewise. * testsuite/23_containers/bitset/cons/dr1325-1.cc: New. * testsuite/23_containers/bitset/cons/dr1325-2.cc: Likewise. From-SVN: r165338 |
||
Paolo Carlini
|
b8b4301eec |
[multiple changes]
2010-09-29 Paolo Carlini <paolo.carlini@oracle.com> * include/Makefile.am: Add debug/forward_list. * include/Makefile.in: Regenerate. * testsuite/util/testsuite_container_traits.h (traits_base): Add has_erase_after and hash_insert_after typedefs. (traits<forward_list<>>): Adjust. * testsuite/util/exception/safety.h (erase_point, erase_range, insert_point): Deal correctly with forward_list. * include/Makefile.am: Add. 2010-09-29 François Dumont <francois.cppdevs@free.fr> * src/debug.cc: Add forward_list specific debug messages. * include/debug/forward_list: New. * include/debug/formatter.h: Add debug message ids and before begin iterator state. * include/debug/macros.h (__glibcxx_check_insert_after, __glibcxx_check_insert_range_after, __glibcxx_check_erase_after, __glibcxx_check_erase_range_after): Add. * include/debug/safe_iterator.h (_BeforeBeginHelper): Add. (_Safe_iterator<>::_M_before_dereferenceable, _Safe_iterator<>::_M_is_before_begin): Add. (_Safe_iterator<>::_M_dereferenceable, _Safe_iterator<>::_M_is_end, _Safe_iterator<>::_M_incrementable): Adjust. * include/std/forward_list: Include debug/forward when _GLIBCXX_DEBUG defined. * include/bits/forward_list.h, forward_list.tcc: Put in std::__norm when debug mode is active. * testsuite/23_containers/forward_list/capacity/1.cc: Fix to compile even in debug mode. * testsuite/23_containers/forward_list/debug/erase_after1.cc, erase_after2.cc, erase_after3.cc, erase_after4.cc, erase_after5.cc, insert_after1.cc,erase_after6.cc, erase_after7.cc, insert_after2.cc, erase_after8.cc, insert_after3.cc, erase_after9.cc: New. From-SVN: r164717 |
||
Luc Hermitte
|
fc99f7809e |
re PR libstdc++/45713 (sizeof std::bitset<ULONG_MAX> == 1)
2010-09-17 Luc Hermitte <hermitte@free.fr> Paolo Carlini <paolo.carlini@oracle.com> PR libstdc++/45713 * include/std/bitset: Fix _GLIBCXX_BITSET_WORDS macro. * testsuite/23_containers/bitset/45713.cc: New. Co-Authored-By: Paolo Carlini <paolo.carlini@oracle.com> From-SVN: r164388 |
||
François Dumont
|
d78301422a |
libstdc++.exp ([check_v3_target_debug_mode]): Fix so that it really detects when debug mode is activated.
2010-09-03 François Dumont <francois.cppdevs@free.fr> * testsuite/lib/libstdc++.exp ([check_v3_target_debug_mode]): Fix so that it really detects when debug mode is activated. * testsuite/util/debug/construct_neg.h, insert_neg.h, assign_neg.h: Remove, content moved... * testsuite/util/debug/checks.h: ... here. Modify checks to take the type of the container to test rather than an intermediate container type traits helper. * testsuite/23_containers/unordered_map/debug/insert1_neg.cc: Update to use dg-require-debug-mode when necessary and use new check functions. * testsuite/23_containers/unordered_map/debug/construct1_neg.cc: Likewise. * testsuite/23_containers/unordered_map/debug/construct2_neg.cc: Likewise. * testsuite/23_containers/unordered_map/debug/insert2_neg.cc: Likewise. * testsuite/23_containers/unordered_map/debug/construct3_neg.cc: Likewise. * testsuite/23_containers/unordered_map/debug/insert3_neg.cc: Likewise. * testsuite/23_containers/unordered_map/debug/construct4_neg.cc: Likewise. * testsuite/23_containers/unordered_map/debug/insert4_neg.cc: Likewise. * testsuite/23_containers/multimap/debug/insert1_neg.cc: Likewise. * testsuite/23_containers/multimap/debug/construct1_neg.cc: Likewise. * testsuite/23_containers/multimap/debug/construct2_neg.cc: Likewise. * testsuite/23_containers/multimap/debug/insert2_neg.cc: Likewise. * testsuite/23_containers/multimap/debug/construct3_neg.cc: Likewise. * testsuite/23_containers/multimap/debug/insert3_neg.cc: Likewise. * testsuite/23_containers/multimap/debug/construct4_neg.cc: Likewise. * testsuite/23_containers/multimap/debug/insert4_neg.cc: Likewise. * testsuite/23_containers/set/debug/insert1_neg.cc: Likewise. * testsuite/23_containers/set/debug/construct1_neg.cc: Likewise. * testsuite/23_containers/set/debug/construct2_neg.cc: Likewise. * testsuite/23_containers/set/debug/insert2_neg.cc: Likewise. * testsuite/23_containers/set/debug/construct3_neg.cc: Likewise. * testsuite/23_containers/set/debug/insert3_neg.cc: Likewise. * testsuite/23_containers/set/debug/construct4_neg.cc: Likewise. * testsuite/23_containers/set/debug/insert4_neg.cc: Likewise. * testsuite/23_containers/unordered_multimap/debug/insert1_neg.cc: Likewise. * testsuite/23_containers/unordered_multimap/debug/construct1_neg.cc: Likewise. * testsuite/23_containers/unordered_multimap/debug/construct2_neg.cc: Likewise. * testsuite/23_containers/unordered_multimap/debug/insert2_neg.cc: Likewise. * testsuite/23_containers/unordered_multimap/debug/construct3_neg.cc: Likewise. * testsuite/23_containers/unordered_multimap/debug/insert3_neg.cc: Likewise. * testsuite/23_containers/unordered_multimap/debug/construct4_neg.cc: Likewise. * testsuite/23_containers/unordered_multimap/debug/insert4_neg.cc: Likewise. * testsuite/23_containers/vector/debug/assign1_neg.cc: Likewise. * testsuite/23_containers/vector/debug/construct1_neg.cc: Likewise. * testsuite/23_containers/vector/debug/construct2_neg.cc: Likewise. * testsuite/23_containers/vector/debug/assign2_neg.cc: Likewise. * testsuite/23_containers/vector/debug/construct3_neg.cc: Likewise. * testsuite/23_containers/vector/debug/assign3_neg.cc: Likewise. * testsuite/23_containers/vector/debug/construct4_neg.cc: Likewise. * testsuite/23_containers/vector/debug/assign4_neg.cc: Likewise. * testsuite/23_containers/vector/debug/insert1_neg.cc: Likewise. * testsuite/23_containers/vector/debug/insert2_neg.cc: Likewise. * testsuite/23_containers/vector/debug/insert3_neg.cc: Likewise. * testsuite/23_containers/vector/debug/insert4_neg.cc: Likewise. * testsuite/23_containers/unordered_set/debug/insert1_neg.cc: Likewise. * testsuite/23_containers/unordered_set/debug/construct1_neg.cc: Likewise. * testsuite/23_containers/unordered_set/debug/construct2_neg.cc: Likewise. * testsuite/23_containers/unordered_set/debug/insert2_neg.cc: Likewise. * testsuite/23_containers/unordered_set/debug/construct3_neg.cc: Likewise. * testsuite/23_containers/unordered_set/debug/insert3_neg.cc: Likewise. * testsuite/23_containers/unordered_set/debug/construct4_neg.cc: Likewise. * testsuite/23_containers/unordered_set/debug/insert4_neg.cc: Likewise. * testsuite/23_containers/deque/debug/assign1_neg.cc: Likewise. * testsuite/23_containers/deque/debug/construct1_neg.cc: Likewise. * testsuite/23_containers/deque/debug/construct2_neg.cc: Likewise. * testsuite/23_containers/deque/debug/assign2_neg.cc: Likewise. * testsuite/23_containers/deque/debug/construct3_neg.cc: Likewise. * testsuite/23_containers/deque/debug/assign3_neg.cc: Likewise. * testsuite/23_containers/deque/debug/construct4_neg.cc: Likewise. * testsuite/23_containers/deque/debug/assign4_neg.cc: Likewise. * testsuite/23_containers/deque/debug/insert1_neg.cc: Likewise. * testsuite/23_containers/deque/debug/insert2_neg.cc: Likewise. * testsuite/23_containers/deque/debug/insert3_neg.cc: Likewise. * testsuite/23_containers/deque/debug/insert4_neg.cc: Likewise. * testsuite/23_containers/multiset/debug/insert1_neg.cc: Likewise. * testsuite/23_containers/multiset/debug/construct1_neg.cc: Likewise. * testsuite/23_containers/multiset/debug/construct2_neg.cc: Likewise. * testsuite/23_containers/multiset/debug/insert2_neg.cc: Likewise. * testsuite/23_containers/multiset/debug/construct3_neg.cc: Likewise. * testsuite/23_containers/multiset/debug/insert3_neg.cc: Likewise. * testsuite/23_containers/multiset/debug/construct4_neg.cc: Likewise. * testsuite/23_containers/multiset/debug/insert4_neg.cc: Likewise. * testsuite/23_containers/list/debug/assign1_neg.cc: Likewise. * testsuite/23_containers/list/debug/construct1_neg.cc: Likewise. * testsuite/23_containers/list/debug/construct2_neg.cc: Likewise. * testsuite/23_containers/list/debug/assign2_neg.cc: Likewise. * testsuite/23_containers/list/debug/construct3_neg.cc: Likewise. * testsuite/23_containers/list/debug/assign3_neg.cc: Likewise. * testsuite/23_containers/list/debug/construct4_neg.cc: Likewise. * testsuite/23_containers/list/debug/assign4_neg.cc: Likewise. * testsuite/23_containers/list/debug/insert1_neg.cc: Likewise. * testsuite/23_containers/list/debug/insert2_neg.cc: Likewise. * testsuite/23_containers/list/debug/insert3_neg.cc: Likewise. * testsuite/23_containers/list/debug/insert4_neg.cc: Likewise. * testsuite/23_containers/unordered_multiset/debug/insert1_neg.cc: Likewise. * testsuite/23_containers/unordered_multiset/debug/construct1_neg.cc: Likewise. * testsuite/23_containers/unordered_multiset/debug/construct2_neg.cc: Likewise. * testsuite/23_containers/unordered_multiset/debug/insert2_neg.cc: Likewise. * testsuite/23_containers/unordered_multiset/debug/construct3_neg.cc: Likewise. * testsuite/23_containers/unordered_multiset/debug/insert3_neg.cc: Likewise. * testsuite/23_containers/unordered_multiset/debug/construct4_neg.cc: Likewise. * testsuite/23_containers/unordered_multiset/debug/insert4_neg.cc: Likewise. * testsuite/23_containers/map/debug/insert1_neg.cc: Likewise. * testsuite/23_containers/map/debug/construct1_neg.cc: Likewise. * testsuite/23_containers/map/debug/construct2_neg.cc: Likewise. * testsuite/23_containers/map/debug/insert2_neg.cc: Likewise. * testsuite/23_containers/map/debug/construct3_neg.cc: Likewise. * testsuite/23_containers/map/debug/insert3_neg.cc: Likewise. * testsuite/23_containers/map/debug/construct4_neg.cc: Likewise. * testsuite/23_containers/map/debug/insert4_neg.cc: Likewise. * testsuite/23_containers/unordered_map/debug/cont_traits.h: Remove. * testsuite/23_containers/unordered_map/debug/debug_cont_traits.h: Likewise. * testsuite/23_containers/multimap/debug/cont_traits.h: Likewise. * testsuite/23_containers/multimap/debug/debug_cont_traits.h: Likewise. * testsuite/23_containers/set/debug/cont_traits.h: Likewise. * testsuite/23_containers/set/debug/debug_cont_traits.h: Likewise. * testsuite/23_containers/unordered_multimap/debug/cont_traits.h: Likewise. * testsuite/23_containers/unordered_multimap/debug/ debug_cont_traits.h: Likewise. * testsuite/23_containers/vector/debug/cont_traits.h: Likewise. * testsuite/23_containers/vector/debug/debug_cont_traits.h: Likewise. * testsuite/23_containers/unordered_set/debug/cont_traits.h: Likewise. * testsuite/23_containers/unordered_set/debug/debug_cont_traits.h: Likewise. * testsuite/23_containers/deque/debug/cont_traits.h: Likewise. * testsuite/23_containers/deque/debug/debug_cont_traits.h: Likewise. * testsuite/23_containers/multiset/debug/cont_traits.h: Likewise. * testsuite/23_containers/multiset/debug/debug_cont_traits.h: Likewise. * testsuite/23_containers/list/debug/cont_traits.h: Likewise. * testsuite/23_containers/list/debug/debug_cont_traits.h: Likewise. * testsuite/23_containers/unordered_multiset/debug/cont_traits.h: Likewise. * testsuite/23_containers/unordered_multiset/debug/ debug_cont_traits.h: Likewise. * testsuite/23_containers/map/debug/cont_traits.h: Likewise. * testsuite/23_containers/map/debug/debug_cont_traits.h: Likewise. * testsuite/21_strings/basic_string/element_access/char: Tidy. * testsuite/21_strings/basic_string/element_access/wchar_t: Likewise. From-SVN: r163837 |