Daily bump.
[official-gcc.git] / libstdc++-v3 / ChangeLog
blob34a130ea6686c8161b927efbe1c0984b83f50417
1 2021-11-12  Jonathan Wakely  <jwakely@redhat.com>
3         PR libstdc++/59675
4         * acinclude.m4 (libtool_VERSION): Bump version.
5         * config/abi/pre/gnu.ver (GLIBCXX_3.4.30): Add version and
6         export new symbol.
7         * configure: Regenerate.
8         * include/bits/c++config (__replacement_assert): Remove, declare
9         __glibcxx_assert_fail instead.
10         * src/c++11/debug.cc (__glibcxx_assert_fail): New function to
11         replace __replacement_assert, writing to stderr instead of
12         stdout.
13         * testsuite/util/testsuite_abi.cc: Update latest version.
15 2021-11-12  Jonathan Wakely  <jwakely@redhat.com>
16             Josh Marshall  <joshua.r.marshall.1991@gmail.com>
18         * include/bits/alloc_traits.h (_Destroy): Make constexpr for
19         C++20 mode.
20         * include/bits/allocator.h (__shrink_to_fit::_S_do_it):
21         Likewise.
22         * include/bits/stl_algobase.h (__fill_a1): Declare _Bit_iterator
23         overload constexpr for C++20.
24         * include/bits/stl_bvector.h (_Bit_type, _S_word_bit): Move out
25         of inline namespace.
26         (_Bit_reference, _Bit_iterator_base, _Bit_iterator)
27         (_Bit_const_iterator, _Bvector_impl_data, _Bvector_base)
28         (vector<bool, A>>): Add constexpr to every member function.
29         (_Bvector_base::_M_allocate): Initialize storage during constant
30         evaluation.
31         (vector<bool, A>::_M_initialize_value): Use __fill_bvector_n
32         instead of memset.
33         (__fill_bvector_n): New helper function to replace memset during
34         constant evaluation.
35         * include/bits/stl_uninitialized.h (__uninitialized_copy<false>):
36         Move logic to ...
37         (__do_uninit_copy): New function.
38         (__uninitialized_fill<false>): Move logic to ...
39         (__do_uninit_fill): New function.
40         (__uninitialized_fill_n<false>): Move logic to ...
41         (__do_uninit_fill_n): New function.
42         (__uninitialized_copy_a): Add constexpr. Use __do_uninit_copy.
43         (__uninitialized_move_a, __uninitialized_move_if_noexcept_a):
44         Add constexpr.
45         (__uninitialized_fill_a): Add constexpr. Use __do_uninit_fill.
46         (__uninitialized_fill_n_a): Add constexpr. Use
47         __do_uninit_fill_n.
48         (__uninitialized_default_n, __uninitialized_default_n_a)
49         (__relocate_a_1, __relocate_a): Add constexpr.
50         * include/bits/stl_vector.h (_Vector_impl_data, _Vector_impl)
51         (_Vector_base, vector): Add constexpr to every member function.
52         (_Vector_impl::_S_adjust): Disable ASan annotation during
53         constant evaluation.
54         (_Vector_base::_S_use_relocate): Disable bitwise-relocation
55         during constant evaluation.
56         (vector::_Temporary_value): Use a union for storage.
57         * include/bits/vector.tcc (vector, vector<bool>): Add constexpr
58         to every member function.
59         * include/std/vector (erase_if, erase): Add constexpr.
60         * testsuite/23_containers/headers/vector/synopsis.cc: Add
61         constexpr for C++20 mode.
62         * testsuite/23_containers/vector/bool/cmp_c++20.cc: Change to
63         compile-only test using constant expressions.
64         * testsuite/23_containers/vector/bool/capacity/29134.cc: Adjust
65         namespace for _S_word_bit.
66         * testsuite/23_containers/vector/bool/modifiers/insert/31370.cc:
67         Likewise.
68         * testsuite/23_containers/vector/cmp_c++20.cc: Likewise.
69         * testsuite/23_containers/vector/cons/89164.cc: Adjust errors
70         for C++20 and move C++17 test to ...
71         * testsuite/23_containers/vector/cons/89164_c++17.cc: ... here.
72         * testsuite/23_containers/vector/bool/capacity/constexpr.cc: New test.
73         * testsuite/23_containers/vector/bool/cons/constexpr.cc: New test.
74         * testsuite/23_containers/vector/bool/element_access/constexpr.cc: New test.
75         * testsuite/23_containers/vector/bool/modifiers/assign/constexpr.cc: New test.
76         * testsuite/23_containers/vector/bool/modifiers/constexpr.cc: New test.
77         * testsuite/23_containers/vector/bool/modifiers/swap/constexpr.cc: New test.
78         * testsuite/23_containers/vector/capacity/constexpr.cc: New test.
79         * testsuite/23_containers/vector/cons/constexpr.cc: New test.
80         * testsuite/23_containers/vector/data_access/constexpr.cc: New test.
81         * testsuite/23_containers/vector/element_access/constexpr.cc: New test.
82         * testsuite/23_containers/vector/modifiers/assign/constexpr.cc: New test.
83         * testsuite/23_containers/vector/modifiers/constexpr.cc: New test.
84         * testsuite/23_containers/vector/modifiers/swap/constexpr.cc: New test.
86 2021-11-11  Jonathan Wakely  <jwakely@redhat.com>
88         * include/debug/deque (deque::operator=(const deque&)): Remove
89         definition.
90         * include/debug/list (list::operator=(const list&)): Likewise.
91         * include/debug/map.h (map::operator=(const map&)): Likewise.
92         * include/debug/multimap.h (multimap::operator=(const multimap&)):
93         Likewise.
94         * include/debug/multiset.h (multiset::operator=(const multiset&)):
95         Likewise.
96         * include/debug/set.h (set::operator=(const set&)): Likewise.
97         * include/debug/string (basic_string::operator=(const basic_string&)):
98         Likewise.
99         * include/debug/vector (vector::operator=(const vector&)):
100         Likewise.
101         (_Safe_vector::operator=(const _Safe_vector&)): Define for
102         C++98 as well.
104 2021-11-11  Jonathan Wakely  <jwakely@redhat.com>
106         * include/std/memory_resource (memory_resource::allocate):
107         Implicitly create objects in the returned storage.
109 2021-11-11  Jonathan Wakely  <jwakely@redhat.com>
111         * include/bits/stl_bvector.h (vector<bool>::data()): Give
112         protected access, and delete for C++11 and later.
114 2021-11-10  Jonathan Wakely  <jwakely@redhat.com>
116         PR libstdc++/100117
117         * testsuite/17_intro/headers/c++1998/49745.cc: Explicitly list
118         all C++ headers instead of including <bits/stdc++.h>
120 2021-11-10  Jonathan Wakely  <jwakely@redhat.com>
122         PR libstdc++/100748
123         PR libstdc++/103133
124         * config/os/gnu-linux/os_defines.h (_GLIBCXX_GTHREAD_USE_WEAK):
125         Define for glibc 2.34 and later.
127 2021-11-09  François Dumont  <fdumont@gcc.gnu.org>
129         * include/bits/hashtable_policy.h (__distance_fw): Replace class keyword with
130         typename.
131         * include/bits/hashtable.h (_Hashtable<>::_M_merge_unique): Remove noexcept
132         qualification. Use const_iterator for node extraction/reinsert.
133         (_Hashtable<>::_M_merge_multi): Likewise. Compute new hash code before extract.
134         * include/debug/safe_container.h (_Safe_container<>): Make all methods
135         protected.
136         * include/debug/safe_unordered_container.h
137         (_Safe_unordered_container<>::_UContInvalidatePred<_ExtractKey, _Source>): New.
138         (_Safe_unordered_container<>::_UMContInvalidatePred<_ExtractKey, _Source>): New.
139         (_Safe_unordered_container<>::_UContMergeGuard<_Source, _InvalidatePred>): New.
140         (_Safe_unordered_container<>::_S_uc_guard<_ExtractKey, _Source>): New.
141         (_Safe_unordered_container<>::_S_umc_guard<_ExtractKey, _Source>): New.
142         (_Safe_unordered_container<>::_M_invalide_all): Make public.
143         (_Safe_unordered_container<>::_M_invalide_if): Likewise.
144         (_Safe_unordered_container<>::_M_invalide_local_if): Likewise.
145         * include/debug/unordered_map
146         (unordered_map<>::mapped_type, pointer, const_pointer): New typedef.
147         (unordered_map<>::reference, const_reference, difference_type): New typedef.
148         (unordered_map<>::get_allocator, empty, size, max_size): Add usings.
149         (unordered_map<>::bucket_count, max_bucket_count, bucket): Add usings.
150         (unordered_map<>::hash_function, key_equal, count, contains): Add usings.
151         (unordered_map<>::operator[], at, rehash, reserve): Add usings.
152         (unordered_map<>::merge): New.
153         (unordered_multimap<>::mapped_type, pointer, const_pointer): New typedef.
154         (unordered_multimap<>::reference, const_reference, difference_type): New typedef.
155         (unordered_multimap<>::get_allocator, empty, size, max_size): Add usings.
156         (unordered_multimap<>::bucket_count, max_bucket_count, bucket): Add usings.
157         (unordered_multimap<>::hash_function, key_equal, count, contains): Add usings.
158         (unordered_multimap<>::rehash, reserve): Add usings.
159         (unordered_multimap<>::merge): New.
160         * include/debug/unordered_set
161         (unordered_set<>::mapped_type, pointer, const_pointer): New typedef.
162         (unordered_set<>::reference, const_reference, difference_type): New typedef.
163         (unordered_set<>::get_allocator, empty, size, max_size): Add usings.
164         (unordered_set<>::bucket_count, max_bucket_count, bucket): Add usings.
165         (unordered_set<>::hash_function, key_equal, count, contains): Add usings.
166         (unordered_set<>::rehash, reserve): Add usings.
167         (unordered_set<>::merge): New.
168         (unordered_multiset<>::mapped_type, pointer, const_pointer): New typedef.
169         (unordered_multiset<>::reference, const_reference, difference_type): New typedef.
170         (unordered_multiset<>::get_allocator, empty, size, max_size): Add usings.
171         (unordered_multiset<>::bucket_count, max_bucket_count, bucket): Add usings.
172         (unordered_multiset<>::hash_function, key_equal, count, contains): Add usings.
173         (unordered_multiset<>::rehash, reserve): Add usings.
174         (unordered_multiset<>::merge): New.
175         * testsuite/23_containers/unordered_map/debug/merge1_neg.cc: New test.
176         * testsuite/23_containers/unordered_map/debug/merge2_neg.cc: New test.
177         * testsuite/23_containers/unordered_map/debug/merge3_neg.cc: New test.
178         * testsuite/23_containers/unordered_map/debug/merge4_neg.cc: New test.
179         * testsuite/23_containers/unordered_multimap/debug/merge1_neg.cc: New test.
180         * testsuite/23_containers/unordered_multimap/debug/merge2_neg.cc: New test.
181         * testsuite/23_containers/unordered_multimap/debug/merge3_neg.cc: New test.
182         * testsuite/23_containers/unordered_multimap/debug/merge4_neg.cc: New test.
183         * testsuite/23_containers/unordered_multiset/debug/merge1_neg.cc: New test.
184         * testsuite/23_containers/unordered_multiset/debug/merge2_neg.cc: New test.
185         * testsuite/23_containers/unordered_multiset/debug/merge3_neg.cc: New test.
186         * testsuite/23_containers/unordered_multiset/debug/merge4_neg.cc: New test.
187         * testsuite/23_containers/unordered_set/debug/merge1_neg.cc: New test.
188         * testsuite/23_containers/unordered_set/debug/merge2_neg.cc: New test.
189         * testsuite/23_containers/unordered_set/debug/merge3_neg.cc: New test.
190         * testsuite/23_containers/unordered_set/debug/merge4_neg.cc: New test.
191         * testsuite/util/testsuite_abi.h: [_GLIBCXX_DEBUG] Use normal unordered
192         container implementation.
194 2021-11-09  Jonathan Wakely  <jwakely@redhat.com>
196         * testsuite/26_numerics/random/random_device/cons/token.cc:
197         Print results of random_device_available checks.
199 2021-11-09  Jonathan Wakely  <jwakely@redhat.com>
201         PR libstdc++/103146
202         * src/c++11/random.cc: Check __powerpc64__ not __powerpc__.
204 2021-11-09  Jonathan Wakely  <jwakely@redhat.com>
206         * acinclude.m4 (GLIBCXX_CHECK_GETENTROPY, GLIBCXX_CHECK_ARC4RANDOM):
207         Define.
208         * configure.ac (GLIBCXX_CHECK_GETENTROPY, GLIBCXX_CHECK_ARC4RANDOM):
209         Use them.
210         * config.h.in: Regenerate.
211         * configure: Regenerate.
212         * src/c++11/random.cc (random_device): Add getentropy and
213         arc4random as sources.
214         * testsuite/26_numerics/random/random_device/cons/token.cc:
215         Check new tokens.
216         * testsuite/26_numerics/random/random_device/entropy.cc:
217         Likewise.
219 2021-11-09  Jonathan Wakely  <jwakely@redhat.com>
221         * testsuite/26_numerics/random/random_device/cons/token.cc:
222         Retry if random devices produce the same value.
224 2021-11-09  Rasmus Villemoes  <rasmus.villemoes@prevas.dk>
226         * config/os/vxworks/os_defines.h (_GLIBCXX_HAVE_TLS): Only
227         define for VxWorks >= 6.6.
229 2021-11-05  Jonathan Wakely  <jwakely@redhat.com>
231         * include/bits/range_access.h (begin(valarray), end(valarray)):
232         Add noexcept.
234 2021-11-05  Jonathan Wakely  <jwakely@redhat.com>
236         * include/std/tuple (tuple_size_v): Fix pack expansion.
238 2021-11-05  Jonathan Wakely  <jwakely@redhat.com>
240         * src/c++11/random.cc (__x86_rdrand, __x86_rdseed): Add
241         [[unlikely]] attribute.
243 2021-11-05  Jonathan Wakely  <jwakely@redhat.com>
245         * src/c++11/random.cc [__powerpc__] (USE_DARN): Define.
246         (__ppc_darn): New function to use POWER9 DARN instruction.
247         (Which): Add 'darn' enumerator.
248         (which_source): Check for __ppc_darn.
249         (random_device::_M_init): Support "darn" and "hw" tokens.
250         (random_device::_M_getentropy): Add darn to switch.
251         * testsuite/26_numerics/random/random_device/cons/token.cc:
252         Check "darn" token.
253         * testsuite/26_numerics/random/random_device/entropy.cc:
254         Likewise.
256 2021-11-05  Jonathan Wakely  <jwakely@redhat.com>
258         * testsuite/lib/gdb-test.exp: Add target selector support to the
259         dg-final directives.
260         * testsuite/libstdc++-prettyprinters/80276.cc: Add xfail for
261         C++20.
262         * testsuite/libstdc++-prettyprinters/libfundts.cc: Likewise.
263         * testsuite/libstdc++-prettyprinters/prettyprinters.exp: Tweak
264         comment.
266 2021-11-04  Jonathan Wakely  <jwakely@redhat.com>
268         PR libstdc++/103086
269         * python/libstdcxx/v6/printers.py (_tuple_impl_get): New helper
270         for accessing the tuple element stored in a _Tuple_impl node.
271         (tuple_get): New function for accessing a tuple element.
272         (unique_ptr_get): New function for accessing a unique_ptr.
273         (UniquePointerPrinter, StdPathPrinter): Use unique_ptr_get.
274         * python/libstdcxx/v6/xmethods.py (UniquePtrGetWorker): Cast
275         tuple to its base class before accessing _M_head_impl.
277 2021-11-04  Jonathan Wakely  <jwakely@redhat.com>
279         * doc/xml/manual/evolution.xml: Document deprecations.
280         * doc/html/*: Regenerate.
281         * libsupc++/exception (unexpected_handler, unexpected)
282         (get_unexpected, set_unexpected): Add deprecated attribute.
283         Do not define without _GLIBCXX_USE_DEPRECATED for C++17 and up.
284         * libsupc++/eh_personality.cc (PERSONALITY_FUNCTION): Disable
285         deprecated warnings.
286         * libsupc++/eh_ptr.cc (std::rethrow_exception): Likewise.
287         * libsupc++/eh_terminate.cc: Likewise.
288         * libsupc++/eh_throw.cc (__cxa_init_primary_exception):
289         Likewise.
290         * libsupc++/unwind-cxx.h (struct __cxa_exception): Use
291         terminate_handler instead of unexpected_handler.
292         (struct __cxa_dependent_exception): Likewise.
293         (__unexpected): Likewise.
294         * testsuite/18_support/headers/exception/synopsis.cc: Add
295         dg-warning for deprecated warning.
296         * testsuite/18_support/exception_ptr/60612-unexpected.cc:
297         Disable deprecated warnings.
298         * testsuite/18_support/set_unexpected.cc: Likewise.
299         * testsuite/18_support/unexpected_handler.cc: Likewise.
301 2021-11-04  Jonathan Wakely  <jwakely@redhat.com>
303         * include/bits/utility.h (__find_uniq_type_in_pack): Move
304         definition to here, ...
305         * include/std/tuple (__find_uniq_type_in_pack): ... from here.
306         * include/std/variant (__detail__variant::__index_of): Remove.
307         (__detail::__variant::__exactly_once): Define using
308         __find_uniq_type_in_pack instead of __index_of.
309         (get<T>, get_if<T>, variant::__index_of): Likewise.
311 2021-11-04  Jonathan Wakely  <jwakely@redhat.com>
313         * include/bits/stl_pair.h (tuple_size_v): Define partial
314         specializations for std::pair.
315         * include/bits/utility.h (_Nth_type): Move definition here
316         and define primary template.
317         (tuple_size_v): Move definition here.
318         * include/std/array (tuple_size_v): Define partial
319         specializations for std::array.
320         * include/std/tuple (tuple_size_v): Move primary template to
321         <bits/utility.h>.  Define partial specializations for
322         std::tuple.
323         (tuple_element): Change definition to use _Nth_type.
324         * include/std/variant (_Nth_type): Move to <bits/utility.h>.
325         (variant_alternative, variant): Adjust qualification of
326         _Nth_type.
327         * testsuite/20_util/tuple/element_access/get_neg.cc: Prune
328         additional errors from _Nth_type.
330 2021-11-04  Jonathan Wakely  <jwakely@redhat.com>
332         * include/std/variant (__detail::__variant::__emplace): New
333         function template.
334         (_Copy_assign_base::operator=): Reorder conditions to match
335         bulleted list of effects in the standard. Use __emplace instead
336         of _M_reset followed by _Construct.
337         (_Move_assign_base::operator=): Likewise.
338         (__construct_by_index): Remove.
339         (variant::emplace): Use __emplace instead of _M_reset followed
340         by __construct_by_index.
341         (variant::swap): Hoist valueless cases out of visitor. Use
342         __emplace to replace _M_reset followed by _Construct.
344 2021-11-04  Jonathan Wakely  <jwakely@redhat.com>
346         * include/std/variant (_Nth_type): Define partial
347         specializations to reduce number of instantiations.
348         (variant_size_v): Define partial specializations to avoid
349         instantiations.
350         (variant_alternative): Use _Nth_type. Add static assert.
351         (__tuple_count, __tuple_count_v): Replace with ...
352         (__count): New variable template.
353         (_Variant_union): Add deleted constructor.
354         (variant::__to_type): Use _Nth_type.
355         (variant::emplace): Use _Nth_type. Add deleted overloads for
356         invalid types and indices.
358 2021-11-04  Jonathan Wakely  <jwakely@redhat.com>
360         PR libstdc++/102912
361         * include/std/variant (_Variant_storage::__index_of): Remove.
362         (__variant_construct_single): Remove.
363         (__variant_construct): Remove.
364         (_Copy_ctor_base::_Copy_ctor_base(const _Copy_ctor_base&)): Do
365         construction directly instead of using __variant_construct.
366         (_Move_ctor_base::_Move_ctor_base(_Move_ctor_base&&)): Likewise.
367         (_Move_ctor_base::_M_destructive_move()): Remove.
368         (_Move_ctor_base::_M_destructive_copy()): Remove.
369         (_Copy_assign_base::operator=(const _Copy_assign_base&)): Do
370         construction directly instead of using _M_destructive_copy.
371         (variant::swap): Do construction directly instead of using
372         _M_destructive_move.
373         * testsuite/20_util/variant/102912.cc: New test.
375 2021-11-03  Jonathan Wakely  <jwakely@redhat.com>
377         PR libstdc++/66742
378         * include/bits/list.tcc (list::sort): Use mutable iterators for
379         comparisons.
380         * include/bits/stl_list.h (_Scratch_list::_Ptr_cmp): Likewise.
381         * testsuite/23_containers/list/operations/66742.cc: Check
382         non-const comparisons.
384 2021-11-03  Jonathan Wakely  <jwakely@redhat.com>
386         * include/std/valarray (valarray::valarray()): Add noexcept.
387         (valarray::operator[]): Likewise.
389 2021-11-01  Jonathan Wakely  <jwakely@redhat.com>
391         * include/debug/stl_iterator.h (__valid_range): Add constexpr
392         for C++20. Qualify call to avoid ADL.
393         (__get_distance, __can_advance, __unsafe, __base): Likewise.
394         * testsuite/25_algorithms/move/constexpr.cc: Also check with
395         std::reverse_iterator arguments.
397 2021-11-01  Jonathan Wakely  <jwakely@redhat.com>
399         * include/std/span (span(Range&&)): Reorder constraints.
401 2021-11-01  Jonathan Wakely  <jwakely@redhat.com>
403         PR libstdc++/103022
404         * include/std/valarray (begin, end): Do not dereference an empty
405         valarray. Add noexcept and [[nodiscard]].
406         * testsuite/26_numerics/valarray/range_access.cc: Check empty
407         valarray. Check iterator properties. Run as well as compiling.
408         * testsuite/26_numerics/valarray/range_access2.cc: Likewise.
409         * testsuite/26_numerics/valarray/103022.cc: New test.
411 2021-10-29  Jonathan Wakely  <jwakely@redhat.com>
413         * testsuite/23_containers/stack/deduction.cc: Fix typo.
415 2021-10-26  Martin Sebor  <msebor@redhat.com>
417         * testsuite/21_strings/basic_string/capacity/1.cc: Also suppress
418         -Wstringop-overread.
419         * testsuite/27_io/filesystem/path/factory/u8path-char8_t.cc: Same.
421 2021-10-26  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
423         * testsuite/28_regex/basic_regex/84110.cc (test01)
424         [__cpp_exceptions]: Disambiguate extended.
426 2021-10-26  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
428         * testsuite/17_intro/names.cc [__sun__] (r, x): Undef.
430 2021-10-22  Jonathan Wakely  <jwakely@redhat.com>
432         PR libstdc++/102894
433         * include/std/any (make_any): Add SFINAE constraint.
434         * testsuite/20_util/any/102894.cc: New test.
436 2021-10-21  Jonathan Wakely  <jwakely@redhat.com>
438         * doc/doxygen/stdheader.cc: Refactor. Use C++23. Add new
439         headers.
440         * scripts/run_doxygen: Fix post-processing of #include
441         directives in man pages. Use new xg++ to compile helper program.
443 2021-10-21  Jonathan Wakely  <jwakely@redhat.com>
445         * include/bits/mofunc_impl.h: Add doxygen comments.
446         * include/std/functional: Likewise.
448 2021-10-21  Jonathan Wakely  <jwakely@redhat.com>
450         * include/bits/alloc_traits.h: Suppress doxygen documentation.
451         * include/bits/allocated_ptr.h: Likewise.
452         * include/bits/enable_special_members.h: Likewise.
453         * include/bits/hashtable.h: Likewise.
454         * include/bits/hashtable_policy.h: Likewise.
455         * include/bits/uses_allocator.h: Likewise.
456         * include/bits/node_handle.h: Document node handles and suppress
457         documentation for protected members.
458         * include/std/any: Suppress documentation for implementation
459         details.
461 2021-10-21  Patrick Palka  <ppalka@redhat.com>
463         PR libstdc++/102358
464         * include/bits/stl_iterator.h (__niter_base): Make constexpr
465         for C++20.
466         (__miter_base): Likewise.
467         * testsuite/25_algorithms/move/constexpr.cc: New test.
469 2021-10-21  Patrick Palka  <ppalka@redhat.com>
471         * include/std/ranges (istream_view): Replace this function
472         template with an alias template as per P2432R1.
473         (wistream_view): Define as per P2432R1.
474         (views::_Istream, views::istream): Likewise.
475         * testsuite/std/ranges/istream_view.cc (test07): New test.
477 2021-10-21  Patrick Palka  <ppalka@redhat.com>
479         * include/bits/ranges_util.h (views::_Drop): Forward declare.
480         (subrange): Befriend views::_Drop.
481         (subrange::_S_store_size): Declare constexpr instead of just
482         const, remove obsolete comment.
483         * include/std/ranges (views::__detail::__is_empty_view): Define.
484         (views::__detail::__is_basic_string_view): Likewise.
485         (views::__detail::__is_subrange): Likewise.
486         (views::__detail::__is_iota_view): Likewise.
487         (views::__detail::__can_take_view): Rename template parm _Tp to _Dp.
488         (views::_Take): Rename template parm _Tp to _Dp, make it non-deducible
489         and fix it to range_difference_t<_Range>.  Implement P1739R4 and
490         LWG 3407 changes.
491         (views::__detail::__can_drop_view): Rename template parm _Tp to _Dp.
492         (views::_Drop): As with views::_Take.
493         (views::_Counted): Implement P1739R4 changes.
494         * include/std/span (__detail::__is_std_span): Rename to ...
495         (__detail::__is_span): ... this and turn it into a variable
496         template.
497         (__detail::__is_std_array): Turn it into a variable template.
498         (span::span): Adjust uses of __is_std_span and __is_std_array
499         accordingly.
500         * testsuite/std/ranges/adaptors/p1739.cc: New test.
502 2021-10-21  Patrick Palka  <ppalka@redhat.com>
504         * include/bits/stl_iterator.h (common_iterator::__arrow_proxy):
505         Make fully constexpr as per LWG 3595.
506         (common_iterator::__postfix_proxy): Likewise.
508 2021-10-21  Patrick Palka  <ppalka@redhat.com>
510         * include/std/ranges (lazy_split_view::base): Add forward_range
511         constraint as per LWG 3591.
512         (lazy_split_view::begin, lazy_split_view::end): Also check
513         simpleness of _Pattern as per LWG 3592.
514         (split_view::base): Relax copyable constraint as per LWG 3590.
516 2021-10-21  Patrick Palka  <ppalka@redhat.com>
518         * include/std/ranges (join_view::__iter_cat::_S_iter_cat): Adjust
519         criteria for returning bidirectional_iterator_tag as per LWG 3535.
520         (join_view::_Iterator::_S_iter_concept): Likewise.
522 2021-10-21  Patrick Palka  <ppalka@redhat.com>
524         * include/bits/ranges_base.h (viewable_range): Adjust as per
525         LWG 3481.
526         * testsuite/std/ranges/adaptors/all.cc (test07): New test.
528 2021-10-21  Jonathan Wakely  <jwakely@redhat.com>
530         PR libstdc++/102863
531         * include/std/optional (optional::and_then, optional::transform):
532         Remove requires-clause.
533         * testsuite/20_util/optional/monadic/and_then.cc: Check
534         overload resolution doesn't cause errors.
535         * testsuite/20_util/optional/monadic/transform.cc: Likewise.
537 2021-10-20  Jonathan Wakely  <jwakely@redhat.com>
539         * testsuite/20_util/optional/monadic/transform.cc: Check that
540         an rvalue result is not materialized too soon.
542 2021-10-19  Patrick Palka  <ppalka@redhat.com>
544         * include/std/ranges (iota_view::_Iterator::operator+): Adjust
545         definition as per LWG 3580.
546         (iota_view::_Iterator::operator-): Likewise.
548 2021-10-19  Patrick Palka  <ppalka@redhat.com>
550         * include/std/ranges (basic_istream_view::_M_object): Value
551         initialize as per LWG 3568.
553 2021-10-19  Patrick Palka  <ppalka@redhat.com>
555         * include/bits/ranges_util.h
556         (__detail::__uses_nonqualification_pointer_conversion): Define
557         and use it ...
558         (__detail::__convertible_to_nonslicing): ... here, as per LWG 3470.
559         * testsuite/std/ranges/subrange/1.cc: New test.
561 2021-10-19  Patrick Palka  <ppalka@redhat.com>
563         * include/std/ranges (iota_view::_Iterator): Befriend iota_view.
564         (iota_view::_Sentinel): Likewise.
565         (iota_view::iota_view): Add three overloads, each taking an
566         iterator/sentinel pair as per LWG 3523.
567         * testsuite/std/ranges/iota/iota_view.cc (test06): New test.
569 2021-10-19  Patrick Palka  <ppalka@redhat.com>
571         * include/bits/ranges_base.h (view_interface): Forward declare.
572         (__detail::__is_derived_from_view_interface_fn): Declare.
573         (__detail::__is_derived_from_view_interface): Define as per LWG 3549.
574         (enable_view): Adjust as per LWG 3549.
575         * include/bits/ranges_util.h (view_interface): Don't derive from
576         view_base.
577         * include/std/ranges (filter_view): Revert r11-3504 change.
578         (transform_view): Likewise.
579         (take_view): Likewise.
580         (take_while_view): Likewise.
581         (drop_view): Likewise.
582         (drop_while_view): Likewise.
583         (join_view): Likewise.
584         (lazy_split_view): Likewise.
585         (split_view): Likewise.
586         (reverse_view): Likewise.
587         * testsuite/std/ranges/adaptors/sizeof.cc: Update expected sizes.
588         * testsuite/std/ranges/view.cc (test_view::test_view): Remove
589         this default ctor since views no longer need to be default initable.
590         (test01): New test.
592 2021-10-19  Jonathan Wakely  <jwakely@redhat.com>
594         * src/c++11/random.cc (which_source): New helper function.
595         (random_device::_M_getentropy()): Use which_source and return
596         suitable values for sources other than device files.
597         * testsuite/26_numerics/random/random_device/entropy.cc: New test.
599 2021-10-19  Jonathan Wakely  <jwakely@redhat.com>
601         * doc/Makefile.am (stamp-html-doxygen, stamp-html-doxygen)
602         (stamp-latex-doxygen, stamp-man-doxygen): Fix recipes for
603         relative ${top_srcdir}.
604         * doc/Makefile.in: Regenerate.
606 2021-10-19  Jonathan Wakely  <jwakely@redhat.com>
608         * include/std/variant (_Uninitialized): Use an empty struct
609         for the unused union member, instead of char.
611 2021-10-19  Jonathan Wakely  <jwakely@redhat.com>
613         * include/bits/stl_stack.h (stack(Iterator, Iterator)): Remove
614         non-deducible template parameter from deduction guide.
615         * testsuite/23_containers/stack/deduction.cc: Check new C++23
616         deduction guides.
618 2021-10-19  Jonathan Wakely  <jwakely@redhat.com>
620         * include/std/optional (_Optional_payload_base::_Storage): Add
621         constructor taking a callable function to invoke.
622         (_Optional_payload_base::_M_apply): New function.
623         (__cpp_lib_monadic_optional): Define for C++23.
624         (optional::and_then, optional::transform, optional::or_else):
625         Define for C++23.
626         * include/std/ranges (__detail::__cached): Remove.
627         (__detail::__non_propagating_cache): Remove use of __cached for
628         contained value. Use _Optional_payload_base::_M_construct and
629         _Optional_payload_base::_M_apply to set the contained value.
630         * include/std/version (__cpp_lib_monadic_optional): Define.
631         * testsuite/20_util/optional/monadic/and_then.cc: New test.
632         * testsuite/20_util/optional/monadic/or_else.cc: New test.
633         * testsuite/20_util/optional/monadic/or_else_neg.cc: New test.
634         * testsuite/20_util/optional/monadic/transform.cc: New test.
635         * testsuite/20_util/optional/monadic/version.cc: New test.
637 2021-10-19  Jonathan Wakely  <jwakely@redhat.com>
639         PR libstdc++/102825
640         * include/bits/mofunc_impl.h (move_only_function): Remove
641         invalid base initializer.
642         * testsuite/20_util/move_only_function/cons.cc: Instantiate
643         constructors to check bodies.
645 2021-10-15  Jonathan Wakely  <jwakely@redhat.com>
647         * include/bits/fs_path.h (path::_S_convert(T)): Avoid recursive
648         call to function with deduced return type.
650 2021-10-15  Jonathan Wakely  <jwakely@redhat.com>
652         * include/bits/basic_string.h (__cpp_lib_string_resize_and_overwrite):
653         Define for C++23.
654         (basic_string::resize_and_overwrite): Declare.
655         * include/bits/basic_string.tcc (basic_string::resize_and_overwrite):
656         Define.
657         * include/std/version (__cpp_lib_resize_and_overwrite): Define
658         for C++23.
659         * testsuite/21_strings/basic_string/capacity/char/resize_and_overwrite.cc:
660         New test.
662 2021-10-15  Jonathan Wakely  <jwakely@redhat.com>
664         PR libstdc++/101263
665         * include/std/ranges (__cached): New wrapper struct.
666         (__non_propagating_cache): Use __cached for contained value.
667         (__non_propagating_cache::_M_emplace_deref): Add constexpr. Use
668         std::construct_at instead of placement new.
669         * testsuite/std/ranges/adaptors/join.cc: Check constexpr works.
671 2021-10-15  Jonathan Wakely  <jwakely@redhat.com>
673         * include/std/variant (__cpp_lib_variant): Update value for
674         C++20.
675         (__variant_cast, __variant_construct): Add constexpr for C++20.
676         (__variant_construct_single, __construct_by_index) Likewise. Use
677         std::_Construct instead of placement new.
678         (_Uninitialized<T, false>) [__cplusplus >= 202002]: Replace
679         buffer with a union and define a destructor.
680         (_Variadic_union) [__cplusplus >= 202002]: Add a specialization
681         for non-trivial destruction.
682         (_Variant_storage::__index_of): New helper variable template.
683         (_Variant_storage::~_Variant_storage()): Add constexpr.
684         (_Variant_storage::_M_reset()): Likewise.
685         (_Copy_ctor_base, _Move_ctor_base): Likewise.
686         (_Copy_assign_base, _Move_assign_base): Likewise.
687         (variant, swap): Likewise.
688         * include/std/version (__cpp_lib_variant): Update value for
689         C++20.
690         * testsuite/20_util/optional/version.cc: Check for exact value
691         in C++17.
692         * testsuite/20_util/variant/87619.cc: Increase timeout for
693         C++20 mode.
694         * testsuite/20_util/variant/constexpr.cc: New test.
695         * testsuite/20_util/variant/version.cc: New test.
697 2021-10-15  Jonathan Wakely  <jwakely@redhat.com>
699         * include/std/variant (__detail::__variant::__get_storage):
700         Remove unused function.
701         (__variant_construct_by_index): Set index after construction is
702         complete. Rename to ...
703         (__detail::__variant::__construct_by_index): ... this.
704         (variant): Use new name for __variant_construct_by_index friend
705         declaration. Remove __get_storage friend declaration.
706         (variant::emplace): Use new name and remove try-blocks.
708 2021-10-15  Jonathan Wakely  <jwakely@redhat.com>
710         * include/std/variant (_Variant_storage::_M_storage()): Remove.
711         (__detail::__variant::__get_storage): Remove.
712         (variant): Remove friend declaration of __get_storage.
714 2021-10-15  Jason Merrill  <jason@redhat.com>
716         * testsuite/20_util/integer_comparisons/greater_equal_neg.cc:
717         * testsuite/20_util/integer_comparisons/greater_neg.cc:
718         * testsuite/20_util/integer_comparisons/less_equal_neg.cc:
719         Adjust expected message.
720         * testsuite/lib/prune.exp: Prune 'in constexpr expansion'.
722 2021-10-14  Jonathan Wakely  <jwakely@redhat.com>
724         * include/std/variant (__variant::__get(in_place_index_t<N>, U&&)):
725         Rename to __get_n and remove first argument. Replace pair of
726         overloads with a single function using 'if constexpr'.
727         (__variant::__get(Variant&&)): Adjust to use __get_n.
729 2021-10-14  Jonathan Wakely  <jwakely@redhat.com>
731         * include/bits/fs_path.h (path(path&&)): Make unconditionally
732         noexcept.
733         (path::_S_convert(T)): Add condtional noexcept.
735 2021-10-14  Jonathan Wakely  <jwakely@redhat.com>
737         PR libstdc++/102743
738         * include/bits/fs_path.h (path::_S_convert(T)): Fix condition
739         for returning the same string unchanged.
741 2021-10-14  Jonathan Wakely  <jwakely@redhat.com>
743         * include/bits/regex.h: Check __cpp_inline_variables instead of
744         __cplusplus.
746 2021-10-14  Jonathan Wakely  <jwakely@redhat.com>
748         * testsuite/20_util/is_layout_compatible/version.cc: Check
749         correct macro.
751 2021-10-14  Jonathan Wakely  <jwakely@redhat.com>
753         * include/bits/stl_construct.h (_Construct): Use
754         std::construct_at when constant evaluated.
755         * include/std/optional (_Storage, _Optional_payload, optional):
756         Add constexpr as specified by P2231R1.
757         * include/std/version (__cpp_lib_optional): Update value for
758         C++20.
759         * testsuite/20_util/optional/requirements.cc: Check feature test
760         macro.
761         * testsuite/20_util/optional/constexpr/assign.cc: New test.
762         * testsuite/20_util/optional/constexpr/cons/conv.cc: New test.
763         * testsuite/20_util/optional/constexpr/modifiers.cc: New test.
764         * testsuite/20_util/optional/constexpr/swap.cc: New test.
765         * testsuite/20_util/optional/version.cc: New test.
767 2021-10-13  Jonathan Wakely  <jwakely@redhat.com>
769         * include/bits/fs_path.h (__detail::__is_contiguous): Add
770         partial specializations for pointers and __normal_iterator.
772 2021-10-13  Jonathan Wakely  <jwakely@redhat.com>
774         * testsuite/27_io/filesystem/path/construct/102592.C: Moved to...
775         * testsuite/27_io/filesystem/path/construct/102592.cc: ...here.
776         * testsuite/28_regex/match_results/102667.C: Moved to...
777         * testsuite/28_regex/match_results/102667.cc: ...here.
779 2021-10-13  Jonathan Wakely  <jwakely@redhat.com>
781         * include/bits/fs_path.h (__detail::__is_contiguous): New
782         variable template to identify contiguous iterators.
783         (__detail::__unified_char8_t): New alias template to decide when
784         to treat char8_t as char without encoding conversion.
785         (__detail::__effective_range(const basic_string<C,T>&)): Use
786         std::char_traits<C> for returned string view.
787         (__detail::__effective_range(const basic_string_view<C,T>&)):
788         Likewise.
789         (__detail::__effective_range(const Source&)): Use
790         __is_contiguous to detect mode cases of contiguous iterators.
791         Use __unified_char8_t to return a std::string instead of
792         std::u8string.
794 2021-10-13  Jonathan Wakely  <jwakely@redhat.com>
796         PR libstdc++/102592
797         * include/bits/fs_path.h (path::path(Iter, Iter, format))
798         (path::append(Iter, Iter), path::concat(Iter, Iter)): Call
799         __string_from_range directly, instead of two-argument overload
800         of _S_convert.
801         (path::_S_convert(Iter, Iter)): Remove.
802         * testsuite/27_io/filesystem/path/construct/102592.C: New test.
804 2021-10-13  Jonathan Wakely  <jwakely@redhat.com>
806         * include/bits/c++config (__terminate): Add extern "C++".
808 2021-10-12  Jonathan Wakely  <jwakely@redhat.com>
810         * testsuite/20_util/tuple/comparison_operators/overloaded.cc:
811         Restore test for operator<.
812         * testsuite/20_util/tuple/comparison_operators/overloaded2.cc:
813         Adjust expected errors for C++20.
815 2021-10-12  Jonathan Wakely  <jwakely@redhat.com>
817         PR libstdc++/101960
818         * include/std/tuple (_Tuple_impl(_Tuple_impl&&)): Define as
819         defauled.
820         * testsuite/20_util/tuple/cons/101960.cc: Check tuples with
821         array elements before the last element.
823 2021-10-12  Jonathan Wakely  <jwakely@redhat.com>
825         * include/bits/stl_iterator_base_funcs.h (__advance): Add
826         deleted overload to improve diagnostics.
827         (__distance): Likewise.
829 2021-10-11  Jonathan Wakely  <jwakely@redhat.com>
831         * include/bits/atomic_timed_wait.h: Remove unused header.
832         * include/bits/c++config (std:__terminate): Define.
833         * include/bits/semaphore_base.h: Remove <exception> and use
834         __terminate instead of terminate.
835         * include/bits/std_thread.h: Likewise.
836         * libsupc++/eh_terminate.cc (std::terminate): Use qualified-id
837         to call __cxxabiv1::__terminate.
839 2021-10-11  Jonathan Wakely  <jwakely@redhat.com>
841         * include/bits/regex.h (basic_regex::assign(Iter, Iter)): Avoid
842         std::__to_address by using poitner directly or using base()
843         member of __normal_iterator.
845 2021-10-11  Jonathan Wakely  <jwakely@redhat.com>
847         * testsuite/18_support/numeric_limits/lowest.cc: Use
848         numeric_limits<T>::is_integer instead of is_integral<T>::value.
850 2021-10-11  Jonathan Wakely  <jwakely@redhat.com>
852         PR libstdc++/89927
853         * include/bits/regex.h (basic_regex(const _Ch_type*, size_t)):
854         Add __glibcxx_requires_string_len assertion.
855         (basic_regex::assign(InputIterator, InputIterator)): Add
856         __glibcxx_requires_valid_range assertion.
857         * include/bits/regex_scanner.tcc (_Scanner::_M_advance())
858         (_Scanner::_M_scan_normal()): Use string literal in assertions.
860 2021-10-11  Jonathan Wakely  <jwakely@redhat.com>
862         PR libstdc++/102667
863         * include/bits/regex.h (match_result::empty()): Optimize by
864         calling the base function directly.
865         (match_results::end()): Check _Base_type::empty() not empty().
866         * testsuite/28_regex/match_results/102667.C: New test.
868 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
870         PR libstdc++/98725
871         * testsuite/18_support/numeric_limits/lowest.cc: Remove use of
872         _GLIBCXX_USE_WCHAR_T.
873         * testsuite/18_support/numeric_limits/min_max.cc: Replace use of
874         _GLIBCXX_USE_WCHAR_T with checks for WCHAR_MIN and WCHAR_MAX.
875         * testsuite/20_util/from_chars/1_neg.cc: Remove use of
876         _GLIBCXX_USE_WCHAR_T.
877         * testsuite/20_util/function_objects/searchers.cc: Likewise. Use
878         char_traits<wchar_t>::length instead of wcslen.
879         * testsuite/20_util/hash/requirements/explicit_instantiation.cc:
880         Likewise.
881         * testsuite/20_util/is_arithmetic/value.cc: Likewise.
882         * testsuite/20_util/is_compound/value.cc: Likewise.
883         * testsuite/20_util/is_floating_point/value.cc: Likewise.
884         * testsuite/20_util/is_fundamental/value.cc: Likewise.
885         * testsuite/20_util/is_integral/value.cc: Likewise.
886         * testsuite/20_util/is_signed/value.cc: Likewise.
887         * testsuite/20_util/is_unsigned/value.cc: Likewise.
888         * testsuite/20_util/is_void/value.cc: Likewise.
889         * testsuite/20_util/make_signed/requirements/typedefs-1.cc:
890         Likewise.
891         * testsuite/20_util/make_signed/requirements/typedefs-2.cc:
892         Likewise.
893         * testsuite/20_util/make_signed/requirements/typedefs-3.cc:
894         Likewise.
895         * testsuite/20_util/make_signed/requirements/typedefs-4.cc:
896         Likewise.
897         * testsuite/20_util/make_unsigned/requirements/typedefs-1.cc:
898         Likewise.
899         * testsuite/20_util/make_unsigned/requirements/typedefs-2.cc:
900         Likewise.
901         * testsuite/20_util/make_unsigned/requirements/typedefs-3.cc:
902         Likewise.
903         * testsuite/20_util/to_chars/3.cc: Likewise.
904         * testsuite/20_util/type_identity/requirements/typedefs.cc:
905         Likewise.
906         * testsuite/21_strings/basic_string/hash/debug.cc: Likewise.
907         * testsuite/21_strings/basic_string/hash/hash.cc: Likewise.
908         * testsuite/21_strings/basic_string/literals/types-char8_t.cc:
909         Likewise.
910         * testsuite/21_strings/basic_string/literals/types.cc: Likewise.
911         * testsuite/21_strings/basic_string/literals/values-char8_t.cc:
912         Likewise.
913         * testsuite/21_strings/basic_string/literals/values.cc:
914         Likewise.
915         * testsuite/21_strings/basic_string/modifiers/64422.cc:
916         Likewise.
917         * testsuite/21_strings/basic_string/range_access/wchar_t/1.cc:
918         Likewise.
919         * testsuite/21_strings/basic_string/requirements/citerators.cc:
920         Likewise.
921         * testsuite/21_strings/basic_string/requirements/typedefs.cc:
922         Likewise.
923         * testsuite/21_strings/basic_string/types/pmr_typedefs.cc:
924         Likewise.
925         * testsuite/21_strings/basic_string_view/literals/types-char8_t.cc:
926         Likewise.
927         * testsuite/21_strings/basic_string_view/literals/types.cc:
928         Likewise.
929         * testsuite/21_strings/basic_string_view/literals/values-char8_t.cc:
930         Likewise.
931         * testsuite/21_strings/basic_string_view/literals/values.cc:
932         Likewise.
933         * testsuite/21_strings/basic_string_view/requirements/typedefs.cc:
934         Likewise.
935         * testsuite/21_strings/basic_string_view/typedefs.cc: Likewise.
936         * testsuite/21_strings/char_traits/requirements/constexpr_functions.cc:
937         Likewise.
938         * testsuite/21_strings/char_traits/requirements/constexpr_functions_c++17.cc:
939         Likewise.
940         * testsuite/21_strings/char_traits/requirements/constexpr_functions_c++20.cc:
941         Likewise.
942         * testsuite/22_locale/ctype/is/string/89728_neg.cc: Likewise.
943         * testsuite/25_algorithms/fill/4.cc: Likewise.
944         * testsuite/25_algorithms/fill_n/1.cc: Likewise.
945         * testsuite/experimental/functional/searchers.cc: Likewise. Use
946         char_traits<wchar_t>::length instead of wcslen.
947         * testsuite/experimental/polymorphic_allocator/pmr_typedefs_string.cc:
948         Likewise.
949         * testsuite/experimental/string_view/literals/types-char8_t.cc:
950         Likewise.
951         * testsuite/experimental/string_view/literals/types.cc:
952         Likewise.
953         * testsuite/experimental/string_view/literals/values-char8_t.cc:
954         Likewise.
955         * testsuite/experimental/string_view/literals/values.cc:
956         Likewise.
957         * testsuite/experimental/string_view/range_access/wchar_t/1.cc:
958         Likewise.
959         * testsuite/experimental/string_view/requirements/typedefs.cc:
960         Likewise.
961         * testsuite/experimental/string_view/typedefs.cc: Likewise.
962         * testsuite/ext/vstring/range_access.cc: Likewise.
963         * testsuite/std/concepts/concepts.lang/concept.arithmetic/integral.cc:
964         Likewise.
965         * testsuite/std/concepts/concepts.lang/concept.arithmetic/signed_integral.cc:
966         Likewise.
967         * testsuite/std/concepts/concepts.lang/concept.arithmetic/unsigned_integral.cc:
968         Likewise.
969         * testsuite/tr1/4_metaprogramming/is_arithmetic/value.cc:
970         Likewise.
971         * testsuite/tr1/4_metaprogramming/is_compound/value.cc:
972         Likewise.
973         * testsuite/tr1/4_metaprogramming/is_floating_point/value.cc:
974         Likewise.
975         * testsuite/tr1/4_metaprogramming/is_fundamental/value.cc:
976         Likewise.
977         * testsuite/tr1/4_metaprogramming/is_integral/value.cc:
978         Likewise.
979         * testsuite/tr1/4_metaprogramming/is_signed/value.cc: Likewise.
980         * testsuite/tr1/4_metaprogramming/is_unsigned/value.cc:
981         Likewise.
982         * testsuite/tr1/4_metaprogramming/is_void/value.cc: Likewise.
983         * testsuite/tr1/6_containers/hash/24799.cc: Likewise.
985 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
987         PR libstdc++/98725
988         * include/std/ostream (operator<<(basic_ostream<char, Tr>&, wchar_t))
989         (operator<<(basic_ostream<char, Tr>&, const wchar_t*)): Always
990         define as deleted. Do not check _GLIBCXX_USE_WCHAR_T.
992 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
994         PR libstdc++/98725
995         * include/bits/locale_conv.h (wstring_convert, wbuffer_convert):
996         Define unconditionally. Do not check _GLIBCXX_USE_WCHAR_T.
998 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1000         PR libstdc++/98725
1001         * include/c_global/cstddef [!_GLIBCXX_USE_WCHAR_T]
1002         (__byte_operand<wchar_t>): Define specialization.
1003         * include/std/type_traits (__make_signed<wchar_t>)
1004         (__make_unsigned<wchar_t>): Remove redundant check for
1005         __WCHAR_TYPE__ being defined.
1006         * include/tr1/type_traits [!_GLIBCXX_USE_WCHAR_T]
1007         (__is_integral_helper<wchar_t>): Likewise.
1009 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1011         PR libstdc++/98725
1012         * include/ext/rc_string_base.h [!_GLIBCXX_USE_WCHAR_T]
1013         (__rc_string_base<wchar_t>): Define member function.
1014         * include/ext/vstring.h [!_GLIBCXX_USE_WCHAR_T]
1015         (hash<__gnu_cxx::__wvstring>): Define specialization.
1016         * include/ext/vstring_fwd.h [!_GLIBCXX_USE_WCHAR_T] (__wvstring)
1017         (__wsso_string, __wrc_string): Declare typedefs.
1019 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1021         PR libstdc++/98725
1022         * include/bits/char_traits.h (char_traits<wchar_t>): Define
1023         explicit specialization unconditionally.
1024         * include/bits/basic_string.h (hash<wstring>): Define
1025         unconditionally. Do not check _GLIBCXX_USE_WCHAR_T.
1026         * include/bits/stringfwd.h (wstring): Likewise.
1027         * include/debug/string (wstring): Likewise.
1028         * include/experimental/string_view (experimental::wstring_view)
1029         (hash<experimental::wstring_view>): Likewise.
1030         * include/std/string (pmr::wstring, hash<pmr::wstring>):
1031         Likewise.
1032         * include/std/string_view (wstring_view, hash<wstring_view>):
1033         Likewise.
1035 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1037         * testsuite/27_io/basic_filebuf/close/81256.cc: Moved to...
1038         * testsuite/27_io/basic_filebuf/close/wchar_t/81256.cc: ...here.
1040 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1042         * testsuite/22_locale/conversions/buffer/1.cc: Check
1043         _GLIBCXX_USE_WCHAR_T.
1044         * testsuite/22_locale/conversions/buffer/3.cc: Likewise. Add
1045         test using char16_t.
1046         * testsuite/22_locale/conversions/string/1.cc: Check
1047         _GLIBCXX_USE_WCHAR_T.
1048         * testsuite/27_io/filesystem/path/generic/generic_string.cc:
1049         Likewise.
1050         * testsuite/27_io/filesystem/path/modifiers/make_preferred.cc:
1051         Likewise.
1052         * testsuite/27_io/filesystem/path/native/alloc.cc: Likewise.
1053         * testsuite/27_io/filesystem/path/native/string-char8_t.cc:
1054         Likewise.
1055         * testsuite/27_io/filesystem/path/native/string.cc: Likewise.
1056         * testsuite/28_regex/algorithms/regex_match/extended/wstring_locale.cc:
1057         Likewise.
1058         * testsuite/experimental/filesystem/path/generic/generic_string.cc:
1059         Likewise.
1060         * testsuite/experimental/filesystem/path/native/alloc.cc:
1061         Likewise.
1062         * testsuite/experimental/filesystem/path/native/string-char8_t.cc:
1063         Likewise.
1064         * testsuite/experimental/filesystem/path/native/string.cc:
1065         Likewise.
1067 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1069         * testsuite/26_numerics/bit/bit.rotate/rotr.cc:
1070         * testsuite/util/testsuite_common_types.h:
1072 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1074         * testsuite/18_support/numeric_limits/40856.cc: Replace use of
1075         _GLIBCXX_USE_INT128.
1076         * testsuite/18_support/numeric_limits/dr559.cc: Likewise.
1077         * testsuite/18_support/numeric_limits/lowest.cc: Likewise.
1078         * testsuite/18_support/numeric_limits/max_digits10.cc: Likewise.
1079         * testsuite/20_util/is_floating_point/value.cc: Likewise.
1080         * testsuite/20_util/is_integral/value.cc: Likewise.
1081         * testsuite/20_util/is_signed/value.cc: Likewise.
1082         * testsuite/20_util/is_unsigned/value.cc: Likewise.
1083         * testsuite/20_util/make_signed/requirements/typedefs-1.cc:
1084         Likewise.
1085         * testsuite/20_util/make_signed/requirements/typedefs-2.cc:
1086         Likewise.
1087         * testsuite/20_util/make_unsigned/requirements/typedefs-1.cc:
1088         Likewise.
1089         * testsuite/20_util/make_unsigned/requirements/typedefs-2.cc:
1090         Likewise.
1091         * testsuite/20_util/type_identity/requirements/typedefs.cc:
1092         Likewise.
1093         * testsuite/26_numerics/bit/bit.count/countl_one.cc: Likewise.
1094         * testsuite/26_numerics/bit/bit.count/countl_zero.cc: Likewise.
1095         * testsuite/26_numerics/bit/bit.count/countr_one.cc: Likewise.
1096         * testsuite/26_numerics/bit/bit.count/countr_zero.cc: Likewise.
1097         * testsuite/26_numerics/bit/bit.count/popcount.cc: Likewise.
1098         * testsuite/26_numerics/bit/bit.pow.two/bit_ceil.cc: Likewise.
1099         * testsuite/26_numerics/bit/bit.pow.two/bit_floor.cc: Likewise.
1100         * testsuite/26_numerics/bit/bit.pow.two/bit_width.cc: Likewise.
1101         * testsuite/26_numerics/bit/bit.pow.two/has_single_bit.cc:
1102         Likewise.
1103         * testsuite/26_numerics/bit/bit.rotate/rotl.cc: Likewise.
1105 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1107         * include/bits/hashtable_policy.h (_Select1st): Replace use of
1108         std::get.
1109         (_Select2nd): Remove.
1110         (_NodeBuilder::_S_build): Use _NodeGenerator::__node_type
1111         typedef instead of deducing it. Remove unnecessary piecewise
1112         construction.
1113         (_ReuseOrAllocNode): Make __node_type public.
1114         (_Map_base): Adjust partial specialization to be able to extract
1115         the mapped_type without using tuple_element.
1116         (_Map_base::at): Define inline
1117         * testsuite/23_containers/unordered_map/requirements/53339.cc:
1118         Remove XFAIL.
1119         * testsuite/23_containers/unordered_multimap/requirements/53339.cc:
1120         Likewise.
1122 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1124         * include/bits/hashtable.h: Move static assertion to destructor.
1125         * include/bits/hashtable_policy.h: Deduce value type from node
1126         type without instantiating it.
1128 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1130         * src/c++11/limits.cc: Fail if __cpp_inline_variables is
1131         defined.
1133 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1135         PR libstdc++/92546
1136         * include/bits/ranges_algobase.h: Replace <iterator> with a
1137         subset of the headers it includes.
1139 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1141         * include/experimental/deque (erase, erase_if): Revert changes
1142         to avoid debug mode overhead.
1143         * include/experimental/map (erase, erase_if): Likewise.
1144         * include/experimental/set (erase, erase_if): Likewise.
1145         * include/experimental/unordered_map (erase, erase_if):
1146         Likewise.
1147         * include/experimental/unordered_set (erase, erase_if):
1148         Likewise.
1149         * include/experimental/vector (erase, erase_if): Likewise.
1150         * include/std/deque (erase, erase_if): Likewise.
1151         * include/std/map (erase, erase_if): Likewise.
1152         * include/std/set (erase, erase_if): Likewise.
1153         * include/std/unordered_map (erase, erase_if): Likewise.
1154         * include/std/unordered_set (erase, erase_if): Likewise.
1155         * include/std/vector (erase, erase_if): Likewise.
1157 2021-10-08  Jonathan Wakely  <jwakely@redhat.com>
1159         * include/std/chrono (__detail::__units_suffix_misc): New
1160         helper function.
1161         (__detail::__units_suffix): Likewise.
1162         (chrono::operator<<(basic_ostream&, const duration&)): Define.
1163         * testsuite/20_util/duration/io.cc: New test.
1165 2021-10-07  Jonathan Wakely  <jwakely@redhat.com>
1167         * include/Makefile.am: Add new header.
1168         * include/Makefile.in: Regenerate.
1169         * include/std/chrono (duration, time_point, system_clock)
1170         (steady_clock, high_resolution_clock, chrono_literals, sys_time)
1171         (file_clock, file_time): Move to ...
1172         * include/bits/chrono.h: New file.
1173         * include/bits/atomic_futex.h: Include new header instead of
1174         <chrono>.
1175         * include/bits/atomic_timed_wait.h: Likewise.
1176         * include/bits/fs_fwd.h: Likewise.
1177         * include/bits/semaphore_base.h: Likewise.
1178         * include/bits/this_thread_sleep.h: Likewise.
1179         * include/bits/unique_lock.h: Likewise.
1180         * include/experimental/bits/fs_fwd.h: Likewise.
1181         * include/experimental/chrono: Likewise.
1182         * include/experimental/io_context: Likewise.
1183         * include/experimental/netfwd: Likewise.
1184         * include/experimental/timer: Likewise.
1185         * include/std/condition_variable: Likewise.
1186         * include/std/mutex: Likewise.
1187         * include/std/shared_mutex: Likewise.
1189 2021-10-07  Jonathan Wakely  <jwakely@redhat.com>
1191         PR libstdc++/102377
1192         * include/bits/atomic_wait.h (__waiter_pool_base:_S_align):
1193         Hardcode to 64 instead of using non-constant constant.
1195 2021-10-07  Jonathan Wakely  <jwakely@redhat.com>
1197         * include/bits/erase_if.h (__erase_nodes_if): Remove redundant
1198         __niter_base calls.
1199         * include/std/string (erase, erase_if): Likewise.
1200         * include/std/deque (erase, erase_if): Access non-debug
1201         container directly.
1202         * include/std/map (erase, erase_if): Likewise.
1203         * include/std/set (erase, erase_if): Likewise.
1204         * include/std/unordered_map (erase, erase_if): Likewise.
1205         * include/std/unordered_set (erase, erase_if): Likewise.
1206         * include/std/vector (erase, erase_if): Likewise.
1207         * include/experimental/deque (erase, erase_if): Likewise.
1208         * include/experimental/map (erase, erase_if): Likewise.
1209         * include/experimental/set (erase, erase_if): Likewise.
1210         * include/experimental/unordered_map (erase, erase_if):
1211         Likewise.
1212         * include/experimental/unordered_set (erase, erase_if):
1213         Likewise.
1214         * include/experimental/vector (erase, erase_if): Likewise.
1216 2021-10-06  Jonathan Wakely  <jwakely@redhat.com>
1218         * include/Makefile.am: Add new headers.
1219         * include/Makefile.in: Regenerate.
1220         * include/std/functional: Include <bits/move_only_function.h>.
1221         * include/std/version (__cpp_lib_move_only_function): Define.
1222         * include/bits/mofunc_impl.h: New file.
1223         * include/bits/move_only_function.h: New file.
1224         * testsuite/20_util/move_only_function/call.cc: New test.
1225         * testsuite/20_util/move_only_function/cons.cc: New test.
1226         * testsuite/20_util/move_only_function/move.cc: New test.
1227         * testsuite/20_util/move_only_function/version.cc: New test.
1229 2021-10-05  Jonathan Wakely  <jwakely@redhat.com>
1231         * testsuite/21_strings/basic_string_view/requirements/trivially_copyable.cc:
1232         New test.
1233         * testsuite/23_containers/span/trivially_copyable.cc: New test.
1235 2021-10-05  Jonathan Wakely  <jwakely@redhat.com>
1237         * include/bits/utility.h (__is_in_place_type_v): Define
1238         variable template to detect in_place_type_t specializations.
1239         (__is_in_place_type): Replace class template with alias
1240         template using __is_in_place_type_v.
1241         * include/std/any (any(T&&)): Check __is_in_place_type first and
1242         avoid instantiating is_copy_constructible unnecessarily.
1244 2021-10-05  Jonathan Wakely  <jwakely@redhat.com>
1246         * testsuite/20_util/integer_comparisons/greater.cc: New test.
1248 2021-10-05  Jonathan Wakely  <jwakely@redhat.com>
1250         * testsuite/27_io/basic_ostream/inserters_other/char/volatile_ptr.cc:
1251         Check result matches non-volatile pointer.
1253 2021-10-05  Jonathan Wakely  <jwakely@redhat.com>
1255         PR c++/102535
1256         * testsuite/20_util/is_trivially_constructible/value.cc: Adjust
1257         expected value for C++20.
1259 2021-10-05  Jonathan Wakely  <jwakely@redhat.com>
1261         * include/bits/std_function.h (_Any_data::_M_access): Add
1262         noexcept.
1263         (_Function_base::_Base_manager::_M_get_pointer): Likewise.
1264         (_Function_base::_Base_manager::_M_not_empty_function):
1265         Likewise.
1267 2021-10-05  Jonathan Wakely  <jwakely@redhat.com>
1269         * include/std/ostream (operator<<(const volatile void*)):
1270         Add new overload, as per P1147R1.
1271         * testsuite/27_io/basic_ostream/inserters_other/char/volatile_ptr.cc:
1272         New test.
1274 2021-10-05  Jonathan Wakely  <jwakely@redhat.com>
1276         * include/bits/stl_queue.h
1277         (__cpp_lib_adaptor_iterator_pair_constructor): Set to correct
1278         value.
1279         * include/bits/stl_stack.h
1280         (__cpp_lib_adaptor_iterator_pair_constructor): Likewise.
1281         * include/std/version
1282         (__cpp_lib_adaptor_iterator_pair_constructor): Likewise.
1283         * testsuite/23_containers/queue/cons_from_iters.cc: Update
1284         expected value.
1285         * testsuite/23_containers/stack/cons_from_iters.cc: Likewise.
1287 2021-10-04  Jonathan Wakely  <jwakely@redhat.com>
1289         * include/bits/forward_list.h (forward_list): Use non-deduced
1290         context for allocator parameter of allocator-extended copy and
1291         move constructors.
1292         * include/bits/stl_bvector.h (vector<bool>): Likewise.
1293         * include/bits/stl_deque.h (deque): Likewise.
1294         * include/bits/stl_list.h (list): Likewise.
1295         * include/bits/stl_map.h (map): Likewise.
1296         * include/bits/stl_multimap.h (multimap): Likewise.
1297         * include/bits/stl_multiset.h (multiset): Likewise.
1298         * include/bits/stl_set.h (set): Likewise.
1299         * include/bits/stl_vector.h (vector): Likewise.
1300         * include/bits/stl_queue.h (queue, priority_queue): Do not
1301         constrain Allocator template parameter of deduction guides that
1302         have a Container parameter.
1303         * include/bits/stl_stack.h (stack): Likewise.
1304         * include/debug/deque (__gnu_debug::deque): Use non-deduced
1305         context for allocator parameter of allocator-extended copy and
1306         move constructors.
1307         * include/debug/list (__gnu_debug::list): Likewise.
1308         * include/debug/map.h (__gnu_debug::map): Likewise.
1309         * include/debug/multimap.h (__gnu_debug::multimap): Likewise.
1310         * include/debug/multiset.h (__gnu_debug::multiset): Likewise.
1311         * include/debug/set.h (__gnu_debug::set): Likewise.
1312         * include/debug/vector (__gnu_debug::vector): Likewise.
1313         * testsuite/23_containers/deque/cons/deduction.cc: Test class
1314         template argument deduction with non-deduced allocator
1315         arguments.
1316         * testsuite/23_containers/forward_list/cons/deduction.cc:
1317         Likewise.
1318         * testsuite/23_containers/list/cons/deduction.cc: Likewise.
1319         * testsuite/23_containers/map/cons/deduction.cc: Likewise.
1320         * testsuite/23_containers/multimap/cons/deduction.cc: Likewise.
1321         * testsuite/23_containers/multiset/cons/deduction.cc: Likewise.
1322         * testsuite/23_containers/priority_queue/deduction.cc: Likewise.
1323         * testsuite/23_containers/queue/deduction.cc: Likewise.
1324         * testsuite/23_containers/set/cons/deduction.cc: Likewise.
1325         * testsuite/23_containers/stack/deduction.cc: Likewise.
1326         * testsuite/23_containers/unordered_map/cons/deduction.cc:
1327         Likewise.
1328         * testsuite/23_containers/unordered_multimap/cons/deduction.cc:
1329         Likewise.
1330         * testsuite/23_containers/unordered_multiset/cons/deduction.cc:
1331         Likewise.
1332         * testsuite/23_containers/unordered_set/cons/deduction.cc:
1333         Likewise.
1334         * testsuite/23_containers/vector/cons/deduction.cc: Likewise.
1336 2021-10-04  Jonathan Wakely  <jwakely@redhat.com>
1338         * include/std/variant (__detail::__variant::__as): Add missing
1339         noexcept to first overload.
1341 2021-10-04  Jonathan Wakely  <jwakely@redhat.com>
1343         * include/bits/basic_string.h (basic_string(nullptr_t)): Define
1344         as deleted.
1345         (operator=(nullptr_t)): Likewise.
1346         * include/bits/cow_string.h (basic_string(nullptr_t)): Likewise.
1347         (operator=(nullptr_t)): Likewise.
1348         * include/std/string_view (basic_string_view(nullptr_t)):
1349         Likewise.
1350         * testsuite/21_strings/basic_string/cons/char/nullptr.cc: New test.
1351         * testsuite/21_strings/basic_string_view/cons/char/nonnull.cc:
1352         Change dg-warning to dg-error.
1353         * testsuite/21_strings/basic_string_view/cons/wchar_t/nonnull.cc:
1354         Likewise.
1356 2021-10-02  Jonathan Wakely  <jwakely@redhat.com>
1358         * src/c++17/fs_ops.cc (create_directory): Fix typo in enum name.
1359         * src/filesystem/ops-common.h (__last_system_error): Add
1360         explicit cast to avoid narrowing conversion.
1361         (do_space): Fix type in function name.
1363 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1365         PR libstdc++/102100
1366         * include/Makefile.am (c++config.h): Define
1367         _GLIBCXX_VERBOSE_ASSERT based on configure output.
1368         * include/Makefile.in: Regenerate.
1369         * include/bits/c++config: Fix condition for verbose assertions.
1371 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1373         PR libstdc++/92546
1374         * include/bits/erase_if.h (__erase_nodes_if): Use __niter_base to
1375         unwrap debug iterators.
1376         * include/bits/refwrap.h: Do not error if included in C++03.
1377         * include/bits/stl_algo.h (__remove_if): Move to ...
1378         * include/bits/stl_algobase.h (__remove_if): ... here.
1379         * include/std/deque (erase, erase_if): Use __remove_if instead of
1380         remove and remove_if.
1381         * include/std/string (erase, erase_if): Likewise.
1382         * include/std/vector (erase, erase_if): Likewise.
1384 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1386         PR libstdc++/66742
1387         * include/bits/list.tcc (list::sort()): Use _Scratch_list
1388         objects for splicing and merging.
1389         (list::sort(StrictWeakOrdering)): Likewise.
1390         * include/bits/stl_list.h (__detail::_Scratch_list): New type.
1391         * src/c++98/list.cc (_List_node_base::_M_transfer): Add
1392         assertion for --enable-libstdcxx-debug library.
1393         * testsuite/23_containers/list/operations/66742.cc: New test.
1395 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1397         PR libstdc++/100612
1398         * include/std/thread (__pmf_expects_stop_token): New variable
1399         template to detect a pointer to member function that needs a
1400         stop_token to be added to the arguments.
1401         (jthread::__S_create): Use __pmf_expects_stop_token.
1402         (jthread::__S_create_pmf): New function.
1403         * testsuite/30_threads/jthread/100612.cc: New test.
1405 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1407         * include/bits/stl_queue.h
1408         (__cpp_lib_adaptor_iterator_pair_constructor): Define for C++23, as
1409         per P1425R4.
1410         (queue(InputIterator, InputIterator)): Likewise.
1411         (queue(InputIterator, InputIterator, const Alloc&)): Likewise.
1412         * include/bits/stl_stack.h
1413         (__cpp_lib_adaptor_iterator_pair_constructor): Likewise.
1414         (stack(InputIterator, InputIterator)): Likewise.
1415         (stack(InputIterator, InputIterator, const Alloc&)): Likewise.
1416         * include/std/version (__cpp_lib_adaptor_iterator_pair_constructor):
1417         Define.
1418         * testsuite/23_containers/queue/cons_from_iters.cc: New test.
1419         * testsuite/23_containers/stack/cons_from_iters.cc: New test.
1421 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1423         * include/bits/stl_queue.h (priority_queue): Add
1424         allocator-extended overloads for constructors taking iterator.
1425         * testsuite/23_containers/priority_queue/lwg3506.cc: New test.
1427 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1429         * include/bits/stl_queue.h (priority_queue): Construct sequence
1430         from iterators when no sequence argument is present (LWG 3529).
1431         * testsuite/23_containers/priority_queue/lwg3529.cc: New test.
1433 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1435         * include/bits/stl_queue.h (priority_queue): Constrain
1436         constructors with InputIterator parameters (LWG 3522).
1437         * testsuite/23_containers/priority_queue/lwg3522.cc: New test.
1439 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1441         * include/bits/ranges_base.h (ranges::distance): Split overload
1442         into two (LWG 3392).
1443         * testsuite/24_iterators/range_operations/lwg3392.cc: New test.
1445 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1447         * testsuite/30_threads/thread/cons/3.cc: Remove derivation from
1448         std::unary_function.
1449         * testsuite/30_threads/thread/cons/4.cc: Likewise.
1450         * testsuite/30_threads/thread/cons/5.cc: Likewise.
1452 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1454         * testsuite/ext/pb_ds/example/basic_multimap.cc: Remove
1455         unnecesary derivation from std::unary_function.
1456         * testsuite/ext/pb_ds/example/erase_if.cc: Likewise.
1457         * testsuite/ext/pb_ds/example/hash_illegal_resize.cc: Likewise.
1458         * testsuite/ext/pb_ds/example/hash_initial_size.cc: Likewise.
1459         * testsuite/ext/pb_ds/example/hash_load_set_change.cc: Likewise.
1460         * testsuite/ext/pb_ds/example/hash_mod.cc: Likewise.
1461         * testsuite/ext/pb_ds/example/hash_resize.cc: Likewise.
1462         * testsuite/ext/pb_ds/example/hash_shift_mask.cc: Likewise.
1463         * testsuite/ext/pb_ds/example/priority_queue_dijkstra.cc:
1464         Likewise.
1465         * testsuite/ext/pb_ds/example/ranged_hash.cc: Likewise.
1466         * testsuite/ext/pb_ds/example/store_hash.cc: Likewise.
1468 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1470         * src/c++11/functexcept.cc (__throw_out_of_range_fmt): Do not
1471         expand the format string for freestanding, or non-vebose, or if
1472         we're just going to abort anyway.
1473         * src/c++11/snprintf_lite.cc: Remove unused header and
1474         declaration.
1476 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1478         * include/std/variant (__do_visit): Use variant_npos instead of
1479         literal -1 that requires a narrowing conversion.
1481 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1483         PR libstdc++/99327
1484         * src/filesystem/ops-common.h (__unsupported): New function to
1485         return a suitable error code for missing functionality.
1486         (posix::off_t): New typedef.
1487         (posix::*): Set errno to ENOSYS instead of ENOTSUP for no-op
1488         fallback implementations.
1489         (do_copy_file): Replace uses of errc::not_supported.
1490         * src/c++17/fs_ops.cc (fs::copy, fs::copy_file, create_dir)
1491         (fs::create_directory, fs::create_directory_symlink)
1492         (fs::create_hard_link, fs::create_symlink, fs::current_path)
1493         (fs::equivalent, do_stat, fs::file_size, fs::hard_link_count)
1494         (fs::last_write_time, fs::permissions, fs::read_symlink):
1495         Replace uses of errc::not_supported.
1496         (fs::resize_file): Qualify off_t.
1497         * src/filesystem/ops.cc (fs::copy, fs::copy_file, create_dir)
1498         (fs::create_directory, fs::create_directory_symlink)
1499         (fs::create_hard_link, fs::create_symlink, fs::current_path)
1500         (fs::equivalent, do_stat, fs::file_size, fs::last_write_time)
1501         (fs::permissions, fs::read_symlink, fs::system_complete):
1502         Replace uses of errc::not_supported.
1503         (fs::resize_file): Qualify off_t and enable unconditionally.
1504         * testsuite/19_diagnostics/system_error/cons-1.cc: Likewise.
1506 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1508         * src/filesystem/ops-common.h (last_error): New helper function.
1509         (filesystem::do_space): Use last_error().
1510         * src/c++17/fs_ops.cc (fs::absolute, fs::create_hard_link)
1511         (fs::equivalent, fs::remove, fs::temp_directory_path): Use
1512         last_error().
1513         * src/filesystem/ops.cc (fs::create_hard_link)
1514         (fs::remove, fs::temp_directory_path): Likewise.
1516 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1518         * include/std/type_traits (__conditional): New class template
1519         for internal uses of std::conditional.
1520         (__conditional_t): New alias template to replace conditional_t.
1521         (__and_, __or_, __result_of_memfun, __result_of_memobj): Use
1522         __conditional_t instead of conditional::type.
1523         * include/bits/atomic_base.h (__atomic_impl::_Diff): Likewise.
1524         * include/bits/hashtable.h (_Hashtable): Likewise.
1525         * include/bits/hashtable_policy.h (_Node_iterator, _Insert_base)
1526         (_Local_iterator): Likewise. Replace typedefs with
1527         using-declarations.
1528         * include/bits/move.h (move_if_noexcept): Use __conditional_t.
1529         * include/bits/parse_numbers.h (_Select_int_base): Likewise.
1530         * include/bits/ptr_traits.h (__make_not_void): Likewise.
1531         * include/bits/ranges_algobase.h (__copy_or_move_backward)
1532         (__copy_or_move): Likewise.
1533         * include/bits/ranges_base.h (borrowed_iterator_t): Likewise.
1534         * include/bits/ranges_util.h (borrowed_subrange_t): Likewise.
1535         * include/bits/regex_compiler.h (_BracketMatcher): Use
1536         __conditional_t. Replace typedefs with using-declarations.
1537         * include/bits/shared_ptr_base.h (__shared_count): Use
1538         __conditional_t.
1539         * include/bits/stl_algobase.h (__copy_move, __copy_move_backward):
1540         Likewise.
1541         * include/bits/stl_iterator.h (__detail::__clamp_iter_cat)
1542         (reverse_iterator::iterator_concept)
1543         (__make_move_if_noexcept_iterator)
1544         (iterator_traits<common_iterator<_It, _Sent>>)
1545         (iterator_traits<counted_iterator<_It>>): Likewise.
1546         * include/bits/stl_pair.h (_PCC, pair::operator=): Likewise.
1547         * include/bits/stl_tree.h (_Rb_tree::insert_return_type)
1548         (_Rb_tree::_M_clone_node): Likewise.
1549         * include/bits/unique_ptr.h (unique_ptr(unique_ptr<U,E>&&)):
1550         Likewise.
1551         * include/bits/uses_allocator.h (__uses_alloc): Likewise.
1552         (__is_uses_allocator_predicate): Likewise.
1553         * include/debug/functions.h (__foreign_iterator_aux2): Likewise.
1554         * include/experimental/any (any::_Manager, __any_caster):
1555         Likewise.
1556         * include/experimental/executor (async_completion): Likewise.
1557         * include/experimental/functional (__boyer_moore_base_t):
1558         Likewise.
1559         * include/std/any (any::_Manager): Likewise.
1560         * include/std/functional (__boyer_moore_base_t): Likewise.
1561         * include/std/ranges (borrowed_iterator_t)
1562         (borrowed_subrange_t, __detail::__maybe_present_t)
1563         (__detail::__maybe_const_t, split_view): Likewise.
1564         * include/std/tuple (__empty_not_final, tuple::operator=):
1565         Likewise.
1566         * include/std/variant (__detail::__variant::__get_t): Likewise.
1568 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1570         PR libstdc++/78113
1571         * include/std/variant (__do_visit): Use a switch when we have a
1572         single variant with a small number of alternatives.
1574 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1576         PR libstdc++/90943
1577         * include/std/variant (__cpp_lib_variant): Update value.
1578         (__detail::__variant::__as): New helpers implementing the
1579         as-variant exposition-only function templates.
1580         (visit, visit<R>): Use __as to upcast the variant parameters.
1581         * include/std/version (__cpp_lib_variant): Update value.
1582         * testsuite/20_util/variant/visit_inherited.cc: New test.
1584 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1586         * include/bits/stl_iterator.h (__normal_iterator): Simplify
1587         converting constructor and do not require _Container::pointer.
1589 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1591         * include/bits/cow_string.h [_GLIBCXX_FULLY_DYNAMIC_STRING]
1592         (basic_string(basic_string&&)): Add noexcept and avoid
1593         allocation, by sharing rep with the rvalue string.
1595 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1597         * include/bits/stl_iterator.h (common_iterator::__arrow_proxy)
1598         (common_iterator::__postfix_proxy): Add noexcept.
1600 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1602         PR libstdc++/94418
1603         * include/bits/stl_iterator.h (reverse_iterator): Use
1604         conditional noexcept on constructors and assignment operators.
1605         * testsuite/24_iterators/reverse_iterator/noexcept.cc: New test.
1607 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1609         PR libstdc++/100153
1610         * include/bits/vector.tcc (vector<bool>::_M_shrink_to_fit()):
1611         When size() is zero just deallocate and reset.
1613 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1615         PR libstdc++/96733
1616         * include/bits/stl_algo.h (clamp): Use std::min and std::max.
1618 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1620         * include/bits/regex.h (basic_regex::multiline): Define for
1621         non-strict C++11 and C++14 modes.
1622         * include/bits/regex_constants.h (regex_constants::multiline):
1623         Add _GLIBCXX_RESOLVE_LIB_DEFECTS comment.
1625 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1627         * testsuite/25_algorithms/is_permutation/2.cc: Include <iterator>.
1629 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1631         * include/bits/stream_iterator.h (istream_iterator): Add
1632         noexcept to constructors and non-throwing member functions and
1633         friend functions.
1634         (ostream_iterator): Likewise.
1636 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1638         * include/bits/boost_concept_check.h (_Is_vector_bool_iterator):
1639         New trait to identify vector<bool> iterators, including debug
1640         ones.
1641         (_ForwardIteratorReferenceConcept): Add default template
1642         argument using _Is_vector_bool_iterator and use it in partial
1643         specialization for the vector<bool> cases.
1644         (_Mutable_ForwardIteratorReferenceConcept): Likewise.
1645         * testsuite/24_iterators/operations/prev_neg.cc: Adjust dg-error
1646         line number.
1648 2021-10-01  Jonathan Wakely  <jwakely@redhat.com>
1650         * include/bits/list.tcc (list::merge): Remove call to size() and
1651         try-catch block. Use _Finalize_merge instead.
1652         * include/bits/stl_list.h (list::_Finalize_merge): New
1653         scope guard type to update _M_size members after a merge.
1655 2021-09-30  Jonathan Wakely  <jwakely@redhat.com>
1657         * include/bits/regex.h (basic_regex::multiline): Fix #if
1658         condition.
1660 2021-09-29  Jonathan Wakely  <jwakely@redhat.com>
1662         * include/bits/regex.h (basic_regex::multiline): Define constant
1663         for C++17.
1664         * include/bits/regex_constants.h (regex_constants::multiline):
1665         Define constant for C++17.
1666         (regex_constants::__multiline): Define duplicate constant for
1667         internal use in C++11 and C++14.
1668         * include/bits/regex_executor.h (_Executor::_M_match_multiline()):
1669         New member function.
1670         (_Executor::_M_is_line_terminator(_CharT)): New member function.
1671         (_Executor::_M_at_begin(), _Executor::_M_at_end()): Use new
1672         member functions to support multiline matches.
1673         * testsuite/28_regex/algorithms/regex_match/multiline.cc: New test.
1675 2021-09-29  Jonathan Wakely  <jwakely@redhat.com>
1677         * include/bits/regex_compiler.h (_Compiler::_S_validate): New
1678         function.
1679         * include/bits/regex_compiler.tcc (_Compiler::_Compiler): Use
1680         _S_validate to check flags.
1681         * include/bits/regex_error.h (_S_grammar): New error code for
1682         internal use.
1683         * testsuite/28_regex/basic_regex/ctors/grammar.cc: New test.
1685 2021-09-29  Jonathan Wakely  <jwakely@redhat.com>
1687         PR libstdc++/84110
1688         * include/bits/regex_error.h (regex_constants::_S_null): New
1689         error code for internal use.
1690         * include/bits/regex_scanner.tcc (_Scanner::_M_scan_normal()):
1691         Check for null character.
1692         * testsuite/28_regex/basic_regex/84110.cc: New test.
1694 2021-09-29  Jonathan Wakely  <jwakely@redhat.com>
1696         * include/bits/regex.h (__detail::__is_contiguous_iter): Move
1697         here from <bits/regex_compiler.h>.
1698         (basic_regex::_M_compile): New function to compile an NFA from
1699         a regular expression string.
1700         (basic_regex::basic_regex): Use _M_compile instead of delegating
1701         to other constructors.
1702         (basic_regex::operator=(const basic_regex&)): Define as
1703         defaulted.
1704         (basic_regex::operator=(initializer_list<C>)): Use _M_compile.
1705         (basic_regex::assign(const basic_regex&)): Use copy assignment.
1706         (basic_regex::assign(basic_regex&&)): Use move assignment.
1707         (basic_regex::assign(const C*, flag_type)): Use _M_compile
1708         instead of constructing a temporary string.
1709         (basic_regex::assign(const C*, size_t, flag_type)): Likewise.
1710         (basic_regex::assign(const basic_string<C,T,A>&, flag_type)):
1711         Use _M_compile instead of constructing a temporary basic_regex.
1712         (basic_regex::assign(InputIter, InputIter, flag_type)): Avoid
1713         constructing a temporary string for contiguous iterators of the
1714         right value type.
1715         * include/bits/regex_compiler.h (__is_contiguous_iter): Move to
1716         <bits/regex.h>.
1717         (__enable_if_contiguous_iter, __disable_if_contiguous_iter)
1718         (__compile_nfa): Remove.
1719         * testsuite/28_regex/basic_regex/assign/exception_safety.cc: New
1720         test.
1721         * testsuite/28_regex/basic_regex/ctors/char/other.cc: New test.
1723 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1725         * include/bits/atomic_timed_wait.h (__platform_wait_until_impl):
1726         Return false for ETIMEDOUT and true otherwise.
1728 2021-09-28  François Dumont  <fdumont@gcc.gnu.org>
1730         * testsuite/20_util/default_delete/48631_neg.cc: Adapt dg-prune-output message
1731         to also match message with '__8' in it.
1733 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1735         * include/bits/regex_automaton.h (_NFA_base::_SizeT): Remove.
1736         * include/bits/regex_compiler.h (_Compiler::_IterT): Remove.
1737         * include/bits/regex_compiler.tcc: Likewise.
1738         * include/bits/regex_scanner.h (_Scanner::_IterT): Remove.
1739         * include/bits/regex_scanner.tcc: Likewise.
1741 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1743         * include/bits/regex_compiler.tcc: Add line break in empty while
1744         statement.
1745         * include/bits/regex_executor.tcc: Avoid unused parameter
1746         warning.
1748 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1750         * include/bits/regex.h (basic_regex, swap): Add noexcept to
1751         non-throwing functions.
1752         * include/bits/regex_automaton.h (_State_base, _State)
1753         (_NFA_base): Likewise.
1754         * include/bits/regex_compiler.h (_Compiler): Likewise.
1755         * include/bits/regex_error.h (regex_error::code()): Likewise.
1756         * include/bits/regex_scanner.h (_Scanner): Likewise.
1758 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1760         * include/bits/atomic_wait.h (_GLIBCXX_HAVE_PLATFORM_WAIT):
1761         Define before first attempt to check it.
1763 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1765         * testsuite/23_containers/priority_queue/requirements/explicit_instantiation/1.cc:
1766         Do not check non-default constructible sequences when
1767         _GLIBCXX_CONCEPT_CHECKS is defined.
1768         * testsuite/23_containers/priority_queue/requirements/explicit_instantiation/1_c++98.cc:
1769         Likewise.
1770         * testsuite/23_containers/queue/requirements/explicit_instantiation/1.cc:
1771         Likewise.
1772         * testsuite/23_containers/queue/requirements/explicit_instantiation/1_c++98.cc:
1773         Likewise.
1774         * testsuite/23_containers/stack/requirements/explicit_instantiation/1.cc:
1775         Likewise.
1776         * testsuite/23_containers/stack/requirements/explicit_instantiation/1_c++98.cc:
1777         Likewise.
1779 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1781         * testsuite/23_containers/deque/requirements/explicit_instantiation/3.cc:
1782         Do not test implicit allocator rebinding when _GLIBCXX_CONCEPT_CHECKS
1783         is defined.
1784         * testsuite/23_containers/forward_list/requirements/explicit_instantiation/3.cc:
1785         Likewise.
1786         * testsuite/23_containers/list/requirements/explicit_instantiation/3.cc:
1787         Likewise.
1788         * testsuite/23_containers/list/requirements/explicit_instantiation/5.cc:
1789         Likewise.
1790         * testsuite/23_containers/map/requirements/explicit_instantiation/3.cc:
1791         Likewise.
1792         * testsuite/23_containers/map/requirements/explicit_instantiation/5.cc:
1793         Likewise.
1794         * testsuite/23_containers/multimap/requirements/explicit_instantiation/3.cc:
1795         Likewise.
1796         * testsuite/23_containers/multimap/requirements/explicit_instantiation/5.cc:
1797         Likewise.
1798         * testsuite/23_containers/multiset/requirements/explicit_instantiation/3.cc:
1799         Likewise.
1800         * testsuite/23_containers/multiset/requirements/explicit_instantiation/5.cc:
1801         Likewise.
1802         * testsuite/23_containers/set/requirements/explicit_instantiation/3.cc:
1803         Likewise.
1804         * testsuite/23_containers/set/requirements/explicit_instantiation/5.cc:
1805         Likewise.
1806         * testsuite/23_containers/unordered_map/requirements/explicit_instantiation/3.cc:
1807         Likewise.
1808         * testsuite/23_containers/unordered_multimap/requirements/explicit_instantiation/3.cc:
1809         Likewise.
1810         * testsuite/23_containers/unordered_multiset/requirements/explicit_instantiation/3.cc:
1811         Likewise.
1812         * testsuite/23_containers/unordered_set/requirements/explicit_instantiation/3.cc:
1813         Likewise.
1814         * testsuite/23_containers/vector/ext_pointer/explicit_instantiation/3.cc:
1815         Likewise.
1816         * testsuite/23_containers/vector/requirements/explicit_instantiation/3.cc:
1817         Likewise.
1819 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1821         * include/bits/boost_concept_check.h (_ForwardIteratorConcept)
1822         (_BidirectionalIteratorConcept, _RandomAccessIteratorConcept):
1823         Check result types of iterator operations.
1824         (_Mutable_ForwardIteratorConcept): Check that iterator's
1825         reference type is a reference to its value type.
1826         (_Mutable_BidirectionalIteratorConcept): Do not require the
1827         value type to be assignable.
1828         (_Mutable_RandomAccessIteratorConcept): Likewise.
1829         * testsuite/24_iterators/operations/prev_neg.cc: Adjust dg-error
1830         line number.
1832 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1834         * testsuite/25_algorithms/copy/34595.cc: Add missing operation
1835         for type used as an iterator.
1836         * testsuite/25_algorithms/unique_copy/check_type.cc: Likewise.
1838 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1840         * testsuite/20_util/is_nothrow_swappable/value.h: Use custom
1841         comparison function for priority_queue of type with no
1842         relational operators.
1843         * testsuite/20_util/is_swappable/value.h: Likewise.
1844         * testsuite/24_iterators/output/concept.cc: Add operator< to
1845         type used in set.
1847 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1849         * include/bits/boost_concept_check.h (_OutputIteratorConcept):
1850         Use a function to preserve value category of the type.
1851         * include/bits/stl_algobase.h (copy, move, fill_n): Use a
1852         reference as the second argument for _OutputIteratorConcept.
1853         (copy_backward, move_backward): Use _OutputIteratorConcept
1854         instead of _ConvertibleConcept.
1856 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1858         * include/bits/stl_iterator.h (pointer_traits): Define partial
1859         specialization for __normal_iterator.
1860         * testsuite/24_iterators/normal_iterator/to_address.cc: New test.
1862 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1864         * include/bits/move.h (forward(remove_reference_t<T>&&)):
1865         Improve text of static_assert.
1866         * testsuite/20_util/forward/c_neg.cc: Adjust dg-error.
1867         * testsuite/20_util/forward/f_neg.cc: Likewise.
1869 2021-09-28  Jonathan Wakely  <jwakely@redhat.com>
1871         PR libstdc++/102499
1872         * include/bits/fs_path.h (path::begin, path::end): Add noexcept
1873         to declarations, to match definitions.
1875 2021-09-24  Jonathan Wakely  <jwakely@redhat.com>
1877         * include/bits/range_access.h (cbegin, cend): Remove redundant
1878         'inline' specifier.
1880 2021-09-23  Jonathan Wakely  <jwakely@redhat.com>
1882         * testsuite/20_util/specialized_algorithms/memory_management_tools/destroy_neg.cc:
1883         Remove dg-error lines for C++20-only errors.
1885 2021-09-23  Jonathan Wakely  <jwakely@redhat.com>
1887         * testsuite/19_diagnostics/headers/system_error/93151.cc:
1888         Disable PCH.
1890 2021-09-23  Jonathan Wakely  <jwakely@redhat.com>
1892         * src/c++11/system_error.cc (system_error_category) [_WIN32]:
1893         Map Windows error codes to generic POSIX error numbers. Use
1894         FormatMessage instead of strerror.
1895         * testsuite/19_diagnostics/error_category/system_category.cc:
1896         Adjust for new behaviour on Windows.
1898 2021-09-23  Jonathan Wakely  <jwakely@redhat.com>
1900         * src/c++11/system_error.cc (generic_error_category): Define
1901         class and virtual functions as 'final'.
1902         (generic_error_category::equivalent(int, const error_condition&)):
1903         Override.
1904         (system_error_category): Define class and virtual functions as
1905         'final'.
1906         (system_error_category::equivalent(int, const error_condition&)):
1907         Override.
1908         (generic_category_instance, system_category_instance): Use
1909         constinit union to make the objects immortal.
1911 2021-09-23  Jonathan Wakely  <jwakely@redhat.com>
1913         PR libstdc++/102425
1914         * src/c++11/system_error.cc
1915         (system_error_category::default_error_condition): Add 0 to
1916         switch.
1917         * testsuite/19_diagnostics/error_category/102425.cc: New test.
1919 2021-09-17  Jonathan Wakely  <jwakely@redhat.com>
1921         * include/bits/fs_path.h (path::iterator): Add noexcept to all
1922         member functions and friend functions.
1923         (distance): Add noexcept.
1924         (advance): Add noexcept and inline.
1925         * include/experimental/bits/fs_path.h (path::iterator):
1926         Add noexcept to all member functions.
1928 2021-09-17  Jonathan Wakely  <jwakely@redhat.com>
1930         PR libstdc++/102270
1931         * include/std/tuple (_Tuple_impl): Add constexpr to constructor
1932         missed in previous patch.
1933         * testsuite/20_util/tuple/cons/102270.C: Moved to...
1934         * testsuite/20_util/tuple/cons/102270.cc: ...here.
1935         * testsuite/util/testsuite_allocator.h (SimpleAllocator): Add
1936         constexpr to constructor so it can be used for C++20 tests.
1938 2021-09-17  Jonathan Wakely  <jwakely@redhat.com>
1940         * testsuite/26_numerics/valarray/dr630-3.C: Moved to...
1941         * testsuite/26_numerics/valarray/dr630-3.cc: ...here.
1942         * testsuite/27_io/basic_iostream/cons/16251.C: Moved to...
1943         * testsuite/27_io/basic_iostream/cons/16251.cc: ...here.
1945 2021-09-16  Jonathan Wakely  <jwakely@redhat.com>
1947         * src/Makefile.am (stamp-debug): Add all Makefiles as
1948         prerequisites.
1949         * src/Makefile.in: Regenerate.
1951 2021-09-16  Jonathan Wakely  <jwakely@redhat.com>
1953         * testsuite/ext/pb_ds/regression/tree_map_rand.cc: Increase
1954         timeout factor to 3.
1955         * testsuite/ext/pb_ds/regression/tree_set_rand.cc: Likewise.
1957 2021-09-16  Jonathan Wakely  <jwakely@redhat.com>
1959         * doc/xml/manual/using.xml: Generalize to apply to more than
1960         just -std=c++11.
1961         * doc/html/manual/using_macros.html: Regenerate.
1963 2021-09-16  Jonathan Wakely  <jwakely@redhat.com>
1965         * include/std/optional (nullptr_t): Make constructor noexcept.
1967 2021-09-16  Jonathan Wakely  <jwakely@redhat.com>
1969         * include/bits/fs_path.h (advance): Remove non-deducible
1970         template parameter.
1972 2021-09-16  Jonathan Wakely  <jwakely@redhat.com>
1974         PR libstdc++/102270
1975         * include/std/tuple (_Head_base, _Tuple_impl): Add
1976         _GLIBCXX20_CONSTEXPR to allocator-extended constructors.
1977         (tuple<>::swap(tuple&)): Add _GLIBCXX20_CONSTEXPR.
1978         * testsuite/20_util/tuple/cons/102270.C: New test.
1980 2021-09-16  Jonathan Wakely  <jwakely@redhat.com>
1982         PR libstdc++/102280
1983         * include/std/span (span(Range&&)): Add constraint to deduction
1984         guide.
1986 2021-09-16  Jonathan Wakely  <jwakely@redhat.com>
1988         * src/c++98/Makefile.am: Use CXXCOMPILE not LTCXXCOMPILE.
1989         * src/c++98/Makefile.in: Regenerate.
1991 2021-09-16  Jonathan Wakely  <jwakely@redhat.com>
1993         * include/bits/basic_string.h [_GLIBCXX_USE_CXX11_ABI]
1994         (to_string): Add noexcept if the type width is 32 bits or less.
1996 2021-09-16  Jonathan Wakely  <jwakely@redhat.com>
1998         * include/bits/unique_ptr.h (__uniq_ptr_impl::_M_ptr)
1999         (__uniq_ptr_impl::_M_deleter): Add noexcept.
2001 2021-09-16  Thomas Rodgers  <rodgert@twrodgers.com>
2003         PR libstdc++/101761
2004         * testsuite/29_atomics/atomic_ref/wait_notify.cc (test): Use
2005         va and vb as arguments to wait/notify, remove unused bb local.
2007 2021-09-15  Hugo Beauzée-Luyssen  <hugo@beauzee.fr>
2009         * crossconfig.m4: Check for TLS support on mingw.
2010         * configure: Regenerate.
2012 2021-09-13  Jason Merrill  <jason@redhat.com>
2014         * include/std/version: Define __cpp_lib_hardware_interference_size.
2015         * libsupc++/new: Define hardware interference size variables.
2017 2021-09-10  Jonathan Wakely  <jwakely@redhat.com>
2019         * testsuite/experimental/net/internet/resolver/ops/lookup.cc:
2020         Fix invalid hostname to only match the .invalid TLD.
2022 2021-09-02  Jonathan Wakely  <jwakely@redhat.com>
2024         * include/bits/atomic_base.h (__atomic_base<P*>::compare_exchange_weak):
2025         Add new functions.
2026         * include/std/atomic (atomic<T*>::compare_exchange_weak): Use
2027         it.
2029 2021-09-02  Jonathan Wakely  <jwakely@redhat.com>
2031         * include/std/atomic: Tweak whitespace.
2033 2021-09-02  Jonathan Wakely  <jwakely@redhat.com>
2035         PR c++/102177
2036         * include/bits/atomic_base.h (__is_valid_cmpexch_failure_order):
2037         New function to check if a memory order is valid for the failure
2038         case of compare exchange operations.
2039         (__atomic_base<I>::compare_exchange_weak): Simplify assertions
2040         by using __is_valid_cmpexch_failure_order.
2041         (__atomic_base<I>::compare_exchange_strong): Likewise.
2042         (__atomic_base<P*>::compare_exchange_weak): Likewise.
2043         (__atomic_base<P*>::compare_exchange_strong): Likewise.
2044         (__atomic_impl::compare_exchange_weak): Add assertion.
2045         (__atomic_impl::compare_exchange_strong): Likewise.
2046         * include/std/atomic (atomic::compare_exchange_weak): Likewise.
2047         (atomic::compare_exchange_strong): Likewise.
2049 2021-09-02  Jonathan Wakely  <jwakely@redhat.com>
2051         * include/std/functional (invoke_r): Define.
2052         * include/std/version (__cpp_lib_invoke_r): Define.
2053         * testsuite/20_util/function_objects/invoke/version.cc: Check
2054         for __cpp_lib_invoke_r as well as __cpp_lib_invoke.
2055         * testsuite/20_util/function_objects/invoke/4.cc: New test.
2057 2021-08-31  Jonathan Wakely  <jwakely@redhat.com>
2059         PR libstdc++/98421
2060         * include/std/span (span(Iter, size_type), span(Iter, Iter)):
2061         Add valid range checks.
2062         * testsuite/23_containers/span/cons_1_assert_neg.cc: New test.
2063         * testsuite/23_containers/span/cons_2_assert_neg.cc: New test.
2065 2021-08-31  Jonathan Wakely  <jwakely@redhat.com>
2067         * configure.ac: Fix checks for F_GETFL, F_SETFL and O_NONBLOCK.
2068         * configure: Regenerate.
2070 2021-08-31  Jonathan Wakely  <jwakely@redhat.com>
2072         * src/c++11/system_error.cc (error_category::~error_category()):
2073         Remove noexcept-specifier.
2074         (system_error::~system_error()): Likewise.
2075         * testsuite/19_diagnostics/error_category/noexcept.cc: New test.
2076         * testsuite/19_diagnostics/system_error/noexcept.cc: New test.
2078 2021-08-31  Jonathan Wakely  <jwakely@redhat.com>
2080         PR libstdc++/102074
2081         * include/bits/atomic_timed_wait.h (__timed_waiter_pool)
2082         [!_GLIBCXX_HAVE_PLATFORM_TIMED_WAIT]: Add missing return.
2084 2021-08-31  Jonathan Wakely  <jwakely@redhat.com>
2086         * include/experimental/internet (__make_resolver_error_code):
2087         Handle EAI_SYSTEM errors.
2088         (basic_resolver_results): Use __make_resolver_error_code. Use
2089         Glibc NI_MAXHOST and NI_MAXSERV values for buffer sizes.
2091 2021-08-31  Jonathan Wakely  <jwakely@redhat.com>
2093         * testsuite/experimental/net/internet/resolver/ops/lookup.cc:
2094         Try other service if "http" fails.
2096 2021-08-31  Jonathan Wakely  <jwakely@redhat.com>
2098         * testsuite/17_intro/names.cc: Undefine some more names used
2099         by Solaris system headers.
2101 2021-08-30  Jason Merrill  <jason@redhat.com>
2103         PR c++/96286
2104         * testsuite/30_threads/promise/requirements/lwg3466.cc:
2105         Remove dg-prune-outputs.
2107 2021-08-28  Jonathan Wakely  <jwakely@redhat.com>
2109         * include/bits/alloc_traits.h (allocator_traits): Add explicit
2110         specialization for allocator<void>. Improve doxygen comments.
2111         * include/bits/allocator.h (allocator<void>): Restore for the
2112         versioned namespace.
2113         (allocator<void>::construct, allocator<void>::destroy): Remove.
2114         * include/ext/extptr_allocator.h (_Extptr_allocator<void>):
2115         Add default constructor and converting constructor.
2117 2021-08-28  Jonathan Wakely  <jwakely@redhat.com>
2119         * include/bits/stl_uninitialized.h: Fix typo in comment.
2121 2021-08-28  Jonathan Wakely  <jwakely@redhat.com>
2123         PR libstdc++/99876
2124         * src/c++17/fs_ops.cc (fs::absolute): Call non-throwing form,
2125         to avoid unnecessary current_path() call.
2127 2021-08-28  Jonathan Wakely  <jwakely@redhat.com>
2129         * include/bits/std_function.h (function::function(F&&)): Give
2130         name to defaulted template parameter, to improve diagnostics.
2131         Use markdown for more doxygen comments.
2133 2021-08-26  Jonathan Wakely  <jwakely@redhat.com>
2135         * include/bits/std_function.h (function): Adjust doxygen
2136         comments.
2137         * include/bits/unique_ptr.h (make_unique_for_overwrite):
2138         Change parameter name to match doxygen comment.
2140 2021-08-26  Jonathan Wakely  <jwakely@redhat.com>
2142         * include/bits/std_function.h (_function_base::_Base_manager):
2143         Replace _M_init_functor with a function template using a
2144         forwarding reference, and a pair of _M_create function
2145         templates. Reuse _M_create for the clone operation.
2146         (function::_Decay_t): New alias template.
2147         (function::_Callable): Simplify by using _Decay.
2148         (function::function(F)): Change parameter to forwarding
2149         reference, as per LWG 2447. Add noexcept-specifier. Simplify
2150         constraints.
2151         (function::operator=(F&&)): Add noexcept-specifier.
2152         * testsuite/20_util/function/cons/lwg2774.cc: New test.
2153         * testsuite/20_util/function/cons/noexcept.cc: New test.
2155 2021-08-26  Jonathan Wakely  <jwakely@redhat.com>
2157         * include/bits/std_function.h (function::function(F)): Add
2158         static assertions to check constructibility requirements.
2160 2021-08-26  Jonathan Wakely  <jwakely@redhat.com>
2162         PR libstdc++/100285
2163         * configure.ac: Check for O_NONBLOCK.
2164         * configure: Regenerate.
2165         * include/experimental/internet: Include <ws2tcpip.h> for
2166         Windows.  Use preprocessor conditions around more constants.
2167         * include/experimental/socket: Use preprocessor conditions
2168         around more constants.
2169         * testsuite/experimental/net/internet/resolver/base.cc: Only use
2170         constants when the corresponding C macro is defined.
2171         * testsuite/experimental/net/socket/basic_socket.cc: Likewise.
2172         * testsuite/experimental/net/socket/socket_base.cc: Likewise.
2173         Make preprocessor checks more fine-grained.
2175 2021-08-25  Jonathan Wakely  <jwakely@redhat.com>
2177         * testsuite/17_intro/names.cc: Check 'sz'.
2179 2021-08-25  Jonathan Wakely  <jwakely@redhat.com>
2181         * testsuite/17_intro/names.cc: Adjust for Windows.
2183 2021-08-25  Jonathan Wakely  <jwakely@redhat.com>
2185         * include/std/valarray: Uglify 'func' parameters.
2186         * testsuite/17_intro/names.cc: Add 'func' to checks.
2188 2021-08-25  Jonathan Wakely  <jwakely@redhat.com>
2190         PR libstdc++/102064
2191         * include/bits/stl_uninitialized.h (_GLIBCXX_USE_ASSIGN_FOR_INIT):
2192         Define macro to check conditions for optimizing trivial cases.
2193         (__check_constructible): New function to do static assert.
2194         (uninitialized_copy, uninitialized_fill, uninitialized_fill_n):
2195         Use new macro.
2196         * testsuite/20_util/specialized_algorithms/uninitialized_copy/1.cc:
2197         Adjust dg-error pattern.
2198         * testsuite/23_containers/vector/cons/89164.cc: Likewise. Add
2199         C++17-specific checks from 89164_c++17.cc.
2200         * testsuite/23_containers/vector/cons/89164_c++17.cc: Removed.
2201         * testsuite/20_util/specialized_algorithms/uninitialized_copy/102064.cc:
2202         New test.
2203         * testsuite/20_util/specialized_algorithms/uninitialized_copy_n/102064.cc:
2204         New test.
2205         * testsuite/20_util/specialized_algorithms/uninitialized_fill/102064.cc:
2206         New test.
2207         * testsuite/20_util/specialized_algorithms/uninitialized_fill_n/102064.cc:
2208         New test.
2210 2021-08-25  Jonathan Wakely  <jwakely@redhat.com>
2212         PR libstdc++/102048
2213         * include/ext/rope (rope::erase(size_type)): Remove broken
2214         function.
2216 2021-08-24  Jonathan Wakely  <jwakely@redhat.com>
2218         * doc/xml/manual/status_cxx2020.xml: Update table.
2219         * doc/html/manual/status.html: Regenerate.
2221 2021-08-24  Jonathan Wakely  <jwakely@redhat.com>
2223         * include/std/type_traits (is_layout_compatible): Define.
2224         (is_corresponding_member): Define.
2225         * include/std/version (__cpp_lib_is_layout_compatible): Define.
2226         * testsuite/20_util/is_layout_compatible/is_corresponding_member.cc:
2227         New test.
2228         * testsuite/20_util/is_layout_compatible/value.cc: New test.
2229         * testsuite/20_util/is_layout_compatible/version.cc: New test.
2230         * testsuite/20_util/is_pointer_interconvertible/with_class.cc:
2231         New test.
2232         * testsuite/23_containers/span/layout_compat.cc: Do not use real
2233         std::is_layout_compatible trait if available.
2235 2021-08-24  Jonathan Wakely  <jwakely@redhat.com>
2237         * src/c++11/cxx11-shim_facets.cc: Fix mismatched class-key in
2238         explicit instantiation definitions.
2240 2021-08-23  Jonathan Wakely  <jwakely@redhat.com>
2242         * include/std/ranges (basic_istream_view): Add default template
2243         argument.
2244         * testsuite/std/ranges/istream_view.cc: Check it.
2246 2021-08-23  Jonathan Wakely  <jwakely@redhat.com>
2248         * libsupc++/dyncast.cc (__dynamic_cast): Add __builtin_expect to
2249         precondition check.
2251 2021-08-23  Jonathan Wakely  <jwakely@redhat.com>
2253         PR libstdc++/90787
2254         * testsuite/util/testsuite_fs.h (permissions_are_testable):
2255         Define as inline.
2257 2021-08-20  Jonathan Wakely  <jwakely@redhat.com>
2259         PR libstdc++/90787
2260         * testsuite/27_io/filesystem/iterators/directory_iterator.cc:
2261         Use new __gnu_test::permissions_are_testable() function.
2262         * testsuite/27_io/filesystem/iterators/recursive_directory_iterator.cc:
2263         Likewise.
2264         * testsuite/27_io/filesystem/operations/exists.cc: Likewise.
2265         * testsuite/27_io/filesystem/operations/is_empty.cc: Likewise.
2266         * testsuite/27_io/filesystem/operations/remove.cc: Likewise.
2267         * testsuite/27_io/filesystem/operations/remove_all.cc: Likewise.
2268         * testsuite/27_io/filesystem/operations/status.cc: Likewise.
2269         * testsuite/27_io/filesystem/operations/symlink_status.cc:
2270         Likewise.
2271         * testsuite/27_io/filesystem/operations/temp_directory_path.cc:
2272         Likewise.
2273         * testsuite/experimental/filesystem/iterators/directory_iterator.cc:
2274         Likewise.
2275         * testsuite/experimental/filesystem/iterators/recursive_directory_iterator.cc:
2276         Likewise.
2277         * testsuite/experimental/filesystem/operations/exists.cc:
2278         Likewise.
2279         * testsuite/experimental/filesystem/operations/is_empty.cc:
2280         Likewise.
2281         * testsuite/experimental/filesystem/operations/remove.cc:
2282         Likewise.
2283         * testsuite/experimental/filesystem/operations/remove_all.cc:
2284         Likewise.
2285         * testsuite/experimental/filesystem/operations/temp_directory_path.cc:
2286         Likewise.
2287         * testsuite/util/testsuite_fs.h (__gnu_test::permissions_are_testable):
2288         New function to guess whether testing permissions will work.
2290 2021-08-19  Jonathan Wakely  <jwakely@redhat.com>
2292         * doc/xml/manual/status_cxx2020.xml: Move row  earlier in table.
2293         * doc/html/manual/status.html: Regenerate.
2295 2021-08-19  Jonathan Wakely  <jwakely@redhat.com>
2297         * doc/doxygen/user.cfg.in: Update to Doxygen 1.9.2
2299 2021-08-19  Jonathan Wakely  <jwakely@redhat.com>
2301         PR libstdc++/101965
2302         * include/std/charconv (__to_chars_i): Remove redundant check.
2304 2021-08-19  Jonathan Wakely  <jwakely@redhat.com>
2306         PR libstdc++/101960
2307         * include/std/tuple (_Tuple_impl(_Tuple_impl&&)): Use base
2308         class' move constructor. Define as defaulted for versioned
2309         namespace.
2310         * testsuite/20_util/tuple/cons/101960.cc: New test.
2312 2021-08-19  Jonathan Wakely  <jwakely@redhat.com>
2314         PR libstdc++/100139
2315         * doc/xml/manual/status_cxx2020.xml: Add P1739R4 to status table.
2316         * doc/html/manual/status.html: Regenerate.
2318 2021-08-19  Jonathan Wakely  <jwakely@redhat.com>
2320         * include/bits/shared_ptr.h: Add @since and @headerfile tags.
2321         * include/bits/unique_ptr.h: Add @headerfile tags.
2323 2021-08-19  Jonathan Wakely  <jwakely@redhat.com>
2325         * src/filesystem/ops-common.h (filesystem::file_time): Improve
2326         overflow check by using system_clock::duration::max().
2328 2021-08-19  Jonathan Wakely  <jwakely@redhat.com>
2330         * include/bits/stl_tree.h: Tweak whitespace.
2332 2021-08-18  Jonathan Wakely  <jwakely@redhat.com>
2334         * include/bits/unique_ptr.h (default_delete): Add @since tag.
2335         (unique_ptr, unique_ptr<T[]>): Likewise. Improve @brief.
2336         (make_unique, make_unique_for_overwrite): Likewise. Add @tparam,
2337         @param, and @returns.
2338         (_MakeUniq): Move to __detail namespace. Add alias template
2339         helpers.
2341 2021-08-18  Jonathan Wakely  <jwakely@redhat.com>
2343         * include/bits/stl_function.h: Improve doxygen comments.
2345 2021-08-18  Jonathan Wakely  <jwakely@redhat.com>
2347         * doc/doxygen/user.cfg.in (PREDEFINED): Enable doxygen
2348         processing for C++20 components and components that depend on
2349         compiler features.
2350         * include/bits/stl_algo.h (random_shuffle): Use @deprecated.
2351         * include/std/type_traits: Improve doxygen comments for C++20
2352         traits.
2354 2021-08-18  Jonathan Wakely  <jwakely@redhat.com>
2356         * include/ext/type_traits.h (__promote_2, __promote_3)
2357         (__promote_4): Redfine as alias templates using __promoted_t.
2358         * include/std/complex (__promote_2): Remove partial
2359         specializations for std::complex.
2361 2021-08-18  Jonathan Wakely  <jwakely@redhat.com>
2363         * include/bits/stl_algo.h (min(initializer_list<T>))
2364         (min(initializer_list<T>, Compare)): Call __min_element directly to
2365         avoid redundant debug checks for valid ranges.
2366         (max(initializer_list<T>), max(initializer_list<T>, Compare)):
2367         Likewise, for __max_element.
2368         (minmax(initializer_list<T>), minmax(initializer_list<T>, Compare)):
2369         Likewise, for __minmax_element.
2371 2021-08-18  Jonathan Wakely  <jwakely@redhat.com>
2373         * include/debug/deque (deque(size_type, const T&, const A&)):
2374         Prevent class template argument deduction and replace with a
2375         deduction guide.
2376         * include/debug/forward_list (forward_list(size_type, const T&, const A&)):
2377         Likewise.
2378         * include/debug/list (list(size_type, const T&, const A&)):
2379         Likewise.
2380         * include/debug/vector (vector(size_type, const T&, const A&)):
2381         Likewise.
2383 2021-08-18  Jonathan Wakely  <jwakely@redhat.com>
2385         * python/libstdcxx/v6/printers.py (StdBitReferencePrinter): Use
2386         'std::vector<bool>::reference' as type name, not _Bit_reference.
2387         (build_libstdcxx_dictionary): Register printers for vector<bool>
2388         types in debug mode too.
2389         * testsuite/libstdc++-prettyprinters/simple.cc: Adjust expected
2390         output for invalid _Bit_reference. Use vector<bool>::reference
2391         instead of _Bit_reference.
2392         * testsuite/libstdc++-prettyprinters/simple11.cc: Likewise.
2394 2021-08-17  Thomas Schwinge  <thomas@codesourcery.com>
2396         * testsuite/lib/libstdc++.exp: Avoid illegal argument to verbose,
2397         continued.
2399 2021-08-17  Luc Michel  <lmichel@kalray.eu>
2400             Marc Poulhies  <mpoulhies@kalrayinc.com>
2402         * testsuite/lib/gdb-test.exp (gdb_version_check)
2403         (gdb_version_check_xmethods): Only check the GDB version for
2404         local native targets.
2406 2021-08-17  Antony Polukhin  <antoshkka@gmail.com>
2407             Jonathan Wakely  <jwakely@redhat.com>
2409         * include/bits/random.tcc (seed_seq::seed_seq): Reserve capacity
2410         if distance is O(1).
2411         * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error
2412         line number.
2414 2021-08-17  Jonathan Wakely  <jwakely@redhat.com>
2416         * testsuite/26_numerics/random/seed_seq/cons/range.cc: Check
2417         construction from input iterators.
2419 2021-08-17  Jonathan Wakely  <jwakely@redhat.com>
2421         * python/libstdcxx/v6/printers.py (StdErrorCatPrinter): Remove.
2423 2021-08-17  Jonathan Wakely  <jwakely@redhat.com>
2425         PR libstdc++/101923
2426         * include/bits/std_function.h (function(function&&)): Check for
2427         non-empty parameter before doing any work.
2429 2021-08-17  Jonathan Wakely  <jwakely@redhat.com>
2431         * include/bits/cow_string.h (basic_string::contains): Do not
2432         define for -std=gnu++20.
2434 2021-08-17  Jonathan Wakely  <jwakely@redhat.com>
2436         * include/bits/ranges_util.h (__not_same_as): Rename to
2437         __different_from.
2438         * include/std/ranges (__not_same_as): Likewise.
2440 2021-08-17  Jonathan Wakely  <jwakely@redhat.com>
2442         * include/std/utility (exchange): Add noexcept-specifier.
2443         * testsuite/20_util/exchange/noexcept.cc: New test.
2445 2021-08-17  Jonathan Wakely  <jwakely@redhat.com>
2447         * python/libstdcxx/v6/printers.py (StdErrorCodePrinter): Define.
2448         (build_libstdcxx_dictionary): Register printer for
2449         std::error_code and std::error_condition.
2450         * testsuite/libstdc++-prettyprinters/cxx11.cc: Test it.
2452 2021-08-16  Jonathan Wakely  <jwakely@redhat.com>
2454         PR libstdc++/101937
2455         * src/c++11/debug.cc (PrintContext::_M_indent): Replace with a
2456         static data member.
2457         (print_word): Use qualified-id to access it.
2459 2021-08-16  Jonathan Wakely  <jwakely@redhat.com>
2461         * python/Makefile.am [GLIBCXX_BUILD_DEBUG] (install-data-local):
2462         Install another copy of the GDB hook.
2463         * python/Makefile.in: Regenerate.
2465 2021-08-12  Jonathan Wakely  <jwakely@redhat.com>
2467         PR libstdc++/101870
2468         * include/c_global/cmath (hypot): Use __promoted_t.
2469         (lerp): Add new overload accepting any arithmetic types.
2470         * include/ext/type_traits.h (__promoted_t): New alias template.
2471         * testsuite/26_numerics/lerp.cc: Moved to...
2472         * testsuite/26_numerics/lerp/1.cc: ...here.
2473         * testsuite/26_numerics/lerp/constexpr.cc: New test.
2474         * testsuite/26_numerics/lerp/version.cc: New test.
2476 2021-08-12  Jonathan Wakely  <jwakely@redhat.com>
2478         * testsuite/26_numerics/lerp.cc: Add header name to #error.
2479         * testsuite/26_numerics/midpoint/integral.cc: Likewise.
2480         * testsuite/26_numerics/midpoint/version.cc: New test.
2482 2021-08-12  Jonathan Wakely  <jwakely@redhat.com>
2484         * include/experimental/random (experimental::randint): Add
2485         nodiscard attribute.
2487 2021-08-12  Jonathan Wakely  <jwakely@redhat.com>
2489         * src/c++98/locale_init.cc: Require C++11.
2490         * src/c++98/localename.cc: Likewise.
2491         * src/c++98/misc-inst.cc: Require C++98.
2493 2021-08-11  Jonathan Wakely  <jwakely@redhat.com>
2495         PR libstdc++/101866
2496         * testsuite/experimental/random/randint.cc: Loop and retry if
2497         reseed() produces the same sequence.
2499 2021-08-11  Jonathan Wakely  <jwakely@redhat.com>
2501         * include/std/type_traits (__cpp_lib_is_pointer_interconvertible)
2502         (is_pointer_interconvertible_base_of_v)
2503         (is_pointer_interconvertible_base_of): Define for C++20.
2504         * include/std/version (__cpp_lib_is_pointer_interconvertible):
2505         Define.
2506         * testsuite/23_containers/span/layout_compat.cc: Use correct
2507         feature test macro for std::is_layout_compatible_v.
2508         * testsuite/20_util/is_pointer_interconvertible/value.cc: New test.
2509         * testsuite/20_util/is_pointer_interconvertible/version.cc: New test.
2511 2021-08-09  Jonathan Wakely  <jwakely@redhat.com>
2513         * include/bits/regex.h (basic_regex::transform_primary): Use
2514         _GLIBCXX_STD_C::vector for local variable.
2515         * include/bits/regex.tcc (__regex_algo_impl): Use reference to
2516         _GLIBCXX_STD_C::vector base class of match_results.
2517         * include/bits/regex_automaton.tcc (_StateSeq:_M_clone): Use
2518         _GLIBCXX_STD_C::map and _GLIBCXX_STD_C::deque for local
2519         variables.
2520         * include/bits/regex_compiler.h (_BracketMatcher): Use
2521         _GLIBCXX_STD_C::vector for data members.
2522         * include/bits/regex_executor.h (_Executor): Likewise.
2523         * include/std/regex [_GLIBCXX_DEBUG]: Include <debug/vector>.
2525 2021-08-09  François Dumont  <fdumont@gcc.gnu.org>
2527         * include/debug/safe_container.h
2528         (_Safe_container(_Safe_container&&, const _Alloc&, std::true_type)): New.
2529         (_Safe_container(_Safe_container&&, const _Alloc&, std::false_type)): New.
2530         (_Safe_container(_Safe_container&&, const _Alloc&)): Use latters.
2532 2021-08-09  Jonathan Wakely  <jwakely@redhat.com>
2534         * testsuite/23_containers/unordered_map/cons/default.cc: Add
2535         equality comparison operators to allocator.
2536         * testsuite/23_containers/unordered_set/cons/default.cc:
2537         Likewise.
2539 2021-08-08  François Dumont  <fdumont@gcc.gnu.org>
2541         * testsuite/25_algorithms/copy/debug/constexpr_neg.cc: Replace 'failed_assertion'
2542         dg-prune-output reason with 'builtin_unreachable'.
2543         * testsuite/25_algorithms/copy_backward/debug/constexpr_neg.cc: Likewise.
2544         * testsuite/25_algorithms/equal/debug/constexpr_neg.cc: Likewise.
2545         * testsuite/25_algorithms/lower_bound/debug/constexpr_partitioned_neg.cc: Likewise.
2546         * testsuite/25_algorithms/lower_bound/debug/constexpr_partitioned_pred_neg.cc: Likewise.
2547         * testsuite/25_algorithms/lower_bound/debug/constexpr_valid_range_neg.cc: Likewise.
2548         * testsuite/25_algorithms/upper_bound/debug/constexpr_partitioned_neg.cc: Likewise.
2549         * testsuite/25_algorithms/upper_bound/debug/constexpr_partitioned_pred_neg.cc: Likewise.
2550         * testsuite/25_algorithms/upper_bound/debug/constexpr_valid_range_neg.cc: Likewise.
2552 2021-08-08  Hans-Peter Nilsson  <hp@bitrange.com>
2554         * testsuite/std/ranges/iota/max_size_type.cc: Set
2555         dg-timeout-factor to 4.
2557 2021-08-06  Jonathan Wakely  <jwakely@redhat.com>
2559         * libsupc++/compare (compare_three_way, strong_order)
2560         (weak_order, partial_order, compare_strong_order_fallback)
2561         (compare_weak_order_fallback, compare_partial_order_fallback):
2562         Move nodiscard attributes to correct location.
2564 2021-08-05  Jonathan Wakely  <jwakely@redhat.com>
2566         PR libstdc++/101782
2567         * include/bits/ranges_base.h (ranges::begin, ranges::end)
2568         (ranges::rbegin, ranges::rend, ranges::size, ranges::ssize)
2569         (ranges::empty, ranges::data): Move attribute after the
2570         declarator-id instead of at the end of the declarator.
2571         * include/bits/stl_iterator.h (__gnu_cxx::__normal_iterator):
2572         Move attributes back to the start of the function declarator,
2573         but move the requires-clause to the end.
2574         (common_iterator): Move attribute after the declarator-id.
2575         * include/bits/stl_queue.h (queue): Remove ill-formed attributes
2576         from friend declaration that are not definitions.
2577         * include/std/ranges (views::all, views::filter)
2578         (views::transform, views::take, views::take_while,
2579         views::drop) (views::drop_while, views::join,
2580         views::lazy_split) (views::split, views::counted,
2581         views::common, views::reverse) (views::elements): Move
2582         attributes after the declarator-id.
2584 2021-08-05  Jonathan Wakely  <jwakely@redhat.com>
2586         * libsupc++/compare (partial_ordering, weak_ordering)
2587         (strong_ordering, is_eq, is_neq, is_lt, is_lteq, is_gt, is_gteq)
2588         (compare_three_way, strong_order, weak_order, partial_order)
2589         (compare_strong_order_fallback, compare_weak_order_fallback)
2590         (compare_partial_order_fallback, __detail::__synth3way): Add
2591         nodiscard attribute.
2592         * testsuite/18_support/comparisons/categories/zero_neg.cc: Add
2593         -Wno-unused-result to options.
2595 2021-08-05  Jonathan Wakely  <jwakely@redhat.com>
2597         PR libstdc++/101782
2598         * include/bits/ranges_base.h (ranges::begin, ranges::end)
2599         (ranges::rbegin, ranges::rend, ranges::size, ranges::ssize)
2600         (ranges::empty, ranges::data): Move attribute to the end of
2601         the declarator.
2602         * include/bits/stl_iterator.h (__gnu_cxx::__normal_iterator)
2603         (common_iterator): Likewise for non-member operator functions.
2604         * include/std/ranges (views::all, views::filter)
2605         (views::transform, views::take, views::take_while, views::drop)
2606         (views::drop_while, views::join, views::lazy_split)
2607         (views::split, views::counted, views::common, views::reverse)
2608         (views::elements): Likewise.
2609         * testsuite/std/ranges/access/101782.cc: New test.
2611 2021-08-04  Jonathan Wakely  <jwakely@redhat.com>
2613         * include/bits/forward_list.h: Add [[nodiscard]] to functions
2614         with no side-effects.
2615         * include/bits/stl_bvector.h: Likewise.
2616         * include/bits/stl_deque.h: Likewise.
2617         * include/bits/stl_list.h: Likewise.
2618         * include/bits/stl_queue.h: Likewise.
2619         * include/bits/stl_stack.h: Likewise.
2620         * include/bits/stl_vector.h: Likewise.
2621         * include/debug/deque: Likewise.
2622         * include/debug/forward_list: Likewise.
2623         * include/debug/list: Likewise.
2624         * include/debug/safe_iterator.h: Likewise.
2625         * include/debug/vector: Likewise.
2626         * include/std/array: Likewise.
2627         * testsuite/23_containers/array/creation/3_neg.cc: Use
2628         -Wno-unused-result.
2629         * testsuite/23_containers/array/debug/back1_neg.cc: Cast result
2630         to void.
2631         * testsuite/23_containers/array/debug/back2_neg.cc: Likewise.
2632         * testsuite/23_containers/array/debug/front1_neg.cc: Likewise.
2633         * testsuite/23_containers/array/debug/front2_neg.cc: Likewise.
2634         * testsuite/23_containers/array/debug/square_brackets_operator1_neg.cc:
2635         Likewise.
2636         * testsuite/23_containers/array/debug/square_brackets_operator2_neg.cc:
2637         Likewise.
2638         * testsuite/23_containers/array/tuple_interface/get_neg.cc:
2639         Adjust dg-error line numbers.
2640         * testsuite/23_containers/deque/cons/clear_allocator.cc: Cast
2641         result to void.
2642         * testsuite/23_containers/deque/debug/invalidation/4.cc:
2643         Likewise.
2644         * testsuite/23_containers/deque/types/1.cc: Use
2645         -Wno-unused-result.
2646         * testsuite/23_containers/list/types/1.cc: Cast result to void.
2647         * testsuite/23_containers/priority_queue/members/7161.cc:
2648         Likewise.
2649         * testsuite/23_containers/queue/members/7157.cc: Likewise.
2650         * testsuite/23_containers/vector/59829.cc: Likewise.
2651         * testsuite/23_containers/vector/ext_pointer/types/1.cc:
2652         Likewise.
2653         * testsuite/23_containers/vector/ext_pointer/types/2.cc:
2654         Likewise.
2655         * testsuite/23_containers/vector/types/1.cc: Use
2656         -Wno-unused-result.
2658 2021-08-04  Jonathan Wakely  <jwakely@redhat.com>
2660         * include/bits/iterator_concepts.h (iter_move): Add
2661         [[nodiscard]].
2662         * include/bits/range_access.h (begin, end, cbegin, cend)
2663         (rbegin, rend, crbegin, crend, size, data, ssize): Likewise.
2664         * include/bits/ranges_base.h (ranges::begin, ranges::end)
2665         (ranges::cbegin, ranges::cend, ranges::rbegin, ranges::rend)
2666         (ranges::crbegin, ranges::crend, ranges::size, ranges::ssize)
2667         (ranges::empty, ranges::data, ranges::cdata): Likewise.
2668         * include/bits/stl_iterator.h (reverse_iterator, __normal_iterator)
2669         (back_insert_iterator, front_insert_iterator, insert_iterator)
2670         (move_iterator, move_sentinel, common_iterator)
2671         (counted_iterator): Likewise.
2672         * include/bits/stl_iterator_base_funcs.h (distance, next, prev):
2673         Likewise.
2674         * include/bits/stream_iterator.h (istream_iterator)
2675         (ostream_iterartor): Likewise.
2676         * include/bits/streambuf_iterator.h (istreambuf_iterator)
2677         (ostreambuf_iterator): Likewise.
2678         * include/std/ranges (views::single, views::iota, views::all)
2679         (views::filter, views::transform, views::take, views::take_while)
2680         (views::drop, views::drop_while, views::join, views::lazy_split)
2681         (views::split, views::counted, views::common, views::reverse)
2682         (views::elements): Likewise.
2683         * testsuite/20_util/rel_ops.cc: Use -Wno-unused-result.
2684         * testsuite/24_iterators/move_iterator/greedy_ops.cc: Likewise.
2685         * testsuite/24_iterators/normal_iterator/greedy_ops.cc:
2686         Likewise.
2687         * testsuite/24_iterators/reverse_iterator/2.cc: Likewise.
2688         * testsuite/24_iterators/reverse_iterator/greedy_ops.cc:
2689         Likewise.
2690         * testsuite/21_strings/basic_string/range_access/char/1.cc:
2691         Cast result to void.
2692         * testsuite/21_strings/basic_string/range_access/wchar_t/1.cc:
2693         Likewise.
2694         * testsuite/21_strings/basic_string_view/range_access/char/1.cc:
2695         Likewise.
2696         * testsuite/21_strings/basic_string_view/range_access/wchar_t/1.cc:
2697         Likewise.
2698         * testsuite/23_containers/array/range_access.cc: Likewise.
2699         * testsuite/23_containers/deque/range_access.cc: Likewise.
2700         * testsuite/23_containers/forward_list/range_access.cc:
2701         Likewise.
2702         * testsuite/23_containers/list/range_access.cc: Likewise.
2703         * testsuite/23_containers/map/range_access.cc: Likewise.
2704         * testsuite/23_containers/multimap/range_access.cc: Likewise.
2705         * testsuite/23_containers/multiset/range_access.cc: Likewise.
2706         * testsuite/23_containers/set/range_access.cc: Likewise.
2707         * testsuite/23_containers/unordered_map/range_access.cc:
2708         Likewise.
2709         * testsuite/23_containers/unordered_multimap/range_access.cc:
2710         Likewise.
2711         * testsuite/23_containers/unordered_multiset/range_access.cc:
2712         Likewise.
2713         * testsuite/23_containers/unordered_set/range_access.cc:
2714         Likewise.
2715         * testsuite/23_containers/vector/range_access.cc: Likewise.
2716         * testsuite/24_iterators/customization_points/iter_move.cc:
2717         Likewise.
2718         * testsuite/24_iterators/istream_iterator/sentinel.cc:
2719         Likewise.
2720         * testsuite/24_iterators/istreambuf_iterator/sentinel.cc:
2721         Likewise.
2722         * testsuite/24_iterators/move_iterator/dr2061.cc: Likewise.
2723         * testsuite/24_iterators/operations/prev_neg.cc: Likewise.
2724         * testsuite/24_iterators/ostreambuf_iterator/2.cc: Likewise.
2725         * testsuite/24_iterators/range_access/range_access.cc:
2726         Likewise.
2727         * testsuite/24_iterators/range_operations/100768.cc: Likewise.
2728         * testsuite/26_numerics/valarray/range_access2.cc: Likewise.
2729         * testsuite/28_regex/range_access.cc: Likewise.
2730         * testsuite/experimental/string_view/range_access/char/1.cc:
2731         Likewise.
2732         * testsuite/experimental/string_view/range_access/wchar_t/1.cc:
2733         Likewise.
2734         * testsuite/ext/vstring/range_access.cc: Likewise.
2735         * testsuite/std/ranges/adaptors/take.cc: Likewise.
2736         * testsuite/std/ranges/p2259.cc: Likewise.
2738 2021-08-03  Jonathan Wakely  <jwakely@redhat.com>
2740         * include/bits/random.tcc (linear_congruential_engine): Do not
2741         define static constexpr members when they are implicitly inline.
2742         * include/std/ratio (ratio, __ratio_multiply, __ratio_divide)
2743         (__ratio_add, __ratio_subtract): Likewise.
2744         * include/std/type_traits (integral_constant): Likewise.
2745         * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error
2746         line number.
2748 2021-08-03  Jonathan Wakely  <jwakely@redhat.com>
2750         * testsuite/util/testsuite_common_types.h: Replace uses of
2751         tr1::unordered_map and tr1::unordered_set with their C++11
2752         equivalents.
2753         * testsuite/29_atomics/atomic/cons/assign_neg.cc: Adjust
2754         dg-error line number.
2755         * testsuite/29_atomics/atomic/cons/copy_neg.cc: Likewise.
2756         * testsuite/29_atomics/atomic_integral/cons/assign_neg.cc:
2757         Likewise.
2758         * testsuite/29_atomics/atomic_integral/cons/copy_neg.cc:
2759         Likewise.
2760         * testsuite/29_atomics/atomic_integral/operators/bitwise_neg.cc:
2761         Likewise.
2762         * testsuite/29_atomics/atomic_integral/operators/decrement_neg.cc:
2763         Likewise.
2764         * testsuite/29_atomics/atomic_integral/operators/increment_neg.cc:
2765         Likewise.
2767 2021-08-03  Jonathan Wakely  <jwakely@redhat.com>
2769         * include/std/memory_resource (polymorphic_allocator::delete_object):
2770         Call destructor directly instead of using destroy.
2771         (allocator_traits<polymorphic_allocator<T>>): Define partial
2772         specialization.
2774 2021-08-03  Jonathan Wakely  <jwakely@redhat.com>
2776         * testsuite/20_util/function_objects/binders/3113.cc: Remove
2777         trailing whitespace.
2778         * testsuite/20_util/shared_ptr/assign/auto_ptr.cc: Likewise.
2779         * testsuite/20_util/shared_ptr/assign/auto_ptr_neg.cc: Likewise.
2780         * testsuite/20_util/shared_ptr/assign/auto_ptr_rvalue.cc:
2781         Likewise.
2782         * testsuite/20_util/shared_ptr/creation/dr925.cc: Likewise.
2783         * testsuite/25_algorithms/headers/algorithm/synopsis.cc:
2784         Likewise.
2785         * testsuite/25_algorithms/random_shuffle/requirements/explicit_instantiation/2.cc:
2786         Likewise.
2787         * testsuite/25_algorithms/random_shuffle/requirements/explicit_instantiation/pod.cc:
2788         Likewise.
2790 2021-08-03  Jonathan Wakely  <jwakely@redhat.com>
2792         * doc/xml/manual/evolution.xml: Document deprecation.
2793         * doc/html/*: Regenerate.
2794         * include/bits/c++config (_GLIBCXX14_DEPRECATED): Define.
2795         (_GLIBCXX14_DEPRECATED_SUGGEST): Define.
2796         * include/bits/stl_algo.h (random_shuffle): Deprecate for C++14
2797         and later.
2798         * testsuite/25_algorithms/headers/algorithm/synopsis.cc: Adjust
2799         for C++11 and C++14 changes to std::random_shuffle and
2800         std::shuffle.
2801         * testsuite/25_algorithms/random_shuffle/1.cc: Add options to
2802         use deprecated algorithms.
2803         * testsuite/25_algorithms/random_shuffle/59603.cc: Likewise.
2804         * testsuite/25_algorithms/random_shuffle/moveable.cc: Likewise.
2805         * testsuite/25_algorithms/random_shuffle/requirements/explicit_instantiation/2.cc:
2806         Likewise.
2807         * testsuite/25_algorithms/random_shuffle/requirements/explicit_instantiation/pod.cc:
2808         Likewise.
2810 2021-08-03  Jonathan Wakely  <jwakely@redhat.com>
2812         * testsuite/23_containers/forward_list/operations/3.cc:
2813         Use lambda instead of std::bind2nd.
2814         * testsuite/20_util/function_objects/binders/3113.cc: Add
2815         options for testing deprecated features.
2816         * testsuite/20_util/pair/cons/99957.cc: Likewise.
2817         * testsuite/20_util/shared_ptr/assign/auto_ptr.cc: Likewise.
2818         * testsuite/20_util/shared_ptr/assign/auto_ptr_neg.cc: Likewise.
2819         * testsuite/20_util/shared_ptr/assign/auto_ptr_rvalue.cc:
2820         Likewise.
2821         * testsuite/20_util/shared_ptr/cons/43820_neg.cc: Likewise.
2822         * testsuite/20_util/shared_ptr/cons/auto_ptr.cc: Likewise.
2823         * testsuite/20_util/shared_ptr/cons/auto_ptr_neg.cc: Likewise.
2824         * testsuite/20_util/shared_ptr/creation/dr925.cc: Likewise.
2825         * testsuite/20_util/unique_ptr/cons/auto_ptr.cc: Likewise.
2826         * testsuite/20_util/unique_ptr/cons/auto_ptr_neg.cc: Likewise.
2827         * testsuite/ext/pb_ds/example/priority_queue_erase_if.cc:
2828         Likewise.
2829         * testsuite/ext/pb_ds/example/priority_queue_split_join.cc:
2830         Likewise.
2831         * testsuite/lib/dg-options.exp (dg_add_options_using-deprecated):
2832         New proc.
2834 2021-08-03  Jonathan Wakely  <jwakely@redhat.com>
2836         * include/bits/regex_executor.h (_State_info): Replace
2837         unique_ptr<bool[]> with array of bool.
2838         * include/bits/regex_executor.tcc: Likewise.
2839         * include/bits/regex_scanner.tcc: Replace std::strchr with
2840         __builtin_strchr.
2841         * include/std/regex: Replace standard headers with smaller
2842         internal ones.
2843         * testsuite/28_regex/traits/char/lookup_classname.cc: Include
2844         <string.h> for strlen.
2845         * testsuite/28_regex/traits/char/lookup_collatename.cc:
2846         Likewise.
2848 2021-08-03  Jonathan Wakely  <jwakely@redhat.com>
2850         * include/bits/locale_conv.h (__detail::_Scoped_ptr): Define new
2851         RAII class template.
2852         (wstring_convert, wbuffer_convert): Use __detail::_Scoped_ptr
2853         instead of unique_ptr.
2855 2021-08-02  Patrick Palka  <ppalka@redhat.com>
2857         PR libstdc++/101599
2858         * include/bits/ranges_algo.h (__reverse_copy_fn::operator()):
2859         Add missing std::move in return statement.
2860         (__partition_copy_fn::operator()): Rename templtae parameter
2861         _O2 to _Out2.  Uglify function parameters out_true and out_false.
2862         * include/bits/ranges_algobase.h (__copy_or_move): Add missing
2863         std::move to recursive call that unwraps a __normal_iterator
2864         output iterator.
2865         * testsuite/25_algorithms/copy/constrained.cc (test06): New test.
2866         * testsuite/25_algorithms/move/constrained.cc (test05): New test.
2868 2021-08-02  Patrick Palka  <ppalka@redhat.com>
2870         PR libstdc++/101589
2871         * include/std/ranges (lazy_split_view::_InnerIter::base): Make
2872         the const& overload unconstrained and return a const reference
2873         as per LWG 3533.  Make unconditionally noexcept.
2874         (elements_view::base): Revert accidental r12-569 change.
2875         (elements_view::_Iterator::base): Make the const& overload
2876         unconstrained and return a const reference as per LWG 3533.
2877         Make unconditionally noexcept.
2879 2021-08-02  Patrick Palka  <ppalka@redhat.com>
2881         PR libstdc++/101483
2882         * include/std/ranges (join_view::_Iterator::_Iterator): Add
2883         missing std::move.
2885 2021-08-02  Jonathan Wakely  <jwakely@redhat.com>
2887         PR libstdc++/101709
2888         * src/filesystem/ops-common.h (get_temp_directory_from_env):
2889         Add error_code parameter.
2890         * src/c++17/fs_ops.cc (fs::temp_directory_path): Pass error_code
2891         argument to get_temp_directory_from_env and check it.
2892         * src/filesystem/ops.cc (fs::temp_directory_path): Likewise.
2894 2021-08-02  Jonathan Wakely  <jwakely@redhat.com>
2896         * testsuite/20_util/tuple/comparison_operators/overloaded2.cc:
2897         Add dg-error for c++11_only target.
2899 2021-07-30  Jonathan Wakely  <jwakely@redhat.com>
2901         PR libstdc++/65018
2902         * configure.ac: Check for secure_getenv.
2903         * config.h.in: Regenerate.
2904         * configure: Regenerate.
2905         * src/filesystem/ops-common.h (get_temp_directory_from_env): New
2906         helper function to obtain path from the environment.
2907         * src/c++17/fs_ops.cc (fs::temp_directory_path): Use new helper.
2908         * src/filesystem/ops.cc (fs::temp_directory_path): Likewise.
2909         * testsuite/27_io/filesystem/operations/temp_directory_path.cc:
2910         Print messages if test cannot be run.
2911         * testsuite/experimental/filesystem/operations/temp_directory_path.cc:
2912         Likewise. Fix incorrect condition. Use "TMP" to work with
2913         Windows as well as POSIX.
2915 2021-07-29  Hans-Peter Nilsson  <hp@bitrange.com>
2917         * src/c++17/memory_resource.cc: Use __exchange instead
2918         of std::exchange.
2920 2021-07-27  Jonathan Wakely  <jwakely@redhat.com>
2922         * include/experimental/optional (__throw_bad_optional_access):
2923         Replace GNU attribute with C++11 attribute.
2924         (optional::value, optional::value_or): Use if statements
2925         instead of conditional expressions.
2926         * include/std/optional (__throw_bad_optional_access)
2927         (optional::value, optional::value_or): Likewise.
2929 2021-07-27  Marek Polacek  <polacek@redhat.com>
2931         DR 1512
2932         PR c++/99701
2933         * testsuite/20_util/tuple/comparison_operators/overloaded.cc:
2934         Move a line...
2935         * testsuite/20_util/tuple/comparison_operators/overloaded2.cc:
2936         ...here.  New test.
2938 2021-07-27  Jonathan Wakely  <jwakely@redhat.com>
2940         * include/bits/cow_string.h: Consistently use tab for
2941         indentation.
2943 2021-07-27  Jonathan Wakely  <jwakely@redhat.com>
2945         * include/Makefile.am: Add new header.
2946         * include/Makefile.in: Regenerate.
2947         * include/bits/basic_string.h [!_GLIBCXX_USE_CXX11_ABI]
2948         (basic_string): Move definition of Copy-on-Write string to
2949         new file.
2950         * include/bits/basic_string.tcc: Likewise.
2951         * include/bits/cow_string.h: New file.
2953 2021-07-27  Jonathan Wakely  <jwakely@redhat.com>
2955         * include/std/algorithm: Do not include <utility>.
2956         * include/std/functional: Likewise.
2957         * include/std/regex: Include <bits/stl_pair.h> instead of
2958         <utility>.
2959         * include/debug/map.h: Likewise.
2960         * include/debug/multimap.h: Likewise.
2961         * include/debug/multiset.h: Likewise.
2962         * include/debug/set.h: Likewise.
2963         * include/debug/vector: Likewise.
2964         * include/bits/fs_path.h: Likewise.
2965         * include/bits/unique_ptr.h: Do not include <utility>.
2966         * include/experimental/any: Likewise.
2967         * include/experimental/executor: Likewise.
2968         * include/experimental/memory: Likewise.
2969         * include/experimental/optional: Likewise.
2970         * include/experimental/socket: Use __exchange instead
2971         of std::exchange.
2972         * src/filesystem/ops-common.h: Likewise.
2973         * testsuite/20_util/default_delete/48631_neg.cc: Adjust expected
2974         errors to not use a hardcoded line number.
2975         * testsuite/20_util/default_delete/void_neg.cc: Likewise.
2976         * testsuite/20_util/specialized_algorithms/uninitialized_copy/constrained.cc:
2977         Include <utility> for std::as_const.
2978         * testsuite/20_util/specialized_algorithms/uninitialized_default_construct/constrained.cc:
2979         Likewise.
2980         * testsuite/20_util/specialized_algorithms/uninitialized_move/constrained.cc:
2981         Likewise.
2982         * testsuite/20_util/specialized_algorithms/uninitialized_value_construct/constrained.cc:
2983         Likewise.
2984         * testsuite/23_containers/vector/cons/destructible_debug_neg.cc:
2985         Adjust dg-error line number.
2987 2021-07-27  Jonathan Wakely  <jwakely@redhat.com>
2989         * include/Makefile.am: Add bits/utility.h header.
2990         * include/Makefile.in: Regenerate.
2991         * include/bits/utility.h: New file.
2992         * include/std/utility (tuple_size, tuple_element): Move
2993         to new header.
2994         * include/std/type_traits (__is_tuple_like_impl<tuple<T...>>):
2995         Move to <tuple>.
2996         (_Index_tuple, _Build_index_tuple, integer_sequence): Likewise.
2997         (in_place_t, in_place_index_t, in_place_type_t): Likewise.
2998         * include/bits/ranges_util.h: Include new header instead of
2999         <utility>.
3000         * include/bits/stl_pair.h (tuple_size, tuple_element): Move
3001         partial specializations for std::pair here.
3002         (get): Move overloads for std::pair here.
3003         * include/std/any: Include new header instead of <utility>.
3004         * include/std/array: Likewise.
3005         * include/std/memory_resource: Likewise.
3006         * include/std/optional: Likewise.
3007         * include/std/variant: Likewise.
3008         * include/std/tuple: Likewise.
3009         (__is_tuple_like_impl<tuple<T...>>): Move here.
3010         (get) Declare overloads for std::array.
3011         * include/std/version (__cpp_lib_tuples_by_type): Change type
3012         to long.
3013         * testsuite/20_util/optional/84601.cc: Include <utility>.
3014         * testsuite/20_util/specialized_algorithms/uninitialized_fill/constrained.cc:
3015         Likewise.
3016         * testsuite/23_containers/array/tuple_interface/get_neg.cc:
3017         Adjust dg-error line numbers.
3018         * testsuite/std/ranges/access/cbegin.cc: Include <utility>.
3019         * testsuite/std/ranges/access/cend.cc: Likewise.
3020         * testsuite/std/ranges/access/end.cc: Likewise.
3021         * testsuite/std/ranges/single_view.cc: Likewise.
3023 2021-07-23  Jonathan Wakely  <jwakely@redhat.com>
3025         * include/std/future: Include <bits/atomic_base.h> instead of
3026         <atomic>.
3028 2021-07-23  Jonathan Wakely  <jwakely@redhat.com>
3030         * include/bits/stl_relops.h: Update documentation comments.
3032 2021-07-22  Jonathan Wakely  <jwakely@redhat.com>
3034         PR libstdc++/101583
3035         * include/bits/hashtable.h (_Hashtable): Replace mixin with
3036         _Enable_default_ctor. Construct it explicitly in all
3037         non-forwarding, non-defaulted constructors.
3038         * testsuite/23_containers/unordered_map/cons/default.cc: Check
3039         non-default constructors can be used.
3040         * testsuite/23_containers/unordered_set/cons/default.cc:
3041         Likewise.
3043 2021-07-22  David Edelsohn  <dje.gcc@gmail.com>
3045         * config/os/aix/os_defines.h (__LIBC_NO_CPP_MATH_OVERLOADS__): Define.
3047 2021-07-22  Jonathan Wakely  <jwakely@redhat.com>
3049         PR libstdc++/94295
3050         * include/ext/new_allocator.h (_GLIBCXX_OPERATOR_NEW)
3051         (_GLIBCXX_OPERATOR_DELETE, _GLIBCXX_SIZED_DEALLOC): Define.
3052         (allocator::allocate, allocator::deallocate): Use new macros.
3054 2021-07-22  Jonathan Wakely  <jwakely@redhat.com>
3056         PR libstdc++/101571
3057         * include/bits/ranges_uninitialized.h (_DestroyGuard): Change
3058         constructor parameter to reference and use addressof.
3059         * testsuite/util/testsuite_iterators.h: Define deleted operator&
3060         overloads for test iterators.
3062 2021-07-22  Jonathan Wakely  <jwakely@redhat.com>
3064         * include/bits/std_function.h (_Function_base): Add
3065         default member initializers and define constructor as defaulted.
3066         (function::_M_invoker): Add default member initializer.
3068 2021-07-22  Jonathan Wakely  <jwakely@redhat.com>
3070         PR libstdc++/100682
3071         * doc/xml/manual/debug_mode.xml: Update documentation about
3072         debug capability of std::array.
3073         * doc/html/*: Regenerate.
3074         * include/debug/array: New file.
3076 2021-07-21  Jonathan Wakely  <jwakely@redhat.com>
3078         PR libstdc++/101542
3079         * include/ext/rope (sequence_buffer): Add move constructor and
3080         move assignment operator.
3081         * testsuite/ext/rope/101542.cc: New test.
3083 2021-07-20  Jonathan Wakely  <jwakely@redhat.com>
3085         PR libstdc++/101510
3086         * src/c++17/fs_ops.cc (fs::create_directories): Use status
3087         instead of symlink_status.
3088         * src/filesystem/ops.cc (fs::create_directories): Likewise.
3089         * testsuite/27_io/filesystem/operations/create_directories.cc:
3090         Check symlink to existing directory.
3091         * testsuite/27_io/filesystem/operations/create_directory.cc: Do
3092         not test with symlinks on Windows.
3093         * testsuite/experimental/filesystem/operations/create_directories.cc:
3094         Check symlink to existing directory.
3095         * testsuite/experimental/filesystem/operations/create_directory.cc:
3096         Do not test with symlinks on Windows.
3098 2021-07-20  Jonathan Wakely  <jwakely@redhat.com>
3100         PR libstdc++/100863
3101         * include/bits/hashtable.h (_Hashtable): Conditionally delete
3102         default constructor by deriving from _Enable_special_members.
3103         * testsuite/23_containers/unordered_map/cons/default.cc: New test.
3104         * testsuite/23_containers/unordered_set/cons/default.cc: New test.
3106 2021-07-20  Jonathan Wakely  <jwakely@redhat.com>
3108         PR libstdc++/101510
3109         * src/c++17/fs_ops.cc (create_dir): Adjust whitespace.
3110         * testsuite/27_io/filesystem/operations/create_directory.cc:
3111         Test creating directory with name of existing symlink to
3112         directory.
3113         * testsuite/experimental/filesystem/operations/create_directory.cc:
3114         Likewise.
3116 2021-07-16  Jonathan Wakely  <jwakely@redhat.com>
3118         * include/std/tuple (get<I>): Add deleted overload for bad
3119         index.
3120         * testsuite/20_util/tuple/element_access/get_neg.cc: Adjust
3121         expected errors.
3123 2021-07-16  Jonathan Wakely  <jwakely@redhat.com>
3125         * include/bits/max_size_type.h (numeric_limits<__max_size_type>):
3126         Use __int_traits unconditionally.
3128 2021-07-16  Jonathan Wakely  <jwakely@redhat.com>
3130         * include/bits/random.h (_Shift::__value): Use constexpr.
3131         (_Select_uint_least_t::type): Use using-declaration.
3132         (_Mod): Likewise.
3133         * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error
3134         line number.
3136 2021-07-16  Jonathan Wakely  <jwakely@redhat.com>
3138         * include/bits/cpp_type_traits.h (__INT_N): Use __extension__
3139         instead of diagnostic pragmas.
3140         * include/bits/functional_hash.h: Likewise.
3141         * include/bits/iterator_concepts.h (__is_signed_int128)
3142         (__is_unsigned_int128): Likewise.
3143         * include/bits/max_size_type.h (__max_size_type): Likewise.
3144         (numeric_limits<__max_size_type>): Likewise.
3145         * include/bits/std_abs.h (abs): Likewise.
3146         * include/bits/stl_algobase.h (__size_to_integer): Likewise.
3147         * include/bits/uniform_int_dist.h (uniform_int_distribution):
3148         Likewise.
3149         * include/ext/numeric_traits.h (_GLIBCXX_INT_N_TRAITS):
3150         Likewise.
3151         * include/std/type_traits (__is_integral_helper<INT_N>)
3152         (__is_signed_integer, __is_unsigned_integer)
3153         (__make_unsigned<INT_N>, __make_signed<INT_N>): Likewise.
3154         * include/std/limits (__INT_N): Add __extension__ keyword.
3155         * include/bits/random.h (_Select_uint_least_t)
3156         (random_device): Likewise.
3158 2021-07-16  Patrick Palka  <ppalka@redhat.com>
3160         PR libstdc++/101231
3161         * include/std/ranges (_CachedPosition::_M_get): For non-forward
3162         ranges, just call __builtin_unreachable.
3163         * testsuite/std/ranges/istream_view.cc (test05): New test.
3165 2021-07-16  Patrick Palka  <ppalka@redhat.com>
3167         PR libstdc++/101214
3168         * include/std/ranges (split_view::split_view): Use std::move.
3169         (split_view::_Iterator::_Iterator): Remove redundant
3170         default_initializable constraint.
3171         (split_view::_Sentinel::_Sentinel): Declare.
3172         * testsuite/std/ranges/adaptors/split.cc (test02): New test.
3174 2021-07-16  Marek Polacek  <polacek@redhat.com>
3176         * testsuite/20_util/ratio/operations/ops_overflow_neg.cc: Add
3177         dg-error.
3179 2021-07-16  Jonathan Wakely  <jwakely@redhat.com>
3181         * include/bits/unique_ptr.h: Adjust doxygen markup.
3183 2021-07-16  Jonathan Wakely  <jwakely@redhat.com>
3185         PR libstdc++/101307
3186         * include/std/type_traits: Adjust doxygen markup.
3188 2021-07-16  Jonathan Wakely  <jwakely@redhat.com>
3190         * include/bits/cpp_type_traits.h: Add diagnostic pragmas around
3191         uses of non-standard integer types.
3192         * include/bits/functional_hash.h: Likewise.
3193         * include/bits/iterator_concepts.h: Likewise.
3194         * include/bits/max_size_type.h: Likewise.
3195         * include/bits/std_abs.h: Likewise.
3196         * include/bits/stl_algobase.h: Likewise.
3197         * include/bits/uniform_int_dist.h: Likewise.
3198         * include/ext/numeric_traits.h: Likewise.
3199         * include/std/type_traits: Likewise.
3201 2021-07-15  Jonathan Wakely  <jwakely@redhat.com>
3203         PR libstdc++/101427
3204         * include/std/tuple (tuple_element): Improve static_assert text.
3205         (__get_helper): Add deleted overload.
3206         (get<i>(tuple<T...>&&), get<i>(const tuple<T...>&&)): Use
3207         __get_helper directly.
3208         (__get_helper2): Remove.
3209         (__find_uniq_type_in_pack): New constexpr helper function.
3210         (get<T>): Use __find_uniq_type_in_pack and __get_helper instead
3211         of __get_helper2.
3212         * testsuite/20_util/tuple/element_access/get_neg.cc: Adjust
3213         expected errors.
3214         * testsuite/20_util/tuple/element_access/101427.cc: New test.
3216 2021-07-15  Jonathan Wakely  <jwakely@redhat.com>
3218         PR libstdc++/101429
3219         * include/bits/c++config (__replacement_assert): Add noexcept.
3220         [!_GLIBCXX_VERBOSE] (__glibcxx_assert_impl): Use __builtin_abort
3221         instead of __replacement_assert.
3223 2021-07-14  Jonathan Wakely  <jwakely@redhat.com>
3225         * include/std/string_view (basic_string_view(It, End)): Add
3226         noexcept-specifier.
3227         * testsuite/21_strings/basic_string_view/cons/char/range.cc:
3228         Check noexcept-specifier. Also check construction without CTAD.
3230 2021-07-13  Jonathan Wakely  <jwakely@redhat.com>
3232         PR c++/101361
3233         * include/std/string_view (ends_with): Use traits_type::compare
3234         directly.
3236 2021-07-13  Jonathan Wakely  <jwakely@redhat.com>
3238         * include/std/string_view: Only include <bits/ranges_base.h>
3239         once, and only for C++20 and later.
3241 2021-07-12  Jonathan Wakely  <jwakely@redhat.com>
3243         PR libstdc++/101411
3244         * include/std/span (as_writable_bytes): Add requires-clause.
3245         * testsuite/23_containers/span/101411.cc: New test.
3247 2021-07-09  Matheus Castanho  <msc@linux.ibm.com>
3249         * include/std/mutex (__lock_impl): Check
3250         _GLIBCXX_HAS_GTHREADS before using __gthread_yield.
3252 2021-07-02  Jonathan Wakely  <jwakely@redhat.com>
3254         PR libstdc++/101271
3255         * include/bits/unique_ptr.h (unique_ptr<T[],D>::operator[]):
3256         Remove noexcept-specifier.
3257         (unique_ptr<T[],D>::_S_nothrow_deref): Remove.
3258         * testsuite/20_util/unique_ptr/lwg2762.cc: Remove checks for
3259         operator[].
3261 2021-07-01  Jonathan Wakely  <jwakely@redhat.com>
3263         * doc/doxygen/doxygroups.cc: Fix docs for std::literals.
3264         * doc/doxygen/user.cfg.in: Exclude the Networking TS header.
3265         Add some more predefined macros.
3266         * include/bits/fs_fwd.h: Move @addtogroup commands inside
3267         namespaces. Add better documentation.
3268         * include/bits/fs_path.h: Likewise.
3269         * include/experimental/bits/fs_fwd.h: Likewise.
3270         * include/experimental/bits/fs_path.h: Likewise.
3271         * include/ext/throw_allocator.h: Fix typo and improve docs.
3272         * include/std/chrono: Move @addtogroup commands.
3273         * include/std/system_error: Move @addtogroup commands.
3274         * libsupc++/exception: Improve documentation.
3275         * libsupc++/exception.h: Add @since documentation.
3277 2021-06-30  Jonathan Wakely  <jwakely@redhat.com>
3279         PR libstdc++/101258
3280         * doc/doxygen/user.cfg.in (INPUT): Add <experimental/simd>.
3281         (COLS_IN_ALPHA_INDEX): Remove obsolete tag.
3282         (PREDEFINED): Add/fix some more macros that need to be expanded.
3283         * include/bits/random.h: Stop Doxygen from documenting internal
3284         implementation details.
3285         * include/bits/random.tcc: Likewise.
3286         * include/bits/this_thread_sleep.h: Fix @file name.
3287         * include/experimental/bits/simd.h: Add to Doxygen group. Do not
3288         document internal implementation details.
3289         * include/experimental/bits/simd_detail.h: Do not document
3290         internal implementation details.
3291         * include/experimental/simd: Define Doxygen groups.
3292         * include/experimental/type_traits: Improve documentation for
3293         the header file. Define groups. Use @since commands.
3294         * include/std/scoped_allocator (scoped_allocator_adaptor): Move
3295         declaration before undocumented region.
3296         * include/std/type_traits (true_type, false_type): Use using
3297         declaration instead of typedef.
3298         (is_invocable_v, is_nothrow_invocable_v, is_invocable_r_v)
3299         (is_nothrow_invocable_r_v): Move definitions next to other C++17
3300         variable templates.
3301         Do not document internal implementation details. Move misplaced
3302         group-end command. Define group for variable templates.
3303         * include/std/variant: Do not document internal implementation
3304         details.
3305         * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error
3306         line number.
3308 2021-06-30  Jonathan Wakely  <jwakely@redhat.com>
3310         * include/experimental/simd: Do not define anything pre-C++17.
3312 2021-06-30  Jonathan Wakely  <jwakely@redhat.com>
3314         * include/bits/random.tcc [__cpp_inline_variables]: Remove
3315         redundant definitions of static constexpr member variables.
3316         * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error
3317         line number.
3319 2021-06-28  Jonathan Wakely  <jwakely@redhat.com>
3321         * include/bits/streambuf.tcc (__copy_streambufs_eof): Remove
3322         explicit instantiation declarations.
3323         * src/c++11/streambuf-inst.cc (__copy_streambufs_eof): Remove
3324         explicit instantiation definitions.
3326 2021-06-28  Jonathan Wakely  <jwakely@redhat.com>
3328         PR libstdc++/97088
3329         * testsuite/17_intro/names.cc: Fix #if condition for names used
3330         by newlib headers.
3332 2021-06-28  Jonathan Wakely  <jwakely@redhat.com>
3334         PR libstdc++/101236
3335         * include/bits/unique_ptr.h (unique_ptr<T[], D>::operator[]):
3336         Fail gracefully if element_type is incomplete.
3337         * testsuite/20_util/unique_ptr/cons/incomplete.cc: Clarify that
3338         the standard doesn't require this test to work for array types.
3339         * testsuite/20_util/unique_ptr/lwg2762.cc: Check that incomplete
3340         types can be used with array specialization.
3341         * testsuite/20_util/unique_ptr/101236.cc: New test.
3343 2021-06-28  Jonathan Wakely  <jwakely@redhat.com>
3345         * doc/xml/manual/intro.xml: Document LWG 415 change.
3346         * doc/html/manual/bugs.html: Regenerate.
3347         * include/bits/istream.tcc (ws): Create sentry and catch
3348         exceptions.
3349         * testsuite/27_io/basic_istream/ws/char/lwg415.cc: New test.
3350         * testsuite/27_io/basic_istream/ws/wchar_t/lwg415.cc: New test.
3352 2021-06-25  Jonathan Wakely  <jwakely@redhat.com>
3354         * include/bits/ostream.tcc (basic_ostream::write): Call sputn
3355         directly instead of using _M_write. Do setstate(__err) all
3356         outside the try-catch block.
3357         * include/std/ostream (basic_ostream::_M_write): Declare
3358         private. Use __ostream_insert. Do not define for the versioned
3359         namespace.
3361 2021-06-25  Jonathan Wakely  <jwakely@redhat.com>
3363         * doc/xml/manual/intro.xml: Document LWG 581 change.
3364         * doc/html/manual/bugs.html: Regenerate.
3365         * include/bits/basic_ios.tcc: Whitespace.
3366         * include/bits/ostream.tcc (basic_ostream::flush()): Construct
3367         sentry.
3368         * testsuite/27_io/basic_ostream/flush/char/2.cc: Check
3369         additional cases.
3370         * testsuite/27_io/basic_ostream/flush/char/exceptions_badbit_throw.cc:
3371         Likewise.
3372         * testsuite/27_io/basic_ostream/flush/wchar_t/2.cc: Likewise.
3373         * testsuite/27_io/basic_ostream/flush/wchar_t/exceptions_badbit_throw.cc:
3374         Likewise.
3376 2021-06-25  Jonathan Wakely  <jwakely@redhat.com>
3378         * include/bits/ostream.tcc (sentry): Only set failbit if badbit
3379         is set, not if eofbit is set.
3380         (tellp, seekp, seekp): Create sentry object. Do not set badbit
3381         on exceptions.
3382         * testsuite/27_io/basic_ostream/seekp/char/exceptions_badbit_throw.cc:
3383         Adjust expected behaviour.
3384         * testsuite/27_io/basic_ostream/seekp/wchar_t/exceptions_badbit_throw.cc:
3385         Likewise.
3386         * testsuite/27_io/basic_ostream/tellp/char/exceptions_badbit_throw.cc:
3387         Likewise.
3388         * testsuite/27_io/basic_ostream/tellp/wchar_t/exceptions_badbit_throw.cc:
3389         Likewise.
3390         * testsuite/27_io/basic_ostream/seekp/char/n3168.cc: New test.
3391         * testsuite/27_io/basic_ostream/seekp/wchar_t/n3168.cc: New test.
3392         * testsuite/27_io/basic_ostream/tellp/char/n3168.cc: New test.
3393         * testsuite/27_io/basic_ostream/tellp/wchar_t/n3168.cc: New test.
3395 2021-06-25  Jonathan Wakely  <jwakely@redhat.com>
3397         * include/std/syncstream (basic_syncbuf::swap()): Remove
3398         noexcept, as per LWG 3498.
3400 2021-06-25  Jonathan Wakely  <jwakely@redhat.com>
3402         PR libstdc++/97088
3403         * testsuite/17_intro/names.cc: Undef more names for newlib and
3404         also for arm-none-linux-gnueabi.
3405         * testsuite/experimental/names.cc: Disable PCH.
3407 2021-06-25  Matthias Kretz  <m.kretz@gsi.de>
3409         * include/experimental/bits/simd.h (__bit_cast): Implement via
3410         __builtin_bit_cast #if available.
3411         (__proposed::simd_bit_cast): Add overloads for simd and
3412         simd_mask, which use __builtin_bit_cast (or __bit_cast #if not
3413         available), which return an object of the requested type with
3414         the same bits as the argument.
3415         * include/experimental/bits/simd_math.h: Use simd_bit_cast
3416         instead of __bit_cast to allow casts to fixed_size_simd.
3417         (copysign): Remove branch that was only required if __bit_cast
3418         cannot be constexpr.
3419         * testsuite/experimental/simd/tests/bits/test_values.h: Switch
3420         from __bit_cast to __proposed::simd_bit_cast since the former
3421         will not cast fixed_size objects anymore.
3423 2021-06-24  Matthias Kretz  <m.kretz@gsi.de>
3425         * include/experimental/bits/simd_math.h
3426         (_GLIBCXX_SIMD_MATH_CALL2_): Rename arg2_ to __arg2.
3427         (_GLIBCXX_SIMD_MATH_CALL3_): Rename arg2_ to __arg2 and arg3_ to
3428         __arg3.
3430 2021-06-24  Matthias Kretz  <m.kretz@gsi.de>
3432         * include/experimental/bits/simd.h (__execute_on_index_sequence)
3433         (__execute_on_index_sequence_with_return)
3434         (__call_with_n_evaluations, __call_with_subscripts): Add flatten
3435         attribute.
3437 2021-06-24  Matthias Kretz  <m.kretz@gsi.de>
3439         * include/experimental/bits/simd_x86.h (_S_trunc, _S_floor)
3440         (_S_ceil): Set bit 8 (_MM_FROUND_NO_EXC) on AVX and SSE4.1
3441         roundp[sd] calls.
3443 2021-06-24  Matthias Kretz  <m.kretz@gsi.de>
3445         * include/experimental/bits/simd_x86.h (_S_ldexp): The AVX512F
3446         implementation doesn't require a _VecBltnBtmsk ABI tag, it
3447         requires either a 64-Byte input (in which case AVX512F must be
3448         available) or AVX512VL.
3450 2021-06-24  Matthias Kretz  <m.kretz@gsi.de>
3452         * include/experimental/bits/simd_math.h: Undefine internal
3453         macros after use.
3454         (frexp): Move #if to a more sensible position and reformat
3455         preceding code.
3456         (logb): Call _SimdImpl::_S_logb for fixed_size instead of
3457         duplicating the code here.
3458         (modf): Simplify condition.
3460 2021-06-24  Matthias Kretz  <m.kretz@gsi.de>
3462         * include/experimental/bits/simd_math.h (fabs): Remove
3463         fabs(simd<integral>) overload.
3465 2021-06-24  Matthias Kretz  <m.kretz@gsi.de>
3467         * include/experimental/bits/simd_converter.h
3468         (_SimdConverter::operator()): Pass _SimdTuple by const-ref.
3469         * include/experimental/bits/simd_fixed_size.h
3470         (_GLIBCXX_SIMD_FIXED_OP): Pass binary operator _SimdTuple
3471         arguments by const-ref.
3472         (_S_masked_unary): Pass _SimdTuple by const-ref.
3474 2021-06-24  Matthias Kretz  <m.kretz@gsi.de>
3476         * include/experimental/bits/simd_fixed_size.h
3477         (_AbisInSimdTuple): Removed.
3479 2021-06-24  Matthias Kretz  <m.kretz@gsi.de>
3481         * include/experimental/bits/simd.h: Add missing operator~
3482         overload for simd<floating-point> to __float_bitwise_operators.
3483         * include/experimental/bits/simd_builtin.h
3484         (_SimdImplBuiltin::_S_complement): Bitcast to int (and back) to
3485         implement complement for floating-point vectors.
3486         * include/experimental/bits/simd_fixed_size.h
3487         (_SimdImplFixedSize::_S_copysign): New function, forwarding to
3488         copysign implementation of _SimdTuple members.
3489         * include/experimental/bits/simd_math.h (copysign): Call
3490         _SimdImpl::_S_copysign for fixed_size arguments. Simplify
3491         generic copysign implementation using the new ~ operator.
3493 2021-06-24  Jonathan Wakely  <jwakely@redhat.com>
3495         * testsuite/experimental/simd/README.md: Fix typos.
3497 2021-06-24  Jonathan Wakely  <jwakely@redhat.com>
3499         * include/bits/shared_ptr_base.h (__shared_ptr_access::operator[]):
3500         Add noexcept.
3501         * include/bits/unique_ptr.h (unique_ptr::operator*): Add
3502         conditional noexcept as per LWG 2762.
3503         * testsuite/20_util/shared_ptr/observers/array.cc: Check that
3504         dereferencing cannot throw.
3505         * testsuite/20_util/shared_ptr/observers/get.cc: Likewise.
3506         * testsuite/20_util/optional/observers/lwg2762.cc: New test.
3507         * testsuite/20_util/unique_ptr/lwg2762.cc: New test.
3509 2021-06-23  Patrick Palka  <ppalka@redhat.com>
3511         PR c++/101174
3512         * testsuite/23_containers/multiset/cons/deduction.cc:
3513         Uncomment CTAD example that was rejected by this bug.
3514         * testsuite/23_containers/set/cons/deduction.cc: Likewise.
3516 2021-06-23  Jonathan Wakely  <jwakely@redhat.com>
3518         * include/std/chrono (chrono::year::is_leap()): Fix incorrect
3519         logic in comment.
3521 2021-06-23  Matthias Kretz  <m.kretz@gsi.de>
3523         * testsuite/experimental/simd/README.md: New file.
3525 2021-06-23  Matthias Kretz  <m.kretz@gsi.de>
3527         * testsuite/experimental/simd/driver.sh: Rewrite output
3528         verbosity logic. Add -p/--percentage option. Allow -v/--verbose
3529         to be used twice. Add -x and -o short options. Parse long
3530         options with = instead of separating space generically. Parce
3531         contracted short options. Make unrecognized options an error.
3532         If same-line output is active, trap on EXIT to increment the
3533         progress (only with --percentage), erase the line and print the
3534         current status.
3535         * testsuite/experimental/simd/generate_makefile.sh: Initialize
3536         helper files for progress account keeping. Update help target
3537         for changes to DRIVEROPTS.
3539 2021-06-23  Matthias Kretz  <m.kretz@gsi.de>
3541         * testsuite/Makefile.am (check-simd): Remove -fno-tree-vrp flag
3542         and associated warning.
3543         * testsuite/Makefile.in: Regenerate.
3545 2021-06-23  Cassio Neri  <cassio.neri@gmail.com>
3546             Jonathan Wakely  <jwakely@redhat.com>
3547             Ulrich Drepper  <drepper@redhat.com>
3549         * include/std/chrono (chrono::year::is_leap()): Optimize.
3551 2021-06-23  Patrick Palka  <ppalka@redhat.com>
3553         PR c++/86439
3554         * testsuite/23_containers/map/cons/deduction.cc: Replace ambiguous
3555         CTAD examples.
3556         * testsuite/23_containers/multimap/cons/deduction.cc: Likewise.
3557         * testsuite/23_containers/multiset/cons/deduction.cc: Likewise.
3558         Mention one of the replaced examples is broken due to PR101174.
3559         * testsuite/23_containers/set/cons/deduction.cc: Likewise.
3560         * testsuite/23_containers/unordered_map/cons/deduction.cc: Replace
3561         ambiguous CTAD examples.
3562         * testsuite/23_containers/unordered_multimap/cons/deduction.cc:
3563         Likewise.
3564         * testsuite/23_containers/unordered_multiset/cons/deduction.cc:
3565         Likewise.
3566         * testsuite/23_containers/unordered_set/cons/deduction.cc: Likewise.
3568 2021-06-23  Jonathan Wakely  <jwakely@redhat.com>
3570         * include/std/mutex (__detail::__try_lock_impl): Rename
3571         parameter to avoid clashing with newlib's __lockable macro.
3572         (try_lock): Add 'inline' specifier.
3573         * testsuite/17_intro/names.cc: Add check for __lockable.
3574         * testsuite/30_threads/try_lock/5.cc: Add options for pthreads.
3576 2021-06-22  Jonathan Wakely  <jwakely@redhat.com>
3577             Matthias Kretz  <m.kretz@gsi.de>
3579         * include/std/mutex (lock): Replace recursion with iteration
3580         when lockables all have the same type.
3581         (__detail::__try_lock_impl): Likewise. Pass lockables as
3582         parameters, instead of a tuple. Always lock the first one, and
3583         recurse for the rest.
3584         (__detail::__lock_impl): Adjust call to __try_lock_impl.
3585         (__detail::__try_to_lock): Remove.
3586         * testsuite/30_threads/lock/3.cc: Check that mutexes are locked.
3587         * testsuite/30_threads/lock/4.cc: Also test non-heterogeneous
3588         arguments.
3589         * testsuite/30_threads/unique_lock/cons/60497.cc: Also check
3590         std::try_lock.
3591         * testsuite/30_threads/try_lock/5.cc: New test.
3593 2021-06-22  Jonathan Wakely  <jwakely@redhat.com>
3595         * include/std/memory (declare_reachable, undeclare_reachable)
3596         (declare_no_pointers, undeclare_no_pointers, get_pointer_safety)
3597         (pointer_safety): Only define for C++11 to C++20 inclusive.
3598         * testsuite/20_util/pointer_safety/1.cc: Do not run for C++23.
3600 2021-06-22  Jonathan Wakely  <jwakely@redhat.com>
3602         * include/bits/random.h (seed_seq): Constrain initializer-list
3603         constructor.
3604         * include/bits/random.tcc (seed_seq): Add template parameter.
3605         * testsuite/26_numerics/random/seed_seq/cons/default.cc: Check
3606         for noexcept.
3607         * testsuite/26_numerics/random/seed_seq/cons/initlist.cc: Check
3608         constraints.
3610 2021-06-22  Thomas Rodgers  <rodgert@appliantology.com>
3612         PR libstdc++/100806
3613         * include/bits/semaphore_base.h (__atomic_semaphore::_M_release):
3614         Force _M_release() to wake all waiting threads.
3615         * testsuite/30_threads/semaphore/100806.cc: New test.
3617 2021-06-21  Jonathan Wakely  <jwakely@redhat.com>
3619         * include/std/mutex (__try_to_lock): Move to __detail namespace.
3620         (struct __try_lock_impl): Replace with ...
3621         (__detail::__try_lock_impl<Idx>(tuple<Lockables...>&)): New
3622         function templates to implement std::try_lock.
3623         (try_lock): Use new __try_lock_impl.
3624         (__detail::__lock_impl(int, int&, L0&, L1&...)): New function
3625         template to implement std::lock.
3626         (lock): Use __lock_impl.
3628 2021-06-21  Patrick Palka  <ppalka@redhat.com>
3630         * include/bits/ranges_cmp.h (__cpp_lib_ranges): Adjust value.
3632 2021-06-20  Patrick Palka  <ppalka@redhat.com>
3634         * include/std/ranges (__non_propagating_cache::operator bool):
3635         Define for split_view::begin().
3636         (split_view): Define as per P2210.
3637         (views::__detail::__can_split_view): Define.
3638         (views::_Split, views::split): Define.
3639         * testsuite/std/ranges/adaptors/100577.cc (test01, test02):
3640         Test views::split.
3641         * testsuite/std/ranges/adaptors/split.cc: New test.
3642         * testsuite/std/ranges/p2325.cc (test08a): New test.
3643         * testsuite/std/ranges/p2367.cc (test01): Test views::split.
3645 2021-06-20  Patrick Palka  <ppalka@redhat.com>
3647         * include/std/ranges: Rename views::split to views::lazy_split,
3648         split_view to lazy_split_view, etc. throughout.
3649         * testsuite/std/ranges/*: Likewise.
3650         * testsuite/std/ranges/adaptors/lazy_split.cc: New file.
3651         * testsuite/std/ranges/adaptors/lazy_split_neg.cc: New file.
3653 2021-06-20  Patrick Palka  <ppalka@redhat.com>
3655         * include/std/ranges (split_view::_OuterIter::__at_end):
3656         Check _M_trailing_empty.
3657         (split_view::_OuterIter::_M_trailing_empty): Define this
3658         data member.
3659         (split_view::_OuterIter::operator++): Set _M_trailing_empty
3660         appropriately.
3661         (split_view::_OuterIter::operator==): Compare
3662         _M_trailing_empty.
3663         * testsuite/std/ranges/adaptors/100479.cc (test03): Expect two
3664         split parts instead of one.
3665         * testsuite/std/ranges/adaptors/split.cc (test11): New test.
3667 2021-06-20  Patrick Palka  <ppalka@redhat.com>
3669         * include/std/ranges (split_view::_InnerIter::base): Define as
3670         per P2210.
3672 2021-06-19  Patrick Palka  <ppalka@redhat.com>
3674         * include/std/ranges (transform_view::_Iterator::_S_iter_concept):
3675         Consider _Base instead of _Vp as per LWG 3555.
3676         (elements_view::_Iterator::_S_iter_concept): Likewise.
3678 2021-06-19  Patrick Palka  <ppalka@redhat.com>
3680         * include/std/ranges (split_view::_OuterIter::value_type::begin):
3681         Remove the non-const overload, and remove the copyable constraint
3682         on the const overload as per LWG 3553.
3684 2021-06-19  Patrick Palka  <ppalka@redhat.com>
3686         * include/bits/stl_iterator.h
3687         (__detail::__common_iter_use_postfix_proxy): Add
3688         move_constructible constraint as per LWG 3546.
3689         (common_iterator::__postfix_proxy): Adjust initializer of
3690         _M_keep as per LWG 3546.
3692 2021-06-18  Patrick Palka  <ppalka@redhat.com>
3694         PR libstdc++/100387
3695         * include/bits/ranges_algo.h (__minmax_fn::operator()): Rewrite
3696         to limit comparison complexity to 3*N/2.
3697         (__minmax_element_fn::operator()): Likewise.
3698         (shift_right): Avoid premature std::move of __result.
3699         * testsuite/25_algorithms/minmax/constrained.cc (test04, test05):
3700         New tests.
3701         * testsuite/25_algorithms/minmax_element/constrained.cc (test02):
3702         Likewise.
3704 2021-06-18  Patrick Palka  <ppalka@redhat.com>
3706         * include/std/concepts (convertible_to): Just use declval as per
3707         LWG 3557.
3709 2021-06-18  Jonathan Wakely  <jwakely@redhat.com>
3711         PR libstdc++/95833
3712         * include/std/numeric (reduce(Iter, Iter, T, BinaryOp)): Replace
3713         incorrect static_assert with ones matching the 'Mandates'
3714         conditions in the standard.
3715         * testsuite/26_numerics/reduce/95833.cc: New test.
3717 2021-06-18  Jonathan Wakely  <jwakely@redhat.com>
3719         * testsuite/21_strings/basic_string/cons/char/1.cc: Use
3720         diagnostic pragma to suppress -Wstringop-overread error.
3722 2021-06-18  Patrick Palka  <ppalka@redhat.com>
3724         * include/bits/ranges_algo.h (__find_fn, find, __find_if_fn)
3725         (find_if, __find_if_not_fn, find_if_not, _in_in_result)
3726         (__mismatch_fn, mismatch, __search_fn, search): Move to ...
3727         * include/bits/ranges_util.h: ... here.
3728         * include/std/ranges (__detail::find, __detail::find_if)
3729         (__detail::find_if_not, __detail::mismatch): Remove.
3730         (filter_view): Use ranges::find_if instead.
3731         (drop_while_view): Use ranges::find_if_not instead.
3732         (split_view): Use ranges::find and ranges::mismatch instead.
3734 2021-06-18  Patrick Palka  <ppalka@redhat.com>
3736         * include/bits/iterator_concepts.h (weakly_incrementable): Remove
3737         default_initializable requirement.
3738         * include/bits/ranges_base.h (ranges::view): Likewise.
3739         * include/bits/ranges_util.h (subrange): Constrain the default
3740         ctor.
3741         * include/bits/stl_iterator.h (back_insert_iterator): Remove the
3742         default ctor.
3743         (front_insert_iterator): Likewise.
3744         (insert_iterator): Likewise.  Remove NSDMIs.
3745         (common_iterator): Constrain the default ctor.
3746         (counted_iterator): Likewise.
3747         * include/bits/stream_iterator.h (ostream_iterator): Remove the
3748         default ctor.
3749         * include/std/ranges (__detail::__box::operator=): Handle
3750         self-assignment in the primary template.
3751         (__detail::__box): In the partial specialization: adjust
3752         constraints as per P2325.  Add specialized operator= for the
3753         case when the wrapped type is not copyable.  Constrain the
3754         default ctor.  Avoid list-initialization.
3755         (single_view): Constraint the default ctor.
3756         (iota_view): Relax semiregular constraint to copyable.
3757         Constrain the default ctor.
3758         (iota_view::_Iterator): Constraint the default ctor.
3759         (basic_istream_view): Remove the default ctor.  Remove NSDMIs.
3760         Remove redundant checks for empty _M_stream.
3761         (basic_istream_view::_Iterator): Likewise.
3762         (ref_view): Remove the default ctor.  Remove NSDMIs.
3763         (ref_view::_Iterator): Constrain the default ctor.
3764         (__detail::__non_propagating_cache::operator=): Define overload
3765         for assigning from a value of the underlying type.
3766         (filter_view): Likewise.
3767         (filter_view::_Iterator): Likewise.
3768         (transform_view): Likewise.
3769         (transform_view::_Iterator): Likewise.
3770         (take_view): Likewise.
3771         (take_view::_Iterator): Likewise.
3772         (take_while_view): Likewise.
3773         (take_while_view::_Iterator): Likewise.
3774         (drop_while_view): Likewise.
3775         (drop_while_view::_Iterator): Likewise.
3776         (join_view): Likewise.
3777         (split_view::_OuterIter::__current): Adjust after changing the
3778         type of _M_current.
3779         (split_view::_M_current): Wrap it in a __non_propagating_cache.
3780         (split_view::split_view): Constrain the default ctor.
3781         (common_view): Constrain the default ctor.
3782         (reverse_view): Likewise.
3783         (elements_view): Likewise.
3784         * include/std/span (enable_view<span<_ElementType, _Extent>>):
3785         Define this partial specialization to true unconditionally.
3786         * include/std/version (__cpp_lib_ranges): Adjust value.
3787         * testsuite/24_iterators/back_insert_iterator/constexpr.cc:
3788         Don't attempt to default construct a back_insert_iterator.
3789         * testsuite/24_iterators/front_insert_iterator/constexpr.cc:
3790         Don't attempt to default construct a front_insert_iterator.
3791         * testsuite/24_iterators/insert_iterator/constexpr.cc:
3792         Don't attempt to default construct an insert_iterator.
3793         * testsuite/24_iterators/ostream_iterator/requirements/constexpr.cc:
3794         Remove this test for default constructibility of ostream_iterator.
3795         * testsuite/std/ranges/97600.cc: Don't attempt to default
3796         construct a basic_istream_view.
3797         * testsuite/std/ranges/adaptors/detail/semiregular_box.cc:
3798         Rename to ...
3799         * testsuite/std/ranges/adaptors/detail/copyable_box.cc: ... this.
3800         (test02): Adjust now that __box is copyable-box not
3801         semiregular-box.
3802         (test03): New test.
3803         * testsuite/std/ranges/p2325.cc: New test.
3804         * testsuite/std/ranges/single_view.cc (test06): New test.
3805         * testsuite/std/ranges/view.cc: Adjust now that view doesn't
3806         require default_initializable.
3808 2021-06-17  Jonathan Wakely  <jwakely@redhat.com>
3810         PR libstdc++/91488
3811         * include/bits/basic_string.h (__cpp_lib_constexpr_string): Only
3812         define when is_constant_evaluated is available.
3813         * include/bits/char_traits.h (__cpp_lib_constexpr_char_traits):
3814         Likewise.
3815         (__constant_string_p, __constant_array_p): Remove.
3816         (char_traits): Use is_constant_evaluated directly.
3817         * include/std/version (__cpp_lib_constexpr_char_traits)
3818         (__cpp_lib_constexpr_string): Only define when
3819         is_constant_evaluated is available.
3821 2021-06-17  Patrick Palka  <ppalka@redhat.com>
3823         PR libstdc++/100940
3824         * include/std/ranges (__adaptor::_Partial): For the "simple"
3825         forwarding partial specializations, also require that
3826         the extra arguments are trivially copyable.
3827         * testsuite/std/ranges/adaptors/100577.cc (test04): New test.
3829 2021-06-17  Patrick Palka  <ppalka@redhat.com>
3831         PR libstdc++/100940
3832         * include/std/ranges (__adaptor::_RangeAdaptor): Document the
3833         template form of _S_has_simple_extra_args.
3834         (__adaptor::__adaptor_has_simple_extra_args): Add _Args template
3835         parameter pack.  Try to treat _S_has_simple_extra_args as a
3836         variable template parameterized by _Args.
3837         (__adaptor::_Partial): Pass _Arg/_Args to the constraint
3838         __adaptor_has_simple_extra_args.
3839         (views::_Take::_S_has_simple_extra_args): Templatize according
3840         to the type of the extra argument.
3841         (views::_Drop::_S_has_simple_extra_args): Likewise.
3842         (views::_Split::_S_has_simple_extra_args): Define.
3843         * testsuite/std/ranges/adaptors/100577.cc (test01, test02):
3844         Adjust after changes to _S_has_simple_extra_args mechanism.
3845         (test03): Define.
3847 2021-06-16  Jonathan Wakely  <jwakely@redhat.com>
3849         * include/bits/iterator_concepts.h (__decay_copy): Name type.
3851 2021-06-16  Jonathan Wakely  <jwakely@redhat.com>
3853         * include/bits/ranges_base.h (ranges::begin, ranges::end)
3854         (ranges::cbegin, ranges::cend, ranges::rbeing, ranges::rend)
3855         (ranges::crbegin, ranges::crend, ranges::size, ranges::ssize)
3856         (ranges::empty, ranges::data, ranges::cdata): Remove final
3857         keywords and deleted operator& overloads.
3858         * testsuite/24_iterators/customization_points/iter_move.cc: Use
3859         new is_customization_point_object function.
3860         * testsuite/24_iterators/customization_points/iter_swap.cc:
3861         Likewise.
3862         * testsuite/std/concepts/concepts.lang/concept.swappable/swap.cc:
3863         Likewise.
3864         * testsuite/std/ranges/access/begin.cc: Likewise.
3865         * testsuite/std/ranges/access/cbegin.cc: Likewise.
3866         * testsuite/std/ranges/access/cdata.cc: Likewise.
3867         * testsuite/std/ranges/access/cend.cc: Likewise.
3868         * testsuite/std/ranges/access/crbegin.cc: Likewise.
3869         * testsuite/std/ranges/access/crend.cc: Likewise.
3870         * testsuite/std/ranges/access/data.cc: Likewise.
3871         * testsuite/std/ranges/access/empty.cc: Likewise.
3872         * testsuite/std/ranges/access/end.cc: Likewise.
3873         * testsuite/std/ranges/access/rbegin.cc: Likewise.
3874         * testsuite/std/ranges/access/rend.cc: Likewise.
3875         * testsuite/std/ranges/access/size.cc: Likewise.
3876         * testsuite/std/ranges/access/ssize.cc: Likewise.
3877         * testsuite/util/testsuite_iterators.h
3878         (is_customization_point_object): New function.
3880 2021-06-15  Jonathan Wakely  <jwakely@redhat.com>
3882         * include/bits/ranges_base.h (ranges::begin, ranges::end)
3883         (ranges::cbegin, ranges::cend, ranges::rbeing, ranges::rend)
3884         (ranges::crbegin, ranges::crend, ranges::size, ranges::ssize)
3885         (ranges::empty, ranges::data, ranges::cdata): Make types final.
3886         Add deleted operator& overloads.
3887         (ranges::advance, ranges::distance, ranges::next, ranges::prev):
3888         Likewise.
3889         * testsuite/std/ranges/headers/ranges/synopsis.cc: Replace
3890         ill-formed & expressions with using-declarations. Add checks for
3891         other function objects.
3893 2021-06-15  Jonathan Wakely  <jwakely@redhat.com>
3895         * include/bits/ranges_util.h (view_interface): Add noexcept to
3896         empty, operator bool, data and size members.
3897         (subrange): Add noexcept to constructors.
3898         * include/std/ranges (single_view, ref_view): Add noexcept to
3899         constructors.
3900         (views::single, views::all): Add noexcept.
3901         * testsuite/std/ranges/adaptors/all.cc: Check noexcept.
3902         * testsuite/std/ranges/single_view.cc: Likewise.
3904 2021-06-15  Jonathan Wakely  <jwakely@redhat.com>
3906         * include/bits/ranges_util.h (subrange): Add __size_type typedef
3907         and use it to simplify declarations.
3908         (subrange(i, s, n)): Remove assertion.
3909         * testsuite/std/ranges/subrange/constexpr.cc: New test.
3911 2021-06-15  Jonathan Wakely  <jwakely@redhat.com>
3913         * include/bits/iterator_concepts.h (__cust_access::__decay_copy):
3914         Replace with function object.
3915         (__cust_access::__member_begin, ___cust_access::_adl_begin): Use
3916         __decay_copy unqualified.
3917         * include/bits/ranges_base.h (__member_end, __adl_end):
3918         Likewise. Use __range_iter_t for type of ranges::begin.
3919         (__member_rend): Use correct value category for rbegin argument.
3920         (__member_data): Use __decay_copy unqualified.
3921         (__begin_data): Use __range_iter_t for type of ranges::begin.
3923 2021-06-14  Jonathan Wakely  <jwakely@redhat.com>
3925         * include/bits/ranges_base.h (ranges::empty): Check whether
3926         conversion to bool can throw.
3927         * testsuite/std/ranges/access/empty.cc: Check for correct
3928         noexcept-specifier.
3930 2021-06-14  Jonathan Wakely  <jwakely@redhat.com>
3932         PR libstdc++/100894
3933         * include/std/type_traits (__common_ref_impl<X&, Y&>): Only
3934         use the type if it's a reference.
3935         * testsuite/20_util/common_reference/100894.cc: New test.
3937 2021-06-14  Jonathan Wakely  <jwakely@redhat.com>
3939         * testsuite/experimental/filesystem/path/native/conv_c++23.cc:
3940         Add dg-require-filesystem-ts directive.
3942 2021-06-14  Jonathan Wakely  <jwakely@redhat.com>
3944         PR libstdc++/101034
3945         * include/std/any (any(in_place_t<T>, initializer_list<U>, A&&...))
3946         (any::emplace<T>(initializer_list<U>, A&&...)): Fix constraint
3947         to use lvalue.
3948         * testsuite/20_util/any/cons/101034.cc: New test.
3950 2021-06-14  Jonathan Wakely  <jwakely@redhat.com>
3952         * testsuite/17_intro/headers/c++2017/all_attributes.cc: Add
3953         -std=gnu++17 option.
3955 2021-06-14  Jonathan Wakely  <jwakely@redhat.com>
3957         PR libstdc++/101056
3958         * libsupc++/compare (compare_partial_order_fallback): Add
3959         constraint using reversed parameter order, as per LWG 3465.
3960         * testsuite/18_support/comparisons/algorithms/fallback.cc:
3961         Adjust expected result.
3963 2021-06-14  Jonathan Wakely  <jwakely@redhat.com>
3965         * libsupc++/compare (__decayed_same_as): New helper concept.
3966         (strong_order, weak_order, partial_order): Constrain with new
3967         concept instead of using static_assert.
3968         (compare_strong_order_fallback, compare_weak_order_fallback)
3969         (compare_partial_order_fallback): Likewise. Do not deduce return
3970         types. Remove redundant if-constexpr checks.
3971         * testsuite/18_support/comparisons/algorithms/fallback.cc: New test.
3973 2021-06-14  Jonathan Wakely  <jwakely@redhat.com>
3975         PR libstdc++/101055
3976         * include/std/tuple: Use reserved form of attribute name.
3977         * testsuite/17_intro/headers/c++2011/all_attributes.cc: Add
3978         check for no_unique_address.
3979         * testsuite/17_intro/headers/c++2014/all_attributes.cc:
3980         Likewise.
3981         * testsuite/17_intro/headers/c++2017/all_attributes.cc:
3982         Likewise.
3984 2021-06-11  Jonathan Wakely  <jwakely@redhat.com>
3986         * include/bits/fs_path.h (operator==, operator<=>): Use new
3987         _S_compare function.
3988         (path::_S_compare): New function to call path::compare in a
3989         context where path::iterator is complete.
3990         * include/experimental/bits/fs_path.h (operator<, operator==):
3991         Define after path::iterator is complete.
3992         * testsuite/27_io/filesystem/path/native/conv_c++23.cc: New
3993         test.
3994         * testsuite/experimental/filesystem/path/native/conv_c++23.cc:
3995         New test.
3997 2021-06-09  Thomas Rodgers  <rodgert@appliantology.com>
3999         * testsuite/29_atomics/atomic_ref/wait_notify.cc: Guard
4000         test logic with constexpr check for is_always_lock_free.
4002 2021-06-09  Jonathan Wakely  <jwakely@redhat.com>
4004         PR libstdc++/100982
4005         * include/std/optional (optional::operator=(const optional<U>&)):
4006         Fix value category used in is_assignable check.
4007         * testsuite/20_util/optional/assignment/100982.cc: New test.
4009 2021-06-09  Jonathan Wakely  <jwakely@redhat.com>
4011         * include/bits/allocator.h (allocator::is_always_equal): Deprecate.
4012         * include/bits/iterator_concepts.h (indirectly_readable_traits):
4013         Add LWG issue number to comment.
4014         * include/std/memory_resource (polymorphic_allocator::release):
4015         Deprecate.
4016         * testsuite/20_util/allocator/requirements/typedefs.cc: Add
4017         dg-warning for deprecation. Also check std::allocator<void>.
4019 2021-06-08  Thomas Rodgers  <rodgert@appliantology.com>
4021         PR libstdc++/100889
4022         * include/bits/atomic_base.h (atomic_ref<_Tp*>::wait):
4023         Change parameter type from _Tp to _Tp*.
4024         * testsuite/29_atomics/atomic_ref/wait_notify.cc: Extend
4025         coverage of types tested.
4027 2021-06-08  Thomas Rodgers  <rodgert@appliantology.com>
4029         * include/std/barrier (__tree_barrier::_M_arrive): Remove
4030         unnecessary hasher instantiation.
4032 2021-06-08  Jonathan Wakely  <jwakely@redhat.com>
4034         * include/experimental/propagate_const (swap): Constrain.
4035         * testsuite/experimental/propagate_const/swap/lwg3413.cc: New test.
4037 2021-06-07  Avi Kivity  <avi@scylladb.com>
4039         PR libstdc++/100900
4040         * include/std/ranges (elements_view::__iter_cat::_S_iter_cat):
4041         Add missing typename.
4043 2021-06-07  Jonathan Wakely  <jwakely@redhat.com>
4045         PR libstdc++/98842
4046         * include/std/optional (operator<=>(const optional<T>& const U&)):
4047         Add missing constraint and add workaround for template
4048         recursion.
4049         * testsuite/20_util/optional/relops/three_way.cc: Check that
4050         type without equality comparison cannot be compared when wrapped
4051         in std::optional.
4053 2021-06-05  Jonathan Wakely  <jwakely@redhat.com>
4055         PR libstdc++/100824
4056         * include/bits/ranges_base.h (_SSize): Return signed type.
4057         * testsuite/std/ranges/access/ssize.cc: Check with __int128.
4059 2021-06-04  Jonathan Wakely  <jwakely@redhat.com>
4061         * include/bits/ranges_base.h (_SSize): Return the result of
4062         ranges::size converted to the wider of make-signed-like-t<S> and
4063         ptrdiff_t, rather than the ranges different type.
4064         * testsuite/std/ranges/access/ssize.cc: Adjust expected result
4065         for an iota_view that uses an integer class type for its
4066         difference_type.
4068 2021-06-04  Jonathan Wakely  <jwakely@redhat.com>
4070         PR libstdc++/100824
4071         * include/bits/ranges_base.h (__member_data): Use __decay_copy.
4072         * testsuite/std/ranges/access/data.cc: Add testcase from PR.
4074 2021-06-04  Jonathan Wakely  <jwakely@redhat.com>
4076         PR libstdc++/100824
4077         * include/bits/iterator_concepts.h (__detail::__decay_copy)
4078         (__detail::__member_begin, __detail::__adl_begin): Move to
4079         namespace ranges::__cust_access.
4080         (__detail::__ranges_begin): Likewise, and rename to __begin.
4081         Remove redundant static assertion.
4082         * include/bits/ranges_base.h (_Begin, _End, _RBegin, _REnd):
4083         Use lvalue in noexcept specifier.
4084         (__as_const): Add non-deduced parameter for value category.
4085         (_CBegin, _CEnd, _CRBegin, _CREnd, _CData): Adjust uses of
4086         __as_const.
4087         (__member_size, __adl_size, __member_empty, __size0_empty):
4088         (__eq_iter_empty, __adl_data): Use lvalue objects in
4089         requirements.
4090         (__sentinel_size): Likewise. Add check for conversion to
4091         unsigned-like.
4092         (__member_data): Allow non-lvalue types to satisfy the concept,
4093         but use lvalue object in requirements.
4094         (_Size, _SSize): Remove forwarding to always use an lvalue.
4095         (_Data): Likewise. Add static assertion for arrays.
4096         * testsuite/std/ranges/access/cdata.cc: Adjust expected
4097         behaviour for rvalues. Add negative tests for ill-formed
4098         expressions.
4099         * testsuite/std/ranges/access/data.cc: Likewise.
4100         * testsuite/std/ranges/access/empty.cc: Adjust expected
4101         behaviour for rvalues.
4102         * testsuite/std/ranges/access/size.cc: Likewise.
4104 2021-06-04  Tim Adye  <Tim.Adye@cern.ch>
4106         * include/std/any (any::_Manager::_S_access): New static
4107         function to access the contained value.
4108         (any::emplace, __any_caster): Use _S_access member of the
4109         manager type.
4111 2021-06-04  Jonathan Wakely  <jwakely@redhat.com>
4113         * doc/xml/manual/status_cxx2020.xml:
4114         * doc/html/*: Regenerate.
4115         * include/bits/hashtable.h (__cpp_lib_generic_unordered_lookup):
4116         Define.
4117         * include/std/version (__cpp_lib_generic_unordered_lookup):
4118         Define.
4119         * testsuite/23_containers/unordered_map/operations/1.cc: Check
4120         feature test macro.
4121         * testsuite/23_containers/unordered_set/operations/1.cc:
4122         Likewise.
4124 2021-06-03  Patrick Palka  <ppalka@redhat.com>
4126         * include/bits/ranges_algo.h (__detail::__can_reread_output):
4127         Factor out this concept from ...
4128         (__unique_copy_fn::operator()): ... here.  Use the concept
4129         throughout.
4130         * testsuite/std/ranges/range.cc: Remove now ill-formed use
4131         of range_value_t on an output_range.
4132         * testsuite/util/testsuite_iterators.h (output_iterator_wrapper):
4133         Define value_type, pointer and reference member types to void.
4135 2021-06-03  Patrick Palka  <ppalka@redhat.com>
4137         PR libstdc++/100577
4138         * include/std/ranges (_RangeAdaptorClosure): Document
4139         _S_has_simple_call_op mechanism.
4140         (_RangeAdaptor): Document _S_has_simple_extra_args mechanism.
4141         (__closure_has_simple_call_op): New concept.
4142         (__adaptor_has_simple_extra_args): Likewise.
4143         (_Partial<_Adaptor, _Args...>): New partial specialization.
4144         (_Partial<_Adaptor, _Arg>): Likewise.
4145         (_Pipe<_Lhs, _Rhs>): Likewise.
4146         (views::_All::_S_has_simple_call_op): Define to true.
4147         (views::_Filter::_S_has_simple_extra_args): Likewise.
4148         (views::_Transform::_S_has_simple_extra_args): Likewise.
4149         (views::_Take::_S_has_simple_extra_args): Likewise.
4150         (views::_TakeWhile::_S_has_simple_extra_args): Likewise.
4151         (views::_Drop::_S_has_simple_extra_args): Likewise.
4152         (views::_DropWhile::_S_has_simple_extra_args): Likewise.
4153         (views::_Join::_S_has_simple_call_op): Likewise.
4154         (views::_Split): Document why we don't define
4155         _S_has_simple_extra_args to true for this adaptor.
4156         (views::_Common::_S_has_simple_call_op): Define to true.
4157         (views::_Reverse::_S_has_simple_call_op): Likewise.
4158         (views::_Elements::_S_has_simple_call_op): Likewise.
4159         * testsuite/std/ranges/adaptors/100577.cc: New test.
4161 2021-06-02  Jonathan Wakely  <jwakely@redhat.com>
4163         PR libstdc++/100863
4164         PR libstdc++/65816
4165         * include/bits/hashtable_policy.h (_Hashtable_ebo_helper):
4166         Value-initialize subobject.
4167         * testsuite/23_containers/unordered_map/allocator/default_init.cc:
4168         Remove XFAIL.
4169         * testsuite/23_containers/unordered_set/allocator/default_init.cc:
4170         Remove XFAIL.
4172 2021-06-02  Jonathan Wakely  <jwakely@redhat.com>
4174         PR libstdc++/96088
4175         * testsuite/23_containers/unordered_map/96088.cc: Adjust
4176         expected number of allocations.
4177         * testsuite/23_containers/unordered_set/96088.cc: Likewise.
4179 2021-06-02  Jonathan Wakely  <jwakely@redhat.com>
4181         * doc/xml/manual/status_cxxis29124.xml: Improve punctuation.
4182         * doc/xml/manual/status_cxxtr1.xml: Likewise.
4183         * doc/xml/manual/status_cxxtr24733.xml: Likewise.
4184         * doc/html/*: Regenerate.
4186 2021-06-01  Patrick Palka  <ppalka@redhat.com>
4188         PR c++/65816
4189         * testsuite/23_containers/deque/allocator/default_init.cc,
4190         testsuite/23_containers/forward_list/allocator/default_init.cc,
4191         testsuite/23_containers/list/allocator/default_init.cc,
4192         testsuite/23_containers/map/allocator/default_init.cc,
4193         testsuite/23_containers/set/allocator/default_init.cc,
4194         testsuite/23_containers/vector/allocator/default_init.cc,
4195         testsuite/23_containers/vector/bool/allocator/default_init.cc:
4196         Remove xfail.
4198 2021-06-01  Jonathan Wakely  <jwakely@redhat.com>
4200         * testsuite/23_containers/unordered_map/96088.cc: Change
4201         effective target to c++17.
4202         * testsuite/23_containers/unordered_set/96088.cc: Likewise.
4204 2021-06-01  Jonathan Wakely  <jwakely@redhat.com>
4206         * testsuite/22_locale/ctype/is/string/89728_neg.cc: Only test
4207         isblank for C++11 and later.
4209 2021-06-01  Jonathan Wakely  <jwakely@redhat.com>
4211         PR libstdc++/100833
4212         * include/bits/ranges_base.h (ranges::advance(iter, n, sentinel)):
4213         Fix return value for no-op case.
4214         * testsuite/24_iterators/range_operations/advance.cc: Test
4215         return values of three-argument overload.
4217 2021-06-01  Jonathan Wakely  <jwakely@redhat.com>
4219         PR libstdc++/99453
4220         * python/Makefile.am: Use archive name for printer hook if no
4221         dynamic library name is available.
4222         * python/Makefile.in: Regenerate.
4224 2021-05-30  Gerald Pfeifer  <gerald@pfeifer.com>
4226         * doc/xml/manual/abi.xml: Remove dead reference to "Intel
4227         Compilers for Linux: Compatibility with GNU Compilers" article.
4228         * doc/html/manual/abi.html: Regenerate.
4230 2021-05-26  François Dumont  <fdumont@gcc.gnu.org>
4232         * include/debug/formatter.h
4233         (_Error_formatter::_Parameter::_Named): New.
4234         (_Error_formatter::_Parameter::_Type): Inherit latter.
4235         (_Error_formatter::_Parameter::_M_integer): Likewise.
4236         (_Error_formatter::_Parameter::_M_string): Likewise.
4237         * src/c++11/debug.cc: Include <cstring>.
4238         (_Print_func_t): New.
4239         (print_raw(PrintContext&, const char*, ptrdiff_t)): New.
4240         (print_word): Use '%.*s' format in fprintf to render only expected number of chars.
4241         (pretty_print(PrintContext&, const char*, _Print_func_t)): New.
4242         (print_type): Rename in...
4243         (print_type_info): ...this. Use pretty_print.
4244         (print_address, print_integer): New.
4245         (print_named_name, print_iterator_constness, print_iterator_state): New.
4246         (print_iterator_seq_type): New.
4247         (print_named_field, print_type_field, print_instance_field, print_iterator_field): New.
4248         (print_field): Use latters.
4249         (print_quoted_named_name, print_type_type, print_type, print_instance): New.
4250         (print_string(PrintContext&, const char*, const _Parameter*, size_t)):
4251         Change signature to...
4252         (print_string(PrintContext&, const char*, ptrdiff_t, const _Parameter*, size_t)):
4253         ...this and adapt. Remove intermediate buffer to render input string.
4254         (print_string(PrintContext&, const char*, ptrdiff_t)): New.
4256 2021-05-26  Jonathan Wakely  <jwakely@redhat.com>
4258         PR libstdc++/100768
4259         * include/bits/ranges_base.h (advance, distance, next, prev):
4260         Replace function templates with function objects.
4261         * testsuite/24_iterators/headers/iterator/synopsis_c++20.cc:
4262         Adjust for changes to function objects.
4263         * testsuite/std/ranges/adaptors/elements.cc: Add using
4264         declarations for names from namespace ranges.
4265         * testsuite/std/ranges/adaptors/transform.cc: Likewise.
4266         * testsuite/24_iterators/range_operations/100768.cc: New test.
4268 2021-05-24  François Dumont  <fdumont@gcc.gnu.org>
4270         PR libstdc++/96088
4271         * include/bits/hashtable_policy.h (_Select2nd): New.
4272         (_NodeBuilder<>): New.
4273         (_ReuseOrAllocNode<>::operator()): Use variadic template args.
4274         (_AllocNode<>::operator()): Likewise.
4275         * include/bits/hashtable.h
4276         (_Hashtable<>::__node_builder_t): New.
4277         (_Hashtable<>::_M_insert_unique<>(_Kt&&, _Arg&&, const _NodeGenerator&)):
4278          New.
4279         (_Hashtable<>::_S_forward_key): New.
4280         (_Hashtable<>::_M_insert): Use latter.
4281         (_Hashtable<>::_M_insert(const_iterator, _Arg&&, const _NodeGenerator&, false_type)):
4282         Instantiate node first, compute hash code second.
4283         * testsuite/23_containers/unordered_map/96088.cc: New test.
4284         * testsuite/23_containers/unordered_multimap/96088.cc: New test.
4285         * testsuite/23_containers/unordered_multiset/96088.cc: New test.
4286         * testsuite/23_containers/unordered_set/96088.cc: New test.
4287         * testsuite/util/replacement_memory_operators.h
4288         (counter::_M_increment): New.
4289         (counter::_M_decrement): New.
4290         (counter::reset()): New.
4292 2021-05-24  Patrick Palka  <ppalka@redhat.com>
4294         PR libstdc++/100479
4295         * include/std/ranges (__detail::__non_propagating_cache): Move
4296         definition up to before that of _CachedPosition.  Make base
4297         class _Optional_base protected instead of private.  Add const
4298         overload for operator*.
4299         (__detail::_CachedPosition): Rewrite the partial specialization
4300         for forward ranges as a derived class of __non_propagating_cache.
4301         Remove the size constraint on the partial specialization for
4302         random access ranges.  Add copy/move/copy-assignment/move-assignment
4303         members to the offset partial specialization for random
4304         access ranges that propagate the cached value but additionally
4305         invalidate it in the source object on move.
4306         * testsuite/std/ranges/adaptors/100479.cc: New test.
4308 2021-05-24  Jonathan Wakely  <jwakely@redhat.com>
4310         * testsuite/25_algorithms/inplace_merge/constrained.cc: Qualify
4311         call to ranges::next.
4312         * testsuite/25_algorithms/is_sorted/constrained.cc: Likewise.
4313         * testsuite/25_algorithms/is_sorted_until/constrained.cc:
4314         Likewise.
4315         * testsuite/25_algorithms/swap_ranges/1.cc: Qualify call to
4316         swap_ranges.
4318 2021-05-21  Patrick Palka  <ppalka@redhat.com>
4320         PR libstdc++/100606
4321         * include/std/ranges (drop_while_view::begin): Assert the
4322         precondition added by LWG 3490.
4324 2021-05-21  Patrick Palka  <ppalka@redhat.com>
4326         PR libstdc++/100690
4327         * include/std/ranges (iota_view::_Sentinel::_M_distance_from):
4328         Split out this member function from ...
4329         (iota_view::_Sentinel::operator-): ... here, for sake of access
4330         control.
4331         * testsuite/std/ranges/iota/iota_view.cc (test05): New test.
4333 2021-05-20  Jonathan Wakely  <jwakely@redhat.com>
4335         * include/bits/random.tcc (__representable_as_double)
4336         (__p1_representable_as_double): Add "" to static asserts.
4338 2021-05-20  Jonathan Wakely  <jwakely@redhat.com>
4340         PR libstdc++/100676
4341         * include/bits/c++config (__glibcxx_assert_1): Rename to ...
4342         (__glibcxx_constexpr_assert): ... this.
4343         (__glibcxx_assert_impl): Use __glibcxx_constexpr_assert.
4344         (__glibcxx_assert): Define as either __glibcxx_constexpr_assert
4345         or __glibcxx_assert_impl.
4346         (__glibcxx_assert_2): Remove
4347         * include/debug/macros.h (_GLIBCXX_DEBUG_VERIFY_AT_F): Use
4348         __glibcxx_constexpr_assert instead of __glibcxx_assert_1.
4349         * testsuite/21_strings/basic_string_view/element_access/char/back_constexpr_neg.cc:
4350         Adjust expected error.
4351         * testsuite/21_strings/basic_string_view/element_access/char/constexpr_neg.cc:
4352         Likewise.
4353         * testsuite/21_strings/basic_string_view/element_access/char/front_constexpr_neg.cc:
4354         Likewise.
4355         Likewise.
4356         * testsuite/21_strings/basic_string_view/element_access/wchar_t/back_constexpr_neg.cc:
4357         Likewise.
4358         * testsuite/21_strings/basic_string_view/element_access/wchar_t/constexpr_neg.cc:
4359         Likewise.
4360         * testsuite/21_strings/basic_string_view/element_access/wchar_t/front_constexpr_neg.cc:
4361         Likewise.
4362         * testsuite/23_containers/span/back_neg.cc: Likewise.
4363         * testsuite/23_containers/span/front_neg.cc: Likewise.
4364         * testsuite/23_containers/span/index_op_neg.cc: Likewise.
4366 2021-05-20  Patrick Palka  <ppalka@redhat.com>
4368         PR libstdc++/100639
4369         * include/bits/stl_iterator.h (reverse_iterator::difference_type):
4370         In C++20 mode, define in terms of iter_difference_t as per P0896R4.
4371         (reverse_iterator::reference): Likewise, but with iter_reference_t.
4372         (reverse_iterator::value_type): Likewise, but with iter_value_t.
4373         * testsuite/std/ranges/adaptors/reverse.cc (test08): New test.
4374         * testsuite/24_iterators/reverse_iterator/100639.cc: New test.
4376 2021-05-20  Joern Rennecke  <joern.rennecke@riscy-ip.com>
4378         PR libstdc++/100361
4379         * include/std/charconv (to_chars): Hide the overloads for
4380         floating-point types for 16 bit targets.
4381         * src/c++17/floating_to_chars.cc: Don't compile for 16 bit targets.
4382         * testsuite/20_util/to_chars/double.cc: Run this test only on
4383         size32plus targets.
4384         * testsuite/20_util/to_chars/float.cc: Likewise.
4385         * testsuite/20_util/to_chars/long_double.cc: Likewise.
4387 2021-05-18  Patrick Palka  <ppalka@redhat.com>
4389         PR libstdc++/100631
4390         * include/std/ranges (elements_view::_Sentinel::operator-): Use
4391         _M_distance_from in the other operator- overload too.
4392         * testsuite/std/ranges/adaptors/elements.cc (test06): Augment test.
4394 2021-05-18  Thomas Schwinge  <thomas@codesourcery.com>
4396         * testsuite/lib/prune.exp: Add note about 'dg-note'.
4398 2021-05-18  Patrick Palka  <ppalka@redhat.com>
4400         PR libstdc++/100475
4401         * include/std/ranges (__box::__box): Use non-list-initialization
4402         in member initializer list of in-place constructor of the
4403         partial specialization for semiregular types.
4404         (__box::operator->): Use std::__addressof.
4405         * testsuite/std/ranges/adaptors/detail/semiregular_box.cc
4406         (test02): New test.
4407         * testsuite/std/ranges/single_view.cc (test04): New test.
4409 2021-05-18  Patrick Palka  <ppalka@redhat.com>
4411         PR libstdc++/100621
4412         * include/std/ranges (reverse_view::_S_needs_cached_begin):
4413         Set to true if the underlying non-common random-access range
4414         doesn't have a sized sentinel.
4416 2021-05-18  Patrick Palka  <ppalka@redhat.com>
4418         PR libstdc++/100631
4419         * include/std/ranges (elements_view::_Iterator): Also befriend
4420         _Sentinel<!_Const>.
4421         (elements_view::_Sentinel::_M_equal): Templatize.
4422         (elements_view::_Sentinel::_M_distance_from): Split out from ...
4423         (elements_view::_Sentinel::operator-): ... here.  Depend on
4424         _Base2 instead of _Base in the return type.
4425         * testsuite/std/ranges/adaptors/elements.cc (test06, test07):
4426         New tests.
4428 2021-05-17  Thomas Rodgers  <rodgert@twrodgers.com>
4430         * include/bits/atomic_wait.h (__waiter::_M_do_wait_v): loop
4431         until value change observed.
4432         (__waiter_base::_M_laundered): New member.
4433         (__waiter_base::_M_notify): Check _M_laundered to determine
4434         whether to wake one or all.
4435         (__detail::__atomic_compare): Return true if call to
4436         __builtin_memcmp() == 0.
4437         (__waiter_base::_S_do_spin_v): Adjust predicate.
4438         * testsuite/29_atomics/atomic/wait_notify/100334.cc: New
4439         test.
4441 2021-05-17  Jonathan Wakely  <jwakely@redhat.com>
4443         PR libstdc++/100630
4444         * include/experimental/bits/fs_path.h (__is_constructible_from):
4445         Test construction from a const lvalue, not an rvalue.
4446         * testsuite/27_io/filesystem/path/construct/100630.cc: New test.
4447         * testsuite/experimental/filesystem/path/construct/100630.cc:
4448         New test.
4450 2021-05-17  Antony Polukhin  <antoshkka@gmail.com>
4452         PR libstdc++/89728
4453         * include/bits/locale_facets.h (ctype<basic_string<C,T,A>>):
4454         Declare (but do not define) partial specialization.
4455         * testsuite/22_locale/ctype/is/string/89728_neg.cc: New test.
4457 2021-05-17  Jonathan Wakely  <jwakely@redhat.com>
4459         * include/std/thread (jthread::_S_create): Fix static assert
4460         message.
4461         * testsuite/30_threads/jthread/95989.cc: Re-enable test.
4462         * testsuite/30_threads/jthread/jthread.cc: Do not require
4463         pthread effective target.
4464         * testsuite/30_threads/jthread/2.cc: Moved to...
4465         * testsuite/30_threads/jthread/version.cc: ...here.
4467 2021-05-17  Jonathan Wakely  <jwakely@redhat.com>
4469         * doc/Makefile.am: Simplify doxygen recipes and use --latex_cmd.
4470         * doc/Makefile.in: Regenerate.
4471         * doc/doxygen/user.cfg.in (LATEX_CMD_NAME): Add placeholder
4472         value.
4473         * scripts/run_doxygen (print_usage): Always print to stdout and
4474         do not exit.
4475         (fail): New function for exiting on error.
4476         (parse_options): Handle --latex_cmd. Do not treat --help the
4477         same as errors. Simplify handling of required arguments.
4479 2021-05-12  Jonathan Wakely  <jwakely@redhat.com>
4481         * testsuite/25_algorithms/pstl/alg_nonmodifying/find_end.cc:
4482         Increase dg-timeout-factor to 4. Fix -Wunused-parameter
4483         warnings. Replace bitwise AND with logical AND in loop
4484         condition.
4485         * testsuite/25_algorithms/pstl/alg_nonmodifying/search_n.cc:
4486         Replace bitwise AND with logical AND in loop condition.
4487         * testsuite/util/pstl/test_utils.h: Remove unused parameter
4488         names.
4490 2021-05-11  Patrick Palka  <ppalka@redhat.com>
4492         * src/c++17/ryu/LOCAL_PATCHES: Update.
4493         * src/c++17/ryu/ryu_generic_128.h: Remove extern "C".
4494         Remove declarations for never-defined functions.
4495         * testsuite/20_util/to_chars/4.cc: New test.
4497 2021-05-11  Jonathan Wakely  <jwakely@redhat.com>
4499         * testsuite/20_util/headers/memory/synopsis.cc: Define C++98
4500         alternative for macro.
4501         * testsuite/20_util/shared_ptr/creation/99006.cc: Add effective
4502         target keyword.
4503         * testsuite/25_algorithms/copy/debug/99402.cc: Avoid C++11
4504         syntax.
4506 2021-05-11  Jonathan Wakely  <jwakely@redhat.com>
4508         * include/bits/allocator.h (allocator<void>) [C++20]: Add
4509         missing noexcept to constructor. Restore missing POCMA and
4510         is_always_equal_traits.
4511         [C++17]: Make construct and destroy members private and
4512         declare allocator_traits as a friend.
4513         * include/bits/memoryfwd.h (allocator_traits): Declare.
4514         * include/ext/malloc_allocator.h (malloc_allocator::allocate):
4515         Add nodiscard attribute. Add static assertion for LWG 3307.
4516         * include/ext/new_allocator.h (new_allocator::allocate): Add
4517         static assertion for LWG 3307.
4518         * testsuite/20_util/allocator/void.cc: Check that converting
4519         constructor is noexcept. Check for propagation traits and
4520         size_type and difference_type. Check that pointer and
4521         const_pointer are gone in C++20.
4523 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
4525         * include/std/stop_token: Remove TODO comment.
4527 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
4529         * include/bits/shared_ptr_base.h (__shared_count(unique_ptr&&)):
4530         Initialize a non-reference deleter from an rvalue, as per LWG
4531         3548.
4532         (__shared_ptr::_UniqCompatible): Add missing constraint.
4533         * testsuite/20_util/shared_ptr/cons/lwg3548.cc: New test.
4534         * testsuite/20_util/shared_ptr/cons/unique_ptr_deleter.cc: Check
4535         constraints.
4537 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
4539         * testsuite/17_intro/headers/c++2017/all_attributes.cc: Remove
4540         -std=gnu++17 from dg-options directive.
4541         * testsuite/17_intro/headers/c++2017/all_no_exceptions.cc:
4542         Likewise.
4543         * testsuite/17_intro/headers/c++2017/all_pedantic_errors.cc:
4544         Likewise.
4545         * testsuite/17_intro/headers/c++2017/operator_names.cc:
4546         Likewise.
4547         * testsuite/17_intro/headers/c++2017/parallel_mode.cc: Likewise.
4548         * testsuite/17_intro/headers/c++2017/stdc++.cc: Likewise.
4549         * testsuite/17_intro/headers/c++2017/stdc++_multiple_inclusion.cc:
4550         Likewise.
4551         * testsuite/18_support/aligned_alloc/aligned_alloc.cc: Likewise.
4552         * testsuite/18_support/byte/81076.cc: Likewise.
4553         * testsuite/18_support/byte/global_neg.cc: Likewise.
4554         * testsuite/18_support/byte/ops.cc: Likewise.
4555         * testsuite/18_support/byte/requirements.cc: Likewise.
4556         * testsuite/18_support/headers/cfloat/values_c++17.cc: Likewise.
4557         * testsuite/18_support/launder/1.cc: Likewise.
4558         * testsuite/18_support/launder/nodiscard.cc: Likewise.
4559         * testsuite/18_support/launder/requirements.cc: Likewise.
4560         * testsuite/18_support/launder/requirements_neg.cc: Likewise.
4561         * testsuite/18_support/new_aligned.cc: Likewise.
4562         * testsuite/18_support/uncaught_exceptions/uncaught_exceptions.cc:
4563         Likewise.
4564         * testsuite/19_diagnostics/error_code/is_error_code_v.cc:
4565         Likewise.
4566         * testsuite/19_diagnostics/error_condition/hash.cc: Likewise.
4567         * testsuite/20_util/addressof/requirements/constexpr.cc:
4568         Likewise.
4569         * testsuite/20_util/as_const/1.cc: Likewise.
4570         * testsuite/20_util/as_const/rvalue_neg.cc: Likewise.
4571         * testsuite/20_util/bind/83427.cc: Likewise.
4572         * testsuite/20_util/bind/is_placeholder_v.cc: Likewise.
4573         * testsuite/20_util/bool_constant/requirements.cc: Likewise.
4574         * testsuite/20_util/duration/arithmetic/constexpr_c++17.cc:
4575         Likewise.
4576         * testsuite/20_util/duration/requirements/treat_as_floating_point_v.cc:
4577         Likewise.
4578         * testsuite/20_util/duration_cast/rounding.cc: Likewise.
4579         * testsuite/20_util/enable_shared_from_this/members/weak_from_this.cc:
4580         Likewise.
4581         * testsuite/20_util/from_chars/1_neg.cc: Likewise.
4582         * testsuite/20_util/from_chars/requirements.cc: Likewise.
4583         * testsuite/20_util/function/91456.cc: Likewise.
4584         * testsuite/20_util/function/cons/deduction.cc: Likewise.
4585         * testsuite/20_util/function_objects/83607.cc: Likewise.
4586         * testsuite/20_util/function_objects/invoke/59768.cc: Likewise.
4587         * testsuite/20_util/function_objects/mem_fn/80478.cc: Likewise.
4588         * testsuite/20_util/function_objects/not_fn/1.cc: Likewise.
4589         * testsuite/20_util/function_objects/not_fn/87538.cc: Likewise.
4590         * testsuite/20_util/has_unique_object_representations/requirements/explicit_instantiation.cc:
4591         Likewise.
4592         * testsuite/20_util/has_unique_object_representations/requirements/typedefs.cc:
4593         Likewise.
4594         * testsuite/20_util/has_unique_object_representations/value.cc:
4595         Likewise.
4596         * testsuite/20_util/hash/nullptr.cc: Likewise.
4597         * testsuite/20_util/in_place/requirements.cc: Likewise.
4598         * testsuite/20_util/is_aggregate/incomplete_neg.cc: Likewise.
4599         * testsuite/20_util/is_aggregate/requirements/explicit_instantiation.cc:
4600         Likewise.
4601         * testsuite/20_util/is_aggregate/requirements/typedefs.cc:
4602         Likewise.
4603         * testsuite/20_util/is_aggregate/value.cc: Likewise.
4604         * testsuite/20_util/is_invocable/83395.cc: Likewise.
4605         * testsuite/20_util/is_invocable/91456.cc: Likewise.
4606         * testsuite/20_util/is_invocable/requirements/explicit_instantiation.cc:
4607         Likewise.
4608         * testsuite/20_util/is_invocable/requirements/typedefs.cc:
4609         Likewise.
4610         * testsuite/20_util/is_invocable/value.cc: Likewise.
4611         * testsuite/20_util/is_literal_type/deprecated-1z.cc: Likewise.
4612         * testsuite/20_util/is_nothrow_constructible/94003.cc: Likewise.
4613         * testsuite/20_util/is_nothrow_invocable/83395.cc: Likewise.
4614         * testsuite/20_util/is_nothrow_invocable/requirements/explicit_instantiation.cc:
4615         Likewise.
4616         * testsuite/20_util/is_nothrow_invocable/requirements/typedefs.cc: Likewise.
4617         * testsuite/20_util/is_nothrow_invocable/value.cc: Likewise.
4618         * testsuite/20_util/is_nothrow_swappable/requirements/explicit_instantiation.cc:
4619         Likewise.
4620         * testsuite/20_util/is_nothrow_swappable/requirements/typedefs.cc:
4621         Likewise.
4622         * testsuite/20_util/is_nothrow_swappable/value.cc: Likewise.
4623         * testsuite/20_util/is_nothrow_swappable_with/requirements/explicit_instantiation.cc:
4624         Likewise.
4625         * testsuite/20_util/is_nothrow_swappable_with/requirements/typedefs.cc:
4626         Likewise.
4627         * testsuite/20_util/is_nothrow_swappable_with/value.cc:
4628         Likewise.
4629         * testsuite/20_util/is_swappable/requirements/explicit_instantiation.cc:
4630         Likewise.
4631         * testsuite/20_util/is_swappable/requirements/typedefs.cc:
4632         Likewise.
4633         * testsuite/20_util/is_swappable/value.cc: Likewise.
4634         * testsuite/20_util/is_swappable_with/requirements/explicit_instantiation.cc:
4635         Likewise.
4636         * testsuite/20_util/is_swappable_with/requirements/typedefs.cc:
4637         Likewise.
4638         * testsuite/20_util/is_swappable_with/value.cc: Likewise.
4639         * testsuite/20_util/logical_traits/83134.cc: Likewise.
4640         * testsuite/20_util/logical_traits/requirements/explicit_instantiation.cc:
4641         Likewise.
4642         * testsuite/20_util/logical_traits/requirements/typedefs.cc:
4643         Likewise.
4644         * testsuite/20_util/logical_traits/value.cc: Likewise.
4645         * testsuite/20_util/pair/cons/deduction.cc: Likewise.
4646         * testsuite/20_util/pair/swap_cxx17.cc: Likewise.
4647         * testsuite/20_util/ratio/requirements/ratio_equal_v.cc:
4648         Likewise.
4649         * testsuite/20_util/reference_wrapper/83427.cc: Likewise.
4650         * testsuite/20_util/reference_wrapper/deduction.cc: Likewise.
4651         * testsuite/20_util/shared_ptr/casts/reinterpret.cc: Likewise.
4652         * testsuite/20_util/shared_ptr/cons/deduction.cc: Likewise.
4653         * testsuite/20_util/shared_ptr/requirements/weak_type.cc:
4654         Likewise.
4655         * testsuite/20_util/time_point/arithmetic/constexpr.cc:
4656         Likewise.
4657         * testsuite/20_util/time_point_cast/rounding.cc: Likewise.
4658         * testsuite/20_util/to_chars/3.cc: Likewise.
4659         * testsuite/20_util/to_chars/chars_format.cc: Likewise.
4660         * testsuite/20_util/to_chars/lwg3266.cc: Likewise.
4661         * testsuite/20_util/to_chars/requirements.cc: Likewise.
4662         * testsuite/20_util/tuple/78939.cc: Likewise.
4663         * testsuite/20_util/tuple/apply/1.cc: Likewise.
4664         * testsuite/20_util/tuple/apply/2.cc: Likewise.
4665         * testsuite/20_util/tuple/cons/deduction.cc: Likewise.
4666         * testsuite/20_util/tuple/make_from_tuple/1.cc: Likewise.
4667         * testsuite/20_util/tuple/make_from_tuple/2.cc: Likewise.
4668         * testsuite/20_util/tuple/swap_cxx17.cc: Likewise.
4669         * testsuite/20_util/tuple/tuple_size_v.cc: Likewise.
4670         * testsuite/20_util/unique_ptr/cons/deduction_neg.cc: Likewise.
4671         * testsuite/20_util/uses_allocator/requirements/uses_allocator_v.cc:
4672         Likewise.
4673         * testsuite/20_util/variable_templates_for_traits.cc: Likewise.
4674         * testsuite/20_util/void_t/1.cc: Likewise.
4675         * testsuite/20_util/weak_ptr/cons/deduction.cc: Likewise.
4676         * testsuite/24_iterators/container_access.cc: Likewise.
4677         * testsuite/24_iterators/headers/iterator/range_access_c++17.cc:
4678         Likewise.
4679         * testsuite/24_iterators/headers/iterator/synopsis_c++17.cc:
4680         Likewise.
4681         * testsuite/24_iterators/range_access/range_access_cpp17.cc:
4682         Likewise.
4683         * testsuite/24_iterators/range_access/range_access_cpp17_neg.cc:
4684         Likewise.
4685         * testsuite/26_numerics/gcd/gcd_neg.cc: Likewise.
4686         * testsuite/26_numerics/headers/cmath/functions_std_c++17.cc:
4687         Likewise.
4688         * testsuite/26_numerics/headers/cmath/hypot.cc: Likewise.
4689         * testsuite/26_numerics/headers/cmath/special_functions_global.cc:
4690         Likewise.
4691         * testsuite/26_numerics/lcm/1.cc: Likewise.
4692         * testsuite/26_numerics/lcm/lcm_neg.cc: Likewise.
4693         * testsuite/26_numerics/valarray/deduction.cc: Likewise.
4694         * testsuite/27_io/basic_ostream/inserters_other/char/lwg2221.cc:
4695         Likewise.
4696         * testsuite/27_io/manipulators/standard/char/quoted_sv.cc:
4697         Likewise.
4698         * testsuite/27_io/manipulators/standard/wchar_t/quoted_sv.cc:
4699         Likewise.
4700         * testsuite/27_io/types/4.cc: Likewise.
4701         * testsuite/28_regex/basic_regex/ctors/deduction.cc: Likewise.
4702         * testsuite/libstdc++-prettyprinters/91997.cc: Likewise.
4703         * testsuite/libstdc++-prettyprinters/cxx17.cc: Likewise.
4705 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
4707         * testsuite/20_util/function_objects/searchers.cc: Remove
4708         -std=gnu++17 from dg-options directive.
4709         * testsuite/20_util/specialized_algorithms/memory_management_tools/1.cc:
4710         Likewise.
4711         * testsuite/20_util/specialized_algorithms/memory_management_tools/destroy_neg.cc:
4712         Likewise.
4713         * testsuite/20_util/specialized_algorithms/uninitialized_value_construct/94540.cc:
4714         Likewise.
4715         * testsuite/20_util/specialized_algorithms/uninitialized_value_construct/94831.cc:
4716         Likewise.
4717         * testsuite/20_util/specialized_algorithms/uninitialized_value_construct_n/94540.cc:
4718         Likewise.
4719         * testsuite/20_util/specialized_algorithms/uninitialized_value_construct_n/sizes.cc:
4720         Likewise.
4721         * testsuite/20_util/unique_ptr/specialized_algorithms/swap_cxx17.cc:
4722         Likewise.
4723         * testsuite/25_algorithms/clamp/1.cc: Likewise.
4724         * testsuite/25_algorithms/clamp/2.cc: Likewise.
4725         * testsuite/25_algorithms/clamp/constexpr.cc: Likewise.
4726         * testsuite/25_algorithms/clamp/requirements/explicit_instantiation/1.cc:
4727         Likewise.
4728         * testsuite/25_algorithms/clamp/requirements/explicit_instantiation/pod.cc:
4729         Likewise.
4730         * testsuite/25_algorithms/for_each/for_each_n.cc: Likewise.
4731         * testsuite/25_algorithms/for_each/for_each_n_debug.cc:
4732         Likewise.
4733         * testsuite/25_algorithms/sample/1.cc: Likewise.
4734         * testsuite/25_algorithms/sample/2.cc: Likewise.
4735         * testsuite/25_algorithms/sample/3.cc: Likewise.
4736         * testsuite/25_algorithms/sample/81221.cc: Likewise.
4737         * testsuite/25_algorithms/search/searcher.cc: Likewise.
4738         * testsuite/26_numerics/exclusive_scan/1.cc: Likewise.
4739         * testsuite/26_numerics/inclusive_scan/1.cc: Likewise.
4740         * testsuite/26_numerics/reduce/1.cc: Likewise.
4741         * testsuite/26_numerics/reduce/2.cc: Likewise.
4742         * testsuite/26_numerics/transform_exclusive_scan/1.cc: Likewise.
4743         * testsuite/26_numerics/transform_inclusive_scan/1.cc: Likewise.
4744         * testsuite/26_numerics/transform_reduce/1.cc: Likewise.
4746 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
4748         * testsuite/23_containers/array/cons/deduction.cc: Remove
4749         -std=gnu++17 from dg-options directive.
4750         * testsuite/23_containers/array/cons/deduction_neg.cc: Likewise.
4751         * testsuite/23_containers/array/element_access/constexpr_c++17.cc:
4752         Likewise.
4753         * testsuite/23_containers/array/requirements/constexpr_iter.cc:
4754         Likewise.
4755         * testsuite/23_containers/array/specialized_algorithms/swap_cxx17.cc:
4756         Likewise.
4757         * testsuite/23_containers/deque/cons/deduction.cc: Likewise.
4758         * testsuite/23_containers/deque/modifiers/emplace/cxx17_return.cc:
4759         Likewise.
4760         * testsuite/23_containers/forward_list/cons/deduction.cc:
4761         Likewise.
4762         * testsuite/23_containers/forward_list/modifiers/emplace_cxx17_return.cc:
4763         Likewise.
4764         * testsuite/23_containers/list/cons/deduction.cc: Likewise.
4765         * testsuite/23_containers/list/modifiers/emplace/cxx17_return.cc:
4766         Likewise.
4767         * testsuite/23_containers/map/cons/deduction.cc: Likewise.
4768         * testsuite/23_containers/map/modifiers/extract.cc: Likewise.
4769         * testsuite/23_containers/map/modifiers/insert/83226.cc:
4770         Likewise.
4771         * testsuite/23_containers/map/modifiers/insert_or_assign/1.cc:
4772         Likewise.
4773         * testsuite/23_containers/map/modifiers/merge.cc: Likewise.
4774         * testsuite/23_containers/map/modifiers/try_emplace/1.cc:
4775         Likewise.
4776         * testsuite/23_containers/multimap/cons/deduction.cc: Likewise.
4777         * testsuite/23_containers/multimap/modifiers/extract.cc:
4778         Likewise.
4779         * testsuite/23_containers/multimap/modifiers/merge.cc: Likewise.
4780         * testsuite/23_containers/multiset/cons/deduction.cc: Likewise.
4781         * testsuite/23_containers/multiset/modifiers/extract.cc:
4782         Likewise.
4783         * testsuite/23_containers/multiset/modifiers/merge.cc: Likewise.
4784         * testsuite/23_containers/priority_queue/deduction.cc: Likewise.
4785         * testsuite/23_containers/queue/deduction.cc: Likewise.
4786         * testsuite/23_containers/queue/members/emplace_cxx17_return.cc:
4787         Likewise.
4788         * testsuite/23_containers/set/cons/deduction.cc: Likewise.
4789         * testsuite/23_containers/set/modifiers/extract.cc: Likewise.
4790         * testsuite/23_containers/set/modifiers/merge.cc: Likewise.
4791         * testsuite/23_containers/set/modifiers/node_swap.cc: Likewise.
4792         * testsuite/23_containers/stack/deduction.cc: Likewise.
4793         * testsuite/23_containers/stack/members/emplace_cxx17_return.cc:
4794         Likewise.
4795         * testsuite/23_containers/unordered_map/cons/deduction.cc:
4796         Likewise.
4797         * testsuite/23_containers/unordered_map/modifiers/extract.cc:
4798         Likewise.
4799         * testsuite/23_containers/unordered_map/modifiers/insert_or_assign.cc:
4800         Likewise.
4801         * testsuite/23_containers/unordered_map/modifiers/merge.cc:
4802         Likewise.
4803         * testsuite/23_containers/unordered_map/modifiers/try_emplace.cc:
4804         Likewise.
4805         * testsuite/23_containers/unordered_multimap/cons/deduction.cc:
4806         Likewise.
4807         * testsuite/23_containers/unordered_multimap/modifiers/extract.cc:
4808         Likewise.
4809         * testsuite/23_containers/unordered_multimap/modifiers/merge.cc:
4810         Likewise.
4811         * testsuite/23_containers/unordered_multiset/cons/deduction.cc:
4812         Likewise.
4813         * testsuite/23_containers/unordered_multiset/modifiers/extract.cc:
4814         Likewise.
4815         * testsuite/23_containers/unordered_multiset/modifiers/merge.cc:
4816         Likewise.
4817         * testsuite/23_containers/unordered_set/cons/deduction.cc:
4818         Likewise.
4819         * testsuite/23_containers/unordered_set/modifiers/extract.cc:
4820         Likewise.
4821         * testsuite/23_containers/unordered_set/modifiers/merge.cc:
4822         Likewise.
4823         * testsuite/23_containers/vector/bool/emplace_cxx17_return.cc:
4824         Likewise.
4825         * testsuite/23_containers/vector/cons/89164_c++17.cc: Likewise.
4826         * testsuite/23_containers/vector/cons/deduction.cc: Likewise.
4827         * testsuite/23_containers/vector/modifiers/emplace/cxx17_return.cc:
4828         Likewise.
4830 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
4832         * testsuite/21_strings/basic_string/79162.cc: Remove
4833         -std=gnu++17 from dg-options directive.
4834         * testsuite/21_strings/basic_string/cons/char/7.cc: Likewise.
4835         * testsuite/21_strings/basic_string/cons/char/79162.cc:
4836         Likewise.
4837         * testsuite/21_strings/basic_string/cons/char/86138.cc:
4838         Likewise.
4839         * testsuite/21_strings/basic_string/cons/char/9.cc: Likewise.
4840         * testsuite/21_strings/basic_string/cons/char/deduction.cc:
4841         Likewise.
4842         * testsuite/21_strings/basic_string/cons/char/moveable2_c++17.cc:
4843         Likewise.
4844         * testsuite/21_strings/basic_string/cons/wchar_t/7.cc: Likewise.
4845         * testsuite/21_strings/basic_string/cons/wchar_t/79162.cc:
4846         Likewise.
4847         * testsuite/21_strings/basic_string/cons/wchar_t/86138.cc:
4848         Likewise.
4849         * testsuite/21_strings/basic_string/cons/wchar_t/9.cc: Likewise.
4850         * testsuite/21_strings/basic_string/cons/wchar_t/deduction.cc:
4851         Likewise.
4852         * testsuite/21_strings/basic_string/cons/wchar_t/moveable2_c++17.cc:
4853         Likewise.
4854         * testsuite/21_strings/basic_string/hash/hash.cc: Likewise.
4855         * testsuite/21_strings/basic_string/lwg2758.cc: Likewise.
4856         * testsuite/21_strings/basic_string/lwg2946.cc: Likewise.
4857         * testsuite/21_strings/basic_string/modifiers/append/char/4.cc:
4858         Likewise.
4859         * testsuite/21_strings/basic_string/modifiers/append/wchar_t/4.cc:
4860         Likewise.
4861         * testsuite/21_strings/basic_string/modifiers/assign/char/4.cc:
4862         Likewise.
4863         * testsuite/21_strings/basic_string/modifiers/assign/wchar_t/4.cc:
4864         Likewise.
4865         * testsuite/21_strings/basic_string/modifiers/insert/char/3.cc:
4866         Likewise.
4867         * testsuite/21_strings/basic_string/modifiers/insert/wchar_t/3.cc:
4868         Likewise.
4869         * testsuite/21_strings/basic_string/modifiers/replace/char/7.cc:
4870         Likewise.
4871         * testsuite/21_strings/basic_string/modifiers/replace/wchar_t/7.cc:
4872         Likewise.
4873         * testsuite/21_strings/basic_string/operations/compare/char/2.cc:
4874         Likewise.
4875         * testsuite/21_strings/basic_string/operations/compare/wchar_t/2.cc:
4876         Likewise.
4877         * testsuite/21_strings/basic_string/operations/data/char/2.cc:
4878         Likewise.
4879         * testsuite/21_strings/basic_string/operations/data/char/86169.cc:
4880         Likewise.
4881         * testsuite/21_strings/basic_string/operations/data/wchar_t/2.cc:
4882         Likewise.
4883         * testsuite/21_strings/basic_string/operations/find/char/5.cc:
4884         Likewise.
4885         * testsuite/21_strings/basic_string/operations/find/wchar_t/5.cc:
4886         Likewise.
4887         * testsuite/21_strings/basic_string/operators/char/5.cc:
4888         Likewise.
4889         * testsuite/21_strings/basic_string/operators/wchar_t/5.cc:
4890         Likewise.
4891         * testsuite/21_strings/basic_string_view/capacity/1.cc:
4892         Likewise.
4893         * testsuite/21_strings/basic_string_view/capacity/empty_neg.cc:
4894         Likewise.
4895         * testsuite/21_strings/basic_string_view/cons/char/1.cc:
4896         Likewise.
4897         * testsuite/21_strings/basic_string_view/cons/char/2.cc:
4898         Likewise.
4899         * testsuite/21_strings/basic_string_view/cons/char/3.cc:
4900         Likewise.
4901         * testsuite/21_strings/basic_string_view/cons/char/nonnull.cc:
4902         Likewise.
4903         * testsuite/21_strings/basic_string_view/cons/wchar_t/1.cc:
4904         Likewise.
4905         * testsuite/21_strings/basic_string_view/cons/wchar_t/2.cc:
4906         Likewise.
4907         * testsuite/21_strings/basic_string_view/cons/wchar_t/3.cc:
4908         Likewise.
4909         * testsuite/21_strings/basic_string_view/cons/wchar_t/nonnull.cc:
4910         Likewise.
4911         * testsuite/21_strings/basic_string_view/element_access/char/1.cc:
4912         Likewise.
4913         * testsuite/21_strings/basic_string_view/element_access/char/2.cc:
4914         Likewise.
4915         * testsuite/21_strings/basic_string_view/element_access/char/back_constexpr_neg.cc:
4916         Likewise.
4917         * testsuite/21_strings/basic_string_view/element_access/char/constexpr.cc:
4918         Likewise.
4919         * testsuite/21_strings/basic_string_view/element_access/char/constexpr_neg.cc:
4920         Likewise.
4921         * testsuite/21_strings/basic_string_view/element_access/char/empty.cc:
4922         Likewise.
4923         * testsuite/21_strings/basic_string_view/element_access/char/front_back.cc:
4924         Likewise.
4925         * testsuite/21_strings/basic_string_view/element_access/char/front_back_constexpr.cc:
4926         Likewise.
4927         * testsuite/21_strings/basic_string_view/element_access/char/front_constexpr_neg.cc:
4928         Likewise.
4929         * testsuite/21_strings/basic_string_view/element_access/wchar_t/1.cc:
4930         Likewise.
4931         * testsuite/21_strings/basic_string_view/element_access/wchar_t/2.cc:
4932         Likewise.
4933         * testsuite/21_strings/basic_string_view/element_access/wchar_t/back_constexpr_neg.cc:
4934         Likewise.
4935         * testsuite/21_strings/basic_string_view/element_access/wchar_t/constexpr.cc:
4936         Likewise.
4937         * testsuite/21_strings/basic_string_view/element_access/wchar_t/constexpr_neg.cc:
4938         Likewise.
4939         * testsuite/21_strings/basic_string_view/element_access/wchar_t/empty.cc:
4940         Likewise.
4941         * testsuite/21_strings/basic_string_view/element_access/wchar_t/front_back.cc:
4942         Likewise.
4943         * testsuite/21_strings/basic_string_view/element_access/wchar_t/front_constexpr_neg.cc:
4944         Likewise.
4945         * testsuite/21_strings/basic_string_view/include.cc: Likewise.
4946         * testsuite/21_strings/basic_string_view/inserters/94051.cc:
4947         Likewise.
4948         * testsuite/21_strings/basic_string_view/inserters/char/1.cc:
4949         Likewise.
4950         * testsuite/21_strings/basic_string_view/inserters/char/2.cc:
4951         Likewise.
4952         * testsuite/21_strings/basic_string_view/inserters/char/3.cc:
4953         Likewise.
4954         * testsuite/21_strings/basic_string_view/inserters/pod/10081-out.cc:
4955         Likewise.
4956         * testsuite/21_strings/basic_string_view/inserters/wchar_t/1.cc:
4957         Likewise.
4958         * testsuite/21_strings/basic_string_view/inserters/wchar_t/2.cc:
4959         Likewise.
4960         * testsuite/21_strings/basic_string_view/inserters/wchar_t/3.cc:
4961         Likewise.
4962         * testsuite/21_strings/basic_string_view/literals/types-char8_t.cc:
4963         Likewise.
4964         * testsuite/21_strings/basic_string_view/literals/types.cc:
4965         Likewise.
4966         * testsuite/21_strings/basic_string_view/literals/values-char8_t.cc:
4967         Likewise.
4968         * testsuite/21_strings/basic_string_view/literals/values.cc:
4969         Likewise.
4970         * testsuite/21_strings/basic_string_view/modifiers/remove_prefix/char/1.cc:
4971         Likewise.
4972         * testsuite/21_strings/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc:
4973         Likewise.
4974         * testsuite/21_strings/basic_string_view/modifiers/remove_suffix/char/1.cc:
4975         Likewise.
4976         * testsuite/21_strings/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc:
4977         Likewise.
4978         * testsuite/21_strings/basic_string_view/modifiers/swap/char/1.cc:
4979         Likewise.
4980         * testsuite/21_strings/basic_string_view/modifiers/swap/wchar_t/1.cc:
4981         Likewise.
4982         * testsuite/21_strings/basic_string_view/operations/compare/char/1.cc:
4983         Likewise.
4984         * testsuite/21_strings/basic_string_view/operations/compare/char/13650.cc:
4985         Likewise.
4986         * testsuite/21_strings/basic_string_view/operations/compare/char/2.cc:
4987         Likewise.
4988         * testsuite/21_strings/basic_string_view/operations/compare/char/70483.cc:
4989         Likewise.
4990         * testsuite/21_strings/basic_string_view/operations/compare/char/nonnull.cc:
4991         Likewise.
4992         * testsuite/21_strings/basic_string_view/operations/compare/wchar_t/1.cc:
4993         Likewise.
4994         * testsuite/21_strings/basic_string_view/operations/compare/wchar_t/13650.cc:
4995         Likewise.
4996         * testsuite/21_strings/basic_string_view/operations/compare/wchar_t/2.cc:
4997         Likewise.
4998         * testsuite/21_strings/basic_string_view/operations/copy/char/1.cc:
4999         Likewise.
5000         * testsuite/21_strings/basic_string_view/operations/copy/char/2.cc:
5001         Likewise.
5002         * testsuite/21_strings/basic_string_view/operations/copy/wchar_t/1.cc:
5003         Likewise.
5004         * testsuite/21_strings/basic_string_view/operations/copy/wchar_t/2.cc:
5005         Likewise.
5006         * testsuite/21_strings/basic_string_view/operations/data/char/1.cc:
5007         Likewise.
5008         * testsuite/21_strings/basic_string_view/operations/data/wchar_t/1.cc:
5009         Likewise.
5010         * testsuite/21_strings/basic_string_view/operations/find/char/1.cc:
5011         Likewise.
5012         * testsuite/21_strings/basic_string_view/operations/find/char/2.cc:
5013         Likewise.
5014         * testsuite/21_strings/basic_string_view/operations/find/char/3.cc:
5015         Likewise.
5016         * testsuite/21_strings/basic_string_view/operations/find/char/4.cc:
5017         Likewise.
5018         * testsuite/21_strings/basic_string_view/operations/find/char/nonnull.cc:
5019         Likewise.
5020         * testsuite/21_strings/basic_string_view/operations/find/wchar_t/1.cc:
5021         Likewise.
5022         * testsuite/21_strings/basic_string_view/operations/find/wchar_t/2.cc:
5023         Likewise.
5024         * testsuite/21_strings/basic_string_view/operations/find/wchar_t/3.cc:
5025         Likewise.
5026         * testsuite/21_strings/basic_string_view/operations/find/wchar_t/4.cc:
5027         Likewise.
5028         * testsuite/21_strings/basic_string_view/operations/rfind/char/1.cc:
5029         Likewise.
5030         * testsuite/21_strings/basic_string_view/operations/rfind/char/2.cc:
5031         Likewise.
5032         * testsuite/21_strings/basic_string_view/operations/rfind/char/3.cc:
5033         Likewise.
5034         * testsuite/21_strings/basic_string_view/operations/rfind/char/nonnull.cc:
5035         Likewise.
5036         * testsuite/21_strings/basic_string_view/operations/rfind/wchar_t/1.cc:
5037         Likewise.
5038         * testsuite/21_strings/basic_string_view/operations/rfind/wchar_t/2.cc:
5039         Likewise.
5040         * testsuite/21_strings/basic_string_view/operations/rfind/wchar_t/3.cc:
5041         Likewise.
5042         * testsuite/21_strings/basic_string_view/operations/string_conversion/1.cc:
5043         Likewise.
5044         * testsuite/21_strings/basic_string_view/operations/substr/char/1.cc:
5045         Likewise.
5046         * testsuite/21_strings/basic_string_view/operations/substr/char/83511.cc:
5047         Likewise.
5048         * testsuite/21_strings/basic_string_view/operations/substr/wchar_t/1.cc:
5049         Likewise.
5050         * testsuite/21_strings/basic_string_view/operations/substr/wchar_t/83511.cc:
5051         Likewise.
5052         * testsuite/21_strings/basic_string_view/operators/char/2.cc:
5053         Likewise.
5054         * testsuite/21_strings/basic_string_view/operators/char/89446.cc:
5055         Likewise.
5056         * testsuite/21_strings/basic_string_view/operators/wchar_t/2.cc:
5057         Likewise.
5058         * testsuite/21_strings/basic_string_view/operators/wchar_t/89446.cc:
5059         Likewise.
5060         * testsuite/21_strings/basic_string_view/range_access/char/1.cc:
5061         Likewise.
5062         * testsuite/21_strings/basic_string_view/range_access/wchar_t/1.cc:
5063         Likewise.
5064         * testsuite/21_strings/basic_string_view/requirements/explicit_instantiation/1.cc:
5065         Likewise.
5066         * testsuite/21_strings/basic_string_view/requirements/explicit_instantiation/char/1.cc:
5067         Likewise.
5068         * testsuite/21_strings/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc:
5069         Likewise.
5070         * testsuite/21_strings/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc:
5071         Likewise.
5072         * testsuite/21_strings/basic_string_view/requirements/explicit_instantiation/char8_t/1.cc:
5073         Likewise.
5074         * testsuite/21_strings/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc:
5075         Likewise.
5076         * testsuite/21_strings/basic_string_view/requirements/traits_neg.cc:
5077         Likewise.
5078         * testsuite/21_strings/basic_string_view/requirements/typedefs.cc:
5079         Likewise.
5080         * testsuite/21_strings/basic_string_view/typedefs.cc: Likewise.
5081         * testsuite/21_strings/basic_string_view/types/1.cc: Likewise.
5082         * testsuite/21_strings/char_traits/requirements/char/99181.cc:
5083         Likewise.
5084         * testsuite/21_strings/char_traits/requirements/constexpr_functions_c++17.cc:
5086 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
5088         * testsuite/20_util/memory_resource/1.cc: Remove -std=gnu++17
5089         from dg-options directive.
5090         * testsuite/20_util/memory_resource/2.cc: Likewise.
5091         * testsuite/20_util/monotonic_buffer_resource/1.cc: Likewise.
5092         * testsuite/20_util/monotonic_buffer_resource/93208.cc:
5093         Likewise.
5094         * testsuite/20_util/monotonic_buffer_resource/allocate.cc:
5095         Likewise.
5096         * testsuite/20_util/monotonic_buffer_resource/deallocate.cc:
5097         Likewise.
5098         * testsuite/20_util/monotonic_buffer_resource/release.cc:
5099         Likewise.
5100         * testsuite/20_util/monotonic_buffer_resource/upstream_resource.cc:
5101         Likewise.
5102         * testsuite/20_util/polymorphic_allocator/1.cc: Likewise.
5103         * testsuite/20_util/polymorphic_allocator/construct_pair.cc:
5104         Likewise.
5105         * testsuite/20_util/polymorphic_allocator/resource.cc: Likewise.
5106         * testsuite/20_util/polymorphic_allocator/select.cc: Likewise.
5107         * testsuite/20_util/synchronized_pool_resource/allocate.cc:
5108         Likewise.
5109         * testsuite/20_util/synchronized_pool_resource/allocate_single.cc:
5110         Likewise.
5111         * testsuite/20_util/synchronized_pool_resource/cons.cc:
5112         Likewise.
5113         * testsuite/20_util/synchronized_pool_resource/cons_single.cc:
5114         Likewise.
5115         * testsuite/20_util/synchronized_pool_resource/is_equal.cc:
5116         Likewise.
5117         * testsuite/20_util/synchronized_pool_resource/multithreaded.cc:
5118         Likewise.
5119         * testsuite/20_util/synchronized_pool_resource/options.cc:
5120         Likewise.
5121         * testsuite/20_util/synchronized_pool_resource/release.cc:
5122         Likewise.
5123         * testsuite/20_util/synchronized_pool_resource/release_single.cc:
5124         Likewise.
5125         * testsuite/20_util/unsynchronized_pool_resource/allocate-max-chunks.cc:
5126         Likewise.
5127         * testsuite/20_util/unsynchronized_pool_resource/allocate.cc:
5128         Likewise.
5129         * testsuite/20_util/unsynchronized_pool_resource/cons.cc:
5130         Likewise.
5131         * testsuite/20_util/unsynchronized_pool_resource/is_equal.cc:
5132         Likewise.
5133         * testsuite/20_util/unsynchronized_pool_resource/options.cc:
5134         Likewise.
5135         * testsuite/20_util/unsynchronized_pool_resource/release.cc:
5136         Likewise.
5137         * testsuite/21_strings/basic_string/types/pmr_typedefs.cc:
5138         Likewise.
5139         * testsuite/23_containers/deque/types/pmr_typedefs.cc: Likewise.
5140         * testsuite/23_containers/deque/types/pmr_typedefs_debug.cc:
5141         Likewise.
5142         * testsuite/23_containers/forward_list/pmr_typedefs.cc:
5143         Likewise.
5144         * testsuite/23_containers/forward_list/pmr_typedefs_debug.cc:
5145         Likewise.
5146         * testsuite/23_containers/list/pmr_typedefs.cc: Likewise.
5147         * testsuite/23_containers/list/pmr_typedefs_debug.cc: Likewise.
5148         * testsuite/23_containers/map/pmr_typedefs.cc: Likewise.
5149         * testsuite/23_containers/map/pmr_typedefs_debug.cc: Likewise.
5150         * testsuite/23_containers/multimap/pmr_typedefs.cc: Likewise.
5151         * testsuite/23_containers/multimap/pmr_typedefs_debug.cc:
5152         Likewise.
5153         * testsuite/23_containers/multiset/pmr_typedefs.cc: Likewise.
5154         * testsuite/23_containers/multiset/pmr_typedefs_debug.cc:
5155         Likewise.
5156         * testsuite/23_containers/set/pmr_typedefs.cc: Likewise.
5157         * testsuite/23_containers/set/pmr_typedefs_debug.cc: Likewise.
5158         * testsuite/23_containers/unordered_map/pmr_typedefs.cc:
5159         Likewise.
5160         * testsuite/23_containers/unordered_map/pmr_typedefs_debug.cc:
5161         Likewise.
5162         * testsuite/23_containers/unordered_multimap/pmr_typedefs.cc:
5163         Likewise.
5164         * testsuite/23_containers/unordered_multimap/pmr_typedefs_debug.cc:
5165         Likewise.
5166         * testsuite/23_containers/unordered_multiset/pmr_typedefs.cc:
5167         Likewise.
5168         * testsuite/23_containers/unordered_multiset/pmr_typedefs_debug.cc:
5169         Likewise.
5170         * testsuite/23_containers/unordered_set/pmr_typedefs.cc:
5171         Likewise.
5172         * testsuite/23_containers/unordered_set/pmr_typedefs_debug.cc:
5173         Likewise.
5174         * testsuite/23_containers/vector/pmr_typedefs.cc: Likewise.
5175         * testsuite/23_containers/vector/types/pmr_typedefs_debug.cc:
5176         Likewise.
5177         * testsuite/28_regex/match_results/pmr_typedefs.cc: Likewise.
5179 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
5181         * testsuite/29_atomics/atomic/69769.cc: Remove -std=gnu++17 from
5182         dg-options.
5183         * testsuite/29_atomics/atomic/is_always_lock_free.cc:
5184         * testsuite/29_atomics/atomic/requirements/typedefs.cc:
5185         * testsuite/29_atomics/atomic_integral/is_always_lock_free.cc:
5186         * testsuite/29_atomics/atomic_integral/requirements/typedefs.cc:
5187         * testsuite/30_threads/lock_guard/cons/deduction.cc: Likewise.
5188         * testsuite/30_threads/scoped_lock/cons/1.cc: Likewise.
5189         * testsuite/30_threads/scoped_lock/cons/deduction.cc: Likewise.
5190         * testsuite/30_threads/scoped_lock/requirements/explicit_instantiation.cc:
5191         Likewise.
5192         * testsuite/30_threads/scoped_lock/requirements/typedefs.cc:
5193         Likewise.
5194         * testsuite/30_threads/shared_lock/70766.cc: Likewise.
5195         * testsuite/30_threads/shared_mutex/cons/1.cc: Likewise.
5196         * testsuite/30_threads/shared_mutex/cons/assign_neg.cc:
5197         Likewise.
5198         * testsuite/30_threads/shared_mutex/cons/copy_neg.cc: Likewise.
5199         * testsuite/30_threads/shared_mutex/requirements/standard_layout.cc:
5200         Likewise.
5201         * testsuite/30_threads/shared_mutex/try_lock/1.cc: Likewise.
5202         * testsuite/30_threads/shared_mutex/try_lock/2.cc: Likewise.
5203         * testsuite/30_threads/shared_mutex/unlock/1.cc: Likewise.
5204         * testsuite/30_threads/unique_lock/cons/deduction.cc: Likewise.
5206 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
5208         * testsuite/20_util/any/assign/1.cc: Remove -std=gnu++17 from
5209         dg-options directive.
5210         * testsuite/20_util/any/assign/2.cc: Likewise.
5211         * testsuite/20_util/any/assign/emplace.cc: Likewise.
5212         * testsuite/20_util/any/assign/exception.cc: Likewise.
5213         * testsuite/20_util/any/assign/self.cc: Likewise.
5214         * testsuite/20_util/any/cons/1.cc: Likewise.
5215         * testsuite/20_util/any/cons/2.cc: Likewise.
5216         * testsuite/20_util/any/cons/90415.cc: Likewise.
5217         * testsuite/20_util/any/cons/92156.cc: Likewise.
5218         * testsuite/20_util/any/cons/aligned.cc: Likewise.
5219         * testsuite/20_util/any/cons/explicit.cc: Likewise.
5220         * testsuite/20_util/any/cons/in_place.cc: Likewise.
5221         * testsuite/20_util/any/cons/nontrivial.cc: Likewise.
5222         * testsuite/20_util/any/make_any.cc: Likewise.
5223         * testsuite/20_util/any/misc/any_cast.cc: Likewise.
5224         * testsuite/20_util/any/misc/any_cast_neg.cc: Likewise.
5225         * testsuite/20_util/any/misc/any_cast_no_rtti.cc: Likewise.
5226         * testsuite/20_util/any/misc/swap.cc: Likewise.
5227         * testsuite/20_util/any/modifiers/1.cc: Likewise.
5228         * testsuite/20_util/any/modifiers/83658.cc: Likewise.
5229         * testsuite/20_util/any/modifiers/92156.cc: Likewise.
5230         * testsuite/20_util/any/observers/type.cc: Likewise.
5231         * testsuite/20_util/any/requirements.cc: Likewise.
5232         * testsuite/20_util/any/typedefs.cc: Likewise.
5233         * testsuite/20_util/optional/77288.cc: Likewise.
5234         * testsuite/20_util/optional/84601.cc: Likewise.
5235         * testsuite/20_util/optional/assignment/1.cc: Likewise.
5236         * testsuite/20_util/optional/assignment/2.cc: Likewise.
5237         * testsuite/20_util/optional/assignment/3.cc: Likewise.
5238         * testsuite/20_util/optional/assignment/4.cc: Likewise.
5239         * testsuite/20_util/optional/assignment/5.cc: Likewise.
5240         * testsuite/20_util/optional/assignment/6.cc: Likewise.
5241         * testsuite/20_util/optional/assignment/7.cc: Likewise.
5242         * testsuite/20_util/optional/assignment/8.cc: Likewise.
5243         * testsuite/20_util/optional/assignment/9.cc: Likewise.
5244         * testsuite/20_util/optional/bad_access.cc: Likewise.
5245         * testsuite/20_util/optional/cons/77727.cc: Likewise.
5246         * testsuite/20_util/optional/cons/85642.cc: Likewise.
5247         * testsuite/20_util/optional/cons/copy.cc: Likewise.
5248         * testsuite/20_util/optional/cons/deduction.cc: Likewise.
5249         * testsuite/20_util/optional/cons/default.cc: Likewise.
5250         * testsuite/20_util/optional/cons/move.cc: Likewise.
5251         * testsuite/20_util/optional/cons/trivial.cc: Likewise.
5252         * testsuite/20_util/optional/cons/value.cc: Likewise.
5253         * testsuite/20_util/optional/cons/value_neg.cc: Likewise.
5254         * testsuite/20_util/optional/constexpr/cons/default.cc:
5255         Likewise.
5256         * testsuite/20_util/optional/constexpr/cons/value.cc: Likewise.
5257         * testsuite/20_util/optional/constexpr/in_place.cc: Likewise.
5258         * testsuite/20_util/optional/constexpr/make_optional.cc:
5259         Likewise.
5260         * testsuite/20_util/optional/constexpr/nullopt.cc: Likewise.
5261         * testsuite/20_util/optional/constexpr/observers/1.cc: Likewise.
5262         * testsuite/20_util/optional/constexpr/observers/2.cc: Likewise.
5263         * testsuite/20_util/optional/constexpr/observers/3.cc: Likewise.
5264         * testsuite/20_util/optional/constexpr/observers/4.cc: Likewise.
5265         * testsuite/20_util/optional/constexpr/observers/5.cc: Likewise.
5266         * testsuite/20_util/optional/constexpr/relops/1.cc: Likewise.
5267         * testsuite/20_util/optional/constexpr/relops/2.cc: Likewise.
5268         * testsuite/20_util/optional/constexpr/relops/3.cc: Likewise.
5269         * testsuite/20_util/optional/constexpr/relops/4.cc: Likewise.
5270         * testsuite/20_util/optional/constexpr/relops/5.cc: Likewise.
5271         * testsuite/20_util/optional/constexpr/relops/6.cc: Likewise.
5272         * testsuite/20_util/optional/hash.cc: Likewise.
5273         * testsuite/20_util/optional/in_place.cc: Likewise.
5274         * testsuite/20_util/optional/make_optional.cc: Likewise.
5275         * testsuite/20_util/optional/nullopt.cc: Likewise.
5276         * testsuite/20_util/optional/observers/1.cc: Likewise.
5277         * testsuite/20_util/optional/observers/2.cc: Likewise.
5278         * testsuite/20_util/optional/observers/3.cc: Likewise.
5279         * testsuite/20_util/optional/observers/4.cc: Likewise.
5280         * testsuite/20_util/optional/observers/5.cc: Likewise.
5281         * testsuite/20_util/optional/observers/6.cc: Likewise.
5282         * testsuite/20_util/optional/relops/1.cc: Likewise.
5283         * testsuite/20_util/optional/relops/2.cc: Likewise.
5284         * testsuite/20_util/optional/relops/3.cc: Likewise.
5285         * testsuite/20_util/optional/relops/4.cc: Likewise.
5286         * testsuite/20_util/optional/relops/5.cc: Likewise.
5287         * testsuite/20_util/optional/relops/6.cc: Likewise.
5288         * testsuite/20_util/optional/relops/7.cc: Likewise.
5289         * testsuite/20_util/optional/requirements.cc: Likewise.
5290         * testsuite/20_util/optional/swap/1.cc: Likewise.
5291         * testsuite/20_util/optional/swap/2.cc: Likewise.
5292         * testsuite/20_util/optional/typedefs.cc: Likewise.
5293         * testsuite/20_util/variant/80165.cc: Likewise.
5294         * testsuite/20_util/variant/85183.cc: Likewise.
5295         * testsuite/20_util/variant/86874.cc: Likewise.
5296         * testsuite/20_util/variant/87431.cc: Likewise.
5297         * testsuite/20_util/variant/87619.cc: Likewise.
5298         * testsuite/20_util/variant/91807.cc: Likewise.
5299         * testsuite/20_util/variant/any.cc: Likewise.
5300         * testsuite/20_util/variant/compile.cc: Likewise.
5301         * testsuite/20_util/variant/deduction.cc: Likewise.
5302         * testsuite/20_util/variant/exception_safety.cc: Likewise.
5303         * testsuite/20_util/variant/hash.cc: Likewise.
5304         * testsuite/20_util/variant/index_type.cc: Likewise.
5305         * testsuite/20_util/variant/relops/89851.cc: Likewise.
5306         * testsuite/20_util/variant/relops/90008.cc: Likewise.
5307         * testsuite/20_util/variant/run.cc: Likewise.
5308         * testsuite/20_util/variant/visit.cc: Likewise.
5310 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
5312         * testsuite/27_io/basic_filebuf/open/char/path.cc: Remove
5313         -std=gnu++17 from dg-options directive.
5314         * testsuite/27_io/basic_fstream/cons/char/path.cc: Likewise.
5315         * testsuite/27_io/basic_fstream/open/char/path.cc: Likewise.
5316         * testsuite/27_io/basic_ifstream/cons/char/path.cc: Likewise.
5317         * testsuite/27_io/basic_ifstream/open/char/path.cc: Likewise.
5318         * testsuite/27_io/basic_ofstream/cons/char/path.cc: Likewise.
5319         * testsuite/27_io/basic_ofstream/open/char/path.cc: Likewise.
5320         * testsuite/27_io/filesystem/directory_entry/86597.cc: Likewise.
5321         * testsuite/27_io/filesystem/directory_entry/lwg3171.cc:
5322         Likewise.
5323         * testsuite/27_io/filesystem/file_status/1.cc: Likewise.
5324         * testsuite/27_io/filesystem/filesystem_error/cons.cc: Likewise.
5325         * testsuite/27_io/filesystem/filesystem_error/copy.cc: Likewise.
5326         * testsuite/27_io/filesystem/iterators/91067.cc: Likewise.
5327         * testsuite/27_io/filesystem/iterators/caching.cc: Likewise.
5328         * testsuite/27_io/filesystem/iterators/directory_iterator.cc:
5329         Likewise.
5330         * testsuite/27_io/filesystem/iterators/pop.cc: Likewise.
5331         * testsuite/27_io/filesystem/iterators/recursion_pending.cc:
5332         Likewise.
5333         * testsuite/27_io/filesystem/iterators/recursive_directory_iterator.cc:
5334         Likewise.
5335         * testsuite/27_io/filesystem/operations/absolute.cc: Likewise.
5336         * testsuite/27_io/filesystem/operations/all.cc: Likewise.
5337         * testsuite/27_io/filesystem/operations/canonical.cc: Likewise.
5338         * testsuite/27_io/filesystem/operations/copy.cc: Likewise.
5339         * testsuite/27_io/filesystem/operations/copy_file.cc: Likewise.
5340         * testsuite/27_io/filesystem/operations/create_directories.cc:
5341         Likewise.
5342         * testsuite/27_io/filesystem/operations/create_directory.cc:
5343         Likewise.
5344         * testsuite/27_io/filesystem/operations/create_symlink.cc:
5345         Likewise.
5346         * testsuite/27_io/filesystem/operations/current_path.cc:
5347         Likewise.
5348         * testsuite/27_io/filesystem/operations/equivalent.cc: Likewise.
5349         * testsuite/27_io/filesystem/operations/exists.cc: Likewise.
5350         * testsuite/27_io/filesystem/operations/file_size.cc: Likewise.
5351         * testsuite/27_io/filesystem/operations/is_empty.cc: Likewise.
5352         * testsuite/27_io/filesystem/operations/last_write_time.cc:
5353         Likewise.
5354         * testsuite/27_io/filesystem/operations/permissions.cc:
5355         Likewise.
5356         * testsuite/27_io/filesystem/operations/proximate.cc: Likewise.
5357         * testsuite/27_io/filesystem/operations/read_symlink.cc:
5358         Likewise.
5359         * testsuite/27_io/filesystem/operations/relative.cc: Likewise.
5360         * testsuite/27_io/filesystem/operations/remove.cc: Likewise.
5361         * testsuite/27_io/filesystem/operations/remove_all.cc: Likewise.
5362         * testsuite/27_io/filesystem/operations/rename.cc: Likewise.
5363         * testsuite/27_io/filesystem/operations/resize_file.cc:
5364         Likewise.
5365         * testsuite/27_io/filesystem/operations/space.cc: Likewise.
5366         * testsuite/27_io/filesystem/operations/status.cc: Likewise.
5367         * testsuite/27_io/filesystem/operations/symlink_status.cc:
5368         Likewise.
5369         * testsuite/27_io/filesystem/operations/temp_directory_path.cc:
5370         Likewise.
5371         * testsuite/27_io/filesystem/operations/weakly_canonical.cc:
5372         Likewise.
5373         * testsuite/27_io/filesystem/path/append/path.cc: Likewise.
5374         * testsuite/27_io/filesystem/path/append/source.cc: Likewise.
5375         * testsuite/27_io/filesystem/path/assign/assign.cc: Likewise.
5376         * testsuite/27_io/filesystem/path/assign/copy.cc: Likewise.
5377         * testsuite/27_io/filesystem/path/compare/compare.cc: Likewise.
5378         * testsuite/27_io/filesystem/path/compare/lwg2936.cc: Likewise.
5379         * testsuite/27_io/filesystem/path/compare/path.cc: Likewise.
5380         * testsuite/27_io/filesystem/path/compare/strings.cc: Likewise.
5381         * testsuite/27_io/filesystem/path/concat/92853.cc: Likewise.
5382         * testsuite/27_io/filesystem/path/concat/94063.cc: Likewise.
5383         * testsuite/27_io/filesystem/path/concat/path.cc: Likewise.
5384         * testsuite/27_io/filesystem/path/concat/strings.cc: Likewise.
5385         * testsuite/27_io/filesystem/path/construct/80762.cc: Likewise.
5386         * testsuite/27_io/filesystem/path/construct/90281.cc: Likewise.
5387         * testsuite/27_io/filesystem/path/construct/90634.cc: Likewise.
5388         * testsuite/27_io/filesystem/path/construct/copy.cc: Likewise.
5389         * testsuite/27_io/filesystem/path/construct/default.cc:
5390         Likewise.
5391         * testsuite/27_io/filesystem/path/construct/format.cc: Likewise.
5392         * testsuite/27_io/filesystem/path/construct/locale.cc: Likewise.
5393         * testsuite/27_io/filesystem/path/construct/range.cc: Likewise.
5394         * testsuite/27_io/filesystem/path/construct/string_view.cc:
5395         Likewise.
5396         * testsuite/27_io/filesystem/path/decompose/extension.cc:
5397         Likewise.
5398         * testsuite/27_io/filesystem/path/decompose/filename.cc:
5399         Likewise.
5400         * testsuite/27_io/filesystem/path/decompose/parent_path.cc:
5401         Likewise.
5402         * testsuite/27_io/filesystem/path/decompose/relative_path.cc:
5403         Likewise.
5404         * testsuite/27_io/filesystem/path/decompose/root_directory.cc:
5405         Likewise.
5406         * testsuite/27_io/filesystem/path/decompose/root_name.cc:
5407         Likewise.
5408         * testsuite/27_io/filesystem/path/decompose/root_path.cc:
5409         Likewise.
5410         * testsuite/27_io/filesystem/path/decompose/stem.cc: Likewise.
5411         * testsuite/27_io/filesystem/path/factory/u8path-char8_t.cc:
5412         Likewise.
5413         * testsuite/27_io/filesystem/path/factory/u8path.cc: Likewise.
5414         * testsuite/27_io/filesystem/path/generation/normal.cc:
5415         Likewise.
5416         * testsuite/27_io/filesystem/path/generation/normal2.cc:
5417         Likewise.
5418         * testsuite/27_io/filesystem/path/generation/proximate.cc:
5419         Likewise.
5420         * testsuite/27_io/filesystem/path/generation/relative.cc:
5421         Likewise.
5422         * testsuite/27_io/filesystem/path/generic/94242.cc: Likewise.
5423         * testsuite/27_io/filesystem/path/generic/generic_string.cc:
5424         Likewise.
5425         * testsuite/27_io/filesystem/path/generic/utf.cc: Likewise.
5426         * testsuite/27_io/filesystem/path/generic/wchar_t.cc: Likewise.
5427         * testsuite/27_io/filesystem/path/io/dr2989.cc: Likewise.
5428         * testsuite/27_io/filesystem/path/itr/components.cc: Likewise.
5429         * testsuite/27_io/filesystem/path/itr/traversal.cc: Likewise.
5430         * testsuite/27_io/filesystem/path/modifiers/clear.cc: Likewise.
5431         * testsuite/27_io/filesystem/path/modifiers/make_preferred.cc:
5432         Likewise.
5433         * testsuite/27_io/filesystem/path/modifiers/remove_filename.cc:
5434         Likewise.
5435         * testsuite/27_io/filesystem/path/modifiers/replace_extension.cc:
5436         Likewise.
5437         * testsuite/27_io/filesystem/path/modifiers/replace_filename.cc:
5438         Likewise.
5439         * testsuite/27_io/filesystem/path/modifiers/swap.cc: Likewise.
5440         * testsuite/27_io/filesystem/path/native/alloc.cc: Likewise.
5441         * testsuite/27_io/filesystem/path/native/string-char8_t.cc:
5442         Likewise.
5443         * testsuite/27_io/filesystem/path/native/string.cc: Likewise.
5444         * testsuite/27_io/filesystem/path/nonmember/append.cc: Likewise.
5445         * testsuite/27_io/filesystem/path/nonmember/cmp.cc: Likewise.
5446         * testsuite/27_io/filesystem/path/nonmember/hash_value.cc:
5447         Likewise.
5448         * testsuite/27_io/filesystem/path/query/empty.cc: Likewise.
5449         * testsuite/27_io/filesystem/path/query/empty_neg.cc:
5450         * testsuite/27_io/filesystem/path/query/has_extension.cc:
5451         Likewise.
5452         * testsuite/27_io/filesystem/path/query/has_filename.cc:
5453         Likewise.
5454         * testsuite/27_io/filesystem/path/query/has_parent_path.cc:
5455         Likewise.
5456         * testsuite/27_io/filesystem/path/query/has_relative_path.cc:
5457         Likewise.
5458         * testsuite/27_io/filesystem/path/query/has_root_directory.cc:
5459         Likewise.
5460         * testsuite/27_io/filesystem/path/query/has_root_name.cc:
5461         Likewise.
5462         * testsuite/27_io/filesystem/path/query/has_root_path.cc:
5463         Likewise.
5464         * testsuite/27_io/filesystem/path/query/has_stem.cc: Likewise.
5465         * testsuite/27_io/filesystem/path/query/is_absolute.cc:
5466         Likewise.
5467         * testsuite/27_io/filesystem/path/query/is_relative.cc:
5468         Likewise.
5469         * testsuite/experimental/filesystem/path/construct/string_view.cc:
5470         Likewise.
5472 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
5474         * testsuite/20_util/specialized_algorithms/pstl/uninitialized_construct.cc:
5475         Remove -std=gnu++17 from dg-options.
5476         * testsuite/20_util/specialized_algorithms/pstl/uninitialized_copy_move.cc:
5477         Likewise.
5478         * testsuite/20_util/specialized_algorithms/pstl/uninitialized_fill_destroy.cc:
5479         Likewise.
5480         * testsuite/25_algorithms/pstl/alg_merge/inplace_merge.cc:
5481         Likewise.
5482         * testsuite/25_algorithms/pstl/alg_merge/merge.cc: Likewise.
5483         * testsuite/25_algorithms/pstl/alg_modifying_operations/copy_if.cc:
5484         Likewise.
5485         * testsuite/25_algorithms/pstl/alg_modifying_operations/copy_move.cc:
5486         Likewise.
5487         * testsuite/25_algorithms/pstl/alg_modifying_operations/fill.cc:
5488         Likewise.
5489         * testsuite/25_algorithms/pstl/alg_modifying_operations/generate.cc:
5490         Likewise.
5491         * testsuite/25_algorithms/pstl/alg_modifying_operations/is_partitioned.cc:
5492         Likewise.
5493         * testsuite/25_algorithms/pstl/alg_modifying_operations/partition.cc:
5494         Likewise.
5495         * testsuite/25_algorithms/pstl/alg_modifying_operations/partition_copy.cc:
5496         Likewise.
5497         * testsuite/25_algorithms/pstl/alg_modifying_operations/remove.cc:
5498         Likewise.
5499         * testsuite/25_algorithms/pstl/alg_modifying_operations/remove_copy.cc:
5500         Likewise.
5501         * testsuite/25_algorithms/pstl/alg_modifying_operations/replace.cc:
5502         Likewise.
5503         * testsuite/25_algorithms/pstl/alg_modifying_operations/replace_copy.cc:
5504         Likewise.
5505         * testsuite/25_algorithms/pstl/alg_modifying_operations/rotate.cc:
5506         Likewise.
5507         * testsuite/25_algorithms/pstl/alg_modifying_operations/rotate_copy.cc:
5508         Likewise.
5509         * testsuite/25_algorithms/pstl/alg_modifying_operations/swap_ranges.cc:
5510         Likewise.
5511         * testsuite/25_algorithms/pstl/alg_modifying_operations/transform_binary.cc:
5512         Likewise.
5513         * testsuite/25_algorithms/pstl/alg_modifying_operations/transform_unary.cc:
5514         Likewise.
5515         * testsuite/25_algorithms/pstl/alg_modifying_operations/unique.cc:
5516         Likewise.
5517         * testsuite/25_algorithms/pstl/alg_modifying_operations/unique_copy_equal.cc:
5518         Likewise.
5519         * testsuite/25_algorithms/pstl/alg_nonmodifying/adjacent_find.cc:
5520         Likewise.
5521         * testsuite/25_algorithms/pstl/alg_nonmodifying/all_of.cc:
5522         Likewise.
5523         * testsuite/25_algorithms/pstl/alg_nonmodifying/any_of.cc:
5524         Likewise.
5525         * testsuite/25_algorithms/pstl/alg_nonmodifying/count.cc:
5526         Likewise.
5527         * testsuite/25_algorithms/pstl/alg_nonmodifying/equal.cc:
5528         Likewise.
5529         * testsuite/25_algorithms/pstl/alg_nonmodifying/find.cc:
5530         Likewise.
5531         * testsuite/25_algorithms/pstl/alg_nonmodifying/find_end.cc:
5532         Likewise.
5533         * testsuite/25_algorithms/pstl/alg_nonmodifying/find_first_of.cc:
5534         Likewise.
5535         * testsuite/25_algorithms/pstl/alg_nonmodifying/find_if.cc:
5536         Likewise.
5537         * testsuite/25_algorithms/pstl/alg_nonmodifying/for_each.cc:
5538         Likewise.
5539         * testsuite/25_algorithms/pstl/alg_nonmodifying/mismatch.cc:
5540         Likewise.
5541         * testsuite/25_algorithms/pstl/alg_nonmodifying/none_of.cc:
5542         Likewise.
5543         * testsuite/25_algorithms/pstl/alg_nonmodifying/nth_element.cc:
5544         Likewise.
5545         * testsuite/25_algorithms/pstl/alg_nonmodifying/reverse.cc:
5546         Likewise.
5547         * testsuite/25_algorithms/pstl/alg_nonmodifying/reverse_copy.cc:
5548         Likewise.
5549         * testsuite/25_algorithms/pstl/alg_nonmodifying/search_n.cc:
5550         Likewise.
5551         * testsuite/25_algorithms/pstl/alg_sorting/includes.cc:
5552         Likewise.
5553         * testsuite/25_algorithms/pstl/alg_sorting/is_heap.cc: Likewise.
5554         * testsuite/25_algorithms/pstl/alg_sorting/is_sorted.cc:
5555         Likewise.
5556         * testsuite/25_algorithms/pstl/alg_sorting/lexicographical_compare.cc:
5557         Likewise.
5558         * testsuite/25_algorithms/pstl/alg_sorting/minmax_element.cc:
5559         Likewise.
5560         * testsuite/25_algorithms/pstl/alg_sorting/partial_sort.cc:
5561         Likewise.
5562         * testsuite/25_algorithms/pstl/alg_sorting/partial_sort_copy.cc:
5563         Likewise.
5564         * testsuite/25_algorithms/pstl/alg_sorting/set.cc: Likewise.
5565         * testsuite/25_algorithms/pstl/alg_sorting/sort.cc: Likewise.
5566         * testsuite/25_algorithms/pstl/feature_test-2.cc: Likewise.
5567         * testsuite/25_algorithms/pstl/feature_test-3.cc: Likewise.
5568         * testsuite/25_algorithms/pstl/feature_test-4.cc: Likewise.
5569         * testsuite/25_algorithms/pstl/feature_test-5.cc: Likewise.
5570         * testsuite/25_algorithms/pstl/feature_test.cc: Likewise.
5571         * testsuite/26_numerics/pstl/numeric_ops/adjacent_difference.cc:
5572         Likewise.
5573         * testsuite/26_numerics/pstl/numeric_ops/reduce.cc: Likewise.
5574         * testsuite/26_numerics/pstl/numeric_ops/scan.cc: Likewise.
5575         * testsuite/26_numerics/pstl/numeric_ops/transform_reduce.cc:
5576         Likewise.
5577         * testsuite/26_numerics/pstl/numeric_ops/transform_scan.cc:
5578         Likewise.
5580 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
5582         * testsuite/20_util/scoped_allocator/69293_neg.cc: Add dg-error
5583         for additional errors in C++20.
5584         * testsuite/20_util/specialized_algorithms/memory_management_tools/destroy_neg.cc:
5585         Likewise.
5586         * testsuite/20_util/uses_allocator/69293_neg.cc: Likewise.
5587         * testsuite/27_io/filesystem/path/io/dr2989.cc: Likewise.
5589 2021-05-10  Jonathan Wakely  <jwakely@redhat.com>
5591         * testsuite/20_util/variant/compile.cc: Rename 'any' to avoid
5592         clash with std::any.
5594 2021-05-07  Jonathan Wakely  <jwakely@redhat.com>
5596         * include/std/istream (__rvalue_stream_extraction_t): Replace
5597         use of __rval_streamable.
5598         * include/std/ostream (__rvalue_stream_insertion_t): Likewise.
5599         (__rval_streamable): Remove.
5600         (_Require_derived_from_ios_base, __derived_from_ios_base): New
5601         helper for checking constraints.
5602         * testsuite/27_io/basic_istream/extractors_other/char/4.cc: Fix
5603         reference to the wrong subclause of the standard.
5604         * testsuite/27_io/basic_istream/extractors_other/wchar_t/4.cc:
5605         Likewise.
5606         * testsuite/27_io/basic_ostream/inserters_other/char/6.cc:
5607         Likewise.
5608         * testsuite/27_io/basic_ostream/inserters_other/wchar_t/6.cc:
5609         Likewise.
5610         * testsuite/27_io/basic_ostream/inserters_other/char/99692.cc:
5611         New test.
5612         * testsuite/27_io/filesystem/path/io/dr2989.cc: Adjust pruned
5613         errors.
5615 2021-05-06  Jonathan Wakely  <jwakely@redhat.com>
5617         * include/bits/stl_algobase.h (__copy_move, __copy_move_backward):
5618         Improve static_assert messages.
5619         * testsuite/25_algorithms/copy/58982.cc: Adjust expected output.
5620         * testsuite/25_algorithms/copy_n/58982.cc: Likewise.
5622 2021-05-06  Patrick Palka  <ppalka@redhat.com>
5624         * include/std/ranges (filter_view::_Iterator::base): Make the
5625         const& overload unconstrained and return a const reference as
5626         per LWG 3533.  Make unconditionally noexcept.
5627         (transform_view::_Iterator::base): Likewise.
5628         (elements_view::_Iterator::base): Likewise.
5630 2021-05-06  Patrick Palka  <ppalka@redhat.com>
5632         * include/bits/stl_iterator.h (move_iterator::base): Make the
5633         const& overload unconstrained and return a const reference as
5634         per LWG 3391.  Make unconditionally noexcept.
5635         (counted_iterator::base): Likewise.
5636         * testsuite/24_iterators/move_iterator/lwg3391.cc: New test.
5637         * testsuite/24_iterators/move_iterator/move_only.cc: Adjust
5638         has_member_base concept to decay-copy the result of base().
5640 2021-05-06  Jonathan Wakely  <jwakely@redhat.com>
5642         * include/std/type_traits (remove_cvref_t): Define in terms of
5643         remove_cvref.
5644         * testsuite/20_util/remove_cvref/value.cc: Check alias.
5646 2021-05-06  Jonathan Wakely  <jwakely@redhat.com>
5648         Revert:
5649         2021-05-05  Jonathan Wakely  <jwakely@redhat.com>
5651         * include/std/charconv (__from_chars_alnum): Pass unsigned
5652         char to std::isdigit.
5654 2021-05-05  Patrick Palka  <ppalka@redhat.com>
5656         * include/bits/ranges_util.h (enable_borrowed_range<subrange>):
5657         Remove constraints on this partial specialization.
5658         * include/std/ranges (enable_borrowed_range<iota_view>):
5659         Likewise.
5661 2021-05-05  Patrick Palka  <ppalka@redhat.com>
5663         * include/std/ranges (transform_view::_Iterator::iter_swap):
5664         Remove as per LWG 3520.
5665         (join_view::_Iterator::iter_swap): Add indirectly_swappable
5666         constraint as per LWG 3517.
5668 2021-05-05  Jonathan Wakely  <jwakely@redhat.com>
5670         * testsuite/20_util/function_objects/invoke/3.cc: Check feature
5671         test macro.
5672         * testsuite/20_util/function_objects/invoke/version.cc: New test.
5674 2021-05-05  Jonathan Wakely  <jwakely@redhat.com>
5676         * include/std/charconv (__from_chars_alnum): Pass unsigned
5677         char to std::isdigit.
5679 2021-05-05  Corentin Gay  <gay@adacore.com>
5681         * acinclude.m4: Add VxWorks-specific case for the
5682         configuration of ctypes.
5683         * configure: Regenerate.
5684         * config/locale/vxworks/ctype_members.cc: Add VxWorks-specific
5685         version.
5686         * config/os/vxworks/ctype_base.h: Adjust for VxWorks7+.
5687         * config/os/vxworks/ctype_configure_char.cc: Likewise.
5688         * config/os/vxworks/ctype_inline.h: Likewise.
5689         * testsuite/28_regex/traits/char/isctype.cc: Defines
5690         NEWLINE_IN_CLASS_BLANK if the target is VxWorks.
5691         * testsuite/28_regex/traits/wchar_t/isctype.cc: Likewise.
5693 2021-05-04  Jonathan Wakely  <jwakely@redhat.com>
5695         * include/std/future (promise::set_value): Check for existence
5696         of shared state before dereferncing it.
5697         (promise::set_exception, promise::set_value_at_thread_exit)
5698         (promise::set_exception_at_thread_exit): Likewise.
5699         (promise<R&>::set_value, promise<R&>::set_exception)
5700         (promise<R&>::set_value_at_thread_exit)
5701         (promise<R&>::set_exception_at_thread_exit): Likewise.
5702         (promise<void>::set_value, promise<void>::set_exception)
5703         (promise<void>::set_value_at_thread_exit)
5704         (promise<void>::set_exception_at_thread_exit): Likewise.
5705         * testsuite/30_threads/promise/members/at_thread_exit2.cc:
5706         Remove unused variable.
5708 2021-05-04  Jonathan Wakely  <jwakely@redhat.com>
5710         * include/bits/basic_string.h (basic_string(const CharT*, const A&)):
5711         Do not do arithmetic on null pointer.
5713 2021-05-04  Jonathan Wakely  <jwakely@redhat.com>
5715         * include/ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp
5716         (find_key_pointer(key_const_reference, false_type))
5717         (find_key_pointer(key_const_reference, true_type)): Do not
5718         dereference null pointer.
5720 2021-05-04  Jonathan Wakely  <jwakely@redhat.com>
5722         * testsuite/20_util/from_chars/3.cc: Use unsigned type to avoid
5723         overflow.
5724         * testsuite/24_iterators/reverse_iterator/2.cc: Do not add
5725         non-zero value to null pointer.
5726         * testsuite/25_algorithms/copy_backward/move_iterators/69478.cc:
5727         Use past-the-end iterator for result.
5728         * testsuite/25_algorithms/move_backward/69478.cc: Likewise.
5729         * testsuite/25_algorithms/move_backward/93872.cc: Likewise.
5731 2021-05-04  Jonathan Wakely  <jwakely@redhat.com>
5733         PR libstdc++/100384
5734         * include/std/variant (__get_t): New alias template yielding the
5735         return type of std::get<N> on a variant.
5736         (__visit_result_t): New alias template yielding the result of
5737         std::visit.
5738         (__same_types): Move into namespace __detail::__variant.
5739         (__check_visitor_results): Likewise. Use __invoke_result_t and
5740         __get_t.
5741         (__check_visitor_result): Remove.
5742         (visit): Use __visit_result_t for return type.
5743         * testsuite/20_util/variant/100384.cc: New test.
5745 2021-05-04  Jonathan Wakely  <jwakely@redhat.com>
5747         * acinclude.m4 (GLIBCXX_ENABLE_INT128_FLOAT128): Remove
5748         checks for __int128 and rename to GLIBCXX_ENABLE_FLOAT128.
5749         * config.h.in: Regenerate.
5750         * configure: Regenerate.
5751         * configure.ac: Adjust to use GLIBCXX_ENABLE_FLOAT128.
5752         * include/bits/random.h (_Select_uint_least_t<s, 1>):
5753         Use __SIZEOF_INT128__ to decide whether to use __int128.
5754         * include/std/charconv (__to_chars_unsigned_type): Likewise.
5756 2021-05-03  Gerald Pfeifer  <gerald@pfeifer.com>
5758         * doc/xml/manual/ctype.xml: Move unix.org reference to https.
5759         * doc/html/manual/facets.html: Regenerate.
5761 2021-04-30  Patrick Palka  <ppalka@redhat.com>
5763         * include/std/ranges (__detail::__non_propating_cache): Define
5764         as per P2328.
5765         (join_view): Remove constraints on the value and reference types
5766         of the wrapped iterator type as per P2328.
5767         (join_view::_Iterator::_M_satisfy): Adjust as per P2328.
5768         (join_view::_Iterator::operator++): Likewise.
5769         (join_view::_M_inner): Use __non_propating_cache as per P2328.
5770         Remove now-redundant use of __maybe_present_t.
5771         * testsuite/std/ranges/adaptors/join.cc: Include <array>.
5772         (test10): New test.
5774 2021-04-30  Jonathan Wakely  <jwakely@redhat.com>
5776         * include/bits/basic_string.h (__cpp_lib_constexpr_string):
5777         Only define for C++17 and later.
5778         * include/std/version (__cpp_lib_semaphore): Fix condition
5779         to match the one in <semaphore>.
5781 2021-04-30  Jonathan Wakely  <jwakely@redhat.com>
5783         * acinclude.m4 (GLIBCXX_CHECK_INT64_T): Delete.
5784         * config.h.in: Regenerate.
5785         * configure: Regenerate.
5786         * configure.ac: Do not use GLIBCXX_CHECK_INT64_T.
5787         * include/bits/postypes.h: Remove include of <stdint.h> and
5788         definition/undefinition of the __STDC_LIMIT_MACROS and
5789         __STDC_CONSTANT_MACROS macros.
5790         (streamoff): Use __INT64_TYPE__ if defined.
5792 2021-04-30  Patrick Palka  <ppalka@redhat.com>
5794         * include/std/ranges (split_view::_InnerIter::operator++):
5795         Depend on _Base instead of _Vp directly, as per LWG 3532.
5797 2021-04-30  Patrick Palka  <ppalka@redhat.com>
5799         * include/bits/ranges_util.h (subrange::subrange): Avoid
5800         list-initialization in delegating constructor.
5801         * include/std/ranges (single_view): Replace implicit guide
5802         with explicit deduction guide that decays its argument.
5803         (_Single::operator()): Avoid CTAD when constructing the
5804         single_view object.
5805         (_Iota::operator()): Avoid list-initialization.
5806         (__detail::__can_filter_view, _Filter::operator()): Likewise.
5807         (__detail::__can_transform_view, _Transform::operator()): Likewise.
5808         (take_view::begin): Likewise.
5809         (__detail::__can_take_view, _Take::operator()): Likewise.
5810         (__detail::__can_take_while_view, _TakeWhile::operator()): Likewise.
5811         (__detail::__can_drop_view, _Drop::operator()): Likewise.
5812         (__detail::__can_drop_while_view, _DropWhile::operator()): Likewise.
5813         (split_view::split_view): Use views::single when initializing
5814         _M_pattern.
5815         (__detail::__can_split_view, _Split::operator()): Avoid
5816         list-initialization.
5817         (_Counted::operator()): Likewise.
5818         * testsuite/std/ranges/p2367.cc: New test.
5820 2021-04-30  Jonathan Wakely  <jwakely@redhat.com>
5822         PR libstdc++/60497
5823         * include/bits/basic_ios.tcc (basic_ios::copyfmt): use
5824         std::addressof.
5825         * include/bits/basic_string.tcc (basic_string::swap)
5826         (basic_string::assign): Likewise.
5827         * include/bits/deque.tcc (deque::operator=(const deque&)):
5828         Likewise.
5829         * include/bits/stl_tree.h (_Rb_tree::operator=(const * _Rb_tree&)):
5830         Likewise.
5831         * include/bits/vector.tcc (vector::operator=(const vector&)):
5832         Likewise.
5834 2021-04-30  Jonathan Wakely  <jwakely@redhat.com>
5836         * include/std/istream (operator>>(Istream&&, x&)): Simplify, as
5837         per LWG 1203.
5838         * include/std/ostream (operator<<(Ostream&&, const x&)):
5839         Likewise.
5840         * testsuite/27_io/basic_istream/extractors_character/char/lwg2499_neg.cc:
5841         Adjust dg-error pattern.
5842         * testsuite/27_io/basic_istream/extractors_character/wchar_t/lwg2499_neg.cc:
5843         Likewise.
5844         * testsuite/27_io/basic_istream/extractors_other/char/4.cc: Define
5845         is_extractable trait to replace std::__is_extractable. Make it
5846         work with rvalue streams as well as lvalues, to replace f() and
5847         g() helper functions.
5848         * testsuite/27_io/basic_istream/extractors_other/wchar_t/4.cc:
5849         Likewise.
5850         * testsuite/27_io/basic_ostream/inserters_other/char/6.cc:
5851         Define is_insertable trait to replace std::__is_insertable. Make
5852         it work with rvalue streams as well as lvalues, to replace f()
5853         and g() helper functions.
5854         * testsuite/27_io/basic_ostream/inserters_other/wchar_t/6.cc:
5855         Likewise.
5856         * testsuite/27_io/filesystem/path/io/dr2989.cc: Prune additional
5857         errors from new constraints.
5858         * testsuite/27_io/rvalue_streams-2.cc: Remove PR 80675 checks,
5859         which are no longer expected to compile.
5860         * testsuite/27_io/rvalue_streams.cc: Adjust existing test.
5861         Verify LWG 1203 changes.
5863 2021-04-30  Jonathan Wakely  <jwakely@redhat.com>
5865         PR libstdc++/100285
5866         * include/experimental/socket (__basic_socket_impl::set_option)
5867         (__basic_socket_impl::get_option) [!_GLIBCXX_HAVE_SYS_SOCKET_H]:
5868         Just set error code.
5869         * testsuite/experimental/net/socket/socket_base.cc: CHeck
5870         for <sys/socket.h> not <socket.h>.
5872 2021-04-30  Jonathan Wakely  <jwakely@redhat.com>
5874         PR libstdc++/100180
5875         PR libstdc++/100286
5876         PR libstdc++/100351
5877         * testsuite/experimental/net/internet/address/v4/comparisons.cc:
5878         Use new effective-target keyword.
5879         * testsuite/experimental/net/internet/address/v4/cons.cc:
5880         Likewise.
5881         * testsuite/experimental/net/internet/address/v4/creation.cc:
5882         Likewise.
5883         * testsuite/experimental/net/internet/address/v4/members.cc:
5884         Likewise.
5885         * testsuite/experimental/net/internet/address/v6/members.cc:
5886         Likewise.
5887         * testsuite/experimental/net/internet/resolver/base.cc:
5888         Likewise.
5889         * testsuite/experimental/net/internet/resolver/ops/lookup.cc:
5890         Likewise.
5891         * testsuite/experimental/net/internet/resolver/ops/reverse.cc:
5892         Likewise.
5893         * testsuite/experimental/net/internet/socket/opt.cc:
5894         Likewise.
5895         * testsuite/experimental/net/internet/tcp.cc:
5896         Likewise.
5897         * testsuite/experimental/net/internet/udp.cc:
5898         Likewise.
5899         * testsuite/lib/libstdc++.exp (check_effective_target_net_ts_ip):
5900         New proc to check net_ts_ip et.
5902 2021-04-28  Jonathan Wakely  <jwakely@redhat.com>
5904         PR libstdc++/97930
5905         * testsuite/20_util/pair/requirements/structural.cc: New test.
5907 2021-04-28  Jonathan Wakely  <jwakely@redhat.com>
5909         * include/bits/stl_pair.h (pair) [__cplusplus > 202002]: Add
5910         new definitions for constructors and assignment operators using
5911         concepts for constraints.
5912         * testsuite/20_util/pair/cons/99957.cc: Disable for C++20 and
5913         later.
5914         * testsuite/20_util/pair/cons/explicit_construct.cc: Adjust
5915         expected error messages to also match C++20 errors.
5917 2021-04-28  Jonathan Wakely  <jwakely@redhat.com>
5919         PR libstdc++/99957
5920         * include/bits/stl_pair.h (_PCC::_MoveCopyPair, _PCC::_CopyMovePair):
5921         Combine and replace with ...
5922         (_PCC::_DeprConsPair): New SFINAE helper function.
5923         (pair): Merge preprocessor blocks so that all C++03 members
5924         are defined together at the end.
5925         (pair::pair(const _T1&, _U2&&), pair::pair(_U1&&, const _T2&)):
5926         Replace _T1 and _T2 parameters with __null_ptr_constant and
5927         adjust constraints.
5928         * testsuite/20_util/pair/40925.cc: Use nullptr instead of 0.
5929         * testsuite/20_util/pair/cons/explicit_construct.cc: Likewise.
5930         * testsuite/20_util/pair/cons/99957.cc: New test.
5932 2021-04-28  Jonathan Wakely  <jwakely@redhat.com>
5934         * include/bits/basic_string.h (__cpp_lib_constexpr_string): Define.
5935         * include/std/version (__cpp_lib_constexpr_string): Define.
5936         * testsuite/21_strings/char_traits/requirements/constexpr_functions_c++17.cc:
5937         Check for __cpp_lib_constexpr_string.
5938         * testsuite/21_strings/char_traits/requirements/constexpr_functions_c++20.cc:
5939         Likewise.
5940         * testsuite/21_strings/char_traits/requirements/version.cc: New test.
5942 2021-04-28  Jonathan Wakely  <jwakely@redhat.com>
5944         * doc/Makefile.am (stamp-pdf-doxygen): Improve comment about
5945         dealing with errors. Use '@' to prevent shell command being
5946         echoed.
5947         * doc/Makefile.in: Regenerate.
5949 2021-04-28  Jonathan Wakely  <jwakely@redhat.com>
5951         PR libstdc++/100298
5952         * include/bits/std_thread.h (thread::hardware_concurrency): Add
5953         missing noexcept to inline definition for non-gthreads targets.
5955 2021-04-28  Patrick Palka  <ppalka@redhat.com>
5957         PR libstdc++/100187
5958         PR libstdc++/100237
5959         PR libstdc++/100249
5960         PR libstdc++/100287
5961         * include/bits/ranges_algo.h (__search_n_fn::operator()): Give
5962         the __value_comp lambda an explicit bool return type.
5963         (__is_permutation_fn::operator()): Give the __proj_scan local
5964         variable auto&& return type.  Give the __comp_scan lambda an
5965         explicit bool return type.
5966         (__remove_fn::operator()): Give the __pred lambda an explicit
5967         bool return type.
5968         (__partition_fn::operator()): Don't std::move __first twice
5969         when returning an empty subrange.
5970         (__min_fn::operator()): Don't std::move __comp.
5971         (__max_fn::operator()): Likewise.
5972         (__minmax_fn::operator()): Likewise.
5974 2021-04-27  Patrick Palka  <ppalka@redhat.com>
5976         PR libstdc++/100290
5977         * include/std/ranges (join_view::_Iterator::operator++): Correct
5978         the return type of the lambda to avoid returning a copy of
5979         _M_parent->_M_inner.
5980         * testsuite/std/ranges/adaptors/join.cc (test10): New test.
5982 2021-04-27  Jakub Jelinek  <jakub@redhat.com>
5984         Revert:
5985         2021-04-22  Jakub Jelinek  <jakub@redhat.com>
5987         PR target/100182
5988         * testsuite/29_atomics/atomic_float/1.cc: Add dg-xfail-run-if for
5989         ia32.
5990         * testsuite/29_atomics/atomic_float/wait_notify.cc: Add dg-skip-if for
5991         ia32.
5993 2021-04-27  Jonathan Wakely  <jwakely@redhat.com>
5995         * include/experimental/internet (address_v6::bytes_type): Adjust
5996         formatting.
5997         (basic_endpoint): Define _M_is_v6() to put all checks for
5998         AF_INET6 in one place.
5999         (basic_endpoint::resize): Simplify.
6000         (operator==(const tcp&, const tcp&)): Add constexpr and noexcept.
6001         (operator!=(const tcp&, const tcp&)): Likewise.
6002         (operator==(const udp&, const udp&)): Likewise.
6003         (operator!=(const udp&, const udp&)): Likewise.
6004         * testsuite/experimental/net/internet/tcp.cc: New test.
6005         * testsuite/experimental/net/internet/udp.cc: New test.
6007 2021-04-27  Jonathan Wakely  <jwakely@redhat.com>
6009         PR libstdc++/100286
6010         * include/experimental/internet (resolver_errc, resolver_category())
6011         (make_error_code, make_error_condition): Define unconditionally,
6012         only make enumerators and use of gai_strerror depend on the
6013         availability of <netdb.h>.
6014         (address_v4::to_string): Use correct constant for string length.
6015         (address_v4::to_string, address_v6::to_string): Define
6016         unconditionally, throw if unsupported.
6017         (make_address_v4, make_address_v6): Define unconditionally.
6018         Return an error if unsupported.
6019         (tcp, udp, v6_only, unicast::hops, multicast::*): Define
6020         conditionally,
6021         * testsuite/experimental/net/internet/socket/opt.cc: Check for
6022         <netinet/in.h> and <netinet/tcp.h> before using types from
6023         namespace net::ip.
6025 2021-04-27  Jonathan Wakely  <jwakely@redhat.com>
6027         PR libstdc++/100285
6028         * include/experimental/internet (resolver_base::flags):
6029         Define overloaded operators as hidden friends.
6030         * include/experimental/socket (socket_base::message_flags):
6031         Likewise.
6033 2021-04-26  Jonathan Wakely  <jwakely@redhat.com>
6035         * include/experimental/internet (tcp::no_delay, v6_only)
6036         (unicast::hops, multicast::hops, multicast::enable_loopback):
6037         Change access of base class and static data members. Add
6038         using-declaration for __socket_crtp::operator=(_Tp).
6039         (multicast::__mcastopt): New type.
6040         (multicast::join_group, multicast::leave_group): Derive from
6041         __mcastopt for common implementation.
6042         * include/experimental/socket: Add comment.
6043         * testsuite/experimental/net/internet/socket/opt.cc: New test.
6044         * testsuite/experimental/net/socket/socket_base.cc: Check for
6045         protected constructor/destructor of socket_base. Check for
6046         explicit constructors of socket option classes.
6048 2021-04-26  Jonathan Wakely  <jwakely@redhat.com>
6050         * include/experimental/bits/net.h (__socket_base): Add
6051         bool template parameter to allow BooleanSocketOption and
6052         IntegerSocketOption to have different __socket_base<int>
6053         base classes.
6054         (__socket_base<bool>): Adjust base class.
6055         (__socket_base<int>): Add partial specialization.
6056         (__socket_crtp::operator=(_Tp)): Add noexcept-specifier.
6057         * include/experimental/socket (socket_base::broadcast)
6058         (socket_base::debug, socket_base::do_not_route)
6059         (socket_base::keep_alive, socket_base::linger)
6060         (socket_base::out_of_band_inline)
6061         (socket_base::receive_buffer_size)
6062         (socket_base::receive_low_watermark)
6063         (socket_base::reuse_address, socket_base::send_buffer_size)
6064         (socket_base::send_low_watermark): Add using-declaration for
6065         __socket_crtp::operator=(_Tp).
6066         * testsuite/experimental/net/socket/socket_base.cc: Check
6067         properties of socket option types.
6069 2021-04-26  Jonathan Wakely  <jwakely@redhat.com>
6071         * include/experimental/internet (resolver_base::flags): Remove
6072         enumerators. Initialize constants directly with desired values.
6073         Make all operators constexpr and noexcept.
6074         * testsuite/experimental/net/internet/resolver/base.cc: Use
6075         __gnu_test::test_bitmask_values for bitmask type. Check
6076         construction and destruction is protected.
6078 2021-04-26  Jonathan Wakely  <jwakely@redhat.com>
6080         * include/bits/semaphore_base.h: Include <exception> and <errno.h>.
6082 2021-04-26  Jonathan Wakely  <jwakely@redhat.com>
6084         PR libstdc++/100259
6085         * include/experimental/internet (net::ip::make_error_code)
6086         (net::ip::make_error_condition, net::ip::make_network_v4)
6087         (net::ip::operator==(const udp&, const udp&)): Add 'inline'.
6089 2021-04-24  David Edelsohn  <dje.gcc@gmail.com>
6091         * testsuite/lib/dg-options.exp (atomic_link_flags): New.
6092         (add_options_for_libatomic): Use atomic_link_flags.
6094 2021-04-23  Jonathan Wakely  <jwakely@redhat.com>
6096         PR libstdc++/100180
6097         * include/experimental/io_context (io_context): Define
6098         dummy_pollfd type so that most member functions still compile
6099         without <poll.h> and struct pollfd.
6101 2021-04-23  Jonathan Wakely  <jwakely@redhat.com>
6103         * include/experimental/io_context (io_context::async_wait): Add
6104         comment.
6105         * include/experimental/socket (basic_socket::async_connect):
6106         Cast wait_type constant to int.
6107         (basic_datagram_socket::async_receive): Likewise.
6108         (basic_datagram_socket::async_receive_from): Likewise.
6109         (basic_datagram_socket::async_send): Likewise.
6110         (basic_datagram_socket::async_send_to): Likewise.
6111         (basic_stream_socket::async_receive): Likewise.
6112         (basic_stream_socket::async_send): Likewise. Use io_context
6113         parameter directly, instead of via an executor.
6114         (basic_socket_acceptor::async_accept): Likewise.
6116 2021-04-23  Jonathan Wakely  <jwakely@redhat.com>
6118         * include/experimental/socket (socket_base::shutdown_type):
6119         (socket_base::wait_type, socket_base::message_flags):
6120         Remove enumerators. Initialize constants directly with desired
6121         values.
6122         (socket_base::message_flags): Make all operators constexpr and
6123         noexcept.
6124         * testsuite/util/testsuite_common_types.h (test_bitmask_values):
6125         New test utility.
6126         * testsuite/experimental/net/socket/socket_base.cc: New test.
6128 2021-04-22  David Edelsohn  <dje.gcc@gmail.com>
6130         * config/os/aix/atomicity.h: Delete.
6132 2021-04-22  Jonathan Wakely  <jwakely@redhat.com>
6134         * include/bits/atomic_timed_wait.h (__cond_wait_until_impl):
6135         Handle system_clock as well as steady_clock.
6136         * testsuite/30_threads/semaphore/try_acquire_for.cc: Re-enable.
6137         * testsuite/30_threads/semaphore/try_acquire_until.cc:
6138         Re-enable.
6140 2021-04-22  Jonathan Wakely  <jwakely@redhat.com>
6142         * testsuite/30_threads/semaphore/try_acquire_posix.cc: Add
6143         options for libatomic.
6145 2021-04-22  Jonathan Wakely  <jwakely@redhat.com>
6147         * config/os/gnu-linux/os_defines.h: Fix type in comment.
6149 2021-04-22  Jonathan Wakely  <jwakely@redhat.com>
6151         PR libstdc++/99006
6152         * include/bits/shared_ptr.h (allocate_shared): Assert that _Tp
6153         is not an array type.
6154         * include/bits/shared_ptr_base.h (__allocate_shared): Likewise.
6155         * testsuite/20_util/shared_ptr/creation/99006.cc: New test.
6157 2021-04-22  Thomas Rodgers  <rodgert@twrodgers.com>
6159         * include/bits/atomic_wait.h: Always notify waiters in the
6160         case of 'bare' address notification.
6162 2021-04-22  Jakub Jelinek  <jakub@redhat.com>
6164         PR target/100182
6165         * testsuite/29_atomics/atomic_float/1.cc: Add dg-xfail-run-if for
6166         ia32.
6167         * testsuite/29_atomics/atomic_float/wait_notify.cc: Add dg-skip-if for
6168         ia32.
6170 2021-04-22  Jonathan Wakely  <jwakely@redhat.com>
6172         PR libstdc++/100179
6173         * include/bits/semaphore_base.h: Remove #error.
6174         * include/std/semaphore: Do not define anything unless one of
6175         the implementations is available.
6177 2021-04-21  Thomas Rodgers  <rodgert@twrodgers.com>
6179         * include/bits/semaphore_base.h: Always reload __old in
6180         __atomic_semaphore::_S_do_try_acquire().
6181         * testsuite/30_threads/stop_token/stop_callback/destroy.cc:
6182         re-enable testcase.
6184 2021-04-21  Philippe Blain  <levraiphilippeblain@gmail.com>
6185             Jonathan Wakely  <jwakely@redhat.com>
6187         PR libstdc++/99453
6188         * python/Makefile.am: Install libstdc++*-gdb.py more robustly.
6189         * python/Makefile.in: Regenerate.
6191 2021-04-21  Thomas Rodgers  <rodgert@twrodgers.com>
6193         * include/bits/semaphore_base.h: Add missing _M_try_acquire()
6194         member to __platform_wait.
6196 2021-04-21  Jonathan Wakely  <jwakely@redhat.com>
6198         * include/std/latch: Replace tab characters in license text.
6199         * include/std/semaphore: Likewise.
6201 2021-04-21  Jakub Jelinek  <jakub@redhat.com>
6203         PR libstdc++/100164
6204         * acinclude.m4: For POSIX semaphores AC_DEFINE HAVE_POSIX_SEMAPHORE
6205         rather than _GLIBCXX_HAVE_POSIX_SEMAPHORE.
6206         * configure: Regenerated.
6207         * config.h.in: Regenerated.
6209 2021-04-20  Jonathan Wakely  <jwakely@redhat.com>
6211         * testsuite/30_threads/semaphore/try_acquire_for.cc: Disable
6212         test for targets not using futexes for semaphores.
6213         * testsuite/30_threads/semaphore/try_acquire_until.cc: Likewise.
6214         * testsuite/30_threads/stop_token/stop_callback/destroy.cc:
6215         Disable for all targets.
6217 2021-04-20  Thomas Rodgers  <trodgers@redhat.com>
6219         * include/Makefile.am: Add new <bits/this_thread_sleep.h> header.
6220         * include/Makefile.in: Regenerate.
6221         * include/bits/this_thread_sleep.h: New file.
6222         * include/bits/atomic_base.h: Adjust all calls
6223         to __atomic_wait/__atomic_notify for new call signatures.
6224         * include/bits/atomic_timed_wait.h: Extensive rewrite.
6225         * include/bits/atomic_wait.h: Likewise.
6226         * include/bits/semaphore_base.h: Adjust all calls
6227         to __atomic_wait/__atomic_notify for new call signatures.
6228         * include/std/atomic: Likewise.
6229         * include/std/barrier: Likewise.
6230         * include/std/latch: Likewise.
6231         * include/std/semaphore: Likewise.
6232         * include/std/thread (this_thread::sleep_for)
6233         (this_thread::sleep_until): Move to new header.
6234         * testsuite/29_atomics/atomic/wait_notify/bool.cc: Simplify
6235         test.
6236         * testsuite/29_atomics/atomic/wait_notify/generic.cc: Likewise.
6237         * testsuite/29_atomics/atomic/wait_notify/pointers.cc: Likewise.
6238         * testsuite/29_atomics/atomic_flag/wait_notify/1.cc: Likewise.
6239         * testsuite/29_atomics/atomic_float/wait_notify.cc: Likewise.
6240         * testsuite/29_atomics/atomic_integral/wait_notify.cc: Likewise.
6241         * testsuite/29_atomics/atomic_ref/wait_notify.cc: Likewise.
6243 2021-04-20  Patrick Palka  <ppalka@redhat.com>
6245         PR libstdc++/95983
6246         * include/bits/stl_iterator.h (__detail::__move_iter_cat):
6247         Define.
6248         (move_iterator): Derive from the above in C++20 in order to
6249         conditionally define iterator_category as per P2259.
6250         (move_iterator::__base_cat): No longer used, so remove.
6251         (move_iterator::iterator_category): Remove in C++20.
6252         (__detail::__common_iter_use_postfix_proxy): Define.
6253         (common_iterator::_Proxy): Rename to ...
6254         (common_iterator:__arrow_proxy): ... this.
6255         (common_iterator::__postfix_proxy): Define as per P2259.
6256         (common_iterator::operator->): Adjust.
6257         (common_iterator::operator++): Adjust as per P2259.
6258         (iterator_traits<common_iterator>::_S_iter_cat): Define.
6259         (iterator_traits<common_iterator>::iterator_category): Change as
6260         per P2259.
6261         (__detail::__counted_iter_value_type): Define.
6262         (__detail::__counted_iter_concept): Define.
6263         (__detail::__counted_iter_cat): Define.
6264         (counted_iterator): Derive from the above three classes in order
6265         to conditionally define value_type, iterator_concept and
6266         iterator category respectively as per P2259.
6267         (counted_iterator::operator->): Define as per P2259.
6268         (incrementable_traits<counted_iterator>): Remove as per P2259.
6269         (iterator_traits<counted_iterator>): Adjust as per P2259.
6270         * include/std/ranges (__detail::__iota_view_iter_cat): Define.
6271         (iota_view::_Iterator): Derive from the above in order to
6272         conditionally define iterator_category as per P2259.
6273         (iota_view::_S_iter_cat): Rename to ...
6274         (iota_view::_S_iter_concept): ... this.
6275         (iota_view::iterator_concept): Use it to apply LWG 3291 changes.
6276         (iota_view::iterator_category): Remove.
6277         (__detail::__filter_view_iter_cat): Define.
6278         (filter_view::_Iterator): Derive from the above in order to
6279         conditionally define iterator_category as per P2259.
6280         (filter_view::_Iterator): Move to struct __filter_view_iter_cat.
6281         (filter_view::_Iterator::iterator_category): Remove.
6282         (transform_view::_Base): Define.
6283         (transform_view::__iter_cat): Define.
6284         (transform_view::_Iterator): Derive from the above in order to
6285         conditionally define iterator_category as per P2259.
6286         (transform_view::_Iterator::_Base): Just alias
6287         transform_view::_Base.
6288         (transform_view::_Iterator::_S_iter_cat): Move to struct
6289         transform_view::__iter_cat.
6290         (transform_view::_Iterator::iterator_category): Remove.
6291         (transform_view::_Sentinel::_Base): Just alias
6292         transform_view::_Base.
6293         (join_view::_Base): Define.
6294         (join_view::_Outer_iter): Define.
6295         (join_view::_Inner_iter): Define.
6296         (join_view::_S_ref_is_glvalue): Define.
6297         (join_view::__iter_cat): Define.
6298         (join_view::_Iterator): Derive from it in order to conditionally
6299         define iterator_category as per P2259.
6300         (join_view::_Iterator::_Base): Just alias join_view::_Base.
6301         (join_view::_Iterator::_S_ref_is_glvalue): Just alias
6302         join_view::_S_ref_is_glvalue.
6303         (join_view::_Iterator::_S_iter_cat): Move to struct
6304         transform_view::__iter_cat.
6305         (join_view::_Iterator::_Outer_iter): Just alias
6306         join_view::_Outer_iter.
6307         (join_view::_Iterator::_Inner_iter): Just alias
6308         join_view::_Inner_iter.
6309         (join_view::_Iterator::iterator_category): Remove.
6310         (join_view::_Sentinel::_Base): Just alias join_view::_Base.
6311         (__detail::__split_view_outer_iter_cat): Define.
6312         (__detail::__split_view_inner_iter_cat): Define.
6313         (split_view::_Base): Define.
6314         (split_view::_Outer_iter): Derive from __split_view_outer_iter_cat
6315         in order to conditionally define iterator_category as per P2259.
6316         (split_view::_Outer_iter::iterator_category): Remove.
6317         (split_view::_Inner_iter): Derive from __split_view_inner_iter_cat
6318         in order to conditionally define iterator_category as per P2259.
6319         (split_view::_Inner_iter::_S_iter_cat): Move to
6320         __split_view_inner_iter_cat.
6321         (split_view::_Inner_iter::iterator_category): Remove.
6322         (elements_view::_Base): Define.
6323         (elements_view::__iter_cat): Define.
6324         (elements_view::_Iterator): Derive from the above in order to
6325         conditionall define iterator_category as per P2259.
6326         (elements_view::_Iterator::_Base): Just alias
6327         elements_view::_Base.
6328         (elements_view::_Iterator::_S_iter_concept)
6329         (elements_view::_Iterator::iterator_concept): Define as per
6330         P2259.
6331         (elements_view::_Iterator::iterator_category): Remove.
6332         (elements_view::_Sentinel::_Base): Just alias
6333         elements_view::_Base.
6334         * testsuite/24_iterators/headers/iterator/synopsis_c++20.cc:
6335         Adjust constraints on iterator_traits<counted_iterator>.
6336         * testsuite/std/ranges/p2259.cc: New test.
6338 2021-04-20  Jonathan Wakely  <jwakely@redhat.com>
6340         PR libstdc++/100146
6341         * include/std/charconv (__cpp_lib_to_chars): Define
6342         conditionally.
6343         * include/std/version (__cpp_lib_to_chars): Likewise..
6344         * testsuite/20_util/from_chars/4.cc: Only check feature test
6345         macro, not _GLIBCXX_HAVE_USELOCALE.
6346         * testsuite/20_util/from_chars/5.cc: Likewise.
6347         * testsuite/20_util/from_chars/6.cc: Likewise.
6348         * testsuite/20_util/to_chars/long_double.cc: Likewise.
6350 2021-04-20  Jakub Jelinek  <jakub@redhat.com>
6352         * testsuite/util/testsuite_abi.cc (compare_symbols): If any symbol
6353         versions with _IEEE128_ substring are found, set ieee_version_found
6354         to true.  Ignore missing symbols with _IEEE128_ in version name if
6355         !ieee_version_found.  Use i->first as version_name instead of
6356         i->second.version_name if the latter is empty.
6357         * config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt: Update.
6359 2021-04-19  H.J. Lu  <hjl.tools@gmail.com>
6361         * config/abi/post/x86_64-linux-gnu/x32/baseline_symbols.txt:
6362         Updated.
6364 2021-04-17  Jakub Jelinek  <jakub@redhat.com>
6366         * config/abi/post/powerpc-linux-gnu/baseline_symbols.txt: Update.
6367         * config/abi/post/powerpc64-linux-gnu/32/baseline_symbols.txt: Update.
6369 2021-04-17  Jakub Jelinek  <jakub@redhat.com>
6371         * config/abi/post/x86_64-linux-gnu/baseline_symbols.txt: Update.
6372         * config/abi/post/x86_64-linux-gnu/32/baseline_symbols.txt: Update.
6373         * config/abi/post/i386-linux-gnu/baseline_symbols.txt: Update.
6374         * config/abi/post/i486-linux-gnu/baseline_symbols.txt: Update.
6375         * config/abi/post/s390x-linux-gnu/baseline_symbols.txt: Update.
6376         * config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt: Update.
6378 2021-04-15  Jonathan Wakely  <jwakely@redhat.com>
6380         * testsuite/lib/dg-options.exp (add_options_for_libatomic): Also
6381         add libatomic options for 32-bit sparc*-*-linux-gnu.
6383 2021-04-15  Jonathan Wakely  <jwakely@redhat.com>
6385         PR libstdc++/96657
6386         * libsupc++/Makefile.am: Add atomicity.cc here.
6387         * src/c++98/Makefile.am: Remove it from here.
6388         * libsupc++/Makefile.in: Regenerate.
6389         * src/c++98/Makefile.in: Regenerate.
6390         * testsuite/18_support/exception_ptr/96657.cc: New test.
6392 2021-04-13  Jonathan Wakely  <jwakely@redhat.com>
6394         PR libstdc++/100060
6395         * include/std/bit: Only include <ext/numeric_traits.h> for
6396         hosted build, use <limits> otherwise.
6398 2021-04-13  Jonathan Wakely  <jwakely@redhat.com>
6400         * doc/xml/manual/backwards_compatibility.xml: Remove porting
6401         notes for libg++ and libstdc++-v2, and bibliography.
6402         * doc/html/*: Regenerated.
6404 2021-04-12  Jonathan Wakely  <jwakely@redhat.com>
6406         PR libstdc++/100044
6407         * include/bits/ranges_util.h (__detail::__iterator_sentinel_pair):
6408         Remove helper concept.
6409         (subrange(_Pr), subrange(Pr, __make_unsigned_like<...>)): Remove
6410         deduction guides, as per LWG 3404.
6411         * testsuite/std/ranges/subrange/lwg3282_neg.cc: Check that class
6412         template argument deduction fails.
6414 2021-04-12  Jonathan Wakely  <jwakely@redhat.com>
6416         * testsuite/26_numerics/random/linear_congruential_engine/requirements/non_uint_neg.cc:
6417         Adjust expected error for C++20 mode.
6418         * testsuite/tr1/5_numerical_facilities/random/linear_congruential/requirements/non_uint_neg.cc:
6419         Likewise.
6421 2021-04-12  Jonathan Wakely  <jwakely@redhat.com>
6423         PR libstdc++/99995
6424         * testsuite/17_intro/headers/c++1998/49745.cc: Include all
6425         standard headers and XFAIL for effective-target c++20.
6427 2021-04-09  François Dumont  <fdumont@gcc.gnu.org>
6429         PR libstdc++/99402
6430         * include/debug/helper_functions.h (__can_advance(_InputIterator,
6431         const std::pair<_Diff, _Distance_precision>&, int)): New.
6432         (__can_advance(const _Safe_iterator<>&,
6433         const std::pair<_Diff, _Distance_precision>&, int)): New.
6434         * include/debug/macros.h (__glibcxx_check_can_increment_dist): New,
6435         use latter.
6436         (__glibcxx_check_can_increment_range): Adapt to use latter.
6437         (__glibcxx_check_can_decrement_range): Likewise.
6438         * include/debug/safe_iterator.h
6439         (_Safe_iterator<>::_M_can_advance(const std::pair<_Diff, _Distance_precision>&,
6440         int)): New.
6441         (__can_advance(const _Safe_iterator<>&,
6442         const std::pair<_Diff, _Distance_precision>&, int)): New.
6443         * include/debug/safe_iterator.tcc
6444         (_Safe_iterator<>::_M_can_advance(const std::pair<_Diff, _Distance_precision>&,
6445         int)): New.
6446         (_Safe_iterator<>::_M_valid_range(const _Safe_iterator<>&,
6447         std::pair<difference_type, _Distance_precision>&, bool)): Adapt for
6448         __dp_sign_max_size.
6449         (__copy_move_a): Adapt to use __glibcxx_check_can_increment_dist.
6450         (__copy_move_backward_a): Likewise.
6451         (__equal_aux): Likewise.
6452         * include/debug/stl_iterator.h (__can_advance(const std::reverse_iterator<>&,
6453         const std::pair<_Diff, _Distance_precision>&, int)): New.
6454         (__can_advance(const std::move_iterator<>&,
6455         const std::pair<_Diff, _Distance_precision>&, int)): New.
6456         * testsuite/25_algorithms/copy/debug/99402.cc: New test.
6458 2021-04-09  Jonathan Wakely  <jwakely@redhat.com>
6460         PR libstdc++/99985
6461         * include/bits/hashtable.h (_Hashtable::_S_nothrow_move()): Fix
6462         to be a valid constexpr function in C++11.
6463         * testsuite/23_containers/unordered_set/cons/99985.cc: New test.
6465 2021-04-09  Jonathan Wakely  <jwakely@redhat.com>
6467         * include/bits/fs_fwd.h: Fix doxygen group command.
6468         * include/bits/streambuf_iterator.h: Likewise.
6469         * include/bits/uses_allocator_args.h: Likewise.
6470         * include/std/memory: Likewise.
6471         * include/tr1/complex: Likewise.
6473 2021-04-08  Jonathan Wakely  <jwakely@redhat.com>
6475         * include/bits/basic_string.h: Tweak doxygen comment.
6477 2021-04-08  Patrick Palka  <ppalka@redhat.com>
6479         * include/std/ranges (__detail::find): Define.
6480         (split_view::_OuterIter::operator++): Apply proposed resolution
6481         of LWG 3505.
6482         * testsuite/std/ranges/adaptors/split.cc (test10): New test.
6484 2021-04-08  Patrick Palka  <ppalka@redhat.com>
6486         * include/std/ranges (__detail::find_if): Simplify.
6487         (__detail::find_if_not): Likewise.
6488         (__detail::min): Remove.
6489         (__detail::mismatch): Simplify.
6490         (take_view::size): Use std::min instead of __detail::min.
6492 2021-04-08  Patrick Palka  <ppalka@redhat.com>
6494         * include/std/ranges (__detail::__returnable_element): New
6495         concept.
6496         (elements_view): Use this concept in its constraints.  Add
6497         missing private access specifier.
6498         (elements_view::_S_get_element): Define as per LWG 3502.
6499         (elements_view::operator*, elements_view::operator[]): Use
6500         _S_get_element.
6501         (elements_view::operator++): Remove unnecessary constraint
6502         as per LWG 3492.
6503         * testsuite/std/ranges/adaptors/elements.cc (test05): New test.
6505 2021-04-08  Jonathan Wakely  <jwakely@redhat.com>
6507         * doc/Makefile.am (stamp-pdf-doxygen): Also grep for
6508         out-of-memory error in log file.
6509         * doc/Makefile.in: Regenerate.
6511 2021-04-08  Jonathan Wakely  <jwakely@redhat.com>
6513         * configure: Regenerate.
6515 2021-04-08  Jonathan Wakely  <jwakely@redhat.com>
6517         * include/bits/random.h: Fix doxygen group commands.
6518         * include/bits/regex_constants.h: Likewise.
6519         * include/tr1/random.h: Likewise.
6521 2021-04-08  Jonathan Wakely  <jwakely@redhat.com>
6523         * include/bits/hashtable.h (_Hashtable::_S_nothrow_move()):
6524         New function to determine noexcept-specifier for move
6525         constructors.
6526         (_Hashtable): Use _S_nothrow_move() on move constructors.
6527         * testsuite/23_containers/unordered_map/cons/noexcept_move_construct.cc:
6528         Correct static assertion message.
6529         * testsuite/23_containers/unordered_multimap/cons/noexcept_move_construct.cc:
6530         Likewise.
6531         * testsuite/23_containers/unordered_multiset/cons/noexcept_move_construct.cc:
6532         Likewise.
6533         * testsuite/23_containers/unordered_set/cons/noexcept_move_construct.cc:
6534         Likewise.
6536 2021-04-08  Patrick Palka  <ppalka@redhat.com>
6538         PR libstdc++/98384
6539         * testsuite/20_util/to_chars/long_double.cc: Don't run the test
6540         on targets without a large long double.  XFAIL the execution on
6541         targets with a non-conforming printf.
6543 2021-04-08  Patrick Palka  <ppalka@redhat.com>
6545         PR libstdc++/99433
6546         * include/std/ranges (__adaptor::__maybe_refwrap): Remove.
6547         (__adaptor::__adaptor_invocable): New concept.
6548         (__adaptor::__adaptor_partial_app_viable): New concept.
6549         (__adaptor::_RangeAdaptorClosure): Rewrite, turning it into a
6550         non-template base class.
6551         (__adaptor::_RangeAdaptor): Rewrite, turning it into a CRTP base
6552         class template.
6553         (__adaptor::_Partial): New class template that represents
6554         partial application of a range adaptor non-closure.
6555         (__adaptor::__pipe_invocable): New concept.
6556         (__adaptor::_Pipe): New class template.
6557         (__detail::__can_ref_view): New concept.
6558         (__detail::__can_subrange): New concept.
6559         (all): Replace the lambda here with ...
6560         (_All): ... this functor.  Add appropriate constraints.
6561         (__detail::__can_filter_view): New concept.
6562         (filter, _Filter): As in all/_All.
6563         (__detail::__can_transform): New concept.
6564         (transform, _Transform): As in all/_All.
6565         (__detail::__can_take_view): New concept.
6566         (take, _Take): As in all/_All.
6567         (__detail::__can_take_while_view): New concept.
6568         (take_while, _TakeWhile): As in all/_All.
6569         (__detail::__can_drop_view): New concept.
6570         (drop, _Drop): As in all/_All.
6571         (__detail::__can_drop_while_view): New concept.
6572         (drop_while, _DropWhile): As in all/_All.
6573         (__detail::__can_join_view): New concept.
6574         (join, _Join): As in all/_All.
6575         (__detail::__can_split_view): New concept.
6576         (split, _Split): As in all/_All.  Rename template parameter
6577         _Fp to _Pattern.
6578         (__detail::__already_common): New concept.
6579         (__detail::__can_common_view): New concept.
6580         (common, _Common): As in all/_All.
6581         (__detail::__can_reverse_view): New concept.
6582         (reverse, _Reverse): As in all/_All.
6583         (__detail::__can_elements_view): New concept.
6584         (elements, _Elements): As in all/_All.
6585         (keys, values): Adjust.
6586         * testsuite/std/ranges/adaptors/99433.cc: New test.
6587         * testsuite/std/ranges/adaptors/all.cc: No longer expect that
6588         adding empty range adaptor closure objects to a pipeline doesn't
6589         increase the size of the pipeline.
6590         (test05): New test.
6591         * testsuite/std/ranges/adaptors/common.cc (test03): New test.
6592         * testsuite/std/ranges/adaptors/drop.cc (test09): New test.
6593         * testsuite/std/ranges/adaptors/drop_while.cc (test04): New test.
6594         * testsuite/std/ranges/adaptors/elements.cc (test04): New test.
6595         * testsuite/std/ranges/adaptors/filter.cc (test06): New test.
6596         * testsuite/std/ranges/adaptors/join.cc (test09): New test.
6597         * testsuite/std/ranges/adaptors/p2281.cc: New test.
6598         * testsuite/std/ranges/adaptors/reverse.cc (test07): New test.
6599         * testsuite/std/ranges/adaptors/split.cc (test01, test04):
6600         Adjust.
6601         (test09): New test.
6602         * testsuite/std/ranges/adaptors/split_neg.cc (test01): Adjust
6603         expected error message.
6604         (test02): Likewise.  Extend test.
6605         * testsuite/std/ranges/adaptors/take.cc (test06): New test.
6606         * testsuite/std/ranges/adaptors/take_while.cc (test05): New test.
6607         * testsuite/std/ranges/adaptors/transform.cc (test07, test08):
6608         New test.
6610 2021-04-08  Jonathan Wakely  <jwakely@redhat.com>
6612         * include/std/string_view: Adjust Doxygen @file comment.
6614 2021-04-08  Jonathan Wakely  <jwakely@redhat.com>
6616         * include/std/type_traits (is_scoped_enum<T>): Constrain partial
6617         specialization to not match incomplete enum types. Use a
6618         requires-expression instead of instantiating is_convertible.
6619         (is_scoped_enum<const T>): Add as workaround for PR c++/99968.
6620         * testsuite/20_util/is_scoped_enum/value.cc: Check with
6621         incomplete types and opaque-enum-declarations.
6623 2021-04-07  Jonathan Wakely  <jwakely@redhat.com>
6625         PR libstdc++/99805
6626         * src/c++17/fs_path.cc (path::_M_split_cmpts): Do not call
6627         non-const member on _M_pathname, to avoid copy-on-write.
6628         * testsuite/27_io/filesystem/path/decompose/parent_path.cc:
6629         Check construction from strings that might be shared.
6631 2021-04-06  Jonathan Wakely  <jwakely@redhat.com>
6633         * include/bits/move.h (forward, move, move_if_noexcept)
6634         (addressof): Add _GLIBCXX_NODISCARD.
6635         * include/bits/ranges_cmp.h (identity::operator()): Add
6636         nodiscard attribute.
6637         * include/c_global/cstddef (to_integer): Likewise.
6638         * include/std/bit (bit_cast): Likewise.
6639         * include/std/utility (as_const, to_underlying): Likewise.
6641 2021-04-06  Jonathan Wakely  <jwakely@redhat.com>
6643         * include/bits/move.h (forward): Change static_assert message
6644         to be unambiguous about what must be true.
6645         * testsuite/20_util/forward/c_neg.cc: Adjust dg-error.
6646         * testsuite/20_util/forward/f_neg.cc: Likewise.
6648 2021-04-06  Jonathan Wakely  <jwakely@redhat.com>
6650         * include/bits/alloc_traits.h: Use markdown for code font.
6651         * include/bits/basic_string.h: Fix @param names.
6652         * include/bits/max_size_type.h: Remove period after @file.
6653         * include/bits/regex.h: Fix duplicate @retval names, and rename.
6654         * include/ext/pb_ds/detail/priority_queue_base_dispatch.hpp: Add
6655         group open to match existing group close.
6656         * include/ext/pb_ds/priority_queue.hpp: Add blank line before group
6657         open.
6659 2021-04-06  Jonathan Wakely  <jwakely@redhat.com>
6661         * include/bits/atomic_base.h: Fix doxygen group close.
6662         * include/bits/basic_ios.h: Likewise.
6663         * include/bits/forward_list.h: Likewise.
6664         * include/bits/fs_dir.h: Likewise.
6665         * include/bits/fs_ops.h: Likewise.
6666         * include/bits/fs_path.h: Likewise.
6667         * include/bits/functional_hash.h: Likewise.
6668         * include/bits/gslice.h: Likewise.
6669         * include/bits/gslice_array.h: Likewise.
6670         * include/bits/hashtable_policy.h: Likewise.
6671         * include/bits/indirect_array.h: Likewise.
6672         * include/bits/locale_classes.h: Likewise.
6673         * include/bits/locale_facets.h: Likewise.
6674         * include/bits/locale_facets_nonio.h: Likewise.
6675         * include/bits/mask_array.h: Likewise.
6676         * include/bits/refwrap.h: Likewise.
6677         * include/bits/regex.h: Likewise.
6678         * include/bits/regex_automaton.h: Likewise.
6679         * include/bits/regex_compiler.h: Likewise.
6680         * include/bits/regex_constants.h: Likewise.
6681         * include/bits/regex_error.h: Likewise.
6682         * include/bits/regex_executor.h: Likewise.
6683         * include/bits/regex_scanner.h: Likewise.
6684         * include/bits/shared_ptr.h: Likewise.
6685         * include/bits/shared_ptr_atomic.h: Likewise.
6686         * include/bits/shared_ptr_base.h: Likewise.
6687         * include/bits/slice_array.h: Likewise.
6688         * include/bits/specfun.h: Likewise.
6689         * include/bits/std_function.h: Likewise.
6690         * include/bits/std_mutex.h: Likewise.
6691         * include/bits/stl_deque.h: Likewise.
6692         * include/bits/stl_iterator.h: Likewise.
6693         * include/bits/stl_iterator_base_types.h: Likewise.
6694         * include/bits/stl_map.h: Likewise.
6695         * include/bits/stl_multimap.h: Likewise.
6696         * include/bits/stl_multiset.h: Likewise.
6697         * include/bits/stl_numeric.h: Likewise.
6698         * include/bits/stl_pair.h: Likewise.
6699         * include/bits/stl_set.h: Likewise.
6700         * include/bits/stl_uninitialized.h: Likewise.
6701         * include/bits/stream_iterator.h: Likewise.
6702         * include/bits/streambuf_iterator.h: Likewise.
6703         * include/bits/unique_ptr.h: Likewise.
6704         * include/bits/unordered_map.h: Likewise.
6705         * include/bits/unordered_set.h: Likewise.
6706         * include/decimal/decimal: Likewise.
6707         * include/experimental/any: Likewise.
6708         * include/experimental/array: Likewise.
6709         * include/experimental/bits/fs_dir.h: Likewise.
6710         * include/experimental/bits/fs_fwd.h: Likewise.
6711         * include/experimental/bits/fs_ops.h: Likewise.
6712         * include/experimental/bits/fs_path.h: Likewise.
6713         * include/experimental/buffer: Likewise.
6714         * include/experimental/internet: Likewise.
6715         * include/experimental/optional: Likewise.
6716         * include/experimental/propagate_const: Likewise.
6717         * include/experimental/socket: Likewise.
6718         * include/ext/pb_ds/assoc_container.hpp: Likewise.
6719         * include/ext/pb_ds/detail/priority_queue_base_dispatch.hpp:
6720         Likewise.
6721         * include/ext/pb_ds/detail/tree_policy/node_metadata_selector.hpp: Likewise.
6722         * include/ext/pb_ds/detail/trie_policy/node_metadata_selector.hpp: Likewise.
6723         * include/ext/pb_ds/detail/types_traits.hpp: Likewise.
6724         * include/ext/pb_ds/exception.hpp: Likewise.
6725         * include/ext/pb_ds/priority_queue.hpp: Likewise.
6726         * include/ext/pb_ds/tag_and_trait.hpp: Likewise.
6727         * include/ext/random: Likewise.
6728         * include/std/any: Likewise.
6729         * include/std/atomic: Likewise.
6730         * include/std/bitset: Likewise.
6731         * include/std/chrono: Likewise.
6732         * include/std/complex: Likewise.
6733         * include/std/condition_variable: Likewise.
6734         * include/std/fstream: Likewise.
6735         * include/std/future: Likewise.
6736         * include/std/iostream: Likewise.
6737         * include/std/istream: Likewise.
6738         * include/std/mutex: Likewise.
6739         * include/std/numeric: Likewise.
6740         * include/std/ostream: Likewise.
6741         * include/std/ratio: Likewise.
6742         * include/std/shared_mutex: Likewise.
6743         * include/std/stdexcept: Likewise.
6744         * include/std/streambuf: Likewise.
6745         * include/std/system_error: Likewise.
6746         * include/std/thread: Likewise.
6747         * include/std/valarray: Likewise.
6748         * include/std/variant: Likewise.
6749         * include/tr1/cmath: Likewise.
6750         * include/tr1/regex: Likewise.
6751         * include/tr2/dynamic_bitset: Likewise.
6752         * libsupc++/atomic_lockfree_defines.h: Likewise.
6753         * libsupc++/exception: Likewise.
6754         * libsupc++/exception.h: Likewise.
6755         * libsupc++/exception_ptr.h: Likewise.
6756         * libsupc++/nested_exception.h: Likewise.
6758 2021-03-31  Alexandre Oliva  <oliva@adacore.com>
6760         * testsuite/30_threads/future/members/poll.cc: Use faster
6761         after-ready call in the calibration loop.
6763 2021-03-29  Jonathan Wakely  <jwakely@redhat.com>
6765         * doc/xml/manual/status_cxx2017.xml: Adjust link for PSTL.
6766         * doc/html/manual/status.html: Regenerate.
6768 2021-03-28  François Dumont  <fdumont@gcc.gnu.org>
6770         * include/debug/forward_list
6771         (forward_list(forward_list&&, const allocator_type&)): Add noexcept qualification.
6772         * include/debug/list (list(list&&, const allocator_type&)): Likewise and add
6773         call to safe container allocator aware move constructor.
6774         * include/debug/vector (vector(vector&&, const allocator_type&)):
6775         Fix noexcept qualification.
6776         * testsuite/23_containers/forward_list/cons/noexcept_move_construct.cc:
6777         Add allocator-extended move constructor noexceot qualification check.
6778         * testsuite/23_containers/list/cons/noexcept_move_construct.cc: Likewise.
6780 2021-03-26  Jonathan Wakely  <jwakely@redhat.com>
6782         * src/c++11/random.cc (USE_LCG): Define when a pseudo-random
6783         fallback is needed.
6784         [USE_LCG] (bad_seed, construct_lcg_at, destroy_lcg_at, __lcg):
6785         New helper functions and callback.
6786         (random_device::_M_init): Add 'prng' and 'all' enumerators.
6787         Replace switch with fallthrough with a series of 'if' statements.
6788         [USE_LCG]: Construct an lcg_type engine and use __lcg when cpuid
6789         checks fail.
6790         (random_device::_M_init_pretr1) [USE_MT19937]: Accept "prng"
6791         token.
6792         (random_device::_M_getval): Check for callback unconditionally
6793         and always pass _M_file pointer.
6794         * testsuite/26_numerics/random/random_device/85494.cc: Remove
6795         effective-target check. Use new random_device_available helper.
6796         * testsuite/26_numerics/random/random_device/94087.cc: Likewise.
6797         * testsuite/26_numerics/random/random_device/cons/default-cow.cc:
6798         Remove effective-target check.
6799         * testsuite/26_numerics/random/random_device/cons/default.cc:
6800         Likewise.
6801         * testsuite/26_numerics/random/random_device/cons/token.cc: Use
6802         new random_device_available helper. Test "prng" token.
6803         * testsuite/util/testsuite_random.h (random_device_available):
6804         New helper function.
6806 2021-03-25  François Dumont  <fdumont@gcc.gnu.org>
6808         * include/debug/string
6809         (basic_string(const basic_string&, const _Alloc&)): Define even if !_GLIBCXX_USE_CXX11_ABI.
6810         (basic_string(basic_string&&, const _Alloc&)): Likewise and add noexcept qualification.
6811         (basic_string<>::erase): Adapt to take __const_iterator.
6812         (basic_string(const _CharT*, const _Allocator&)): Remove assign call.
6813         (basic_string<>::insert(const_iterator, _InputIte, _InputIte)): Try to
6814         remove iterator debug layer even if !_GLIBCXX_USE_CXX11_ABI.
6815         [_GLIBCXX_USE_CHAR8_T] (__gnu_debug::u8string): New.
6816         (__gnu_debug::u16string, __gnu_debug::u32string): New.
6817         (std::hash<__gnu_debug::basic_string<>>): New partial specialization.
6818         (std::__is_fast_hash<__gnu_debug::basic_string<>>): Likewise.
6819         * testsuite/util/exception/safety.h
6820         (erase_base<__gnu_debug::basic_string<>>): New partial specialization.
6821         (insert_base<__gnu_debug::basic_string<>>): Likewise.
6822         * testsuite/util/testsuite_container_traits.h (traits<__gnu_debug::basic_string<>>):
6823         New partial specialization.
6824         * testsuite/21_strings/basic_string/hash/debug.cc: New test.
6825         * testsuite/21_strings/basic_string/requirements/citerators.cc:
6826         Add test on __gnu_debug::string.
6827         * testsuite/21_strings/basic_string/requirements/dr438/constructor.cc: Likewise.
6828         * testsuite/21_strings/basic_string/requirements/exception/basic.cc: Likewise.
6829         * testsuite/21_strings/basic_string/requirements/exception/generation_prohibited.cc:
6830         Likewise.
6831         * testsuite/21_strings/basic_string/requirements/exception/propagation_consistent.cc:
6832         Likewise.
6833         * testsuite/21_strings/basic_string/requirements/explicit_instantiation/char/1.cc:
6834         Likewise.
6835         * testsuite/21_strings/basic_string/requirements/explicit_instantiation/char16_t/1.cc:
6836         Likewise.
6837         * testsuite/21_strings/basic_string/requirements/explicit_instantiation/char32_t/1.cc:
6838         Likewise.
6839         * testsuite/21_strings/basic_string/requirements/explicit_instantiation/char8_t/1.cc:
6840         Likewise.
6841         * testsuite/21_strings/basic_string/requirements/explicit_instantiation/wchar_t/1.cc:
6842         Likewise.
6843         * testsuite/21_strings/basic_string/requirements/typedefs.cc: Likewise.
6845 2021-03-25  Jakub Jelinek  <jakub@redhat.com>
6847         PR c++/99672
6848         * testsuite/18_support/source_location/consteval.cc (main): Adjust
6849         expected column numbers.
6850         * testsuite/18_support/source_location/1.cc (main): Likewise.
6852 2021-03-25  Jonathan Wakely  <jwakely@redhat.com>
6854         * libsupc++/new_opa.cc [!_GLIBCXX_HOSTED]: Declare malloc.
6856 2021-03-25  Jonathan Wakely  <jwakely@redhat.com>
6858         * testsuite/util/exception/safety.h (setup_base::generate):
6859         Support seeding random engine.
6860         (erase_point, erase_range): Adjust range of random numbers to
6861         ensure dereferenceable iterators are used where required.
6862         (generation_prohibited::run): Do not try to erase from empty
6863         containers.
6864         * testsuite/util/testsuite_containergen.h (test_containers):
6865         Support seeding random engine.
6867 2021-03-23  Jonathan Wakely  <jwakely@redhat.com>
6869         * testsuite/std/ranges/adaptors/reverse.cc: Replace duplicated
6870         line with a check that uses the const being/end overloads.
6872 2021-03-23  Moritz Sichert  <sichert@in.tum.de>
6874         * include/std/ranges (reverse_view::begin, reverse_view::end):
6875         Qualify make_reverse_iterator calls to avoid ADL.
6876         * testsuite/std/ranges/adaptors/reverse.cc: Test that
6877         views::reverse works when make_reverse_iterator is defined
6878         in an associated namespace.
6880 2021-03-23  Jonathan Wakely  <jwakely@redhat.com>
6882         * include/bits/c++config (_GLIBCXX_LONG_DOUBLE_ALT128_COMPAT):
6883         Do not define when compiling with Clang.
6885 2021-03-22  Jonathan Wakely  <jwakely@redhat.com>
6887         * include/std/string_view (basic_string_view(Range&&)): Define new
6888         constructor and deduction guide.
6889         * testsuite/21_strings/basic_string_view/cons/char/range_c++20.cc: New test.
6890         * testsuite/21_strings/basic_string_view/cons/wchar_t/range_c++20.cc: New test.
6892 2021-03-22  Jonathan Wakely  <jwakely@redhat.com>
6894         * include/bits/range_access.h (begin(T (&)[N]), end(T (&)[N])):
6895         Add missing 'noexcept' as per LWG 2280.
6896         (rbegin(T (&)[N]), rend(T (&)[N]), rbegin(initializer_list<T>))
6897         (rend(initializer_list<T>)): Add 'noexcept' as per LWG 3537.
6898         * testsuite/24_iterators/range_access/range_access.cc: Check for
6899         expected noexcept specifiers. Check result types of generic
6900         std::begin and std::end overloads.
6901         * testsuite/24_iterators/range_access/range_access_cpp14.cc:
6902         Check for expected noexcept specifiers.
6903         * testsuite/24_iterators/range_access/range_access_cpp17.cc:
6904         Likewise.
6906 2021-03-19  Jonathan Wakely  <jwakely@redhat.com>
6908         * include/std/type_traits (is_scoped_enum): Define.
6909         * include/std/version (__cpp_lib_is_scoped_enum): Define.
6910         * testsuite/20_util/is_scoped_enum/value.cc: New test.
6911         * testsuite/20_util/is_scoped_enum/version.cc: New test.
6913 2021-03-16  Jonathan Wakely  <jwakely@redhat.com>
6915         PR libstdc++/99341
6916         * config/abi/post/aarch64-linux-gnu/baseline_symbols.txt: Remove
6917         std::once_flag symbols.
6918         * config/abi/post/ia64-linux-gnu/baseline_symbols.txt: Likewise.
6919         * config/abi/post/m68k-linux-gnu/baseline_symbols.txt: Likewise.
6920         * config/abi/post/riscv64-linux-gnu/baseline_symbols.txt:
6921         Likewise.
6922         * config/abi/pre/gnu.ver: Likewise.
6923         * src/c++11/mutex.cc [_GLIBCXX_HAVE_LINUX_FUTEX]
6924         (struct __once_flag_compat): Remove.
6925         (_ZNSt9once_flag11_M_activateEv): Remove.
6926         (_ZNSt9once_flag9_M_finishEb): Remove.
6928 2021-03-16  Jonathan Wakely  <jwakely@redhat.com>
6930         PR libstdc++/99341
6931         * include/std/mutex [_GLIBCXX_HAVE_LINUX_FUTEX] (once_flag):
6932         Revert to pthread_once_t implementation.
6933         [_GLIBCXX_HAVE_LINUX_FUTEX] (call_once): Likewise.
6934         * src/c++11/mutex.cc [_GLIBCXX_HAVE_LINUX_FUTEX]
6935         (struct __once_flag_compat): New type matching the reverted
6936         implementation of once_flag using futexes.
6937         (once_flag::_M_activate): Remove, replace with ...
6938         (_ZNSt9once_flag11_M_activateEv): ... alias symbol.
6939         (once_flag::_M_finish): Remove, replace with ...
6940         (_ZNSt9once_flag9_M_finishEb): ... alias symbol.
6941         * testsuite/30_threads/call_once/66146.cc: Removed.
6943 2021-03-15  Iain Sandoe  <iain@sandoe.co.uk>
6945         * testsuite/17_intro/names.cc: Exclude j from the list
6946         of test symbols for Darwin.
6948 2021-03-15  Iain Sandoe  <iain@sandoe.co.uk>
6950         * config/os/bsd/darwin/ppc-extra.ver: Add matching for
6951         to_chars and from_chars for long double.
6953 2021-03-15  Patrick Palka  <ppalka@redhat.com>
6955         * include/bits/max_size_type.h (__max_size_type::operator _Tp):
6956         Fix formatting.
6957         (__max_size_type::operator++): Define.
6958         (__max_size_type::operator--): Likewise.
6959         (__max_size_type::operator<=>): Conditionally define (in place
6960         of the other comparison operators).
6961         (__max_diff_type::operator _Tp): Fix formatting.
6962         (__max_diff_type::operator++): Define.
6963         (__max_diff_type::operator--): Likewise.
6964         (__max_diff_type::operator<=>): Conditionally define (in place
6965         of the other comparison operators).
6966         * testsuite/std/ranges/iota/max_size_type.cc (test01): Test
6967         these operator overloads.
6969 2021-03-15  Caroline Tice  <cmtice@google.com>
6971         PR libstdc++/99172
6972         * src/Makefile.am (AM_CXXFLAGS_PRE, AM_CXXFLAGS): Add
6973         AM_CXXFLAGS_PRE with the old definition of AM_CXXFLAGS; make
6974         AM_CXXFLAGS to be AM_CXXFLAGS_PRE with '-fvtable-verify=std'
6975         filtered out.
6976         * src/Makefile.in: Regenerate.
6978 2021-03-11  Patrick Palka  <ppalka@redhat.com>
6980         * src/c++17/floating_to_chars.cc: Simplify the file as if
6981         __SIZEOF_INT128__ is always defined.
6982         [!defined __SIZEOF_INT128__]: Include "uint128_t.h".  Define
6983         a base-10 to_chars overload for the uint128_t class type.
6984         * src/c++17/uint128_t.h: New file.
6985         * testsuite/20_util/to_chars/long_double.cc: No longer expect an
6986         execution FAIL on targets that have a large long double type
6987         but lack __int128.
6989 2021-03-11  Patrick Palka  <ppalka@redhat.com>
6991         * src/c++17/ryu/LOCAL_PATCHES: Update.
6992         * src/c++17/ryu/d2s_intrinsics.h: Don't define uint128_t.
6993         * src/c++17/ryu/generic_128.h: Likewise.
6994         * src/c++17/ryu/ryu_generic_128.h (struct floating_decimal_128):
6995         Use uint128_t instead of __uint128_t.
6996         (generic_binary_to_decimal): Likewise.
6998 2021-03-11  Patrick Palka  <ppalka@redhat.com>
7000         * src/c++17/ryu/LOCAL_PATCHES: New file.
7002 2021-03-11  Patrick Palka  <ppalka@redhat.com>
7004         * src/c++17/floating_to_chars.cc (uint128_t): New conditionally
7005         defined alias of unsigned __int128.
7006         (floating_type_traits_binary128::mantissa_t): Use uint128_t
7007         instead of unsigned __int128.
7008         (floating_type_traits<long double>::mantissa_t)
7009         [LONG_DOUBLE_KIND == LDK_IBM128]: Likewise.
7010         (get_ieee_repr): Likewise.  Make casts from uint_t to mantissa_t
7011         and uint32_t explicit.  Simplify the extraction of mantissa,
7012         exponent and sign bit.
7014 2021-03-11  Jonathan Wakely  <jwakely@redhat.com>
7016         * include/std/barrier (barrier::arrival_token): New move-only
7017         class that encapsulates the underlying token value.
7019 2021-03-11  Jonathan Wakely  <jwakely@redhat.com>
7021         * python/libstdcxx/v6/printers.py (find_type): Use tag attribute
7022         instead of unqualified() method.
7024 2021-03-11  Jonathan Wakely  <jwakely@redhat.com>
7026         PR libstdc++/99537
7027         * include/std/stop_token (_Stop_state_t::_M_release_ownership):
7028         Use acq_rel memory ordering.
7030 2021-03-11  Jonathan Wakely  <jwakely@redhat.com>
7032         PR libstdc++/99533
7033         * src/c++17/fs_dir.cc (recursive_directory_iterator): Use new
7034         helper function to check for permission denied errors.
7035         * src/filesystem/dir.cc (recursive_directory_iterator):
7036         Likewise.
7037         * src/filesystem/dir-common.h (is_permission_denied_error): New
7038         helper function.
7040 2021-03-11  Jonathan Wakely  <jwakely@redhat.com>
7042         PR libstdc++/99536
7043         * include/bits/random.h (normal_distribution): Use
7044         default-initializer for _M_saved and _M_saved_available.
7046 2021-03-10  John David Anglin  <danglin@gcc.gnu.org>
7048         * testsuite/29_atomics/atomic/wait_notify/bool.cc: Add options to
7049         link with libatomic.
7050         * testsuite/29_atomics/atomic/wait_notify/generic.cc: Likewise.
7051         * testsuite/29_atomics/atomic/wait_notify/pointers.cc: Likewise.
7052         * testsuite/29_atomics/atomic_flag/wait_notify/1.cc: Likewise.
7053         * testsuite/30_threads/barrier/arrive.cc: Likewise.
7054         * testsuite/30_threads/barrier/arrive_and_drop.cc: Likewise.
7055         * testsuite/30_threads/barrier/arrive_and_wait.cc: Likewise.
7056         * testsuite/30_threads/barrier/completion.cc: Likewise.
7057         * testsuite/30_threads/latch/3.cc: Likewise.
7058         * testsuite/30_threads/semaphore/try_acquire.cc: Likewise.
7059         * testsuite/30_threads/semaphore/try_acquire_for.cc: Likewise.
7060         * testsuite/30_threads/semaphore/try_acquire_until.cc: Likewise.
7062 2021-03-10  Jonathan Wakely  <jwakely@redhat.com>
7064         PR libstdc++/99413
7065         * include/bits/align.h: Include debug/assertions.h.
7066         * include/bits/codecvt.h: Include bits/c++config.h.
7067         * include/bits/enable_special_members.h: Likewise.
7068         * include/bits/erase_if.h: Likewise.
7069         * include/bits/functional_hash.h: Include <type_traits>.
7070         * include/bits/invoke.h: Include bits/move.h.
7071         * include/bits/ostream_insert.h: Include bits/exception_defines.h.
7072         * include/bits/parse_numbers.h: Include <type_traits>.
7073         * include/bits/predefined_ops.h: Include bits/c++config.h.
7074         * include/bits/range_access.h: Include bits/stl_iterator.h.
7075         * include/bits/stl_bvector.h: Do not include bits/stl_vector.h.
7076         * include/bits/stl_iterator.h: Include bits/stl_iterator_base_types.h.
7077         * include/bits/stl_uninitialized.h: Include bits/stl_algobase.h.
7078         * include/bits/uniform_int_dist.h: Include bits/concept_check.h.
7079         * include/bits/unique_lock.h: Include bits/std_mutex.h.
7080         * include/debug/assertions.h: Include bits/c++config.h.
7082 2021-03-10  Jonathan Wakely  <jwakely@redhat.com>
7084         * include/bits/ranges_cmp.h (__eq_builtin_ptr_cmp): Remove.
7085         (ranges::equal_to, ranges::not_equal_to): Do not constrain
7086         with __eq_builtin_ptr_cmp.
7087         (ranges::less, ranges::greater, ranges::less_equal)
7088         (ranges::greater_equal): Do not constrain with
7089         __less_builtin_ptr_cmp.
7090         * libsupc++/compare (compare_three_way): Do not constrain with
7091         __3way_builtin_ptr_cmp.
7092         * testsuite/18_support/comparisons/object/builtin-ptr-three-way.cc: Moved to...
7093         * testsuite/18_support/comparisons/object/lwg3530.cc: ...here.
7094         * testsuite/20_util/function_objects/range.cmp/lwg3530.cc: New test.
7096 2021-03-10  Jonathan Wakely  <jwakely@redhat.com>
7098         * testsuite/std/time/syn_c++20.cc: Enable synopsis checks for
7099         C++20 calendar types.
7101 2021-03-06  Jakub Jelinek  <jakub@redhat.com>
7103         PR libstdc++/99396
7104         * include/std/bit (__rotl, __rotr): Add optimized variants for power of
7105         two _Nd which the compiler can pattern match the rotates.
7107 2021-03-04  Jonathan Wakely  <jwakely@redhat.com>
7109         PR libstdc++/99382
7110         * testsuite/20_util/specialized_algorithms/uninitialized_default_n/sizes.cc:
7111         Make storage larger than required. Verify no write to the last
7112         element.
7113         * testsuite/20_util/specialized_algorithms/uninitialized_value_construct_n/sizes.cc:
7114         Likewise.
7116 2021-03-03  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
7118         * config/abi/post/i386-solaris/baseline_symbols.txt: Regenerate.
7119         * config/abi/post/i386-solaris/amd64/baseline_symbols.txt:
7120         Likewise.
7121         * config/abi/post/sparc-solaris/baseline_symbols.txt: Likewise.
7122         * config/abi/post/sparc-solaris/sparcv9/baseline_symbols.txt:
7123         Likewise.
7125 2021-03-03  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
7127         * include/experimental/bits/simd.h: Replace reserved _X, _B by
7128         _Xp, _Bp.
7129         * include/experimental/bits/simd_builtin.h: Likewise.
7130         * include/experimental/bits/simd_x86.h: Likewise.
7132 2021-02-27  Jonathan Wakely  <jwakely@redhat.com>
7134         PR libstdc++/99301
7135         * include/std/chrono (year_month_day::_M_days_since_epoch()):
7136         Convert chrono::month and chrono::day to unsigned before
7137         converting to uint32_t.
7139 2021-02-25  Jonathan Wakely  <jwakely@redhat.com>
7141         * include/std/chrono (year_month_day::_S_from_days): Perform
7142         all calculations with type uint32_t.
7144 2021-02-25  Jonathan Wakely  <jwakely@redhat.com>
7146         * doc/xml/manual/abi.xml: Document versioning for GCC 11.
7147         * doc/html/manual/abi.html: Regenerate.
7149 2021-02-25  Jonathan Wakely  <jwakely@redhat.com>
7151         PR libstdc++/99270
7152         * testsuite/27_io/headers/cstdio/types_std.cc: Use pointer to
7153         FILE instead of FILE.
7155 2021-02-25  Andreas Schwab  <schwab@suse.de>
7157         * config/abi/post/aarch64-linux-gnu/baseline_symbols.txt: Update.
7158         * config/abi/post/ia64-linux-gnu/baseline_symbols.txt: Update.
7159         * config/abi/post/m68k-linux-gnu/baseline_symbols.txt: Update.
7160         * config/abi/post/riscv64-linux-gnu/baseline_symbols.txt: Update.
7162 2021-02-25  Jonathan Wakely  <jwakely@redhat.com>
7164         PR libstdc++/99265
7165         * include/std/chrono (year_month_day::_S_from_days): Cast long
7166         to int explicitly.
7168 2021-02-25  Jonathan Wakely  <jwakely@redhat.com>
7170         * include/std/utility (to_underlying): Define.
7171         * include/std/version (__cpp_lib_to_underlying): Define.
7172         * testsuite/20_util/to_underlying/1.cc: New test.
7173         * testsuite/20_util/to_underlying/version.cc: New test.
7175 2021-02-24  Jonathan Wakely  <jwakely@redhat.com>
7177         PR libstdc++/99261
7178         * src/c++17/floating_to_chars.cc (sprintf_ld): Add extra args
7179         before value to be printed.
7181 2021-02-24  Patrick Palka  <ppalka@redhat.com>
7183         * src/c++17/floating_to_chars.cc (__floating_to_chars_precision):
7184         Relax the condition that guards the printf code path to accept
7185         F128_type as well as long double.
7187 2021-02-24  Cassio Neri  <cassio.neri@gmail.com>
7189         * include/std/chrono (year_month_day_last:day): New
7190         implementation.
7192 2021-02-24  Cassio Neri  <cassio.neri@gmail.com>
7194         * include/std/chrono (year::is_leap): New implementation.
7195         * testsuite/std/time/year/2.cc: New test.
7197 2021-02-24  Cassio Neri  <cassio.neri@gmail.com>
7199         * include/std/chrono (year_month_day::_M_days_since_epoch):
7200         New implementation.
7201         * testsuite/std/time/year_month_day/4.cc: New test.
7203 2021-02-24  Cassio Neri  <cassio.neri@gmail.com>
7205         * include/std/chrono (year_month_day::_S_from_days): New
7206         implementation.
7207         * testsuite/std/time/year_month_day/3.cc: New test.
7209 2021-02-24  Patrick Palka  <ppalka@redhat.com>
7211         PR libstdc++/98384
7212         * testsuite/20_util/to_chars/long_double.cc: Include <optional>.
7213         (test01): Simplify verifying the nearby values by using a
7214         2-iteration loop and a dedicated output buffer to check that the
7215         nearby values are different.  Factor out the printf-based
7216         verification into a local function, and check that the leading
7217         hex digits agree before comparing to the output of printf.  Also
7218         verify the output by round-tripping it through from_chars.
7220 2021-02-24  Jonathan Wakely  <jwakely@redhat.com>
7222         PR libstdc++/98389
7223         * config/abi/pre/gnu.ver (GLIBCXX_3.4.29): Do not match to_chars
7224         symbols for long double arguments mangled as 'g'.
7225         * config/os/gnu-linux/ldbl-extra.ver: Likewise.
7226         * config/os/gnu-linux/ldbl-ieee128-extra.ver: Likewise.
7227         * src/c++17/Makefile.am [GLIBCXX_LDBL_ALT128_COMPAT_TRUE]:
7228         Use -mabi=ibmlongdouble for floating_to_chars.cc.
7229         * src/c++17/Makefile.in: Regenerate.
7230         * src/c++17/floating_to_chars.cc (floating_type_traits_binary128):
7231         New type defining type traits of IEEE binary128 format.
7232         (floating_type_traits<__float128>): Define specialization.
7233         (floating_type_traits<long double>): Define in terms of
7234         floating_type_traits_binary128 when appropriate.
7235         (floating_to_shortest_scientific): Handle __float128.
7236         (sprintf_ld): New function template for printing a long double
7237         or __ieee128 value using sprintf.
7238         (__floating_to_chars_shortest, __floating_to_chars_precision):
7239         Use sprintf_ld.
7240         (to_chars): Define overloads for __float128.
7242 2021-02-24  Jonathan Wakely  <jwakely@redhat.com>
7244         * testsuite/17_intro/names.cc: Undefine 'u' on powerpc*-linux*.
7246 2021-02-23  Martin Sebor  <msebor@redhat.com>
7248         PR c++/99074
7249         * libsupc++/dyncast.cc (__dynamic_cast): Return null when
7250         first argument is null.
7252 2021-02-23  Jakub Jelinek  <jakub@redhat.com>
7254         PR libstdc++/99181
7255         * testsuite/21_strings/char_traits/requirements/char/99181.cc: New
7256         test.
7258 2021-02-23  Jakub Jelinek  <jakub@redhat.com>
7260         PR libstdc++/99181
7261         * include/bits/char_traits.h (char_traits<char>::compare): For
7262         constexpr evaluation don't call
7263         __gnu_cxx::char_traits<char_type>::compare but do the comparison loop
7264         directly.
7266 2021-02-23  Jakub Jelinek  <jakub@redhat.com>
7268         PR libstdc++/97549
7269         * include/pstl/parallel_backend_serial.h: Remove __pstl::__par_backend.
7271 2021-02-23  Patrick Palka  <ppalka@redhat.com>
7273         PR libstdc++/98384
7274         * src/c++17/floating_to_chars.cc (get_ieee_repr): Extract
7275         the high- and low-order parts from an IBM long double value
7276         in an endian-agnostic way.
7278 2021-02-19  Jonathan Wakely  <jwakely@redhat.com>
7280         * include/bits/atomic_wait.h (__thread_relax()): Call
7281         __thread_yield() not __gthread_yield().
7283 2021-02-15  Jonathan Wakely  <jwakely@redhat.com>
7285         * include/bits/atomic_wait.h (__thread_yield()): Check
7286         _GLIBCXX_HAS_GTHREADS before using __gthread_yield.
7287         (__thread_relax()): Use __thread_yield() instead of repeating
7288         the preprocessor checks for __gthread_yield.
7290 2021-02-15  Jonathan Wakely  <jwakely@redhat.com>
7292         * include/std/mutex (once_flag::_M_activate()): Add explicit
7293         return statement for passive case.
7294         (once_flag::_M_finish(bool)): Use reserved name for parameter.
7296 2021-02-14  Jonathan Wakely  <jwakely@redhat.com>
7298         PR libstdc++/99096
7299         * testsuite/util/testsuite_fs.h: Always include <unistd.h>.
7301 2021-02-12  Jonathan Wakely  <jwakely@redhat.com>
7303         PR libstdc++/88881
7304         * src/c++17/fs_ops.cc (fs::symlink_status): Re-enable workaround.
7306 2021-02-12  Jonathan Wakely  <jwakely@redhat.com>
7308         * doc/xml/manual/status_cxx2014.xml: Document implementation
7309         specific properties of std::experimental::filesystem::rename.
7310         * doc/xml/manual/status_cxx2017.xml: Document implementation
7311         specific properties of std::filesystem::rename.
7312         * doc/html/*: Regenerate.
7313         * src/c++17/fs_ops.cc (fs::rename): Implement correct behaviour
7314         for directories on Windows.
7315         * src/filesystem/ops-common.h (__gnu_posix::rename): Use
7316         MoveFileExW on Windows.
7317         * testsuite/27_io/filesystem/operations/rename.cc: New test.
7318         * testsuite/experimental/filesystem/operations/rename.cc: New test.
7320 2021-02-12  Jonathan Wakely  <jwakely@redhat.com>
7322         * testsuite/util/testsuite_fs.h (nonexistent_path): Add
7323         random number to the path.
7325 2021-02-12  Jonathan Wakely  <jwakely@redhat.com>
7327         * include/experimental/internet (address_v6::to_string): Include
7328         scope ID in string.
7329         * testsuite/experimental/net/internet/address/v6/members.cc:
7330         Test to_string() results.
7332 2021-02-12  Jonathan Wakely  <jwakely@redhat.com>
7334         * include/experimental/internet (address_v6::any): Avoid using
7335         memcpy in constexpr function.
7336         (address_v6::loopback): Likewise.
7337         (make_address_v6): Fix missing return statements on error paths.
7338         * include/experimental/io_context: Avoid -Wdangling-else
7339         warning.
7340         * testsuite/experimental/net/internet/address/v4/members.cc:
7341         Remove unused variables.
7342         * testsuite/experimental/net/internet/address/v6/members.cc:
7343         New test.
7345 2021-02-12  Jonathan Wakely  <jwakely@redhat.com>
7347         * include/bits/shared_ptr_base.h (__shared_ptr::_M_get_deleter):
7348         Add unused attribute to parameter.
7349         * src/c++11/shared_ptr.cc (_Sp_make_shared_tag::_S_eq):
7350         Likewise.
7352 2021-02-12  Jonathan Wakely  <jwakely@redhat.com>
7354         * testsuite/27_io/basic_ostream/emit/1.cc: Expect test to fail
7355         if -fno-rtti is used.
7356         * testsuite/30_threads/async/forced_unwind.cc: Expect test
7357         to abort if -fno-rtti is used.
7359 2021-02-12  Jonathan Wakely  <jwakely@redhat.com>
7361         * testsuite/util/testsuite_allocator.h (memory_resource):
7362         Remove requirement for RTTI and exceptions to be enabled.
7364 2021-02-12  Jonathan Wakely  <jwakely@redhat.com>
7366         * testsuite/27_io/basic_istringstream/rdbuf/char/2832.cc: Use
7367         static_cast when RTTI is disabled.
7368         * testsuite/27_io/basic_istringstream/rdbuf/wchar_t/2832.cc:
7369         Likewise.
7370         * testsuite/27_io/basic_ostringstream/rdbuf/char/2832.cc:
7371         Likewise.
7372         * testsuite/27_io/basic_ostringstream/rdbuf/wchar_t/2832.cc:
7373         Likewise.
7374         * testsuite/27_io/basic_stringstream/str/char/2.cc:
7375         Likewise.
7376         * testsuite/27_io/basic_stringstream/str/wchar_t/2.cc:
7377         Likewise.
7379 2021-02-12  Jonathan Wakely  <jwakely@redhat.com>
7381         * include/std/ostream (__syncbuf_base::_S_get): Mark parameter
7382         as unused and only use dynamic_cast when RTTI is enabled.
7384 2021-02-12  Jonathan Wakely  <jwakely@redhat.com>
7386         PR libstdc++/99077
7387         * src/c++11/cxx11-ios_failure.cc (__ios_failure(const char*, int)):
7388         Change int parameter to error_code, to match std::ios_failure.
7389         (__throw_ios_failure(const char*, int)): Construct error_code
7390         from int parameter.
7392 2021-02-11  Jonathan Wakely  <jwakely@redhat.com>
7394         * libsupc++/eh_ptr.cc (_GLIBCXX_EH_PTR_RELOPS_COMPAT): Define
7395         new macro.
7396         * libsupc++/exception_ptr.h (_GLIBCXX_EH_PTR_USED): Check new
7397         macro instead of _GLIBCXX_EH_PTR_COMPAT.
7398         (operator==): Likewise.
7400 2021-02-11  Jonathan Wakely  <jwakely@redhat.com>
7402         PR libstdc++/99058
7403         * doc/xml/manual/status_cxx2011.xml: Document when support
7404         became stable.
7405         * doc/xml/manual/status_cxx2014.xml: Likewise.
7406         * doc/xml/manual/status_cxx2017.xml: Likewise.
7407         * doc/html/manual/status.html: Regenerate.
7409 2021-02-10  Jonathan Wakely  <jwakely@redhat.com>
7411         PR libstdc++/88881
7412         * src/c++17/fs_ops.cc (fs::status): Re-enable workaround.
7414 2021-02-10  Jonathan Wakely  <jwakely@redhat.com>
7416         * src/c++17/fs_ops.cc (fs::create_hard_link, fs::equivalent)
7417         (fs::remove): Use std::system_category() for error codes from
7418         GetLastError().
7419         * src/filesystem/ops.cc (fs::create_hard_link, fs::remove):
7420         Likewise.
7422 2021-02-10  Jonathan Wakely  <jwakely@redhat.com>
7424         * testsuite/27_io/filesystem/operations/proximate.cc: Fix typo
7425         in __MINGW32__ macro name.
7426         * testsuite/27_io/filesystem/path/compare/lwg2936.cc: Likewise.
7427         * testsuite/27_io/filesystem/path/generation/proximate.cc:
7428         Likewise.
7429         * testsuite/27_io/filesystem/path/generation/relative.cc:
7430         Likewise.
7431         * testsuite/util/testsuite_fs.h: Likewise.
7433 2021-02-09  François Dumont  <fdumont@gcc.gnu.org>
7435         * include/bits/stl_tree.h
7436         (__has_is_transparent, __has_is_transparent_t): Move...
7437         * include/bits/stl_function.h: ...here.
7438         * include/bits/hashtable_policy.h (_Hash_code_base<>::_M_hash_code_tr): New..
7439         (_Hashtable_base<>::_M_equals_tr): New.
7440         * include/bits/hashtable.h (_Hashtable<>::_M_find_tr, _Hashtable<>::_M_count_tr,
7441         _Hashtable<>::_M_equal_range_tr): New member function templates to perform
7442         heterogeneous lookup.
7443         (_Hashtable<>::_M_find_before_node_tr): New.
7444         (_Hashtable<>::_M_find_node_tr): New.
7445         * include/bits/unordered_map.h (unordered_map::find<>, unordered_map::count<>,
7446         unordered_map::contains<>, unordered_map::equal_range<>): New member function
7447         templates to perform heterogeneous lookup.
7448         (unordered_multimap::find<>, unordered_multimap::count<>,
7449         unordered_multimap::contains<>, unordered_multimap::equal_range<>): Likewise.
7450         * include/bits/unordered_set.h  (unordered_set::find<>, unordered_set::count<>,
7451         unordered_set::contains<>, unordered_set::equal_range<>): Likewise.
7452         (unordered_multiset::find<>, unordered_multiset::count<>,
7453         unordered_multiset::contains<>, unordered_multiset::equal_range<>): Likewise.
7454         * include/debug/unordered_map
7455         (unordered_map::find<>, unordered_map::equal_range<>): Likewise.
7456         (unordered_multimap::find<>, unordered_multimap::equal_range<>): Likewise.
7457         * include/debug/unordered_set
7458         (unordered_set::find<>, unordered_set::equal_range<>): Likewise.
7459         (unordered_multiset::find<>, unordered_multiset::equal_range<>): Likewise.
7460         * testsuite/23_containers/unordered_map/operations/1.cc: New test.
7461         * testsuite/23_containers/unordered_multimap/operations/1.cc: New test.
7462         * testsuite/23_containers/unordered_multiset/operations/1.cc: New test.
7463         * testsuite/23_containers/unordered_set/operations/1.cc: New test.
7465 2021-02-09  François Dumont  <fdumont@gcc.gnu.org>
7467         * include/bits/stl_deque.h
7468         (std::operator-(deque::iterator, deque::iterator)): Replace if/then with
7469         a null pointer test.
7471 2021-02-09  Jonathan Wakely  <jwakely@redhat.com>
7473         * testsuite/27_io/filesystem/operations/remove_all.cc: Remove
7474         test directory after making it writable again.
7475         * testsuite/experimental/filesystem/operations/remove_all.cc:
7476         Likewise.
7478 2021-02-09  Jonathan Wakely  <jwakely@redhat.com>
7480         PR libstdc++/99021
7481         * include/std/coroutine (coroutine_handle<P>::from_address): Add
7482         noexcept.
7484 2021-02-09  Vladimir Vishnevsky  <vv.os.swe@gmail.com>
7486         * include/ext/stdio_sync_filebuf.h: Remove unused <unistd.h>.
7487         * src/c++17/fs_ops.cc (fs::permissions): Qualify mode_t.
7489 2021-02-09  Jakub Jelinek  <jakub@redhat.com>
7491         PR middle-end/98465
7492         * include/bits/basic_string.tcc (basic_string::_M_replace): When __s
7493         points to the characters moved by earlier _S_move, compute the source
7494         address using expression based on the __p pointer rather than __s
7495         pointer.
7497 2021-02-03  Jonathan Wakely  <jwakely@redhat.com>
7499         * testsuite/19_diagnostics/error_code/operators/not_equal.cc:
7500         Add comparison with same category and different values.
7501         * testsuite/19_diagnostics/error_code/operators/less.cc:
7502         Likewise. Fix comparison involving different categories.
7503         * testsuite/19_diagnostics/error_code/operators/three_way.cc:
7504         Likewise.
7505         * testsuite/19_diagnostics/error_condition/operators/less.cc:
7506         Add comment.
7507         * testsuite/19_diagnostics/error_condition/operators/three_way.cc:
7508         Likewise.
7510 2021-02-03  yaozhongxiao  <yaozhongxiao@linux.alibaba.com>
7512         * include/experimental/bits/simd_neon.h: Replace repeated vpadd
7513         calls with a single vaddv for aarch64.
7515 2021-02-03  Matthias Kretz  <kretz@kde.org>
7517         * testsuite/Makefile.am: Warn about the workaround. Add
7518         -fno-tree-vrp to CXXFLAGS passed to the check_simd script.
7519         Improve initial user feedback from make check-simd.
7520         * testsuite/Makefile.in: Regenerated.
7522 2021-02-03  Matthias Kretz  <kretz@kde.org>
7524         * include/experimental/bits/simd.h: Add __detail::_Minimum and
7525         __detail::_Maximum to use them as _BinaryOperation to _S_reduce.
7526         Add hmin and hmax overloads for simd and const_where_expression.
7527         * include/experimental/bits/simd_scalar.h
7528         (_SimdImplScalar::_S_reduce): Make unused _BinaryOperation
7529         parameter const-ref to allow calling _S_reduce with an rvalue.
7530         * testsuite/experimental/simd/tests/reductions.cc: Add tests for
7531         hmin and hmax. Since the compiler statically determined that all
7532         tests pass, repeat the test after a call to make_value_unknown.
7534 2021-02-03  Matthias Kretz  <kretz@kde.org>
7536         * testsuite/experimental/simd/tests/bits/verify.h (verify): Add
7537         instruction pointer data member. Ensure that the `if (m_failed)`
7538         branch is always inlined into the calling code. The body of the
7539         conditional can still be a function call. Move the get_ip call
7540         into the verify ctor to simplify the ctor calls.
7541         (COMPARE): Don't mention the use of all_of for reduction of a
7542         simd_mask. It only distracts from the real issue.
7544 2021-02-03  Matthias Kretz  <kretz@kde.org>
7546         * testsuite/experimental/simd/driver.sh: Abstract reading test
7547         options into read_src_option function. Read skip, only,
7548         expensive, and xfail via read_src_option. Add timeout and
7549         timeout-factor options and adjust timeout variable accordingly.
7550         * testsuite/experimental/simd/tests/loadstore.cc: Set
7551         timeout-factor 2.
7553 2021-02-03  Matthias Kretz  <kretz@kde.org>
7555         * testsuite/experimental/simd/driver.sh: When handling the pipe
7556         to log (and on verbose to stdout) count the lines. If it exceeds
7557         1000 log the issue and exit 125, which is then handled as a
7558         failure.
7560 2021-02-03  Matthias Kretz  <kretz@kde.org>
7562         * testsuite/experimental/simd/tests/hypot3_fma.cc: Add skip:
7563         markup for long double on powerpc64*.
7565 2021-02-03  Matthias Kretz  <kretz@kde.org>
7567         * include/experimental/bits/simd.h: Add __have_power10vec
7568         conditional on _ARCH_PWR10.
7569         * include/experimental/bits/simd_builtin.h: Forward declare
7570         _MaskImplPpc and use it as _MaskImpl when __ALTIVEC__ is
7571         defined.
7572         (_MaskImplBuiltin::_S_some_of): Call _S_popcount from the
7573         _SuperImpl for optimizations and correctness.
7574         * include/experimental/bits/simd_ppc.h: Add _MaskImplPpc.
7575         (_MaskImplPpc::_S_popcount): Implement via vec_cntm for POWER10.
7576         Otherwise, for >=int use -vec_sums divided by a sizeof factor.
7577         For <int use -vec_sums(vec_sum4s(...)) to sum all mask entries.
7579 2021-02-03  Matthias Kretz  <kretz@kde.org>
7581         * testsuite/experimental/simd/driver.sh: Remove executable on
7582         SIGINT. Process compiler and test executable output: In verbose
7583         mode print messages immediately, limited to 1000 lines and
7584         breaking long lines to below $COLUMNS (or 1024 if not set).
7585         Communicating the exit status of the compiler / test with the
7586         necessary pipe is done via a message through stdout/-in.
7588 2021-02-03  Matthias Kretz  <kretz@kde.org>
7590         * testsuite/Makefile.am: Ensure .simd.summary is empty before
7591         collecting a new summary.
7592         * testsuite/Makefile.in: Regenerate.
7594 2021-02-03  Matthias Kretz  <kretz@kde.org>
7596         * testsuite/experimental/simd/generate_makefile.sh: Use
7597         different variables internally than documented for user
7598         overrides. This makes internal append/prepend work as intended.
7600 2021-02-03  Matthias Kretz  <kretz@kde.org>
7602         * testsuite/experimental/simd/driver.sh (verify_test): Print
7603         test output on run xfail. Do not repeat lines from the log that
7604         were already printed on stdout.
7605         (test_selector): Make the compiler flags pattern usable as a
7606         substring selector.
7607         (toplevel): Trap on SIGINT and remove the log and sum files.
7608         Call timout with --foreground to quickly terminate on SIGINT.
7609         * testsuite/experimental/simd/generate_makefile.sh: Simplify run
7610         targets via target patterns. Default DRIVEROPTS to -v for run
7611         targets. Remove log and sum files after completion of the run
7612         target (so that it's always recompiled).
7613         Place help text into text file for reasonable 'make help'
7614         performance.
7616 2021-02-03  Matthias Kretz  <kretz@kde.org>
7618         * include/experimental/bits/simd.h: Remove unnecessary static
7619         assertion. Allow sizeof(8) integer __intrinsic_type to enable
7620         the necessary mask type.
7622 2021-02-03  Matthias Kretz  <kretz@kde.org>
7624         * include/experimental/bits/simd.h: Let __intrinsic_type<long
7625         double, N> be valid if sizeof(long double) == sizeof(double) and
7626         use a __vector double as member type.
7628 2021-02-03  Matthias Kretz  <kretz@kde.org>
7630         * include/experimental/bits/simd.h (__is_intrinsic_type): New
7631         internal type trait. Alias for __is_vector_type on x86.
7632         (_VectorTraitsImpl): Enable for __intrinsic_type in addition for
7633         __vector_type.
7634         (__intrin_bitcast): Allow casting to & from vector & intrinsic
7635         types.
7636         (__intrinsic_type): Explicitly specialize for NEON intrinsic
7637         vector types.
7639 2021-02-03  Matthias Kretz  <kretz@kde.org>
7641         * testsuite/experimental/simd/driver.sh: Implement skip, only,
7642         expensive, and xfail markers. They can select on type, ABI tag
7643         subset number, target-triplet, and compiler flags.
7644         * testsuite/experimental/simd/generate_makefile.sh: The summary
7645         now includes lines for unexpected passes and expected failures.
7646         If the skip or only markers are only conditional on the type, do
7647         not generate rules for those types.
7648         * testsuite/experimental/simd/tests/abs.cc: Mark test expensive
7649         for ABI tag subsets 1-9.
7650         * testsuite/experimental/simd/tests/algorithms.cc: Ditto.
7651         * testsuite/experimental/simd/tests/broadcast.cc: Ditto.
7652         * testsuite/experimental/simd/tests/casts.cc: Ditto.
7653         * testsuite/experimental/simd/tests/generator.cc: Ditto.
7654         * testsuite/experimental/simd/tests/integer_operators.cc: Ditto.
7655         * testsuite/experimental/simd/tests/loadstore.cc: Ditto.
7656         * testsuite/experimental/simd/tests/mask_broadcast.cc: Ditto.
7657         * testsuite/experimental/simd/tests/mask_conversions.cc: Ditto.
7658         * testsuite/experimental/simd/tests/mask_implicit_cvt.cc: Ditto.
7659         * testsuite/experimental/simd/tests/mask_loadstore.cc: Ditto.
7660         * testsuite/experimental/simd/tests/mask_operator_cvt.cc: Ditto.
7661         * testsuite/experimental/simd/tests/mask_operators.cc: Ditto.
7662         * testsuite/experimental/simd/tests/mask_reductions.cc: Ditto.
7663         * testsuite/experimental/simd/tests/operator_cvt.cc: Ditto.
7664         * testsuite/experimental/simd/tests/operators.cc: Ditto.
7665         * testsuite/experimental/simd/tests/reductions.cc: Ditto.
7666         * testsuite/experimental/simd/tests/simd.cc: Ditto.
7667         * testsuite/experimental/simd/tests/split_concat.cc: Ditto.
7668         * testsuite/experimental/simd/tests/splits.cc: Ditto.
7669         * testsuite/experimental/simd/tests/where.cc: Ditto.
7670         * testsuite/experimental/simd/tests/fpclassify.cc: Ditto. In
7671         addition replace "test only floattypes" marker by unconditional
7672         "float|double|ldouble" only marker.
7673         * testsuite/experimental/simd/tests/frexp.cc: Ditto.
7674         * testsuite/experimental/simd/tests/hypot3_fma.cc: Ditto.
7675         * testsuite/experimental/simd/tests/ldexp_scalbn_scalbln_modf.cc:
7676         Ditto.
7677         * testsuite/experimental/simd/tests/logarithm.cc: Ditto.
7678         * testsuite/experimental/simd/tests/math_1arg.cc: Ditto.
7679         * testsuite/experimental/simd/tests/math_2arg.cc: Ditto.
7680         * testsuite/experimental/simd/tests/remqo.cc: Ditto.
7681         * testsuite/experimental/simd/tests/trigonometric.cc: Ditto.
7682         * testsuite/experimental/simd/tests/trunc_ceil_floor.cc: Ditto.
7683         * testsuite/experimental/simd/tests/sincos.cc: Ditto. In
7684         addition, xfail on run because the reference data is missing.
7686 2021-02-02  Jonathan Wakely  <jwakely@redhat.com>
7688         * doc/xml/manual/status_cxx2011.xml: Remove stray table cell.
7689         * doc/xml/manual/status_cxx2014.xml: Likewise.
7690         * doc/xml/manual/status_cxx2017.xml: Likewise.
7691         * doc/html/manual/status.html: Regenerate.
7693 2021-02-01  François Dumont  <fdumont@gcc.gnu.org>
7695         PR libstdc++/70303
7696         * include/bits/stl_deque.h (std::deque<>::operator-(iterator, iterator)):
7697         Return 0 if both iterators are value-initialized.
7698         * testsuite/23_containers/deque/70303.cc: New test.
7699         * testsuite/23_containers/vector/70303.cc: New test.
7701 2021-02-01  Jonathan Wakely  <jwakely@redhat.com>
7703         * doc/xml/manual/status_cxx2011.xml: Update std::call_once
7704         status.
7705         * doc/xml/manual/status_cxx2014.xml: Likewise.
7706         * doc/xml/manual/status_cxx2017.xml: Likewise. Update
7707         std::from_chars and std::to_chars status. Fix formatting.
7708         * doc/html/manual/status.html: Regenerate.
7710 2021-01-28  Jonathan Wakely  <jwakely@redhat.com>
7712         * include/experimental/bits/numeric_traits.h: Update copyright
7713         dates.
7714         * include/experimental/bits/simd.h: Likewise.
7715         * include/experimental/bits/simd_builtin.h: Likewise.
7716         * include/experimental/bits/simd_converter.h: Likewise.
7717         * include/experimental/bits/simd_detail.h: Likewise.
7718         * include/experimental/bits/simd_fixed_size.h: Likewise.
7719         * include/experimental/bits/simd_math.h: Likewise.
7720         * include/experimental/bits/simd_neon.h: Likewise.
7721         * include/experimental/bits/simd_ppc.h: Likewise.
7722         * include/experimental/bits/simd_scalar.h: Likewise.
7723         * include/experimental/bits/simd_x86.h: Likewise.
7724         * include/experimental/bits/simd_x86_conversions.h: Likewise.
7725         * include/experimental/simd: Likewise.
7726         * testsuite/experimental/simd/*: Likewise.
7728 2021-01-27  Jonathan Wakely  <jwakely@redhat.com>
7730         * doc/xml/manual/status_cxx2017.xml: Replace invalid entity.
7731         * doc/html/*: Regenerate.
7733 2021-01-27  Jonathan Wakely  <jwakely@redhat.com>
7735         * testsuite/experimental/simd/generate_makefile.sh: Use printf
7736         instead of echo when printing escape characters.
7738 2021-01-27  Matthias Kretz  <kretz@kde.org>
7740         * scripts/check_simd: New file. This script is called from the
7741         the check-simd target. It determines a set of compiler flags and
7742         simulator setups for calling generate_makefile.sh and passes the
7743         information back to the check-simd target, which recurses to the
7744         generated Makefiles.
7745         * scripts/create_testsuite_files: Remove files below simd/tests/
7746         from testsuite_files and place them in testsuite_files_simd.
7747         * testsuite/Makefile.am: Add testsuite_files_simd. Add
7748         check-simd target.
7749         * testsuite/Makefile.in: Regenerate.
7750         * testsuite/experimental/simd/driver.sh: New file. This script
7751         compiles and runs a given simd test, logging its output and
7752         status. It uses the timeout command to implement compile and
7753         test timeouts.
7754         * testsuite/experimental/simd/generate_makefile.sh: New file.
7755         This script generates a Makefile which uses driver.sh to compile
7756         and run the tests and collect the logs into a single log file.
7757         * testsuite/experimental/simd/tests/abs.cc: New file. Tests
7758         abs(simd).
7759         * testsuite/experimental/simd/tests/algorithms.cc: New file.
7760         Tests min/max(simd, simd).
7761         * testsuite/experimental/simd/tests/bits/conversions.h: New
7762         file. Contains functions to support tests involving conversions.
7763         * testsuite/experimental/simd/tests/bits/make_vec.h: New file.
7764         Support functions make_mask and make_vec.
7765         * testsuite/experimental/simd/tests/bits/mathreference.h: New
7766         file. Support functions to supply precomputed math function
7767         reference data.
7768         * testsuite/experimental/simd/tests/bits/metahelpers.h: New
7769         file. Support code for SFINAE testing.
7770         * testsuite/experimental/simd/tests/bits/simd_view.h: New file.
7771         * testsuite/experimental/simd/tests/bits/test_values.h: New
7772         file. Test functions to easily drive a test with simd objects
7773         initialized from a given list of values and a range of random
7774         values.
7775         * testsuite/experimental/simd/tests/bits/ulp.h: New file.
7776         Support code to determine the ULP distance of simd objects.
7777         * testsuite/experimental/simd/tests/bits/verify.h: New file.
7778         Test framework for COMPARE'ing simd objects and instantiating
7779         the test templates with value_type and ABI tag.
7780         * testsuite/experimental/simd/tests/broadcast.cc: New file. Test
7781         simd broadcasts.
7782         * testsuite/experimental/simd/tests/casts.cc: New file. Test
7783         simd casts.
7784         * testsuite/experimental/simd/tests/fpclassify.cc: New file.
7785         Test floating-point classification functions.
7786         * testsuite/experimental/simd/tests/frexp.cc: New file. Test
7787         frexp(simd).
7788         * testsuite/experimental/simd/tests/generator.cc: New file. Test
7789         simd generator constructor.
7790         * testsuite/experimental/simd/tests/hypot3_fma.cc: New file.
7791         Test 3-arg hypot(simd,simd,simd) and fma(simd,simd,sim).
7792         * testsuite/experimental/simd/tests/integer_operators.cc: New
7793         file. Test integer operators.
7794         * testsuite/experimental/simd/tests/ldexp_scalbn_scalbln_modf.cc:
7795         New file. Test ldexp(simd), scalbn(simd), scalbln(simd), and
7796         modf(simd).
7797         * testsuite/experimental/simd/tests/loadstore.cc: New file. Test
7798         (converting) simd loads and stores.
7799         * testsuite/experimental/simd/tests/logarithm.cc: New file. Test
7800         log*(simd).
7801         * testsuite/experimental/simd/tests/mask_broadcast.cc: New file.
7802         Test simd_mask broadcasts.
7803         * testsuite/experimental/simd/tests/mask_conversions.cc: New
7804         file. Test simd_mask conversions.
7805         * testsuite/experimental/simd/tests/mask_implicit_cvt.cc: New
7806         file. Test simd_mask implicit conversions.
7807         * testsuite/experimental/simd/tests/mask_loadstore.cc: New file.
7808         Test simd_mask loads and stores.
7809         * testsuite/experimental/simd/tests/mask_operator_cvt.cc: New
7810         file. Test simd_mask operators convert as specified.
7811         * testsuite/experimental/simd/tests/mask_operators.cc: New file.
7812         Test simd_mask compares, subscripts, and negation.
7813         * testsuite/experimental/simd/tests/mask_reductions.cc: New
7814         file. Test simd_mask reductions.
7815         * testsuite/experimental/simd/tests/math_1arg.cc: New file. Test
7816         1-arg math functions on simd.
7817         * testsuite/experimental/simd/tests/math_2arg.cc: New file. Test
7818         2-arg math functions on simd.
7819         * testsuite/experimental/simd/tests/operator_cvt.cc: New file.
7820         Test implicit conversions on simd binary operators behave as
7821         specified.
7822         * testsuite/experimental/simd/tests/operators.cc: New file. Test
7823         simd compares, subscripts, not, unary minus, plus, minus,
7824         multiplies, divides, increment, and decrement.
7825         * testsuite/experimental/simd/tests/reductions.cc: New file.
7826         Test reduce(simd).
7827         * testsuite/experimental/simd/tests/remqo.cc: New file. Test
7828         remqo(simd).
7829         * testsuite/experimental/simd/tests/simd.cc: New file. Basic
7830         sanity checks of simd types.
7831         * testsuite/experimental/simd/tests/sincos.cc: New file. Test
7832         sin(simd) and cos(simd).
7833         * testsuite/experimental/simd/tests/split_concat.cc: New file.
7834         Test split(simd) and concat(simd, simd).
7835         * testsuite/experimental/simd/tests/splits.cc: New file. Test
7836         split(simd_mask).
7837         * testsuite/experimental/simd/tests/trigonometric.cc: New file.
7838         Test remaining trigonometric functions on simd.
7839         * testsuite/experimental/simd/tests/trunc_ceil_floor.cc: New
7840         file. Test trunc(simd), ceil(simd), and floor(simd).
7841         * testsuite/experimental/simd/tests/where.cc: New file. Test
7842         masked operations using where.
7844 2021-01-27  Matthias Kretz  <kretz@kde.org>
7846         * doc/xml/manual/status_cxx2017.xml: Add implementation status
7847         of the Parallelism TS 2. Document implementation-defined types
7848         and behavior.
7849         * include/Makefile.am: Add new headers.
7850         * include/Makefile.in: Regenerate.
7851         * include/experimental/simd: New file. New header for
7852         Parallelism TS 2.
7853         * include/experimental/bits/numeric_traits.h: New file.
7854         Implementation of P1841R1 using internal naming. Addition of
7855         missing IEC559 functionality query.
7856         * include/experimental/bits/simd.h: New file. Definition of the
7857         public simd interfaces and general implementation helpers.
7858         * include/experimental/bits/simd_builtin.h: New file.
7859         Implementation of the _VecBuiltin simd_abi.
7860         * include/experimental/bits/simd_converter.h: New file. Generic
7861         simd conversions.
7862         * include/experimental/bits/simd_detail.h: New file. Internal
7863         macros for the simd implementation.
7864         * include/experimental/bits/simd_fixed_size.h: New file. Simd
7865         fixed_size ABI specific implementations.
7866         * include/experimental/bits/simd_math.h: New file. Math
7867         overloads for simd.
7868         * include/experimental/bits/simd_neon.h: New file. Simd NEON
7869         specific implementations.
7870         * include/experimental/bits/simd_ppc.h: New file. Implement bit
7871         shifts to avoid invalid results for integral types smaller than
7872         int.
7873         * include/experimental/bits/simd_scalar.h: New file. Simd scalar
7874         ABI specific implementations.
7875         * include/experimental/bits/simd_x86.h: New file. Simd x86
7876         specific implementations.
7877         * include/experimental/bits/simd_x86_conversions.h: New file.
7878         x86 specific conversion optimizations. The conversion patterns
7879         work around missing conversion patterns in the compiler and
7880         should be removed as soon as PR85048 is resolved.
7881         * testsuite/experimental/simd/standard_abi_usable.cc: New file.
7882         Test that all (not all fixed_size<N>, though) standard simd and
7883         simd_mask types are usable.
7884         * testsuite/experimental/simd/standard_abi_usable_2.cc: New
7885         file. As above but with -ffast-math.
7886         * testsuite/libstdc++-dg/conformance.exp: Don't build simd tests
7887         from the standard test loop. Instead use
7888         check_vect_support_and_set_flags to build simd tests with the
7889         relevant machine flags.
7891 2021-01-27  Jonathan Wakely  <jwakely@redhat.com>
7893         PR libstdc++/66414
7894         * include/bits/string_view.tcc
7895         (basic_string_view::find(const CharT*, size_type, size_type)):
7896         Optimize.
7898 2021-01-27  Paul Fee  <paul.f.fee@gmail.com>
7900         * include/bits/basic_string.h (basic_string::contains): New
7901         member functions.
7902         * include/std/string_view (basic_string_view::contains):
7903         Likewise.
7904         * include/std/version (__cpp_lib_string_contains): Define.
7905         * testsuite/21_strings/basic_string/operations/starts_with/char/1.cc:
7906         Remove trailing whitespace.
7907         * testsuite/21_strings/basic_string/operations/starts_with/wchar_t/1.cc:
7908         Likewise.
7909         * testsuite/21_strings/basic_string/operations/contains/char/1.cc: New test.
7910         * testsuite/21_strings/basic_string/operations/contains/wchar_t/1.cc: New test.
7911         * testsuite/21_strings/basic_string_view/operations/contains/char/1.cc: New test.
7912         * testsuite/21_strings/basic_string_view/operations/contains/char/2.cc: New test.
7913         * testsuite/21_strings/basic_string_view/operations/contains/wchar_t/1.cc: New test.
7915 2021-01-21  Jonathan Wakely  <jwakely@redhat.com>
7917         * src/c++17/Makefile.in: Regenerate.
7919 2021-01-20  David Edelsohn  <dje.gcc@gmail.com>
7921         * config/os/aix/ctype_inline.h (bool ctype<char>:: is): Cast
7922         _OBJ_DATA subscript to unsigned char. Add _THREAD_SAFE access to
7923         __lc_type.
7924         (const char* ctype<char>:: is): Same.
7926 2021-01-18  Jonathan Wakely  <jwakely@redhat.com>
7928         PR libstdc++/98725
7929         * testsuite/20_util/unique_ptr/io/lwg2948.cc:  Do not try to
7930         write to a wide character stream if wide character support is
7931         disabled in the library.
7933 2021-01-18  Jonathan Wakely  <jwakely@redhat.com>
7935         * testsuite/27_io/basic_stringstream/cons/char/1.cc: Use
7936         stringbuf not wstringbuf.
7938 2021-01-18  Jakub Jelinek  <jakub@redhat.com>
7940         PR debug/98708
7941         * src/c++11/Makefile.am (cxx11-ios_failure-lt.s, cxx11-ios_failure.s):
7942         Compile with -gno-as-loc-support.
7943         * src/c++11/Makefile.in: Regenerated.
7945 2021-01-16  H.J. Lu  <hjl.tools@gmail.com>
7947         * testsuite/29_atomics/atomic_flag/test_and_set/explicit-hle.cc:
7948         Add -fcf-protection=none to -march=i486.
7950 2021-01-14  François Dumont  <fdumont@gcc.gnu.org>
7952         * testsuite/23_containers/deque/debug/98466.cc: Make it pre-C++11
7953         compliant.
7955 2021-01-14  Alexandre Oliva  <oliva@adacore.com>
7957         * testsuite/30_threads/future/members/poll.cc: Calibrate
7958         iteration count.
7960 2021-01-14  François Dumont  <fdumont@gcc.gnu.org>
7962         PR libstdc++/98466
7963         * include/bits/hashtable_policy.h (_Node_iterator_base()): Set _M_cur to nullptr.
7964         (_Node_iterator()): Make default.
7965         (_Node_const_iterator()): Make default.
7966         * include/debug/macros.h (__glibcxx_check_erae_range_after): Add _M_singular
7967         iterator checks.
7968         * include/debug/safe_iterator.h
7969         (_GLIBCXX_DEBUG_VERIFY_OPERANDS): Accept if both iterator are value initialized.
7970         * include/debug/safe_local_iterator.h (_GLIBCXX_DEBUG_VERIFY_OPERANDS):
7971         Likewise.
7972         * include/debug/safe_iterator.tcc (_Safe_iterator<>::_M_valid_range): Add
7973         _M_singular checks on input iterators.
7974         * src/c++11/debug.cc (_Safe_iterator_base::_M_can_compare): Remove _M_singular
7975         checks.
7976         * testsuite/23_containers/deque/debug/98466.cc: New test.
7977         * testsuite/23_containers/unordered_map/debug/98466.cc: New test.
7979 2021-01-14  Jonathan Wakely  <jwakely@redhat.com>
7981         PR libstdc++/98471
7982         * include/bits/fs_path.h (__throw_conversion_error): New
7983         function to throw or abort on character conversion errors.
7984         (__wstr_from_utf8): Move definition after filesystem_error has
7985         been defined. Use __throw_conversion_error.
7986         (path::_S_convert<_EcharT>): Use __throw_conversion_error.
7987         (path::_S_str_convert<_CharT, _Traits, _Allocator>): Likewise.
7988         (path::u8string): Likewise.
7990 2021-01-14  Jonathan Wakely  <jwakely@redhat.com>
7992         * include/std/barrier: Update copyright years. Fix whitespace.
7993         * include/std/version: Fix whitespace.
7994         * testsuite/30_threads/barrier/1.cc: Update copyright years.
7995         * testsuite/30_threads/barrier/2.cc: Likewise.
7996         * testsuite/30_threads/barrier/arrive.cc: Likewise.
7997         * testsuite/30_threads/barrier/arrive_and_drop.cc: Likewise.
7998         * testsuite/30_threads/barrier/arrive_and_wait.cc: Likewise.
7999         * testsuite/30_threads/barrier/completion.cc: Likewise.
8001 2021-01-13  Jonathan Wakely  <jwakely@redhat.com>
8003         * doc/doxygen/user.cfg.in (INPUT): Remove include/debug/array.
8005 2021-01-10  David Edelsohn  <dje.gcc@gmail.com>
8007         PR libstdc++/98613
8008         * testsuite/ext/vstring/cons/moveable.cc: Suppress false positive
8009         warning.
8010         * testsuite/ext/vstring/modifiers/assign/move_assign.cc: Same.
8012 2021-01-08  Olivier Hainque  <hainque@adacore.com>
8014         * testsuite/20_util/bind/ref_neg.cc: Tweak the
8015         dg-prune-output regex for out-of-build-tree contexts.
8017 2021-01-07  Thomas Rodgers  <trodgers@redhat.com>
8019         * doc/doxygen/user.cfg.in: Add new header.
8020         * include/Makefile.am (std_headers): likewise.
8021         * include/Makefile.in: Regenerate.
8022         * include/precompiled/stdc++.h: Add new header.
8023         * include/std/barrier: New file.
8024         * include/std/version: Add __cpp_lib_barrier feature test macro.
8025         * testsuite/30_threads/barrier/1.cc: New test.
8026         * testsuite/30_threads/barrier/2.cc: Likewise.
8027         * testsuite/30_threads/barrier/arrive_and_drop.cc: Likewise.
8028         * testsuite/30_threads/barrier/arrive_and_wait.cc: Likewise.
8029         * testsuite/30_threads/barrier/arrive.cc: Likewise.
8030         * testsuite/30_threads/barrier/completion.cc: Likewise.
8032 2021-01-07  Patrick Palka  <ppalka@redhat.com>
8034         PR libstdc++/98384
8035         * testsuite/20_util/to_chars/long_double.cc: Use nexttowardl
8036         instead of the non-standard nextupl and nextdownl.
8038 2021-01-05  Samuel Thibault  <samuel.thibault@ens-lyon.org>
8040         * configure: Re-generate.
8042 2021-01-05  Ed Smith-Rowland  <3dw4rd@verizon.net>
8044         * include/precompiled/stdc++.h: Add <source_location> to C++20 section.
8046 2021-01-01  Jakub Jelinek  <jakub@redhat.com>
8048         * ChangeLog-2020: Rotate ChangeLog.  New file.
8051 Copyright (C) 2021 Free Software Foundation, Inc.
8053 Copying and distribution of this file, with or without modification,
8054 are permitted in any medium without royalty provided the copyright
8055 notice and this notice are preserved.