1 2021-12-10 Jakub Jelinek <jakub@redhat.com>
4 * config/locale/dragonfly/time_members.cc (_M_initialize_timepunct):
5 Initialize "C" _M_am_pm_format to %I:%M:%S %p rather than empty
7 * config/locale/gnu/time_members.cc (_M_initialize_timepunct):
9 * config/locale/generic/time_members.cc (_M_initialize_timepunct):
11 * include/bits/locale_facets_nonio.h (_M_am_pm_format): New method.
12 * include/bits/locale_facets_nonio.tcc (_M_extract_via_format): Handle
14 * config/abi/pre/gnu.ver (GLIBCXX_3.4.30): Export _M_am_pm_format
15 with const _CharT** argument, ensure it isn't exported in GLIBCXX_3.4.
16 * testsuite/22_locale/time_get/get/char/71367.cc: New test.
17 * testsuite/22_locale/time_get/get/wchar_t/71367.cc: New test.
19 2021-12-10 Jakub Jelinek <jakub@redhat.com>
22 * include/bits/locale_facets_nonio.tcc (_M_extract_via_format):
23 Mention in function comment it interprets strptime format string
24 rather than strftime. Handle %a and %A the same by accepting both
25 full and abbreviated names. Similarly handle %h, %b and %B the same.
26 Handle %d and %e the same by accepting possibly optional single space
27 and 1 or 2 digits. For %I store tm_hour 0 instead of tm_hour 12. For
28 %t and %n skip any whitespace. Handle %p and %%. For whitespace in
29 the string skip any whitespace.
30 (_M_extract_num): For __len == 2 accept 1 or 2 digits rather than
31 always 2. Don't punt early if __value * __mult is larget than __max
32 or smaller than __min - __mult, instead punt if __value > __max.
33 At the end verify __value is in between __min and __max and punt
35 (_M_extract_name): Allow non-unique names or names which are prefixes
36 of other names. Don't recompute lengths of names for every character.
37 * testsuite/22_locale/time_get/get/char/3.cc: New test.
38 * testsuite/22_locale/time_get/get/wchar_t/3.cc: New test.
39 * testsuite/22_locale/time_get/get_date/char/12791.cc (test01): Use
40 62 instead 60 and expect 6 to be accepted and thus *ret01 == '2'.
41 * testsuite/22_locale/time_get/get_date/wchar_t/12791.cc (test01):
43 * testsuite/22_locale/time_get/get_time/char/2.cc (test02): Add " PM"
45 * testsuite/22_locale/time_get/get_time/char/5.cc (test01): Expect
46 tm_hour 1 rather than 0.
47 * testsuite/22_locale/time_get/get_time/wchar_t/2.cc (test02): Add
49 * testsuite/22_locale/time_get/get_time/wchar_t/5.cc (test01): Expect
50 tm_hour 1 rather than 0.
52 2021-12-10 Jonathan Wakely <jwakely@redhat.com>
55 * include/bits/atomic_timed_wait.h: Check _GLIBCXX_HAS_GTHREADS
56 before using std::mutex and std::__condvar.
58 2021-12-10 Jonathan Wakely <jwakely@redhat.com>
60 * acinclude.m4 (GLIBCXX_ENABLE_LIBSTDCXX_TIME): Add _GLIBCXX_
61 prefix to NO_SLEEP macro.
62 * config.h.in: Regenerate.
63 * configure: Regenerate.
65 2021-12-10 Jonathan Wakely <jwakely@redhat.com>
67 * include/bits/char_traits.h: Change pragma push to pop.
69 2021-12-10 Thomas Rodgers <rodgert@twrodgers.com>
72 * include/bits/atomic_base.h (__atomic_base<_PTp*>::wait()):
74 * include/std/atomic (atomic<_Tp*>::wait(), atomic_wait()):
76 * testsuite/29_atomics/atomic/wait_notify/102994.cc:
79 2021-12-09 Jonathan Wakely <jwakely@redhat.com>
81 * include/bits/stl_iterator.h (operator==, operator<=>): Define
82 overloads for homogeneous specializations of reverse_iterator,
83 __normal_iterator and move_iterator.
85 2021-12-09 Jonathan Wakely <jwakely@redhat.com>
87 * testsuite/20_util/scoped_allocator/69293_neg.cc: Remove
90 2021-12-09 Jonathan Wakely <jwakely@redhat.com>
93 * libsupc++/exception_ptr.h (__dest_thunk): Add macro for
94 destructor calling convention.
95 (make_exception_ptr): Enable non-throwing implementation for
96 -fno-exceptions and for non-standard calling conventions. Use
97 always_inline attribute on the useless no-rtti no-exceptions
99 * testsuite/18_support/exception_ptr/64241.cc: Add -fno-rtti so
100 the no-op implementation is still used.
102 2021-12-09 Jonathan Wakely <jwakely@redhat.com>
105 * libsupc++/exception_ptr.h (exception_ptr): Fix exception
106 specifications on inline definitions.
107 (make_exception_ptr): Decay the template parameter. Use typeid
109 * testsuite/18_support/exception_ptr/103630.cc: New test.
111 2021-12-09 Jonathan Wakely <jwakely@redhat.com>
114 * config/io/basic_file_stdio.cc (fopen_mode): Add support for
116 * include/bits/ios_base.h (_S_noreplace): Define new enumerator.
117 (ios_base::__noreplace): Define.
118 (ios_base::noreplace): Define for C++23.
119 * include/std/version (__cpp_lib_ios_noreplace): Define.
120 * testsuite/27_io/basic_ofstream/open/char/noreplace.cc: New test.
121 * testsuite/27_io/basic_ofstream/open/wchar_t/noreplace.cc: New test.
123 2021-12-09 Jonathan Wakely <jwakely@redhat.com>
126 * config/abi/pre/gnu.ver (GLIBCXX_3.4.11): Do not export old
127 symbol if .symver renaming is supported.
128 (GLIBCXX_3.4.30): Export new symbol if .symver renaming is
130 * doc/xml/manual/evolution.xml: Document change.
131 * doc/html/manual/api.html: Regenerate.
132 * include/bits/std_mutex.h (__condvar::wait, __condvar::wait_until):
134 * include/std/condition_variable (condition_variable::wait):
136 * src/c++11/condition_variable.cc (condition_variable::wait):
138 * src/c++11/compatibility-condvar.cc (__nothrow_wait_cv::wait):
139 Define nothrow wrapper around std::condition_variable::wait and
140 export the old symbol as an alias to it.
141 * testsuite/30_threads/condition_variable/members/103382.cc: New test.
143 2021-12-09 Jonathan Wakely <jwakely@redhat.com>
146 * include/bits/stl_map.h (insert(Pair&&), emplace(Args&&...)):
147 Check whether the arguments can be looked up directly without
148 constructing a temporary node first.
149 * include/bits/stl_pair.h (__is_pair): Move to here, from ...
150 * include/bits/uses_allocator_args.h (__is_pair): ... here.
151 * testsuite/23_containers/map/modifiers/emplace/92300.cc: New test.
152 * testsuite/23_containers/map/modifiers/insert/92300.cc: New test.
154 2021-12-09 Jonathan Wakely <jwakely@redhat.com>
156 * include/bits/cow_string.h (basic_string::_M_leak_hard): Do not
157 reallocate an empty string.
159 2021-12-09 Jonathan Wakely <jwakely@redhat.com>
164 * include/bits/char_traits.h: Suppress stringop and array-bounds
167 2021-12-09 Jonathan Wakely <jwakely@redhat.com>
170 * config/allocator/new_allocator_base.h: Include
171 <bits/new_allocator.h> instead of <ext/new_allocator.h>.
172 (__allocator_base): Use std::__new_allocator instead of
173 __gnu_cxx::new_allocator.
174 * doc/xml/manual/allocator.xml: Document new default base class
176 * doc/xml/manual/evolution.xml: Likewise.
177 * doc/html/*: Regenerate.
178 * include/Makefile.am: Add bits/new_allocator.h.
179 * include/Makefile.in: Regenerate.
180 * include/experimental/memory_resource (new_delete_resource):
181 Use std::__new_allocator instead of __gnu_cxx::new_allocator.
182 * include/ext/new_allocator.h (new_allocator): Derive from
183 std::__new_allocator. Move implementation to ...
184 * include/bits/new_allocator.h: New file.
185 * testsuite/20_util/allocator/64135.cc: New test.
187 2021-12-08 Jonathan Wakely <jwakely@redhat.com>
189 * include/bits/shared_ptr_base.h (_Sp_counted_base::_M_release()):
190 Make shift width conditional on __double_word condition.
192 2021-12-08 François Dumont <fdumont@gcc.gnu.org>
194 * include/std/deque (erase_if): Use _GLIBCXX_STD_C container reference and
195 __niter_wrap to limit _GLIBCXX_DEBUG mode impact.
196 * include/std/vector (erase_if): Likewise.
198 2021-12-08 Maged Michael <maged.michael@gmail.com>
199 Jonathan Wakely <jwakely@redhat.com>
201 * include/bits/c++config (_GLIBCXX_TSAN): Define macro
202 indicating that TSan is in use.
203 * include/bits/shared_ptr_base.h (_Sp_counted_base::_M_release):
204 Replace definition in primary template with explicit
205 specializations for _S_mutex and _S_atomic policies.
206 (_Sp_counted_base<_S_mutex>::_M_release): New specialization.
207 (_Sp_counted_base<_S_atomic>::_M_release): New specialization,
208 using a single atomic load to access both reference counts at
210 (_Sp_counted_base::_M_release_last_use): New member function.
212 2021-12-07 Tamar Christina <tamar.christina@arm.com>
215 2021-11-19 Tamar Christina <tamar.christina@arm.com>
218 * config/os/newlib/ctype_base.h (upper, lower, alpha, digit, xdigit,
219 space, print, graph, cntrl, punct, alnum, blank): Use short or long
220 names depending on if short ones are defined.
222 2021-12-04 Jonathan Wakely <jwakely@redhat.com>
225 * include/bits/regex.h (match_results): Give names to template
226 parameters in first declaration.
227 (match_results::_M_begin): Add default member-initializer.
229 2021-12-03 Jonathan Wakely <jwakely@redhat.com>
231 * include/bits/stl_tree.h (_Rb_tree::_Auto_node): Define new
232 RAII helper for creating and inserting new nodes.
233 (_Rb_tree::_M_insert_node): Use trailing-return-type to simplify
234 out-of-line definition.
235 (_Rb_tree::_M_insert_lower_node): Likewise.
236 (_Rb_tree::_M_insert_equal_lower_node): Likewise.
237 (_Rb_tree::_M_emplace_unique): Likewise. Use _Auto_node.
238 (_Rb_tree::_M_emplace_equal): Likewise.
239 (_Rb_tree::_M_emplace_hint_unique): Likewise.
240 (_Rb_tree::_M_emplace_hint_equal): Likewise.
242 2021-12-02 Jonathan Wakely <jwakely@redhat.com>
244 * src/c++11/cow-stdexcept.cc [_GLIBCXX_FULLY_DYNAMIC_STRING]
245 (logic_error, runtime_error): Remove custom definitions.
247 2021-12-02 Jonathan Wakely <jwakely@redhat.com>
252 * acinclude.m4 (GLIBCXX_ENABLE_ALLOCATOR): Remove mt, bitmap
254 * configure: Regenerate.
255 * config/allocator/bitmap_allocator_base.h: Removed.
256 * config/allocator/mt_allocator_base.h: Removed.
257 * config/allocator/pool_allocator_base.h: Removed.
258 * doc/xml/manual/allocator.xml: Update.
259 * doc/xml/manual/configure.xml: Update.
260 * doc/xml/manual/evolution.xml: Document removal.
261 * doc/xml/manual/mt_allocator.xml: Editorial tweaks.
262 * doc/html/manual/*: Regenerate.
264 2021-12-02 Jonathan Wakely <jwakely@redhat.com>
266 * include/bits/cow_string.h (basic_string::_M_is_leaked()):
267 Revert change to check __is_single_threaded() before using
270 2021-12-01 Jonathan Wakely <jwakely@redhat.com>
273 * include/bits/stl_tree.h (_Rb_tree(_Rb_tree&&, false_type)):
274 Clear container if elements have been moved-from.
275 * testsuite/23_containers/map/allocator/move_cons.cc: Expect
276 moved-from container to be empty.
277 * testsuite/23_containers/multimap/allocator/move_cons.cc:
279 * testsuite/23_containers/multiset/allocator/103501.cc: New test.
280 * testsuite/23_containers/set/allocator/103501.cc: New test.
282 2021-12-01 Jonathan Wakely <jwakely@redhat.com>
284 * doc/doxygen/user.cfg.in (PREDEFINED): Change macro name.
285 * include/bits/allocator.h (allocate, deallocate): Use
286 std::__is_constant_evaluated() unconditionally, instead of
287 checking whether std::is_constant_evaluated() (or the built-in)
289 * include/bits/basic_string.h: Check new macro. call
290 std::is_constant_evaluated() directly in C++20-only code that is
291 guarded by a suitable macro.
292 * include/bits/basic_string.tcc: Likewise.
293 * include/bits/c++config (__is_constant_evaluated): Define.
294 (_GLIBCXX_HAVE_BUILTIN_IS_CONSTANT_EVALUATED): Replace with ...
295 (_GLIBCXX_HAVE_IS_CONSTANT_EVALUATED): New macro.
296 * include/bits/char_traits.h (char_traits): Replace conditional
297 calls to std::is_constant_evaluated with unconditional calls to
298 std::__is_constant_evaluated.
299 * include/bits/cow_string.h: Use new macro.
300 * include/bits/ranges_algobase.h (__copy_or_move): Replace
301 conditional calls to std::is_constant_evaluated with unconditional
302 calls to std::__is_constant_evaluated.
303 (__copy_or_move_backward, __fill_n_fn): Likewise.
304 * include/bits/ranges_cmp.h (ranges::less): Likewise.
305 * include/bits/stl_algobase.h (lexicographical_compare_three_way):
307 * include/bits/stl_bvector.h: Call std::is_constant_evaluated
308 directly in C++20-only code that is guarded by a suitable macro.
309 * include/bits/stl_construct.h (_Construct, _Destroy, _Destroy_n):
310 Replace is_constant_evaluated with __is_constant_evaluated.
311 * include/bits/stl_function.h (greater, less, greater_equal)
312 (less_equal): Replace __builtin_is_constant_evaluated and
313 __builtin_constant_p with __is_constant_evaluated.
314 * include/bits/stl_vector.h: Call std::is_constant_evaluated()
316 * include/debug/helper_functions.h (__check_singular): Use
317 __is_constant_evaluated instead of built-in, or remove check
319 * include/std/array (operator<=>): Use __is_constant_evaluated
321 * include/std/bit (__bit_ceil): Likewise.
322 * include/std/type_traits (is_constant_evaluated): Define using
323 'if consteval' if possible.
324 * include/std/version: Use new macro.
325 * libsupc++/compare: Use __is_constant_evaluated instead of
326 __builtin_is_constant_evaluated.
327 * testsuite/23_containers/array/tuple_interface/get_neg.cc:
328 Adjust dg-error lines.
330 2021-12-01 Jonathan Wakely <jwakely@redhat.com>
332 * include/bits/cow_string.h (basic_string::_M_is_leaked): Use
333 non-atomic load when __is_single_threaded() is true.
334 (basic_string::_M_is_shared): Likewise.
335 (basic_string::(basic_string&&)) [_GLIBCXX_FULLY_DYNAMIC_STRING]:
336 Use non-atomic store when rvalue is not shared.
338 2021-12-01 Jonathan Wakely <jwakely@redhat.com>
340 * src/c++17/fs_path.cc (path::_M_split_cmpts()): Remove
341 micro-optimization for "/" path.
342 * src/filesystem/path.cc (path::_M_split_cmpts()): Only access
343 the contents of _M_pathname using const member functions.
345 2021-11-30 Jonathan Wakely <jwakely@redhat.com>
347 * testsuite/21_strings/basic_string/cons/char/moveable.cc: Allow
348 moved-from string to be non-empty.
349 * testsuite/21_strings/basic_string/cons/char/moveable2.cc:
351 * testsuite/21_strings/basic_string/cons/char/moveable2_c++17.cc:
353 * testsuite/21_strings/basic_string/cons/wchar_t/moveable.cc:
355 * testsuite/21_strings/basic_string/cons/wchar_t/moveable2.cc:
357 * testsuite/21_strings/basic_string/cons/wchar_t/moveable2_c++17.cc:
359 * testsuite/21_strings/basic_string/modifiers/assign/char/87749.cc:
360 Construct empty string before setting oom flag.
361 * testsuite/21_strings/basic_string/modifiers/assign/wchar_t/87749.cc:
364 2021-11-30 Jonathan Wakely <jwakely@redhat.com>
366 * include/bits/cow_string.h (basic_string(basic_string&&)): Fix
367 mem-initializer for _GLIBCXX_FULLY_DYNAMIC_STRING==0 case.
368 * testsuite/21_strings/basic_string/cons/char/noexcept_move_construct.cc:
369 Remove outdated comment.
370 * testsuite/21_strings/basic_string/cons/wchar_t/noexcept_move_construct.cc:
373 2021-11-30 Jonathan Wakely <jwakely@redhat.com>
375 * src/c++20/sstream-inst.cc (_GLIBCXX_USE_CXX11_ABI): Define to
378 2021-11-30 Jonathan Wakely <jwakely@redhat.com>
380 * include/bits/stl_vector.h (vector::_S_do_relocate): Remove
381 C++20 constexpr specifier.
382 (vector::_S_relocate) [__cpp_if_constexpr]: Call __relocate_a
383 directly without tag dispatching.
385 2021-11-30 Jonathan Wakely <jwakely@redhat.com>
388 * config/allocator/malloc_allocator_base.h
389 (_GLIBCXX_SANITIZE_STD_ALLOCATOR): Define for Clang.
390 * config/allocator/new_allocator_base.h
391 (_GLIBCXX_SANITIZE_STD_ALLOCATOR): Likewise.
393 2021-11-30 Jonathan Wakely <jwakely@redhat.com>
395 * doc/xml/manual/debug_mode.xml: Replace "his or her" with "their".
396 * doc/html/manual/debug_mode_design.html: Regenerate.
398 2021-11-30 Jakub Jelinek <jakub@redhat.com>
400 * include/std/bit (byteswap): Add [[nodiscard]].
402 2021-11-28 Jakub Jelinek <jakub@redhat.com>
404 * include/std/bit (__cpp_lib_byteswap, byteswap): Define.
405 * include/std/version (__cpp_lib_byteswap): Define.
406 * testsuite/26_numerics/bit/bit.byteswap/byteswap.cc: New test.
407 * testsuite/26_numerics/bit/bit.byteswap/version.cc: New test.
409 2021-11-26 Jonathan Wakely <jwakely@redhat.com>
411 * testsuite/24_iterators/move_iterator/dr3265.cc: Fix test to
412 account for LWG 3435 resolution.
414 2021-11-26 Jonathan Wakely <jwakely@redhat.com>
416 * include/bits/stl_uninitialized.h (__relocate_a_1): Do not use
417 memmove during constant evaluation.
418 * include/bits/stl_vector.h (vector::_S_use_relocate()): Do not
419 check is_constant_evaluated in always-constexpr function.
421 2021-11-26 Jonathan Wakely <jwakely@redhat.com>
424 * include/std/tuple (tuple::is_constructible): Remove.
426 2021-11-26 Jonathan Wakely <jwakely@redhat.com>
428 * testsuite/29_atomics/atomic_float/1.cc: Reorder directives.
430 2021-11-26 Jonathan Wakely <jwakely@redhat.com>
432 * testsuite/23_containers/unordered_map/modifiers/move_assign.cc:
433 Change dg-do compile to run.
434 * testsuite/27_io/basic_istream/extractors_character/wchar_t/lwg2499.cc:
437 2021-11-26 Jonathan Wakely <jwakely@redhat.com>
439 * testsuite/21_strings/basic_string_view/element_access/char/back_constexpr_neg.cc:
440 Remove xfail selector.
441 * testsuite/21_strings/basic_string_view/element_access/char/constexpr_neg.cc:
444 * testsuite/21_strings/basic_string_view/element_access/char/front_constexpr_neg.cc:
446 * testsuite/21_strings/basic_string_view/element_access/wchar_t/back_constexpr_neg.cc:
448 * testsuite/21_strings/basic_string_view/element_access/wchar_t/constexpr_neg.cc:
450 * testsuite/21_strings/basic_string_view/element_access/wchar_t/front_constexpr_neg.cc:
452 * testsuite/23_containers/span/101411.cc: Likewise.
453 * testsuite/25_algorithms/copy/debug/constexpr_neg.cc: Likewise.
454 * testsuite/25_algorithms/copy_backward/debug/constexpr_neg.cc:
456 * testsuite/25_algorithms/equal/constexpr_neg.cc: Likewise.
457 * testsuite/25_algorithms/equal/debug/constexpr_neg.cc: Likewise.
458 * testsuite/25_algorithms/lower_bound/debug/constexpr_partitioned_neg.cc:
460 * testsuite/25_algorithms/lower_bound/debug/constexpr_partitioned_pred_neg.cc:
462 * testsuite/25_algorithms/lower_bound/debug/constexpr_valid_range_neg.cc:
464 * testsuite/25_algorithms/upper_bound/debug/constexpr_partitioned_neg.cc:
466 * testsuite/25_algorithms/upper_bound/debug/constexpr_partitioned_pred_neg.cc:
468 * testsuite/25_algorithms/upper_bound/debug/constexpr_valid_range_neg.cc:
471 2021-11-26 Jonathan Wakely <jwakely@redhat.com>
473 * testsuite/20_util/pointer_traits/lwg3545.cc: Move to_address
475 * testsuite/20_util/to_address/lwg3545.cc: ... here. Add -std
476 option before checking effective target.
478 2021-11-25 Jonathan Wakely <jwakely@redhat.com>
480 * testsuite/20_util/tuple/comparison_operators/overloaded2.cc:
481 Remove dg-error for C++11_only error.
483 2021-11-25 Jonathan Wakely <jwakely@redhat.com>
486 * include/bits/ptr_traits.h (pointer_traits): Reimplement to be
487 SFINAE-friendly (LWG 3545).
488 * testsuite/20_util/pointer_traits/lwg3545.cc: New test.
489 * testsuite/20_util/to_address/1_neg.cc: Adjust dg-error line.
490 * testsuite/20_util/to_address/lwg3545.cc: New test.
492 2021-11-25 Jonathan Wakely <jwakely@redhat.com>
495 * include/bits/ranges_algobase.h (__fill_n_fn): Check for
496 constant evaluation before using memset.
497 * testsuite/25_algorithms/fill_n/constrained.cc: Check
498 byte-sized values as well.
500 2021-11-24 Jonathan Wakely <jwakely@redhat.com>
502 * testsuite/libstdc++-prettyprinters/80276.cc: Add xfail for
504 * testsuite/libstdc++-prettyprinters/libfundts.cc: Likewise.
506 2021-11-24 Jonathan Wakely <jwakely@redhat.com>
508 * testsuite/lib/libstdc++.exp: Rename effective target keywords
509 to avoid dashes in the name.
510 * testsuite/*: Update effective targe keywords.
512 2021-11-23 Jonathan Wakely <jwakely@redhat.com>
515 * testsuite/libstdc++-prettyprinters/cxx11.cc: Check unique_ptr
516 with non-empty pointer and non-empty deleter.
518 2021-11-23 Jonathan Wakely <jwakely@redhat.com>
520 * testsuite/18_support/50594.cc: Check effective target.
521 * testsuite/20_util/allocator/1.cc: Likewise.
522 * testsuite/20_util/allocator/overaligned.cc: Likewise.
523 * testsuite/23_containers/unordered_map/96088.cc: Likewise.
524 * testsuite/23_containers/unordered_multimap/96088.cc: Likewise.
525 * testsuite/23_containers/unordered_multiset/96088.cc: Likewise.
526 * testsuite/23_containers/unordered_set/96088.cc: Likewise.
527 * testsuite/ext/throw_allocator/check_delete.cc: Likewise.
528 * testsuite/ext/throw_allocator/check_new.cc: Likewise.
529 * testsuite/lib/libstdc++.exp (check_effective_target_std_allocator_new):
532 2021-11-23 Jonathan Wakely <jwakely@redhat.com>
535 * include/ext/bitmap_allocator.h: Include <bits/stl_function.h>
536 instead of <functional>.
538 2021-11-22 Jonathan Wakely <jwakely@redhat.com>
540 * include/bits/c++config (_GLIBCXX14_DEPRECATED): Fix condition
543 2021-11-20 François Dumont <fdumont@gcc.gnu.org>
545 * include/bits/erase_if.h (__erase_nodes_if): Add _UnsafeContainer template
546 parameter. Use it to get iterators to work with.
547 * include/debug/macros.h (__glibcxx_check_erase2): New.
548 * include/debug/map.h (map<>::erase(_Base_const_iterator)): New.
549 (map<>::erase(const_iterator)): Use latter.
550 * include/debug/multimap.h (multimap<>::erase(_Base_const_iterator)): New.
551 (multimap<>::erase(const_iterator)): Use latter.
552 * include/debug/multiset.h (multiset<>::erase(_Base_const_iterator)): New.
553 (multiset<>::erase(const_iterator)): Use latter.
554 * include/debug/set.h (set<>::erase(_Base_const_iterator)): New.
555 (set<>::erase(const_iterator)): Use latter.
556 * include/debug/unordered_map (unordered_map<>::erase(_Base_const_iterator)): New.
557 (unordered_multimap<>::erase(const_iterator)): New.
558 * include/debug/unordered_set (unordered_set<>::erase(_Base_const_iterator)): New.
559 (unordered_multiset<>::erase(const_iterator)): New.
560 * include/experimental/map (erase_if): Adapt.
561 * include/experimental/set (erase_if): Adapt.
562 * include/experimental/unordered_map (erase_if): Adapt.
563 * include/experimental/unordered_set (erase_if): Adapt.
564 * include/std/map (erase_if): Adapt.
565 * include/std/set (erase_if): Adapt.
566 * include/std/unordered_map (erase_if): Adapt.
567 * include/std/unordered_set (erase_if): Adapt.
569 2021-11-19 Jonathan Wakely <jwakely@redhat.com>
571 * testsuite/27_io/basic_istringstream/cons/char/1.cc: Check all
573 * testsuite/27_io/basic_istringstream/cons/wchar_t/1.cc:
575 * testsuite/27_io/basic_ostringstream/cons/char/1.cc: Likewise.
576 * testsuite/27_io/basic_ostringstream/cons/wchar_t/1.cc:
578 * testsuite/27_io/basic_stringstream/cons/char/1.cc: Likewise.
579 * testsuite/27_io/basic_stringstream/cons/wchar_t/1.cc:
582 2021-11-19 Jonathan Wakely <jwakely@redhat.com>
584 * src/c++98/locale_init.cc (_S_initialize_once): Check if
585 initialization has already been done.
586 (_S_initialize): Replace __gthread_active_p with
587 __is_single_threaded. Use __builtin_expect.
589 2021-11-19 Jonathan Wakely <jwakely@redhat.com>
592 * include/bits/basic_string.tcc (_M_construct): Use the
593 traits assign member to write into allcoated memory.
595 2021-11-19 Iain Sandoe <iain@sandoe.co.uk>
597 * testsuite/lib/prune.exp: Prune dsymutil (ld64) warning.
599 2021-11-19 Jonathan Wakely <jwakely@redhat.com>
603 * testsuite/21_strings/basic_string/capacity/char/1.cc: Add
604 -Wno-stringop-overflow.
605 * testsuite/21_strings/basic_string/operators/char/1.cc:
607 * testsuite/experimental/filesystem/path/factory/u8path-char8_t.cc:
608 Add -Wno-stringop-overread.
610 2021-11-19 Jonathan Wakely <jwakely@redhat.com>
613 * include/bits/basic_string.h (_Alloc_traits): Replace typedef
614 with struct for C++20 mode.
615 * include/bits/basic_string.tcc (_M_replace): Use _Alloc_traits
617 * include/bits/char_traits.h (__gnu_cxx::char_traits::assign):
618 Use std::_Construct during constant evaluation.
619 (__gnu_cxx::char_traits::assign(CharT*, const CharT*, size_t)):
620 Likewise. Replace std::fill_n with memset or manual loop.
621 (__gnu_cxx::char_traits::copy): Likewise, replacing std::copy
623 * include/ext/vstring.h: Include <bits/stl_algobase.h> for
625 * include/std/string_view: Likewise.
626 * testsuite/21_strings/basic_string/capacity/char/resize_and_overwrite.cc:
629 2021-11-19 Tamar Christina <tamar.christina@arm.com>
632 * config/os/newlib/ctype_base.h (upper, lower, alpha, digit, xdigit,
633 space, print, graph, cntrl, punct, alnum, blank): Use short or long
634 names depending on if short ones are defined.
636 2021-11-18 Jonathan Wakely <jwakely@redhat.com>
638 * include/bits/char_traits.h (__gnu_cxx::char_traits::move):
639 Do not compare unrelated pointers during constant evaluation.
640 * testsuite/21_strings/char_traits/requirements/constexpr_functions_c++20.cc:
641 Improve tests for char_traits::move.
643 2021-11-18 Jonathan Wakely <jwakely@redhat.com>
645 * acinclude.m4: Replace AC_CACHE_VAL with AC_CACHE_CHECK.
646 * configure: Regenerate.
648 2021-11-17 Jonathan Wakely <jwakely@redhat.com>
650 * include/experimental/internet (address): Use std::_Construct
651 to initialize union members.
653 2021-11-17 Jonathan Wakely <jwakely@redhat.com>
655 * include/bits/basic_string.h (_M_construct_aux): Only define
656 for C++98. Remove constexpr.
657 (_M_construct_aux_2): Likewise.
658 (_M_construct(InputIter, InputIter)): Remove.
659 (basic_string(const basic_string&)): Call _M_construct with
660 iterator category argument.
661 (basic_string(const basic_string&, size_type, const Alloc&)):
663 (basic_string(const basic_string&, size_type, size_type)):
665 (basic_string(const charT*, size_type, const Alloc&)): Likewise.
666 Check for null pointer.
667 (basic_string(const charT*, const Alloc&)): Likewise.
668 (basic_string(initializer_list<charT>, const Alloc&)): Call
669 _M_construct with iterator category argument.
670 (basic_string(const basic_string&, const Alloc&)): Likewise.
671 (basic_string(basic_string&&, const Alloc&)): Likewise.
672 (basic_string(_InputIter, _InputIter, const Alloc&)): Likewise
673 for C++11 and later, call _M_construct_aux for C++98.
674 * include/bits/basic_string.tcc
675 (_M_construct(I, I, input_iterator_tag)): Replace try-block with
677 (_M_construct(I, I, forward_iterator_tag)): Likewise. Remove
678 __is_null_pointer check.
680 2021-11-17 Jonathan Wakely <jwakely@redhat.com>
683 * include/bits/basic_string.h (_M_use_local_data()): New
684 member function to make local buffer the active member.
685 (assign(const basic_string&)): Use it.
686 * include/bits/basic_string.tcc (_M_construct, reserve()):
689 2021-11-17 Jonathan Wakely <jwakely@redhat.com>
692 * libsupc++/tinfo2.cc (type_info::before): Use unadjusted name
693 to check for the '*' prefix.
694 * testsuite/util/testsuite_shared.cc: Add type_info object for
696 * testsuite/18_support/type_info/103240.cc: New test.
698 2021-11-16 Jonathan Wakely <jwakely@redhat.com>
700 * include/bits/basic_string.h (operator<=>): Use constexpr
702 * testsuite/21_strings/basic_string/modifiers/constexpr.cc:
703 Require cxx11-abit effective target.
704 * testsuite/21_strings/headers/string/synopsis.cc: Add
705 conditional constexpr to declarations, and adjust relational
708 2021-11-16 Patrick Palka <ppalka@redhat.com>
710 * src/c++17/ryu/MERGE: Update the commit hash.
711 * src/c++17/ryu/d2s_intrinsics.h: Merge from Ryu's master
714 2021-11-16 Jonathan Wakely <jwakely@redhat.com>
716 * include/bits/basic_string.h (basic_string, operator""s): Add
718 (basic_string::basic_string(basic_string&&)): Only copy
719 initialized portion of the buffer.
720 (basic_string::basic_string(basic_string&&, const Alloc&)):
722 * include/bits/basic_string.tcc (basic_string): Add constexpr
724 (basic_string::swap(basic_string&)): Only copy initialized
725 portions of the buffers.
726 (basic_string::_M_replace): Add constexpr implementation that
727 doesn't depend on pointer comparisons.
728 * include/bits/cow_string.h: Adjust comment.
729 * include/ext/type_traits.h (__is_null_pointer): Add constexpr.
730 * include/std/string (erase, erase_if): Add constexpr.
731 * include/std/version (__cpp_lib_constexpr_string): Update
733 * testsuite/21_strings/basic_string/cons/char/constexpr.cc:
735 * testsuite/21_strings/basic_string/cons/wchar_t/constexpr.cc:
737 * testsuite/21_strings/basic_string/literals/constexpr.cc:
739 * testsuite/21_strings/basic_string/modifiers/constexpr.cc: New test.
740 * testsuite/21_strings/basic_string/modifiers/swap/char/constexpr.cc:
742 * testsuite/21_strings/basic_string/modifiers/swap/wchar_t/constexpr.cc:
744 * testsuite/21_strings/basic_string/version.cc: New test.
746 2021-11-16 Jonathan Wakely <jwakely@redhat.com>
748 * include/bits/stl_bvector.h (swap(_Bit_reference, _Bit_reference))
749 (swap(_Bit_reference, bool&), swap(bool&, _Bit_reference)):
750 Define as hidden friends of _Bit_reference.
752 2021-11-16 Jonathan Wakely <jwakely@redhat.com>
754 * testsuite/21_strings/basic_string/modifiers/append/wchar_t/1.cc:
755 Fix reads past the end of strings.
756 * testsuite/21_strings/basic_string/operations/compare/wchar_t/1.cc:
758 * testsuite/experimental/string_view/operations/compare/wchar_t/1.cc:
761 2021-11-16 Jonathan Wakely <jwakely@redhat.com>
763 * testsuite/21_strings/basic_string/allocator/71964.cc: Fix
765 * testsuite/23_containers/set/allocator/71964.cc: Likewise.
767 2021-11-15 Jason Merrill <jason@redhat.com>
769 * testsuite/20_util/to_address/1_neg.cc: Adjust error.
770 * testsuite/26_numerics/random/concept.cc: Adjust asserts.
772 2021-11-15 François Dumont <fdumont@gcc.gnu.org>
774 * include/bits/hashtable_policy.h:
775 (_Hash_code_base<>::_M_hash_code(const _Hash&, const _Hash_node_value<_Value, true>&)): New.
776 (_Hash_code_base<>::_M_hash_code<_H2>(const _H2&, const _Hash_node_value<>&)): New.
777 * include/bits/hashtable.h (_Hashtable<>::_M_merge_unique): Use latter.
778 (_Hashtable<>::_M_merge_multi): Likewise.
779 * testsuite/23_containers/unordered_multiset/modifiers/merge.cc (test05): New test.
780 * testsuite/23_containers/unordered_set/modifiers/merge.cc (test04): New test.
782 2021-11-15 Jason Merrill <jason@redhat.com>
784 * src/c++17/memory_resource.cc: Add missing constexpr.
785 * include/experimental/internet: Only mark copy constructor
786 as constexpr with __cpp_constexpr_dynamic_alloc.
788 2021-11-14 François Dumont <fdumont@gcc.gnu.org>
790 * include/debug/safe_container.h (_Safe_container<>::_M_safe): Remove.
791 * include/debug/deque (deque::operator=(initializer_list<>)): Replace
792 _M_base() call with _Base:: call.
793 (deque::operator[](size_type)): Likewise.
794 * include/debug/forward_list (forward_list(forward_list&&, const allocator_type&)):
795 Remove _M_safe() and _M_base() calls.
796 (forward_list::operator=(initializer_list<>)): Remove _M_base() calls.
797 (forward_list::splice_after, forward_list::merge): Likewise.
798 * include/debug/list (list(list&&, const allocator_type&)):
799 Remove _M_safe() and _M_base() calls.
800 (list::operator=(initializer_list<>)): Remove _M_base() calls.
801 (list::splice, list::merge): Likewise.
802 * include/debug/map.h (map(map&&, const allocator_type&)):
803 Remove _M_safe() and _M_base() calls.
804 (map::operator=(initializer_list<>)): Remove _M_base() calls.
805 * include/debug/multimap.h (multimap(multimap&&, const allocator_type&)):
806 Remove _M_safe() and _M_base() calls.
807 (multimap::operator=(initializer_list<>)): Remove _M_base() calls.
808 * include/debug/set.h (set(set&&, const allocator_type&)):
809 Remove _M_safe() and _M_base() calls.
810 (set::operator=(initializer_list<>)): Remove _M_base() calls.
811 * include/debug/multiset.h (multiset(multiset&&, const allocator_type&)):
812 Remove _M_safe() and _M_base() calls.
813 (multiset::operator=(initializer_list<>)): Remove _M_base() calls.
814 * include/debug/string (basic_string(basic_string&&, const allocator_type&)):
815 Remove _M_safe() and _M_base() calls.
816 (basic_string::operator=(initializer_list<>)): Remove _M_base() call.
817 (basic_string::operator=(const _CharT*), basic_string::operator=(_CharT)): Likewise.
818 (basic_string::operator[](size_type), basic_string::operator+=(const basic_string&)):
820 (basic_string::operator+=(const _Char*), basic_string::operator+=(_CharT)): Likewise.
821 * include/debug/unordered_map (unordered_map(unordered_map&&, const allocator_type&)):
822 Remove _M_safe() and _M_base() calls.
823 (unordered_map::operator=(initializer_list<>), unordered_map::merge):
824 Remove _M_base() calls.
825 (unordered_multimap(unordered_multimap&&, const allocator_type&)):
826 Remove _M_safe() and _M_base() calls.
827 (unordered_multimap::operator=(initializer_list<>), unordered_multimap::merge):
828 Remove _M_base() calls.
829 * include/debug/unordered_set (unordered_set(unordered_set&&, const allocator_type&)):
830 Remove _M_safe() and _M_base() calls.
831 (unordered_set::operator=(initializer_list<>), unordered_set::merge):
832 Remove _M_base() calls.
833 (unordered_multiset(unordered_multiset&&, const allocator_type&)):
834 Remove _M_safe() and _M_base() calls.
835 (unordered_multiset::operator=(initializer_list<>), unordered_multiset::merge):
836 Remove _M_base() calls.
837 * include/debug/vector (vector(vector&&, const allocator_type&)):
838 Remove _M_safe() and _M_base() calls.
839 (vector::operator=(initializer_list<>)): Remove _M_base() calls.
840 (vector::operator[](size_type)): Likewise.
842 2021-11-13 Jonathan Wakely <jwakely@redhat.com>
844 * include/Makefile.am: Add spanstream header.
845 * include/Makefile.in: Regenerate.
846 * include/precompiled/stdc++.h: Add spanstream header.
847 * include/std/version (__cpp_lib_spanstream): Define.
848 * include/std/spanstream: New file.
849 * testsuite/27_io/spanstream/1.cc: New test.
850 * testsuite/27_io/spanstream/version.cc: New test.
852 2021-11-13 Hans-Peter Nilsson <hp@axis.com>
855 * acinclude.m4 (GLIBCXX_CHECK_GETENTROPY, GLIBCXX_CHECK_ARC4RANDOM):
856 Use GCC_TRY_COMPILE_OR_LINK instead of AC_TRY_COMPILE.
857 * configure: Regenerate.
859 2021-11-12 Jonathan Wakely <jwakely@redhat.com>
862 * acinclude.m4 (libtool_VERSION): Bump version.
863 * config/abi/pre/gnu.ver (GLIBCXX_3.4.30): Add version and
865 * configure: Regenerate.
866 * include/bits/c++config (__replacement_assert): Remove, declare
867 __glibcxx_assert_fail instead.
868 * src/c++11/debug.cc (__glibcxx_assert_fail): New function to
869 replace __replacement_assert, writing to stderr instead of
871 * testsuite/util/testsuite_abi.cc: Update latest version.
873 2021-11-12 Jonathan Wakely <jwakely@redhat.com>
874 Josh Marshall <joshua.r.marshall.1991@gmail.com>
876 * include/bits/alloc_traits.h (_Destroy): Make constexpr for
878 * include/bits/allocator.h (__shrink_to_fit::_S_do_it):
880 * include/bits/stl_algobase.h (__fill_a1): Declare _Bit_iterator
881 overload constexpr for C++20.
882 * include/bits/stl_bvector.h (_Bit_type, _S_word_bit): Move out
884 (_Bit_reference, _Bit_iterator_base, _Bit_iterator)
885 (_Bit_const_iterator, _Bvector_impl_data, _Bvector_base)
886 (vector<bool, A>>): Add constexpr to every member function.
887 (_Bvector_base::_M_allocate): Initialize storage during constant
889 (vector<bool, A>::_M_initialize_value): Use __fill_bvector_n
891 (__fill_bvector_n): New helper function to replace memset during
893 * include/bits/stl_uninitialized.h (__uninitialized_copy<false>):
895 (__do_uninit_copy): New function.
896 (__uninitialized_fill<false>): Move logic to ...
897 (__do_uninit_fill): New function.
898 (__uninitialized_fill_n<false>): Move logic to ...
899 (__do_uninit_fill_n): New function.
900 (__uninitialized_copy_a): Add constexpr. Use __do_uninit_copy.
901 (__uninitialized_move_a, __uninitialized_move_if_noexcept_a):
903 (__uninitialized_fill_a): Add constexpr. Use __do_uninit_fill.
904 (__uninitialized_fill_n_a): Add constexpr. Use
906 (__uninitialized_default_n, __uninitialized_default_n_a)
907 (__relocate_a_1, __relocate_a): Add constexpr.
908 * include/bits/stl_vector.h (_Vector_impl_data, _Vector_impl)
909 (_Vector_base, vector): Add constexpr to every member function.
910 (_Vector_impl::_S_adjust): Disable ASan annotation during
912 (_Vector_base::_S_use_relocate): Disable bitwise-relocation
913 during constant evaluation.
914 (vector::_Temporary_value): Use a union for storage.
915 * include/bits/vector.tcc (vector, vector<bool>): Add constexpr
916 to every member function.
917 * include/std/vector (erase_if, erase): Add constexpr.
918 * testsuite/23_containers/headers/vector/synopsis.cc: Add
919 constexpr for C++20 mode.
920 * testsuite/23_containers/vector/bool/cmp_c++20.cc: Change to
921 compile-only test using constant expressions.
922 * testsuite/23_containers/vector/bool/capacity/29134.cc: Adjust
923 namespace for _S_word_bit.
924 * testsuite/23_containers/vector/bool/modifiers/insert/31370.cc:
926 * testsuite/23_containers/vector/cmp_c++20.cc: Likewise.
927 * testsuite/23_containers/vector/cons/89164.cc: Adjust errors
928 for C++20 and move C++17 test to ...
929 * testsuite/23_containers/vector/cons/89164_c++17.cc: ... here.
930 * testsuite/23_containers/vector/bool/capacity/constexpr.cc: New test.
931 * testsuite/23_containers/vector/bool/cons/constexpr.cc: New test.
932 * testsuite/23_containers/vector/bool/element_access/constexpr.cc: New test.
933 * testsuite/23_containers/vector/bool/modifiers/assign/constexpr.cc: New test.
934 * testsuite/23_containers/vector/bool/modifiers/constexpr.cc: New test.
935 * testsuite/23_containers/vector/bool/modifiers/swap/constexpr.cc: New test.
936 * testsuite/23_containers/vector/capacity/constexpr.cc: New test.
937 * testsuite/23_containers/vector/cons/constexpr.cc: New test.
938 * testsuite/23_containers/vector/data_access/constexpr.cc: New test.
939 * testsuite/23_containers/vector/element_access/constexpr.cc: New test.
940 * testsuite/23_containers/vector/modifiers/assign/constexpr.cc: New test.
941 * testsuite/23_containers/vector/modifiers/constexpr.cc: New test.
942 * testsuite/23_containers/vector/modifiers/swap/constexpr.cc: New test.
944 2021-11-11 Jonathan Wakely <jwakely@redhat.com>
946 * include/debug/deque (deque::operator=(const deque&)): Remove
948 * include/debug/list (list::operator=(const list&)): Likewise.
949 * include/debug/map.h (map::operator=(const map&)): Likewise.
950 * include/debug/multimap.h (multimap::operator=(const multimap&)):
952 * include/debug/multiset.h (multiset::operator=(const multiset&)):
954 * include/debug/set.h (set::operator=(const set&)): Likewise.
955 * include/debug/string (basic_string::operator=(const basic_string&)):
957 * include/debug/vector (vector::operator=(const vector&)):
959 (_Safe_vector::operator=(const _Safe_vector&)): Define for
962 2021-11-11 Jonathan Wakely <jwakely@redhat.com>
964 * include/std/memory_resource (memory_resource::allocate):
965 Implicitly create objects in the returned storage.
967 2021-11-11 Jonathan Wakely <jwakely@redhat.com>
969 * include/bits/stl_bvector.h (vector<bool>::data()): Give
970 protected access, and delete for C++11 and later.
972 2021-11-10 Jonathan Wakely <jwakely@redhat.com>
975 * testsuite/17_intro/headers/c++1998/49745.cc: Explicitly list
976 all C++ headers instead of including <bits/stdc++.h>
978 2021-11-10 Jonathan Wakely <jwakely@redhat.com>
982 * config/os/gnu-linux/os_defines.h (_GLIBCXX_GTHREAD_USE_WEAK):
983 Define for glibc 2.34 and later.
985 2021-11-09 François Dumont <fdumont@gcc.gnu.org>
987 * include/bits/hashtable_policy.h (__distance_fw): Replace class keyword with
989 * include/bits/hashtable.h (_Hashtable<>::_M_merge_unique): Remove noexcept
990 qualification. Use const_iterator for node extraction/reinsert.
991 (_Hashtable<>::_M_merge_multi): Likewise. Compute new hash code before extract.
992 * include/debug/safe_container.h (_Safe_container<>): Make all methods
994 * include/debug/safe_unordered_container.h
995 (_Safe_unordered_container<>::_UContInvalidatePred<_ExtractKey, _Source>): New.
996 (_Safe_unordered_container<>::_UMContInvalidatePred<_ExtractKey, _Source>): New.
997 (_Safe_unordered_container<>::_UContMergeGuard<_Source, _InvalidatePred>): New.
998 (_Safe_unordered_container<>::_S_uc_guard<_ExtractKey, _Source>): New.
999 (_Safe_unordered_container<>::_S_umc_guard<_ExtractKey, _Source>): New.
1000 (_Safe_unordered_container<>::_M_invalide_all): Make public.
1001 (_Safe_unordered_container<>::_M_invalide_if): Likewise.
1002 (_Safe_unordered_container<>::_M_invalide_local_if): Likewise.
1003 * include/debug/unordered_map
1004 (unordered_map<>::mapped_type, pointer, const_pointer): New typedef.
1005 (unordered_map<>::reference, const_reference, difference_type): New typedef.
1006 (unordered_map<>::get_allocator, empty, size, max_size): Add usings.
1007 (unordered_map<>::bucket_count, max_bucket_count, bucket): Add usings.
1008 (unordered_map<>::hash_function, key_equal, count, contains): Add usings.
1009 (unordered_map<>::operator[], at, rehash, reserve): Add usings.
1010 (unordered_map<>::merge): New.
1011 (unordered_multimap<>::mapped_type, pointer, const_pointer): New typedef.
1012 (unordered_multimap<>::reference, const_reference, difference_type): New typedef.
1013 (unordered_multimap<>::get_allocator, empty, size, max_size): Add usings.
1014 (unordered_multimap<>::bucket_count, max_bucket_count, bucket): Add usings.
1015 (unordered_multimap<>::hash_function, key_equal, count, contains): Add usings.
1016 (unordered_multimap<>::rehash, reserve): Add usings.
1017 (unordered_multimap<>::merge): New.
1018 * include/debug/unordered_set
1019 (unordered_set<>::mapped_type, pointer, const_pointer): New typedef.
1020 (unordered_set<>::reference, const_reference, difference_type): New typedef.
1021 (unordered_set<>::get_allocator, empty, size, max_size): Add usings.
1022 (unordered_set<>::bucket_count, max_bucket_count, bucket): Add usings.
1023 (unordered_set<>::hash_function, key_equal, count, contains): Add usings.
1024 (unordered_set<>::rehash, reserve): Add usings.
1025 (unordered_set<>::merge): New.
1026 (unordered_multiset<>::mapped_type, pointer, const_pointer): New typedef.
1027 (unordered_multiset<>::reference, const_reference, difference_type): New typedef.
1028 (unordered_multiset<>::get_allocator, empty, size, max_size): Add usings.
1029 (unordered_multiset<>::bucket_count, max_bucket_count, bucket): Add usings.
1030 (unordered_multiset<>::hash_function, key_equal, count, contains): Add usings.
1031 (unordered_multiset<>::rehash, reserve): Add usings.
1032 (unordered_multiset<>::merge): New.
1033 * testsuite/23_containers/unordered_map/debug/merge1_neg.cc: New test.
1034 * testsuite/23_containers/unordered_map/debug/merge2_neg.cc: New test.
1035 * testsuite/23_containers/unordered_map/debug/merge3_neg.cc: New test.
1036 * testsuite/23_containers/unordered_map/debug/merge4_neg.cc: New test.
1037 * testsuite/23_containers/unordered_multimap/debug/merge1_neg.cc: New test.
1038 * testsuite/23_containers/unordered_multimap/debug/merge2_neg.cc: New test.
1039 * testsuite/23_containers/unordered_multimap/debug/merge3_neg.cc: New test.
1040 * testsuite/23_containers/unordered_multimap/debug/merge4_neg.cc: New test.
1041 * testsuite/23_containers/unordered_multiset/debug/merge1_neg.cc: New test.
1042 * testsuite/23_containers/unordered_multiset/debug/merge2_neg.cc: New test.
1043 * testsuite/23_containers/unordered_multiset/debug/merge3_neg.cc: New test.
1044 * testsuite/23_containers/unordered_multiset/debug/merge4_neg.cc: New test.
1045 * testsuite/23_containers/unordered_set/debug/merge1_neg.cc: New test.
1046 * testsuite/23_containers/unordered_set/debug/merge2_neg.cc: New test.
1047 * testsuite/23_containers/unordered_set/debug/merge3_neg.cc: New test.
1048 * testsuite/23_containers/unordered_set/debug/merge4_neg.cc: New test.
1049 * testsuite/util/testsuite_abi.h: [_GLIBCXX_DEBUG] Use normal unordered
1050 container implementation.
1052 2021-11-09 Jonathan Wakely <jwakely@redhat.com>
1054 * testsuite/26_numerics/random/random_device/cons/token.cc:
1055 Print results of random_device_available checks.
1057 2021-11-09 Jonathan Wakely <jwakely@redhat.com>
1060 * src/c++11/random.cc: Check __powerpc64__ not __powerpc__.
1062 2021-11-09 Jonathan Wakely <jwakely@redhat.com>
1064 * acinclude.m4 (GLIBCXX_CHECK_GETENTROPY, GLIBCXX_CHECK_ARC4RANDOM):
1066 * configure.ac (GLIBCXX_CHECK_GETENTROPY, GLIBCXX_CHECK_ARC4RANDOM):
1068 * config.h.in: Regenerate.
1069 * configure: Regenerate.
1070 * src/c++11/random.cc (random_device): Add getentropy and
1071 arc4random as sources.
1072 * testsuite/26_numerics/random/random_device/cons/token.cc:
1074 * testsuite/26_numerics/random/random_device/entropy.cc:
1077 2021-11-09 Jonathan Wakely <jwakely@redhat.com>
1079 * testsuite/26_numerics/random/random_device/cons/token.cc:
1080 Retry if random devices produce the same value.
1082 2021-11-09 Rasmus Villemoes <rasmus.villemoes@prevas.dk>
1084 * config/os/vxworks/os_defines.h (_GLIBCXX_HAVE_TLS): Only
1085 define for VxWorks >= 6.6.
1087 2021-11-05 Jonathan Wakely <jwakely@redhat.com>
1089 * include/bits/range_access.h (begin(valarray), end(valarray)):
1092 2021-11-05 Jonathan Wakely <jwakely@redhat.com>
1094 * include/std/tuple (tuple_size_v): Fix pack expansion.
1096 2021-11-05 Jonathan Wakely <jwakely@redhat.com>
1098 * src/c++11/random.cc (__x86_rdrand, __x86_rdseed): Add
1099 [[unlikely]] attribute.
1101 2021-11-05 Jonathan Wakely <jwakely@redhat.com>
1103 * src/c++11/random.cc [__powerpc__] (USE_DARN): Define.
1104 (__ppc_darn): New function to use POWER9 DARN instruction.
1105 (Which): Add 'darn' enumerator.
1106 (which_source): Check for __ppc_darn.
1107 (random_device::_M_init): Support "darn" and "hw" tokens.
1108 (random_device::_M_getentropy): Add darn to switch.
1109 * testsuite/26_numerics/random/random_device/cons/token.cc:
1111 * testsuite/26_numerics/random/random_device/entropy.cc:
1114 2021-11-05 Jonathan Wakely <jwakely@redhat.com>
1116 * testsuite/lib/gdb-test.exp: Add target selector support to the
1117 dg-final directives.
1118 * testsuite/libstdc++-prettyprinters/80276.cc: Add xfail for
1120 * testsuite/libstdc++-prettyprinters/libfundts.cc: Likewise.
1121 * testsuite/libstdc++-prettyprinters/prettyprinters.exp: Tweak
1124 2021-11-04 Jonathan Wakely <jwakely@redhat.com>
1127 * python/libstdcxx/v6/printers.py (_tuple_impl_get): New helper
1128 for accessing the tuple element stored in a _Tuple_impl node.
1129 (tuple_get): New function for accessing a tuple element.
1130 (unique_ptr_get): New function for accessing a unique_ptr.
1131 (UniquePointerPrinter, StdPathPrinter): Use unique_ptr_get.
1132 * python/libstdcxx/v6/xmethods.py (UniquePtrGetWorker): Cast
1133 tuple to its base class before accessing _M_head_impl.
1135 2021-11-04 Jonathan Wakely <jwakely@redhat.com>
1137 * doc/xml/manual/evolution.xml: Document deprecations.
1138 * doc/html/*: Regenerate.
1139 * libsupc++/exception (unexpected_handler, unexpected)
1140 (get_unexpected, set_unexpected): Add deprecated attribute.
1141 Do not define without _GLIBCXX_USE_DEPRECATED for C++17 and up.
1142 * libsupc++/eh_personality.cc (PERSONALITY_FUNCTION): Disable
1143 deprecated warnings.
1144 * libsupc++/eh_ptr.cc (std::rethrow_exception): Likewise.
1145 * libsupc++/eh_terminate.cc: Likewise.
1146 * libsupc++/eh_throw.cc (__cxa_init_primary_exception):
1148 * libsupc++/unwind-cxx.h (struct __cxa_exception): Use
1149 terminate_handler instead of unexpected_handler.
1150 (struct __cxa_dependent_exception): Likewise.
1151 (__unexpected): Likewise.
1152 * testsuite/18_support/headers/exception/synopsis.cc: Add
1153 dg-warning for deprecated warning.
1154 * testsuite/18_support/exception_ptr/60612-unexpected.cc:
1155 Disable deprecated warnings.
1156 * testsuite/18_support/set_unexpected.cc: Likewise.
1157 * testsuite/18_support/unexpected_handler.cc: Likewise.
1159 2021-11-04 Jonathan Wakely <jwakely@redhat.com>
1161 * include/bits/utility.h (__find_uniq_type_in_pack): Move
1162 definition to here, ...
1163 * include/std/tuple (__find_uniq_type_in_pack): ... from here.
1164 * include/std/variant (__detail__variant::__index_of): Remove.
1165 (__detail::__variant::__exactly_once): Define using
1166 __find_uniq_type_in_pack instead of __index_of.
1167 (get<T>, get_if<T>, variant::__index_of): Likewise.
1169 2021-11-04 Jonathan Wakely <jwakely@redhat.com>
1171 * include/bits/stl_pair.h (tuple_size_v): Define partial
1172 specializations for std::pair.
1173 * include/bits/utility.h (_Nth_type): Move definition here
1174 and define primary template.
1175 (tuple_size_v): Move definition here.
1176 * include/std/array (tuple_size_v): Define partial
1177 specializations for std::array.
1178 * include/std/tuple (tuple_size_v): Move primary template to
1179 <bits/utility.h>. Define partial specializations for
1181 (tuple_element): Change definition to use _Nth_type.
1182 * include/std/variant (_Nth_type): Move to <bits/utility.h>.
1183 (variant_alternative, variant): Adjust qualification of
1185 * testsuite/20_util/tuple/element_access/get_neg.cc: Prune
1186 additional errors from _Nth_type.
1188 2021-11-04 Jonathan Wakely <jwakely@redhat.com>
1190 * include/std/variant (__detail::__variant::__emplace): New
1192 (_Copy_assign_base::operator=): Reorder conditions to match
1193 bulleted list of effects in the standard. Use __emplace instead
1194 of _M_reset followed by _Construct.
1195 (_Move_assign_base::operator=): Likewise.
1196 (__construct_by_index): Remove.
1197 (variant::emplace): Use __emplace instead of _M_reset followed
1198 by __construct_by_index.
1199 (variant::swap): Hoist valueless cases out of visitor. Use
1200 __emplace to replace _M_reset followed by _Construct.
1202 2021-11-04 Jonathan Wakely <jwakely@redhat.com>
1204 * include/std/variant (_Nth_type): Define partial
1205 specializations to reduce number of instantiations.
1206 (variant_size_v): Define partial specializations to avoid
1208 (variant_alternative): Use _Nth_type. Add static assert.
1209 (__tuple_count, __tuple_count_v): Replace with ...
1210 (__count): New variable template.
1211 (_Variant_union): Add deleted constructor.
1212 (variant::__to_type): Use _Nth_type.
1213 (variant::emplace): Use _Nth_type. Add deleted overloads for
1214 invalid types and indices.
1216 2021-11-04 Jonathan Wakely <jwakely@redhat.com>
1219 * include/std/variant (_Variant_storage::__index_of): Remove.
1220 (__variant_construct_single): Remove.
1221 (__variant_construct): Remove.
1222 (_Copy_ctor_base::_Copy_ctor_base(const _Copy_ctor_base&)): Do
1223 construction directly instead of using __variant_construct.
1224 (_Move_ctor_base::_Move_ctor_base(_Move_ctor_base&&)): Likewise.
1225 (_Move_ctor_base::_M_destructive_move()): Remove.
1226 (_Move_ctor_base::_M_destructive_copy()): Remove.
1227 (_Copy_assign_base::operator=(const _Copy_assign_base&)): Do
1228 construction directly instead of using _M_destructive_copy.
1229 (variant::swap): Do construction directly instead of using
1230 _M_destructive_move.
1231 * testsuite/20_util/variant/102912.cc: New test.
1233 2021-11-03 Jonathan Wakely <jwakely@redhat.com>
1236 * include/bits/list.tcc (list::sort): Use mutable iterators for
1238 * include/bits/stl_list.h (_Scratch_list::_Ptr_cmp): Likewise.
1239 * testsuite/23_containers/list/operations/66742.cc: Check
1240 non-const comparisons.
1242 2021-11-03 Jonathan Wakely <jwakely@redhat.com>
1244 * include/std/valarray (valarray::valarray()): Add noexcept.
1245 (valarray::operator[]): Likewise.
1247 2021-11-01 Jonathan Wakely <jwakely@redhat.com>
1249 * include/debug/stl_iterator.h (__valid_range): Add constexpr
1250 for C++20. Qualify call to avoid ADL.
1251 (__get_distance, __can_advance, __unsafe, __base): Likewise.
1252 * testsuite/25_algorithms/move/constexpr.cc: Also check with
1253 std::reverse_iterator arguments.
1255 2021-11-01 Jonathan Wakely <jwakely@redhat.com>
1257 * include/std/span (span(Range&&)): Reorder constraints.
1259 2021-11-01 Jonathan Wakely <jwakely@redhat.com>
1262 * include/std/valarray (begin, end): Do not dereference an empty
1263 valarray. Add noexcept and [[nodiscard]].
1264 * testsuite/26_numerics/valarray/range_access.cc: Check empty
1265 valarray. Check iterator properties. Run as well as compiling.
1266 * testsuite/26_numerics/valarray/range_access2.cc: Likewise.
1267 * testsuite/26_numerics/valarray/103022.cc: New test.
1269 2021-10-29 Jonathan Wakely <jwakely@redhat.com>
1271 * testsuite/23_containers/stack/deduction.cc: Fix typo.
1273 2021-10-26 Martin Sebor <msebor@redhat.com>
1275 * testsuite/21_strings/basic_string/capacity/1.cc: Also suppress
1276 -Wstringop-overread.
1277 * testsuite/27_io/filesystem/path/factory/u8path-char8_t.cc: Same.
1279 2021-10-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1281 * testsuite/28_regex/basic_regex/84110.cc (test01)
1282 [__cpp_exceptions]: Disambiguate extended.
1284 2021-10-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1286 * testsuite/17_intro/names.cc [__sun__] (r, x): Undef.
1288 2021-10-22 Jonathan Wakely <jwakely@redhat.com>
1291 * include/std/any (make_any): Add SFINAE constraint.
1292 * testsuite/20_util/any/102894.cc: New test.
1294 2021-10-21 Jonathan Wakely <jwakely@redhat.com>
1296 * doc/doxygen/stdheader.cc: Refactor. Use C++23. Add new
1298 * scripts/run_doxygen: Fix post-processing of #include
1299 directives in man pages. Use new xg++ to compile helper program.
1301 2021-10-21 Jonathan Wakely <jwakely@redhat.com>
1303 * include/bits/mofunc_impl.h: Add doxygen comments.
1304 * include/std/functional: Likewise.
1306 2021-10-21 Jonathan Wakely <jwakely@redhat.com>
1308 * include/bits/alloc_traits.h: Suppress doxygen documentation.
1309 * include/bits/allocated_ptr.h: Likewise.
1310 * include/bits/enable_special_members.h: Likewise.
1311 * include/bits/hashtable.h: Likewise.
1312 * include/bits/hashtable_policy.h: Likewise.
1313 * include/bits/uses_allocator.h: Likewise.
1314 * include/bits/node_handle.h: Document node handles and suppress
1315 documentation for protected members.
1316 * include/std/any: Suppress documentation for implementation
1319 2021-10-21 Patrick Palka <ppalka@redhat.com>
1322 * include/bits/stl_iterator.h (__niter_base): Make constexpr
1324 (__miter_base): Likewise.
1325 * testsuite/25_algorithms/move/constexpr.cc: New test.
1327 2021-10-21 Patrick Palka <ppalka@redhat.com>
1329 * include/std/ranges (istream_view): Replace this function
1330 template with an alias template as per P2432R1.
1331 (wistream_view): Define as per P2432R1.
1332 (views::_Istream, views::istream): Likewise.
1333 * testsuite/std/ranges/istream_view.cc (test07): New test.
1335 2021-10-21 Patrick Palka <ppalka@redhat.com>
1337 * include/bits/ranges_util.h (views::_Drop): Forward declare.
1338 (subrange): Befriend views::_Drop.
1339 (subrange::_S_store_size): Declare constexpr instead of just
1340 const, remove obsolete comment.
1341 * include/std/ranges (views::__detail::__is_empty_view): Define.
1342 (views::__detail::__is_basic_string_view): Likewise.
1343 (views::__detail::__is_subrange): Likewise.
1344 (views::__detail::__is_iota_view): Likewise.
1345 (views::__detail::__can_take_view): Rename template parm _Tp to _Dp.
1346 (views::_Take): Rename template parm _Tp to _Dp, make it non-deducible
1347 and fix it to range_difference_t<_Range>. Implement P1739R4 and
1349 (views::__detail::__can_drop_view): Rename template parm _Tp to _Dp.
1350 (views::_Drop): As with views::_Take.
1351 (views::_Counted): Implement P1739R4 changes.
1352 * include/std/span (__detail::__is_std_span): Rename to ...
1353 (__detail::__is_span): ... this and turn it into a variable
1355 (__detail::__is_std_array): Turn it into a variable template.
1356 (span::span): Adjust uses of __is_std_span and __is_std_array
1358 * testsuite/std/ranges/adaptors/p1739.cc: New test.
1360 2021-10-21 Patrick Palka <ppalka@redhat.com>
1362 * include/bits/stl_iterator.h (common_iterator::__arrow_proxy):
1363 Make fully constexpr as per LWG 3595.
1364 (common_iterator::__postfix_proxy): Likewise.
1366 2021-10-21 Patrick Palka <ppalka@redhat.com>
1368 * include/std/ranges (lazy_split_view::base): Add forward_range
1369 constraint as per LWG 3591.
1370 (lazy_split_view::begin, lazy_split_view::end): Also check
1371 simpleness of _Pattern as per LWG 3592.
1372 (split_view::base): Relax copyable constraint as per LWG 3590.
1374 2021-10-21 Patrick Palka <ppalka@redhat.com>
1376 * include/std/ranges (join_view::__iter_cat::_S_iter_cat): Adjust
1377 criteria for returning bidirectional_iterator_tag as per LWG 3535.
1378 (join_view::_Iterator::_S_iter_concept): Likewise.
1380 2021-10-21 Patrick Palka <ppalka@redhat.com>
1382 * include/bits/ranges_base.h (viewable_range): Adjust as per
1384 * testsuite/std/ranges/adaptors/all.cc (test07): New test.
1386 2021-10-21 Jonathan Wakely <jwakely@redhat.com>
1389 * include/std/optional (optional::and_then, optional::transform):
1390 Remove requires-clause.
1391 * testsuite/20_util/optional/monadic/and_then.cc: Check
1392 overload resolution doesn't cause errors.
1393 * testsuite/20_util/optional/monadic/transform.cc: Likewise.
1395 2021-10-20 Jonathan Wakely <jwakely@redhat.com>
1397 * testsuite/20_util/optional/monadic/transform.cc: Check that
1398 an rvalue result is not materialized too soon.
1400 2021-10-19 Patrick Palka <ppalka@redhat.com>
1402 * include/std/ranges (iota_view::_Iterator::operator+): Adjust
1403 definition as per LWG 3580.
1404 (iota_view::_Iterator::operator-): Likewise.
1406 2021-10-19 Patrick Palka <ppalka@redhat.com>
1408 * include/std/ranges (basic_istream_view::_M_object): Value
1409 initialize as per LWG 3568.
1411 2021-10-19 Patrick Palka <ppalka@redhat.com>
1413 * include/bits/ranges_util.h
1414 (__detail::__uses_nonqualification_pointer_conversion): Define
1416 (__detail::__convertible_to_nonslicing): ... here, as per LWG 3470.
1417 * testsuite/std/ranges/subrange/1.cc: New test.
1419 2021-10-19 Patrick Palka <ppalka@redhat.com>
1421 * include/std/ranges (iota_view::_Iterator): Befriend iota_view.
1422 (iota_view::_Sentinel): Likewise.
1423 (iota_view::iota_view): Add three overloads, each taking an
1424 iterator/sentinel pair as per LWG 3523.
1425 * testsuite/std/ranges/iota/iota_view.cc (test06): New test.
1427 2021-10-19 Patrick Palka <ppalka@redhat.com>
1429 * include/bits/ranges_base.h (view_interface): Forward declare.
1430 (__detail::__is_derived_from_view_interface_fn): Declare.
1431 (__detail::__is_derived_from_view_interface): Define as per LWG 3549.
1432 (enable_view): Adjust as per LWG 3549.
1433 * include/bits/ranges_util.h (view_interface): Don't derive from
1435 * include/std/ranges (filter_view): Revert r11-3504 change.
1436 (transform_view): Likewise.
1437 (take_view): Likewise.
1438 (take_while_view): Likewise.
1439 (drop_view): Likewise.
1440 (drop_while_view): Likewise.
1441 (join_view): Likewise.
1442 (lazy_split_view): Likewise.
1443 (split_view): Likewise.
1444 (reverse_view): Likewise.
1445 * testsuite/std/ranges/adaptors/sizeof.cc: Update expected sizes.
1446 * testsuite/std/ranges/view.cc (test_view::test_view): Remove
1447 this default ctor since views no longer need to be default initable.
1450 2021-10-19 Jonathan Wakely <jwakely@redhat.com>
1452 * src/c++11/random.cc (which_source): New helper function.
1453 (random_device::_M_getentropy()): Use which_source and return
1454 suitable values for sources other than device files.
1455 * testsuite/26_numerics/random/random_device/entropy.cc: New test.
1457 2021-10-19 Jonathan Wakely <jwakely@redhat.com>
1459 * doc/Makefile.am (stamp-html-doxygen, stamp-html-doxygen)
1460 (stamp-latex-doxygen, stamp-man-doxygen): Fix recipes for
1461 relative ${top_srcdir}.
1462 * doc/Makefile.in: Regenerate.
1464 2021-10-19 Jonathan Wakely <jwakely@redhat.com>
1466 * include/std/variant (_Uninitialized): Use an empty struct
1467 for the unused union member, instead of char.
1469 2021-10-19 Jonathan Wakely <jwakely@redhat.com>
1471 * include/bits/stl_stack.h (stack(Iterator, Iterator)): Remove
1472 non-deducible template parameter from deduction guide.
1473 * testsuite/23_containers/stack/deduction.cc: Check new C++23
1476 2021-10-19 Jonathan Wakely <jwakely@redhat.com>
1478 * include/std/optional (_Optional_payload_base::_Storage): Add
1479 constructor taking a callable function to invoke.
1480 (_Optional_payload_base::_M_apply): New function.
1481 (__cpp_lib_monadic_optional): Define for C++23.
1482 (optional::and_then, optional::transform, optional::or_else):
1484 * include/std/ranges (__detail::__cached): Remove.
1485 (__detail::__non_propagating_cache): Remove use of __cached for
1486 contained value. Use _Optional_payload_base::_M_construct and
1487 _Optional_payload_base::_M_apply to set the contained value.
1488 * include/std/version (__cpp_lib_monadic_optional): Define.
1489 * testsuite/20_util/optional/monadic/and_then.cc: New test.
1490 * testsuite/20_util/optional/monadic/or_else.cc: New test.
1491 * testsuite/20_util/optional/monadic/or_else_neg.cc: New test.
1492 * testsuite/20_util/optional/monadic/transform.cc: New test.
1493 * testsuite/20_util/optional/monadic/version.cc: New test.
1495 2021-10-19 Jonathan Wakely <jwakely@redhat.com>
1498 * include/bits/mofunc_impl.h (move_only_function): Remove
1499 invalid base initializer.
1500 * testsuite/20_util/move_only_function/cons.cc: Instantiate
1501 constructors to check bodies.
1503 2021-10-15 Jonathan Wakely <jwakely@redhat.com>
1505 * include/bits/fs_path.h (path::_S_convert(T)): Avoid recursive
1506 call to function with deduced return type.
1508 2021-10-15 Jonathan Wakely <jwakely@redhat.com>
1510 * include/bits/basic_string.h (__cpp_lib_string_resize_and_overwrite):
1512 (basic_string::resize_and_overwrite): Declare.
1513 * include/bits/basic_string.tcc (basic_string::resize_and_overwrite):
1515 * include/std/version (__cpp_lib_resize_and_overwrite): Define
1517 * testsuite/21_strings/basic_string/capacity/char/resize_and_overwrite.cc:
1520 2021-10-15 Jonathan Wakely <jwakely@redhat.com>
1523 * include/std/ranges (__cached): New wrapper struct.
1524 (__non_propagating_cache): Use __cached for contained value.
1525 (__non_propagating_cache::_M_emplace_deref): Add constexpr. Use
1526 std::construct_at instead of placement new.
1527 * testsuite/std/ranges/adaptors/join.cc: Check constexpr works.
1529 2021-10-15 Jonathan Wakely <jwakely@redhat.com>
1531 * include/std/variant (__cpp_lib_variant): Update value for
1533 (__variant_cast, __variant_construct): Add constexpr for C++20.
1534 (__variant_construct_single, __construct_by_index) Likewise. Use
1535 std::_Construct instead of placement new.
1536 (_Uninitialized<T, false>) [__cplusplus >= 202002]: Replace
1537 buffer with a union and define a destructor.
1538 (_Variadic_union) [__cplusplus >= 202002]: Add a specialization
1539 for non-trivial destruction.
1540 (_Variant_storage::__index_of): New helper variable template.
1541 (_Variant_storage::~_Variant_storage()): Add constexpr.
1542 (_Variant_storage::_M_reset()): Likewise.
1543 (_Copy_ctor_base, _Move_ctor_base): Likewise.
1544 (_Copy_assign_base, _Move_assign_base): Likewise.
1545 (variant, swap): Likewise.
1546 * include/std/version (__cpp_lib_variant): Update value for
1548 * testsuite/20_util/optional/version.cc: Check for exact value
1550 * testsuite/20_util/variant/87619.cc: Increase timeout for
1552 * testsuite/20_util/variant/constexpr.cc: New test.
1553 * testsuite/20_util/variant/version.cc: New test.
1555 2021-10-15 Jonathan Wakely <jwakely@redhat.com>
1557 * include/std/variant (__detail::__variant::__get_storage):
1558 Remove unused function.
1559 (__variant_construct_by_index): Set index after construction is
1560 complete. Rename to ...
1561 (__detail::__variant::__construct_by_index): ... this.
1562 (variant): Use new name for __variant_construct_by_index friend
1563 declaration. Remove __get_storage friend declaration.
1564 (variant::emplace): Use new name and remove try-blocks.
1566 2021-10-15 Jonathan Wakely <jwakely@redhat.com>
1568 * include/std/variant (_Variant_storage::_M_storage()): Remove.
1569 (__detail::__variant::__get_storage): Remove.
1570 (variant): Remove friend declaration of __get_storage.
1572 2021-10-15 Jason Merrill <jason@redhat.com>
1574 * testsuite/20_util/integer_comparisons/greater_equal_neg.cc:
1575 * testsuite/20_util/integer_comparisons/greater_neg.cc:
1576 * testsuite/20_util/integer_comparisons/less_equal_neg.cc:
1577 Adjust expected message.
1578 * testsuite/lib/prune.exp: Prune 'in constexpr expansion'.
1580 2021-10-14 Jonathan Wakely <jwakely@redhat.com>
1582 * include/std/variant (__variant::__get(in_place_index_t<N>, U&&)):
1583 Rename to __get_n and remove first argument. Replace pair of
1584 overloads with a single function using 'if constexpr'.
1585 (__variant::__get(Variant&&)): Adjust to use __get_n.
1587 2021-10-14 Jonathan Wakely <jwakely@redhat.com>
1589 * include/bits/fs_path.h (path(path&&)): Make unconditionally
1591 (path::_S_convert(T)): Add condtional noexcept.
1593 2021-10-14 Jonathan Wakely <jwakely@redhat.com>
1596 * include/bits/fs_path.h (path::_S_convert(T)): Fix condition
1597 for returning the same string unchanged.
1599 2021-10-14 Jonathan Wakely <jwakely@redhat.com>
1601 * include/bits/regex.h: Check __cpp_inline_variables instead of
1604 2021-10-14 Jonathan Wakely <jwakely@redhat.com>
1606 * testsuite/20_util/is_layout_compatible/version.cc: Check
1609 2021-10-14 Jonathan Wakely <jwakely@redhat.com>
1611 * include/bits/stl_construct.h (_Construct): Use
1612 std::construct_at when constant evaluated.
1613 * include/std/optional (_Storage, _Optional_payload, optional):
1614 Add constexpr as specified by P2231R1.
1615 * include/std/version (__cpp_lib_optional): Update value for
1617 * testsuite/20_util/optional/requirements.cc: Check feature test
1619 * testsuite/20_util/optional/constexpr/assign.cc: New test.
1620 * testsuite/20_util/optional/constexpr/cons/conv.cc: New test.
1621 * testsuite/20_util/optional/constexpr/modifiers.cc: New test.
1622 * testsuite/20_util/optional/constexpr/swap.cc: New test.
1623 * testsuite/20_util/optional/version.cc: New test.
1625 2021-10-13 Jonathan Wakely <jwakely@redhat.com>
1627 * include/bits/fs_path.h (__detail::__is_contiguous): Add
1628 partial specializations for pointers and __normal_iterator.
1630 2021-10-13 Jonathan Wakely <jwakely@redhat.com>
1632 * testsuite/27_io/filesystem/path/construct/102592.C: Moved to...
1633 * testsuite/27_io/filesystem/path/construct/102592.cc: ...here.
1634 * testsuite/28_regex/match_results/102667.C: Moved to...
1635 * testsuite/28_regex/match_results/102667.cc: ...here.
1637 2021-10-13 Jonathan Wakely <jwakely@redhat.com>
1639 * include/bits/fs_path.h (__detail::__is_contiguous): New
1640 variable template to identify contiguous iterators.
1641 (__detail::__unified_char8_t): New alias template to decide when
1642 to treat char8_t as char without encoding conversion.
1643 (__detail::__effective_range(const basic_string<C,T>&)): Use
1644 std::char_traits<C> for returned string view.
1645 (__detail::__effective_range(const basic_string_view<C,T>&)):
1647 (__detail::__effective_range(const Source&)): Use
1648 __is_contiguous to detect mode cases of contiguous iterators.
1649 Use __unified_char8_t to return a std::string instead of
1652 2021-10-13 Jonathan Wakely <jwakely@redhat.com>
1655 * include/bits/fs_path.h (path::path(Iter, Iter, format))
1656 (path::append(Iter, Iter), path::concat(Iter, Iter)): Call
1657 __string_from_range directly, instead of two-argument overload
1659 (path::_S_convert(Iter, Iter)): Remove.
1660 * testsuite/27_io/filesystem/path/construct/102592.C: New test.
1662 2021-10-13 Jonathan Wakely <jwakely@redhat.com>
1664 * include/bits/c++config (__terminate): Add extern "C++".
1666 2021-10-12 Jonathan Wakely <jwakely@redhat.com>
1668 * testsuite/20_util/tuple/comparison_operators/overloaded.cc:
1669 Restore test for operator<.
1670 * testsuite/20_util/tuple/comparison_operators/overloaded2.cc:
1671 Adjust expected errors for C++20.
1673 2021-10-12 Jonathan Wakely <jwakely@redhat.com>
1676 * include/std/tuple (_Tuple_impl(_Tuple_impl&&)): Define as
1678 * testsuite/20_util/tuple/cons/101960.cc: Check tuples with
1679 array elements before the last element.
1681 2021-10-12 Jonathan Wakely <jwakely@redhat.com>
1683 * include/bits/stl_iterator_base_funcs.h (__advance): Add
1684 deleted overload to improve diagnostics.
1685 (__distance): Likewise.
1687 2021-10-11 Jonathan Wakely <jwakely@redhat.com>
1689 * include/bits/atomic_timed_wait.h: Remove unused header.
1690 * include/bits/c++config (std:__terminate): Define.
1691 * include/bits/semaphore_base.h: Remove <exception> and use
1692 __terminate instead of terminate.
1693 * include/bits/std_thread.h: Likewise.
1694 * libsupc++/eh_terminate.cc (std::terminate): Use qualified-id
1695 to call __cxxabiv1::__terminate.
1697 2021-10-11 Jonathan Wakely <jwakely@redhat.com>
1699 * include/bits/regex.h (basic_regex::assign(Iter, Iter)): Avoid
1700 std::__to_address by using poitner directly or using base()
1701 member of __normal_iterator.
1703 2021-10-11 Jonathan Wakely <jwakely@redhat.com>
1705 * testsuite/18_support/numeric_limits/lowest.cc: Use
1706 numeric_limits<T>::is_integer instead of is_integral<T>::value.
1708 2021-10-11 Jonathan Wakely <jwakely@redhat.com>
1711 * include/bits/regex.h (basic_regex(const _Ch_type*, size_t)):
1712 Add __glibcxx_requires_string_len assertion.
1713 (basic_regex::assign(InputIterator, InputIterator)): Add
1714 __glibcxx_requires_valid_range assertion.
1715 * include/bits/regex_scanner.tcc (_Scanner::_M_advance())
1716 (_Scanner::_M_scan_normal()): Use string literal in assertions.
1718 2021-10-11 Jonathan Wakely <jwakely@redhat.com>
1721 * include/bits/regex.h (match_result::empty()): Optimize by
1722 calling the base function directly.
1723 (match_results::end()): Check _Base_type::empty() not empty().
1724 * testsuite/28_regex/match_results/102667.C: New test.
1726 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1729 * testsuite/18_support/numeric_limits/lowest.cc: Remove use of
1730 _GLIBCXX_USE_WCHAR_T.
1731 * testsuite/18_support/numeric_limits/min_max.cc: Replace use of
1732 _GLIBCXX_USE_WCHAR_T with checks for WCHAR_MIN and WCHAR_MAX.
1733 * testsuite/20_util/from_chars/1_neg.cc: Remove use of
1734 _GLIBCXX_USE_WCHAR_T.
1735 * testsuite/20_util/function_objects/searchers.cc: Likewise. Use
1736 char_traits<wchar_t>::length instead of wcslen.
1737 * testsuite/20_util/hash/requirements/explicit_instantiation.cc:
1739 * testsuite/20_util/is_arithmetic/value.cc: Likewise.
1740 * testsuite/20_util/is_compound/value.cc: Likewise.
1741 * testsuite/20_util/is_floating_point/value.cc: Likewise.
1742 * testsuite/20_util/is_fundamental/value.cc: Likewise.
1743 * testsuite/20_util/is_integral/value.cc: Likewise.
1744 * testsuite/20_util/is_signed/value.cc: Likewise.
1745 * testsuite/20_util/is_unsigned/value.cc: Likewise.
1746 * testsuite/20_util/is_void/value.cc: Likewise.
1747 * testsuite/20_util/make_signed/requirements/typedefs-1.cc:
1749 * testsuite/20_util/make_signed/requirements/typedefs-2.cc:
1751 * testsuite/20_util/make_signed/requirements/typedefs-3.cc:
1753 * testsuite/20_util/make_signed/requirements/typedefs-4.cc:
1755 * testsuite/20_util/make_unsigned/requirements/typedefs-1.cc:
1757 * testsuite/20_util/make_unsigned/requirements/typedefs-2.cc:
1759 * testsuite/20_util/make_unsigned/requirements/typedefs-3.cc:
1761 * testsuite/20_util/to_chars/3.cc: Likewise.
1762 * testsuite/20_util/type_identity/requirements/typedefs.cc:
1764 * testsuite/21_strings/basic_string/hash/debug.cc: Likewise.
1765 * testsuite/21_strings/basic_string/hash/hash.cc: Likewise.
1766 * testsuite/21_strings/basic_string/literals/types-char8_t.cc:
1768 * testsuite/21_strings/basic_string/literals/types.cc: Likewise.
1769 * testsuite/21_strings/basic_string/literals/values-char8_t.cc:
1771 * testsuite/21_strings/basic_string/literals/values.cc:
1773 * testsuite/21_strings/basic_string/modifiers/64422.cc:
1775 * testsuite/21_strings/basic_string/range_access/wchar_t/1.cc:
1777 * testsuite/21_strings/basic_string/requirements/citerators.cc:
1779 * testsuite/21_strings/basic_string/requirements/typedefs.cc:
1781 * testsuite/21_strings/basic_string/types/pmr_typedefs.cc:
1783 * testsuite/21_strings/basic_string_view/literals/types-char8_t.cc:
1785 * testsuite/21_strings/basic_string_view/literals/types.cc:
1787 * testsuite/21_strings/basic_string_view/literals/values-char8_t.cc:
1789 * testsuite/21_strings/basic_string_view/literals/values.cc:
1791 * testsuite/21_strings/basic_string_view/requirements/typedefs.cc:
1793 * testsuite/21_strings/basic_string_view/typedefs.cc: Likewise.
1794 * testsuite/21_strings/char_traits/requirements/constexpr_functions.cc:
1796 * testsuite/21_strings/char_traits/requirements/constexpr_functions_c++17.cc:
1798 * testsuite/21_strings/char_traits/requirements/constexpr_functions_c++20.cc:
1800 * testsuite/22_locale/ctype/is/string/89728_neg.cc: Likewise.
1801 * testsuite/25_algorithms/fill/4.cc: Likewise.
1802 * testsuite/25_algorithms/fill_n/1.cc: Likewise.
1803 * testsuite/experimental/functional/searchers.cc: Likewise. Use
1804 char_traits<wchar_t>::length instead of wcslen.
1805 * testsuite/experimental/polymorphic_allocator/pmr_typedefs_string.cc:
1807 * testsuite/experimental/string_view/literals/types-char8_t.cc:
1809 * testsuite/experimental/string_view/literals/types.cc:
1811 * testsuite/experimental/string_view/literals/values-char8_t.cc:
1813 * testsuite/experimental/string_view/literals/values.cc:
1815 * testsuite/experimental/string_view/range_access/wchar_t/1.cc:
1817 * testsuite/experimental/string_view/requirements/typedefs.cc:
1819 * testsuite/experimental/string_view/typedefs.cc: Likewise.
1820 * testsuite/ext/vstring/range_access.cc: Likewise.
1821 * testsuite/std/concepts/concepts.lang/concept.arithmetic/integral.cc:
1823 * testsuite/std/concepts/concepts.lang/concept.arithmetic/signed_integral.cc:
1825 * testsuite/std/concepts/concepts.lang/concept.arithmetic/unsigned_integral.cc:
1827 * testsuite/tr1/4_metaprogramming/is_arithmetic/value.cc:
1829 * testsuite/tr1/4_metaprogramming/is_compound/value.cc:
1831 * testsuite/tr1/4_metaprogramming/is_floating_point/value.cc:
1833 * testsuite/tr1/4_metaprogramming/is_fundamental/value.cc:
1835 * testsuite/tr1/4_metaprogramming/is_integral/value.cc:
1837 * testsuite/tr1/4_metaprogramming/is_signed/value.cc: Likewise.
1838 * testsuite/tr1/4_metaprogramming/is_unsigned/value.cc:
1840 * testsuite/tr1/4_metaprogramming/is_void/value.cc: Likewise.
1841 * testsuite/tr1/6_containers/hash/24799.cc: Likewise.
1843 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1846 * include/std/ostream (operator<<(basic_ostream<char, Tr>&, wchar_t))
1847 (operator<<(basic_ostream<char, Tr>&, const wchar_t*)): Always
1848 define as deleted. Do not check _GLIBCXX_USE_WCHAR_T.
1850 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1853 * include/bits/locale_conv.h (wstring_convert, wbuffer_convert):
1854 Define unconditionally. Do not check _GLIBCXX_USE_WCHAR_T.
1856 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1859 * include/c_global/cstddef [!_GLIBCXX_USE_WCHAR_T]
1860 (__byte_operand<wchar_t>): Define specialization.
1861 * include/std/type_traits (__make_signed<wchar_t>)
1862 (__make_unsigned<wchar_t>): Remove redundant check for
1863 __WCHAR_TYPE__ being defined.
1864 * include/tr1/type_traits [!_GLIBCXX_USE_WCHAR_T]
1865 (__is_integral_helper<wchar_t>): Likewise.
1867 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1870 * include/ext/rc_string_base.h [!_GLIBCXX_USE_WCHAR_T]
1871 (__rc_string_base<wchar_t>): Define member function.
1872 * include/ext/vstring.h [!_GLIBCXX_USE_WCHAR_T]
1873 (hash<__gnu_cxx::__wvstring>): Define specialization.
1874 * include/ext/vstring_fwd.h [!_GLIBCXX_USE_WCHAR_T] (__wvstring)
1875 (__wsso_string, __wrc_string): Declare typedefs.
1877 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1880 * include/bits/char_traits.h (char_traits<wchar_t>): Define
1881 explicit specialization unconditionally.
1882 * include/bits/basic_string.h (hash<wstring>): Define
1883 unconditionally. Do not check _GLIBCXX_USE_WCHAR_T.
1884 * include/bits/stringfwd.h (wstring): Likewise.
1885 * include/debug/string (wstring): Likewise.
1886 * include/experimental/string_view (experimental::wstring_view)
1887 (hash<experimental::wstring_view>): Likewise.
1888 * include/std/string (pmr::wstring, hash<pmr::wstring>):
1890 * include/std/string_view (wstring_view, hash<wstring_view>):
1893 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1895 * testsuite/27_io/basic_filebuf/close/81256.cc: Moved to...
1896 * testsuite/27_io/basic_filebuf/close/wchar_t/81256.cc: ...here.
1898 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1900 * testsuite/22_locale/conversions/buffer/1.cc: Check
1901 _GLIBCXX_USE_WCHAR_T.
1902 * testsuite/22_locale/conversions/buffer/3.cc: Likewise. Add
1903 test using char16_t.
1904 * testsuite/22_locale/conversions/string/1.cc: Check
1905 _GLIBCXX_USE_WCHAR_T.
1906 * testsuite/27_io/filesystem/path/generic/generic_string.cc:
1908 * testsuite/27_io/filesystem/path/modifiers/make_preferred.cc:
1910 * testsuite/27_io/filesystem/path/native/alloc.cc: Likewise.
1911 * testsuite/27_io/filesystem/path/native/string-char8_t.cc:
1913 * testsuite/27_io/filesystem/path/native/string.cc: Likewise.
1914 * testsuite/28_regex/algorithms/regex_match/extended/wstring_locale.cc:
1916 * testsuite/experimental/filesystem/path/generic/generic_string.cc:
1918 * testsuite/experimental/filesystem/path/native/alloc.cc:
1920 * testsuite/experimental/filesystem/path/native/string-char8_t.cc:
1922 * testsuite/experimental/filesystem/path/native/string.cc:
1925 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1927 * testsuite/26_numerics/bit/bit.rotate/rotr.cc:
1928 * testsuite/util/testsuite_common_types.h:
1930 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1932 * testsuite/18_support/numeric_limits/40856.cc: Replace use of
1933 _GLIBCXX_USE_INT128.
1934 * testsuite/18_support/numeric_limits/dr559.cc: Likewise.
1935 * testsuite/18_support/numeric_limits/lowest.cc: Likewise.
1936 * testsuite/18_support/numeric_limits/max_digits10.cc: Likewise.
1937 * testsuite/20_util/is_floating_point/value.cc: Likewise.
1938 * testsuite/20_util/is_integral/value.cc: Likewise.
1939 * testsuite/20_util/is_signed/value.cc: Likewise.
1940 * testsuite/20_util/is_unsigned/value.cc: Likewise.
1941 * testsuite/20_util/make_signed/requirements/typedefs-1.cc:
1943 * testsuite/20_util/make_signed/requirements/typedefs-2.cc:
1945 * testsuite/20_util/make_unsigned/requirements/typedefs-1.cc:
1947 * testsuite/20_util/make_unsigned/requirements/typedefs-2.cc:
1949 * testsuite/20_util/type_identity/requirements/typedefs.cc:
1951 * testsuite/26_numerics/bit/bit.count/countl_one.cc: Likewise.
1952 * testsuite/26_numerics/bit/bit.count/countl_zero.cc: Likewise.
1953 * testsuite/26_numerics/bit/bit.count/countr_one.cc: Likewise.
1954 * testsuite/26_numerics/bit/bit.count/countr_zero.cc: Likewise.
1955 * testsuite/26_numerics/bit/bit.count/popcount.cc: Likewise.
1956 * testsuite/26_numerics/bit/bit.pow.two/bit_ceil.cc: Likewise.
1957 * testsuite/26_numerics/bit/bit.pow.two/bit_floor.cc: Likewise.
1958 * testsuite/26_numerics/bit/bit.pow.two/bit_width.cc: Likewise.
1959 * testsuite/26_numerics/bit/bit.pow.two/has_single_bit.cc:
1961 * testsuite/26_numerics/bit/bit.rotate/rotl.cc: Likewise.
1963 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1965 * include/bits/hashtable_policy.h (_Select1st): Replace use of
1967 (_Select2nd): Remove.
1968 (_NodeBuilder::_S_build): Use _NodeGenerator::__node_type
1969 typedef instead of deducing it. Remove unnecessary piecewise
1971 (_ReuseOrAllocNode): Make __node_type public.
1972 (_Map_base): Adjust partial specialization to be able to extract
1973 the mapped_type without using tuple_element.
1974 (_Map_base::at): Define inline
1975 * testsuite/23_containers/unordered_map/requirements/53339.cc:
1977 * testsuite/23_containers/unordered_multimap/requirements/53339.cc:
1980 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1982 * include/bits/hashtable.h: Move static assertion to destructor.
1983 * include/bits/hashtable_policy.h: Deduce value type from node
1984 type without instantiating it.
1986 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1988 * src/c++11/limits.cc: Fail if __cpp_inline_variables is
1991 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1994 * include/bits/ranges_algobase.h: Replace <iterator> with a
1995 subset of the headers it includes.
1997 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
1999 * include/experimental/deque (erase, erase_if): Revert changes
2000 to avoid debug mode overhead.
2001 * include/experimental/map (erase, erase_if): Likewise.
2002 * include/experimental/set (erase, erase_if): Likewise.
2003 * include/experimental/unordered_map (erase, erase_if):
2005 * include/experimental/unordered_set (erase, erase_if):
2007 * include/experimental/vector (erase, erase_if): Likewise.
2008 * include/std/deque (erase, erase_if): Likewise.
2009 * include/std/map (erase, erase_if): Likewise.
2010 * include/std/set (erase, erase_if): Likewise.
2011 * include/std/unordered_map (erase, erase_if): Likewise.
2012 * include/std/unordered_set (erase, erase_if): Likewise.
2013 * include/std/vector (erase, erase_if): Likewise.
2015 2021-10-08 Jonathan Wakely <jwakely@redhat.com>
2017 * include/std/chrono (__detail::__units_suffix_misc): New
2019 (__detail::__units_suffix): Likewise.
2020 (chrono::operator<<(basic_ostream&, const duration&)): Define.
2021 * testsuite/20_util/duration/io.cc: New test.
2023 2021-10-07 Jonathan Wakely <jwakely@redhat.com>
2025 * include/Makefile.am: Add new header.
2026 * include/Makefile.in: Regenerate.
2027 * include/std/chrono (duration, time_point, system_clock)
2028 (steady_clock, high_resolution_clock, chrono_literals, sys_time)
2029 (file_clock, file_time): Move to ...
2030 * include/bits/chrono.h: New file.
2031 * include/bits/atomic_futex.h: Include new header instead of
2033 * include/bits/atomic_timed_wait.h: Likewise.
2034 * include/bits/fs_fwd.h: Likewise.
2035 * include/bits/semaphore_base.h: Likewise.
2036 * include/bits/this_thread_sleep.h: Likewise.
2037 * include/bits/unique_lock.h: Likewise.
2038 * include/experimental/bits/fs_fwd.h: Likewise.
2039 * include/experimental/chrono: Likewise.
2040 * include/experimental/io_context: Likewise.
2041 * include/experimental/netfwd: Likewise.
2042 * include/experimental/timer: Likewise.
2043 * include/std/condition_variable: Likewise.
2044 * include/std/mutex: Likewise.
2045 * include/std/shared_mutex: Likewise.
2047 2021-10-07 Jonathan Wakely <jwakely@redhat.com>
2050 * include/bits/atomic_wait.h (__waiter_pool_base:_S_align):
2051 Hardcode to 64 instead of using non-constant constant.
2053 2021-10-07 Jonathan Wakely <jwakely@redhat.com>
2055 * include/bits/erase_if.h (__erase_nodes_if): Remove redundant
2057 * include/std/string (erase, erase_if): Likewise.
2058 * include/std/deque (erase, erase_if): Access non-debug
2060 * include/std/map (erase, erase_if): Likewise.
2061 * include/std/set (erase, erase_if): Likewise.
2062 * include/std/unordered_map (erase, erase_if): Likewise.
2063 * include/std/unordered_set (erase, erase_if): Likewise.
2064 * include/std/vector (erase, erase_if): Likewise.
2065 * include/experimental/deque (erase, erase_if): Likewise.
2066 * include/experimental/map (erase, erase_if): Likewise.
2067 * include/experimental/set (erase, erase_if): Likewise.
2068 * include/experimental/unordered_map (erase, erase_if):
2070 * include/experimental/unordered_set (erase, erase_if):
2072 * include/experimental/vector (erase, erase_if): Likewise.
2074 2021-10-06 Jonathan Wakely <jwakely@redhat.com>
2076 * include/Makefile.am: Add new headers.
2077 * include/Makefile.in: Regenerate.
2078 * include/std/functional: Include <bits/move_only_function.h>.
2079 * include/std/version (__cpp_lib_move_only_function): Define.
2080 * include/bits/mofunc_impl.h: New file.
2081 * include/bits/move_only_function.h: New file.
2082 * testsuite/20_util/move_only_function/call.cc: New test.
2083 * testsuite/20_util/move_only_function/cons.cc: New test.
2084 * testsuite/20_util/move_only_function/move.cc: New test.
2085 * testsuite/20_util/move_only_function/version.cc: New test.
2087 2021-10-05 Jonathan Wakely <jwakely@redhat.com>
2089 * testsuite/21_strings/basic_string_view/requirements/trivially_copyable.cc:
2091 * testsuite/23_containers/span/trivially_copyable.cc: New test.
2093 2021-10-05 Jonathan Wakely <jwakely@redhat.com>
2095 * include/bits/utility.h (__is_in_place_type_v): Define
2096 variable template to detect in_place_type_t specializations.
2097 (__is_in_place_type): Replace class template with alias
2098 template using __is_in_place_type_v.
2099 * include/std/any (any(T&&)): Check __is_in_place_type first and
2100 avoid instantiating is_copy_constructible unnecessarily.
2102 2021-10-05 Jonathan Wakely <jwakely@redhat.com>
2104 * testsuite/20_util/integer_comparisons/greater.cc: New test.
2106 2021-10-05 Jonathan Wakely <jwakely@redhat.com>
2108 * testsuite/27_io/basic_ostream/inserters_other/char/volatile_ptr.cc:
2109 Check result matches non-volatile pointer.
2111 2021-10-05 Jonathan Wakely <jwakely@redhat.com>
2114 * testsuite/20_util/is_trivially_constructible/value.cc: Adjust
2115 expected value for C++20.
2117 2021-10-05 Jonathan Wakely <jwakely@redhat.com>
2119 * include/bits/std_function.h (_Any_data::_M_access): Add
2121 (_Function_base::_Base_manager::_M_get_pointer): Likewise.
2122 (_Function_base::_Base_manager::_M_not_empty_function):
2125 2021-10-05 Jonathan Wakely <jwakely@redhat.com>
2127 * include/std/ostream (operator<<(const volatile void*)):
2128 Add new overload, as per P1147R1.
2129 * testsuite/27_io/basic_ostream/inserters_other/char/volatile_ptr.cc:
2132 2021-10-05 Jonathan Wakely <jwakely@redhat.com>
2134 * include/bits/stl_queue.h
2135 (__cpp_lib_adaptor_iterator_pair_constructor): Set to correct
2137 * include/bits/stl_stack.h
2138 (__cpp_lib_adaptor_iterator_pair_constructor): Likewise.
2139 * include/std/version
2140 (__cpp_lib_adaptor_iterator_pair_constructor): Likewise.
2141 * testsuite/23_containers/queue/cons_from_iters.cc: Update
2143 * testsuite/23_containers/stack/cons_from_iters.cc: Likewise.
2145 2021-10-04 Jonathan Wakely <jwakely@redhat.com>
2147 * include/bits/forward_list.h (forward_list): Use non-deduced
2148 context for allocator parameter of allocator-extended copy and
2150 * include/bits/stl_bvector.h (vector<bool>): Likewise.
2151 * include/bits/stl_deque.h (deque): Likewise.
2152 * include/bits/stl_list.h (list): Likewise.
2153 * include/bits/stl_map.h (map): Likewise.
2154 * include/bits/stl_multimap.h (multimap): Likewise.
2155 * include/bits/stl_multiset.h (multiset): Likewise.
2156 * include/bits/stl_set.h (set): Likewise.
2157 * include/bits/stl_vector.h (vector): Likewise.
2158 * include/bits/stl_queue.h (queue, priority_queue): Do not
2159 constrain Allocator template parameter of deduction guides that
2160 have a Container parameter.
2161 * include/bits/stl_stack.h (stack): Likewise.
2162 * include/debug/deque (__gnu_debug::deque): Use non-deduced
2163 context for allocator parameter of allocator-extended copy and
2165 * include/debug/list (__gnu_debug::list): Likewise.
2166 * include/debug/map.h (__gnu_debug::map): Likewise.
2167 * include/debug/multimap.h (__gnu_debug::multimap): Likewise.
2168 * include/debug/multiset.h (__gnu_debug::multiset): Likewise.
2169 * include/debug/set.h (__gnu_debug::set): Likewise.
2170 * include/debug/vector (__gnu_debug::vector): Likewise.
2171 * testsuite/23_containers/deque/cons/deduction.cc: Test class
2172 template argument deduction with non-deduced allocator
2174 * testsuite/23_containers/forward_list/cons/deduction.cc:
2176 * testsuite/23_containers/list/cons/deduction.cc: Likewise.
2177 * testsuite/23_containers/map/cons/deduction.cc: Likewise.
2178 * testsuite/23_containers/multimap/cons/deduction.cc: Likewise.
2179 * testsuite/23_containers/multiset/cons/deduction.cc: Likewise.
2180 * testsuite/23_containers/priority_queue/deduction.cc: Likewise.
2181 * testsuite/23_containers/queue/deduction.cc: Likewise.
2182 * testsuite/23_containers/set/cons/deduction.cc: Likewise.
2183 * testsuite/23_containers/stack/deduction.cc: Likewise.
2184 * testsuite/23_containers/unordered_map/cons/deduction.cc:
2186 * testsuite/23_containers/unordered_multimap/cons/deduction.cc:
2188 * testsuite/23_containers/unordered_multiset/cons/deduction.cc:
2190 * testsuite/23_containers/unordered_set/cons/deduction.cc:
2192 * testsuite/23_containers/vector/cons/deduction.cc: Likewise.
2194 2021-10-04 Jonathan Wakely <jwakely@redhat.com>
2196 * include/std/variant (__detail::__variant::__as): Add missing
2197 noexcept to first overload.
2199 2021-10-04 Jonathan Wakely <jwakely@redhat.com>
2201 * include/bits/basic_string.h (basic_string(nullptr_t)): Define
2203 (operator=(nullptr_t)): Likewise.
2204 * include/bits/cow_string.h (basic_string(nullptr_t)): Likewise.
2205 (operator=(nullptr_t)): Likewise.
2206 * include/std/string_view (basic_string_view(nullptr_t)):
2208 * testsuite/21_strings/basic_string/cons/char/nullptr.cc: New test.
2209 * testsuite/21_strings/basic_string_view/cons/char/nonnull.cc:
2210 Change dg-warning to dg-error.
2211 * testsuite/21_strings/basic_string_view/cons/wchar_t/nonnull.cc:
2214 2021-10-02 Jonathan Wakely <jwakely@redhat.com>
2216 * src/c++17/fs_ops.cc (create_directory): Fix typo in enum name.
2217 * src/filesystem/ops-common.h (__last_system_error): Add
2218 explicit cast to avoid narrowing conversion.
2219 (do_space): Fix type in function name.
2221 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2224 * include/Makefile.am (c++config.h): Define
2225 _GLIBCXX_VERBOSE_ASSERT based on configure output.
2226 * include/Makefile.in: Regenerate.
2227 * include/bits/c++config: Fix condition for verbose assertions.
2229 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2232 * include/bits/erase_if.h (__erase_nodes_if): Use __niter_base to
2233 unwrap debug iterators.
2234 * include/bits/refwrap.h: Do not error if included in C++03.
2235 * include/bits/stl_algo.h (__remove_if): Move to ...
2236 * include/bits/stl_algobase.h (__remove_if): ... here.
2237 * include/std/deque (erase, erase_if): Use __remove_if instead of
2238 remove and remove_if.
2239 * include/std/string (erase, erase_if): Likewise.
2240 * include/std/vector (erase, erase_if): Likewise.
2242 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2245 * include/bits/list.tcc (list::sort()): Use _Scratch_list
2246 objects for splicing and merging.
2247 (list::sort(StrictWeakOrdering)): Likewise.
2248 * include/bits/stl_list.h (__detail::_Scratch_list): New type.
2249 * src/c++98/list.cc (_List_node_base::_M_transfer): Add
2250 assertion for --enable-libstdcxx-debug library.
2251 * testsuite/23_containers/list/operations/66742.cc: New test.
2253 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2256 * include/std/thread (__pmf_expects_stop_token): New variable
2257 template to detect a pointer to member function that needs a
2258 stop_token to be added to the arguments.
2259 (jthread::__S_create): Use __pmf_expects_stop_token.
2260 (jthread::__S_create_pmf): New function.
2261 * testsuite/30_threads/jthread/100612.cc: New test.
2263 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2265 * include/bits/stl_queue.h
2266 (__cpp_lib_adaptor_iterator_pair_constructor): Define for C++23, as
2268 (queue(InputIterator, InputIterator)): Likewise.
2269 (queue(InputIterator, InputIterator, const Alloc&)): Likewise.
2270 * include/bits/stl_stack.h
2271 (__cpp_lib_adaptor_iterator_pair_constructor): Likewise.
2272 (stack(InputIterator, InputIterator)): Likewise.
2273 (stack(InputIterator, InputIterator, const Alloc&)): Likewise.
2274 * include/std/version (__cpp_lib_adaptor_iterator_pair_constructor):
2276 * testsuite/23_containers/queue/cons_from_iters.cc: New test.
2277 * testsuite/23_containers/stack/cons_from_iters.cc: New test.
2279 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2281 * include/bits/stl_queue.h (priority_queue): Add
2282 allocator-extended overloads for constructors taking iterator.
2283 * testsuite/23_containers/priority_queue/lwg3506.cc: New test.
2285 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2287 * include/bits/stl_queue.h (priority_queue): Construct sequence
2288 from iterators when no sequence argument is present (LWG 3529).
2289 * testsuite/23_containers/priority_queue/lwg3529.cc: New test.
2291 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2293 * include/bits/stl_queue.h (priority_queue): Constrain
2294 constructors with InputIterator parameters (LWG 3522).
2295 * testsuite/23_containers/priority_queue/lwg3522.cc: New test.
2297 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2299 * include/bits/ranges_base.h (ranges::distance): Split overload
2300 into two (LWG 3392).
2301 * testsuite/24_iterators/range_operations/lwg3392.cc: New test.
2303 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2305 * testsuite/30_threads/thread/cons/3.cc: Remove derivation from
2306 std::unary_function.
2307 * testsuite/30_threads/thread/cons/4.cc: Likewise.
2308 * testsuite/30_threads/thread/cons/5.cc: Likewise.
2310 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2312 * testsuite/ext/pb_ds/example/basic_multimap.cc: Remove
2313 unnecesary derivation from std::unary_function.
2314 * testsuite/ext/pb_ds/example/erase_if.cc: Likewise.
2315 * testsuite/ext/pb_ds/example/hash_illegal_resize.cc: Likewise.
2316 * testsuite/ext/pb_ds/example/hash_initial_size.cc: Likewise.
2317 * testsuite/ext/pb_ds/example/hash_load_set_change.cc: Likewise.
2318 * testsuite/ext/pb_ds/example/hash_mod.cc: Likewise.
2319 * testsuite/ext/pb_ds/example/hash_resize.cc: Likewise.
2320 * testsuite/ext/pb_ds/example/hash_shift_mask.cc: Likewise.
2321 * testsuite/ext/pb_ds/example/priority_queue_dijkstra.cc:
2323 * testsuite/ext/pb_ds/example/ranged_hash.cc: Likewise.
2324 * testsuite/ext/pb_ds/example/store_hash.cc: Likewise.
2326 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2328 * src/c++11/functexcept.cc (__throw_out_of_range_fmt): Do not
2329 expand the format string for freestanding, or non-vebose, or if
2330 we're just going to abort anyway.
2331 * src/c++11/snprintf_lite.cc: Remove unused header and
2334 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2336 * include/std/variant (__do_visit): Use variant_npos instead of
2337 literal -1 that requires a narrowing conversion.
2339 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2342 * src/filesystem/ops-common.h (__unsupported): New function to
2343 return a suitable error code for missing functionality.
2344 (posix::off_t): New typedef.
2345 (posix::*): Set errno to ENOSYS instead of ENOTSUP for no-op
2346 fallback implementations.
2347 (do_copy_file): Replace uses of errc::not_supported.
2348 * src/c++17/fs_ops.cc (fs::copy, fs::copy_file, create_dir)
2349 (fs::create_directory, fs::create_directory_symlink)
2350 (fs::create_hard_link, fs::create_symlink, fs::current_path)
2351 (fs::equivalent, do_stat, fs::file_size, fs::hard_link_count)
2352 (fs::last_write_time, fs::permissions, fs::read_symlink):
2353 Replace uses of errc::not_supported.
2354 (fs::resize_file): Qualify off_t.
2355 * src/filesystem/ops.cc (fs::copy, fs::copy_file, create_dir)
2356 (fs::create_directory, fs::create_directory_symlink)
2357 (fs::create_hard_link, fs::create_symlink, fs::current_path)
2358 (fs::equivalent, do_stat, fs::file_size, fs::last_write_time)
2359 (fs::permissions, fs::read_symlink, fs::system_complete):
2360 Replace uses of errc::not_supported.
2361 (fs::resize_file): Qualify off_t and enable unconditionally.
2362 * testsuite/19_diagnostics/system_error/cons-1.cc: Likewise.
2364 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2366 * src/filesystem/ops-common.h (last_error): New helper function.
2367 (filesystem::do_space): Use last_error().
2368 * src/c++17/fs_ops.cc (fs::absolute, fs::create_hard_link)
2369 (fs::equivalent, fs::remove, fs::temp_directory_path): Use
2371 * src/filesystem/ops.cc (fs::create_hard_link)
2372 (fs::remove, fs::temp_directory_path): Likewise.
2374 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2376 * include/std/type_traits (__conditional): New class template
2377 for internal uses of std::conditional.
2378 (__conditional_t): New alias template to replace conditional_t.
2379 (__and_, __or_, __result_of_memfun, __result_of_memobj): Use
2380 __conditional_t instead of conditional::type.
2381 * include/bits/atomic_base.h (__atomic_impl::_Diff): Likewise.
2382 * include/bits/hashtable.h (_Hashtable): Likewise.
2383 * include/bits/hashtable_policy.h (_Node_iterator, _Insert_base)
2384 (_Local_iterator): Likewise. Replace typedefs with
2386 * include/bits/move.h (move_if_noexcept): Use __conditional_t.
2387 * include/bits/parse_numbers.h (_Select_int_base): Likewise.
2388 * include/bits/ptr_traits.h (__make_not_void): Likewise.
2389 * include/bits/ranges_algobase.h (__copy_or_move_backward)
2390 (__copy_or_move): Likewise.
2391 * include/bits/ranges_base.h (borrowed_iterator_t): Likewise.
2392 * include/bits/ranges_util.h (borrowed_subrange_t): Likewise.
2393 * include/bits/regex_compiler.h (_BracketMatcher): Use
2394 __conditional_t. Replace typedefs with using-declarations.
2395 * include/bits/shared_ptr_base.h (__shared_count): Use
2397 * include/bits/stl_algobase.h (__copy_move, __copy_move_backward):
2399 * include/bits/stl_iterator.h (__detail::__clamp_iter_cat)
2400 (reverse_iterator::iterator_concept)
2401 (__make_move_if_noexcept_iterator)
2402 (iterator_traits<common_iterator<_It, _Sent>>)
2403 (iterator_traits<counted_iterator<_It>>): Likewise.
2404 * include/bits/stl_pair.h (_PCC, pair::operator=): Likewise.
2405 * include/bits/stl_tree.h (_Rb_tree::insert_return_type)
2406 (_Rb_tree::_M_clone_node): Likewise.
2407 * include/bits/unique_ptr.h (unique_ptr(unique_ptr<U,E>&&)):
2409 * include/bits/uses_allocator.h (__uses_alloc): Likewise.
2410 (__is_uses_allocator_predicate): Likewise.
2411 * include/debug/functions.h (__foreign_iterator_aux2): Likewise.
2412 * include/experimental/any (any::_Manager, __any_caster):
2414 * include/experimental/executor (async_completion): Likewise.
2415 * include/experimental/functional (__boyer_moore_base_t):
2417 * include/std/any (any::_Manager): Likewise.
2418 * include/std/functional (__boyer_moore_base_t): Likewise.
2419 * include/std/ranges (borrowed_iterator_t)
2420 (borrowed_subrange_t, __detail::__maybe_present_t)
2421 (__detail::__maybe_const_t, split_view): Likewise.
2422 * include/std/tuple (__empty_not_final, tuple::operator=):
2424 * include/std/variant (__detail::__variant::__get_t): Likewise.
2426 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2429 * include/std/variant (__do_visit): Use a switch when we have a
2430 single variant with a small number of alternatives.
2432 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2435 * include/std/variant (__cpp_lib_variant): Update value.
2436 (__detail::__variant::__as): New helpers implementing the
2437 as-variant exposition-only function templates.
2438 (visit, visit<R>): Use __as to upcast the variant parameters.
2439 * include/std/version (__cpp_lib_variant): Update value.
2440 * testsuite/20_util/variant/visit_inherited.cc: New test.
2442 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2444 * include/bits/stl_iterator.h (__normal_iterator): Simplify
2445 converting constructor and do not require _Container::pointer.
2447 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2449 * include/bits/cow_string.h [_GLIBCXX_FULLY_DYNAMIC_STRING]
2450 (basic_string(basic_string&&)): Add noexcept and avoid
2451 allocation, by sharing rep with the rvalue string.
2453 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2455 * include/bits/stl_iterator.h (common_iterator::__arrow_proxy)
2456 (common_iterator::__postfix_proxy): Add noexcept.
2458 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2461 * include/bits/stl_iterator.h (reverse_iterator): Use
2462 conditional noexcept on constructors and assignment operators.
2463 * testsuite/24_iterators/reverse_iterator/noexcept.cc: New test.
2465 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2468 * include/bits/vector.tcc (vector<bool>::_M_shrink_to_fit()):
2469 When size() is zero just deallocate and reset.
2471 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2474 * include/bits/stl_algo.h (clamp): Use std::min and std::max.
2476 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2478 * include/bits/regex.h (basic_regex::multiline): Define for
2479 non-strict C++11 and C++14 modes.
2480 * include/bits/regex_constants.h (regex_constants::multiline):
2481 Add _GLIBCXX_RESOLVE_LIB_DEFECTS comment.
2483 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2485 * testsuite/25_algorithms/is_permutation/2.cc: Include <iterator>.
2487 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2489 * include/bits/stream_iterator.h (istream_iterator): Add
2490 noexcept to constructors and non-throwing member functions and
2492 (ostream_iterator): Likewise.
2494 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2496 * include/bits/boost_concept_check.h (_Is_vector_bool_iterator):
2497 New trait to identify vector<bool> iterators, including debug
2499 (_ForwardIteratorReferenceConcept): Add default template
2500 argument using _Is_vector_bool_iterator and use it in partial
2501 specialization for the vector<bool> cases.
2502 (_Mutable_ForwardIteratorReferenceConcept): Likewise.
2503 * testsuite/24_iterators/operations/prev_neg.cc: Adjust dg-error
2506 2021-10-01 Jonathan Wakely <jwakely@redhat.com>
2508 * include/bits/list.tcc (list::merge): Remove call to size() and
2509 try-catch block. Use _Finalize_merge instead.
2510 * include/bits/stl_list.h (list::_Finalize_merge): New
2511 scope guard type to update _M_size members after a merge.
2513 2021-09-30 Jonathan Wakely <jwakely@redhat.com>
2515 * include/bits/regex.h (basic_regex::multiline): Fix #if
2518 2021-09-29 Jonathan Wakely <jwakely@redhat.com>
2520 * include/bits/regex.h (basic_regex::multiline): Define constant
2522 * include/bits/regex_constants.h (regex_constants::multiline):
2523 Define constant for C++17.
2524 (regex_constants::__multiline): Define duplicate constant for
2525 internal use in C++11 and C++14.
2526 * include/bits/regex_executor.h (_Executor::_M_match_multiline()):
2527 New member function.
2528 (_Executor::_M_is_line_terminator(_CharT)): New member function.
2529 (_Executor::_M_at_begin(), _Executor::_M_at_end()): Use new
2530 member functions to support multiline matches.
2531 * testsuite/28_regex/algorithms/regex_match/multiline.cc: New test.
2533 2021-09-29 Jonathan Wakely <jwakely@redhat.com>
2535 * include/bits/regex_compiler.h (_Compiler::_S_validate): New
2537 * include/bits/regex_compiler.tcc (_Compiler::_Compiler): Use
2538 _S_validate to check flags.
2539 * include/bits/regex_error.h (_S_grammar): New error code for
2541 * testsuite/28_regex/basic_regex/ctors/grammar.cc: New test.
2543 2021-09-29 Jonathan Wakely <jwakely@redhat.com>
2546 * include/bits/regex_error.h (regex_constants::_S_null): New
2547 error code for internal use.
2548 * include/bits/regex_scanner.tcc (_Scanner::_M_scan_normal()):
2549 Check for null character.
2550 * testsuite/28_regex/basic_regex/84110.cc: New test.
2552 2021-09-29 Jonathan Wakely <jwakely@redhat.com>
2554 * include/bits/regex.h (__detail::__is_contiguous_iter): Move
2555 here from <bits/regex_compiler.h>.
2556 (basic_regex::_M_compile): New function to compile an NFA from
2557 a regular expression string.
2558 (basic_regex::basic_regex): Use _M_compile instead of delegating
2559 to other constructors.
2560 (basic_regex::operator=(const basic_regex&)): Define as
2562 (basic_regex::operator=(initializer_list<C>)): Use _M_compile.
2563 (basic_regex::assign(const basic_regex&)): Use copy assignment.
2564 (basic_regex::assign(basic_regex&&)): Use move assignment.
2565 (basic_regex::assign(const C*, flag_type)): Use _M_compile
2566 instead of constructing a temporary string.
2567 (basic_regex::assign(const C*, size_t, flag_type)): Likewise.
2568 (basic_regex::assign(const basic_string<C,T,A>&, flag_type)):
2569 Use _M_compile instead of constructing a temporary basic_regex.
2570 (basic_regex::assign(InputIter, InputIter, flag_type)): Avoid
2571 constructing a temporary string for contiguous iterators of the
2573 * include/bits/regex_compiler.h (__is_contiguous_iter): Move to
2575 (__enable_if_contiguous_iter, __disable_if_contiguous_iter)
2576 (__compile_nfa): Remove.
2577 * testsuite/28_regex/basic_regex/assign/exception_safety.cc: New
2579 * testsuite/28_regex/basic_regex/ctors/char/other.cc: New test.
2581 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2583 * include/bits/atomic_timed_wait.h (__platform_wait_until_impl):
2584 Return false for ETIMEDOUT and true otherwise.
2586 2021-09-28 François Dumont <fdumont@gcc.gnu.org>
2588 * testsuite/20_util/default_delete/48631_neg.cc: Adapt dg-prune-output message
2589 to also match message with '__8' in it.
2591 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2593 * include/bits/regex_automaton.h (_NFA_base::_SizeT): Remove.
2594 * include/bits/regex_compiler.h (_Compiler::_IterT): Remove.
2595 * include/bits/regex_compiler.tcc: Likewise.
2596 * include/bits/regex_scanner.h (_Scanner::_IterT): Remove.
2597 * include/bits/regex_scanner.tcc: Likewise.
2599 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2601 * include/bits/regex_compiler.tcc: Add line break in empty while
2603 * include/bits/regex_executor.tcc: Avoid unused parameter
2606 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2608 * include/bits/regex.h (basic_regex, swap): Add noexcept to
2609 non-throwing functions.
2610 * include/bits/regex_automaton.h (_State_base, _State)
2611 (_NFA_base): Likewise.
2612 * include/bits/regex_compiler.h (_Compiler): Likewise.
2613 * include/bits/regex_error.h (regex_error::code()): Likewise.
2614 * include/bits/regex_scanner.h (_Scanner): Likewise.
2616 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2618 * include/bits/atomic_wait.h (_GLIBCXX_HAVE_PLATFORM_WAIT):
2619 Define before first attempt to check it.
2621 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2623 * testsuite/23_containers/priority_queue/requirements/explicit_instantiation/1.cc:
2624 Do not check non-default constructible sequences when
2625 _GLIBCXX_CONCEPT_CHECKS is defined.
2626 * testsuite/23_containers/priority_queue/requirements/explicit_instantiation/1_c++98.cc:
2628 * testsuite/23_containers/queue/requirements/explicit_instantiation/1.cc:
2630 * testsuite/23_containers/queue/requirements/explicit_instantiation/1_c++98.cc:
2632 * testsuite/23_containers/stack/requirements/explicit_instantiation/1.cc:
2634 * testsuite/23_containers/stack/requirements/explicit_instantiation/1_c++98.cc:
2637 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2639 * testsuite/23_containers/deque/requirements/explicit_instantiation/3.cc:
2640 Do not test implicit allocator rebinding when _GLIBCXX_CONCEPT_CHECKS
2642 * testsuite/23_containers/forward_list/requirements/explicit_instantiation/3.cc:
2644 * testsuite/23_containers/list/requirements/explicit_instantiation/3.cc:
2646 * testsuite/23_containers/list/requirements/explicit_instantiation/5.cc:
2648 * testsuite/23_containers/map/requirements/explicit_instantiation/3.cc:
2650 * testsuite/23_containers/map/requirements/explicit_instantiation/5.cc:
2652 * testsuite/23_containers/multimap/requirements/explicit_instantiation/3.cc:
2654 * testsuite/23_containers/multimap/requirements/explicit_instantiation/5.cc:
2656 * testsuite/23_containers/multiset/requirements/explicit_instantiation/3.cc:
2658 * testsuite/23_containers/multiset/requirements/explicit_instantiation/5.cc:
2660 * testsuite/23_containers/set/requirements/explicit_instantiation/3.cc:
2662 * testsuite/23_containers/set/requirements/explicit_instantiation/5.cc:
2664 * testsuite/23_containers/unordered_map/requirements/explicit_instantiation/3.cc:
2666 * testsuite/23_containers/unordered_multimap/requirements/explicit_instantiation/3.cc:
2668 * testsuite/23_containers/unordered_multiset/requirements/explicit_instantiation/3.cc:
2670 * testsuite/23_containers/unordered_set/requirements/explicit_instantiation/3.cc:
2672 * testsuite/23_containers/vector/ext_pointer/explicit_instantiation/3.cc:
2674 * testsuite/23_containers/vector/requirements/explicit_instantiation/3.cc:
2677 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2679 * include/bits/boost_concept_check.h (_ForwardIteratorConcept)
2680 (_BidirectionalIteratorConcept, _RandomAccessIteratorConcept):
2681 Check result types of iterator operations.
2682 (_Mutable_ForwardIteratorConcept): Check that iterator's
2683 reference type is a reference to its value type.
2684 (_Mutable_BidirectionalIteratorConcept): Do not require the
2685 value type to be assignable.
2686 (_Mutable_RandomAccessIteratorConcept): Likewise.
2687 * testsuite/24_iterators/operations/prev_neg.cc: Adjust dg-error
2690 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2692 * testsuite/25_algorithms/copy/34595.cc: Add missing operation
2693 for type used as an iterator.
2694 * testsuite/25_algorithms/unique_copy/check_type.cc: Likewise.
2696 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2698 * testsuite/20_util/is_nothrow_swappable/value.h: Use custom
2699 comparison function for priority_queue of type with no
2700 relational operators.
2701 * testsuite/20_util/is_swappable/value.h: Likewise.
2702 * testsuite/24_iterators/output/concept.cc: Add operator< to
2705 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2707 * include/bits/boost_concept_check.h (_OutputIteratorConcept):
2708 Use a function to preserve value category of the type.
2709 * include/bits/stl_algobase.h (copy, move, fill_n): Use a
2710 reference as the second argument for _OutputIteratorConcept.
2711 (copy_backward, move_backward): Use _OutputIteratorConcept
2712 instead of _ConvertibleConcept.
2714 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2716 * include/bits/stl_iterator.h (pointer_traits): Define partial
2717 specialization for __normal_iterator.
2718 * testsuite/24_iterators/normal_iterator/to_address.cc: New test.
2720 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2722 * include/bits/move.h (forward(remove_reference_t<T>&&)):
2723 Improve text of static_assert.
2724 * testsuite/20_util/forward/c_neg.cc: Adjust dg-error.
2725 * testsuite/20_util/forward/f_neg.cc: Likewise.
2727 2021-09-28 Jonathan Wakely <jwakely@redhat.com>
2730 * include/bits/fs_path.h (path::begin, path::end): Add noexcept
2731 to declarations, to match definitions.
2733 2021-09-24 Jonathan Wakely <jwakely@redhat.com>
2735 * include/bits/range_access.h (cbegin, cend): Remove redundant
2738 2021-09-23 Jonathan Wakely <jwakely@redhat.com>
2740 * testsuite/20_util/specialized_algorithms/memory_management_tools/destroy_neg.cc:
2741 Remove dg-error lines for C++20-only errors.
2743 2021-09-23 Jonathan Wakely <jwakely@redhat.com>
2745 * testsuite/19_diagnostics/headers/system_error/93151.cc:
2748 2021-09-23 Jonathan Wakely <jwakely@redhat.com>
2750 * src/c++11/system_error.cc (system_error_category) [_WIN32]:
2751 Map Windows error codes to generic POSIX error numbers. Use
2752 FormatMessage instead of strerror.
2753 * testsuite/19_diagnostics/error_category/system_category.cc:
2754 Adjust for new behaviour on Windows.
2756 2021-09-23 Jonathan Wakely <jwakely@redhat.com>
2758 * src/c++11/system_error.cc (generic_error_category): Define
2759 class and virtual functions as 'final'.
2760 (generic_error_category::equivalent(int, const error_condition&)):
2762 (system_error_category): Define class and virtual functions as
2764 (system_error_category::equivalent(int, const error_condition&)):
2766 (generic_category_instance, system_category_instance): Use
2767 constinit union to make the objects immortal.
2769 2021-09-23 Jonathan Wakely <jwakely@redhat.com>
2772 * src/c++11/system_error.cc
2773 (system_error_category::default_error_condition): Add 0 to
2775 * testsuite/19_diagnostics/error_category/102425.cc: New test.
2777 2021-09-17 Jonathan Wakely <jwakely@redhat.com>
2779 * include/bits/fs_path.h (path::iterator): Add noexcept to all
2780 member functions and friend functions.
2781 (distance): Add noexcept.
2782 (advance): Add noexcept and inline.
2783 * include/experimental/bits/fs_path.h (path::iterator):
2784 Add noexcept to all member functions.
2786 2021-09-17 Jonathan Wakely <jwakely@redhat.com>
2789 * include/std/tuple (_Tuple_impl): Add constexpr to constructor
2790 missed in previous patch.
2791 * testsuite/20_util/tuple/cons/102270.C: Moved to...
2792 * testsuite/20_util/tuple/cons/102270.cc: ...here.
2793 * testsuite/util/testsuite_allocator.h (SimpleAllocator): Add
2794 constexpr to constructor so it can be used for C++20 tests.
2796 2021-09-17 Jonathan Wakely <jwakely@redhat.com>
2798 * testsuite/26_numerics/valarray/dr630-3.C: Moved to...
2799 * testsuite/26_numerics/valarray/dr630-3.cc: ...here.
2800 * testsuite/27_io/basic_iostream/cons/16251.C: Moved to...
2801 * testsuite/27_io/basic_iostream/cons/16251.cc: ...here.
2803 2021-09-16 Jonathan Wakely <jwakely@redhat.com>
2805 * src/Makefile.am (stamp-debug): Add all Makefiles as
2807 * src/Makefile.in: Regenerate.
2809 2021-09-16 Jonathan Wakely <jwakely@redhat.com>
2811 * testsuite/ext/pb_ds/regression/tree_map_rand.cc: Increase
2812 timeout factor to 3.
2813 * testsuite/ext/pb_ds/regression/tree_set_rand.cc: Likewise.
2815 2021-09-16 Jonathan Wakely <jwakely@redhat.com>
2817 * doc/xml/manual/using.xml: Generalize to apply to more than
2819 * doc/html/manual/using_macros.html: Regenerate.
2821 2021-09-16 Jonathan Wakely <jwakely@redhat.com>
2823 * include/std/optional (nullptr_t): Make constructor noexcept.
2825 2021-09-16 Jonathan Wakely <jwakely@redhat.com>
2827 * include/bits/fs_path.h (advance): Remove non-deducible
2830 2021-09-16 Jonathan Wakely <jwakely@redhat.com>
2833 * include/std/tuple (_Head_base, _Tuple_impl): Add
2834 _GLIBCXX20_CONSTEXPR to allocator-extended constructors.
2835 (tuple<>::swap(tuple&)): Add _GLIBCXX20_CONSTEXPR.
2836 * testsuite/20_util/tuple/cons/102270.C: New test.
2838 2021-09-16 Jonathan Wakely <jwakely@redhat.com>
2841 * include/std/span (span(Range&&)): Add constraint to deduction
2844 2021-09-16 Jonathan Wakely <jwakely@redhat.com>
2846 * src/c++98/Makefile.am: Use CXXCOMPILE not LTCXXCOMPILE.
2847 * src/c++98/Makefile.in: Regenerate.
2849 2021-09-16 Jonathan Wakely <jwakely@redhat.com>
2851 * include/bits/basic_string.h [_GLIBCXX_USE_CXX11_ABI]
2852 (to_string): Add noexcept if the type width is 32 bits or less.
2854 2021-09-16 Jonathan Wakely <jwakely@redhat.com>
2856 * include/bits/unique_ptr.h (__uniq_ptr_impl::_M_ptr)
2857 (__uniq_ptr_impl::_M_deleter): Add noexcept.
2859 2021-09-16 Thomas Rodgers <rodgert@twrodgers.com>
2862 * testsuite/29_atomics/atomic_ref/wait_notify.cc (test): Use
2863 va and vb as arguments to wait/notify, remove unused bb local.
2865 2021-09-15 Hugo Beauzée-Luyssen <hugo@beauzee.fr>
2867 * crossconfig.m4: Check for TLS support on mingw.
2868 * configure: Regenerate.
2870 2021-09-13 Jason Merrill <jason@redhat.com>
2872 * include/std/version: Define __cpp_lib_hardware_interference_size.
2873 * libsupc++/new: Define hardware interference size variables.
2875 2021-09-10 Jonathan Wakely <jwakely@redhat.com>
2877 * testsuite/experimental/net/internet/resolver/ops/lookup.cc:
2878 Fix invalid hostname to only match the .invalid TLD.
2880 2021-09-02 Jonathan Wakely <jwakely@redhat.com>
2882 * include/bits/atomic_base.h (__atomic_base<P*>::compare_exchange_weak):
2884 * include/std/atomic (atomic<T*>::compare_exchange_weak): Use
2887 2021-09-02 Jonathan Wakely <jwakely@redhat.com>
2889 * include/std/atomic: Tweak whitespace.
2891 2021-09-02 Jonathan Wakely <jwakely@redhat.com>
2894 * include/bits/atomic_base.h (__is_valid_cmpexch_failure_order):
2895 New function to check if a memory order is valid for the failure
2896 case of compare exchange operations.
2897 (__atomic_base<I>::compare_exchange_weak): Simplify assertions
2898 by using __is_valid_cmpexch_failure_order.
2899 (__atomic_base<I>::compare_exchange_strong): Likewise.
2900 (__atomic_base<P*>::compare_exchange_weak): Likewise.
2901 (__atomic_base<P*>::compare_exchange_strong): Likewise.
2902 (__atomic_impl::compare_exchange_weak): Add assertion.
2903 (__atomic_impl::compare_exchange_strong): Likewise.
2904 * include/std/atomic (atomic::compare_exchange_weak): Likewise.
2905 (atomic::compare_exchange_strong): Likewise.
2907 2021-09-02 Jonathan Wakely <jwakely@redhat.com>
2909 * include/std/functional (invoke_r): Define.
2910 * include/std/version (__cpp_lib_invoke_r): Define.
2911 * testsuite/20_util/function_objects/invoke/version.cc: Check
2912 for __cpp_lib_invoke_r as well as __cpp_lib_invoke.
2913 * testsuite/20_util/function_objects/invoke/4.cc: New test.
2915 2021-08-31 Jonathan Wakely <jwakely@redhat.com>
2918 * include/std/span (span(Iter, size_type), span(Iter, Iter)):
2919 Add valid range checks.
2920 * testsuite/23_containers/span/cons_1_assert_neg.cc: New test.
2921 * testsuite/23_containers/span/cons_2_assert_neg.cc: New test.
2923 2021-08-31 Jonathan Wakely <jwakely@redhat.com>
2925 * configure.ac: Fix checks for F_GETFL, F_SETFL and O_NONBLOCK.
2926 * configure: Regenerate.
2928 2021-08-31 Jonathan Wakely <jwakely@redhat.com>
2930 * src/c++11/system_error.cc (error_category::~error_category()):
2931 Remove noexcept-specifier.
2932 (system_error::~system_error()): Likewise.
2933 * testsuite/19_diagnostics/error_category/noexcept.cc: New test.
2934 * testsuite/19_diagnostics/system_error/noexcept.cc: New test.
2936 2021-08-31 Jonathan Wakely <jwakely@redhat.com>
2939 * include/bits/atomic_timed_wait.h (__timed_waiter_pool)
2940 [!_GLIBCXX_HAVE_PLATFORM_TIMED_WAIT]: Add missing return.
2942 2021-08-31 Jonathan Wakely <jwakely@redhat.com>
2944 * include/experimental/internet (__make_resolver_error_code):
2945 Handle EAI_SYSTEM errors.
2946 (basic_resolver_results): Use __make_resolver_error_code. Use
2947 Glibc NI_MAXHOST and NI_MAXSERV values for buffer sizes.
2949 2021-08-31 Jonathan Wakely <jwakely@redhat.com>
2951 * testsuite/experimental/net/internet/resolver/ops/lookup.cc:
2952 Try other service if "http" fails.
2954 2021-08-31 Jonathan Wakely <jwakely@redhat.com>
2956 * testsuite/17_intro/names.cc: Undefine some more names used
2957 by Solaris system headers.
2959 2021-08-30 Jason Merrill <jason@redhat.com>
2962 * testsuite/30_threads/promise/requirements/lwg3466.cc:
2963 Remove dg-prune-outputs.
2965 2021-08-28 Jonathan Wakely <jwakely@redhat.com>
2967 * include/bits/alloc_traits.h (allocator_traits): Add explicit
2968 specialization for allocator<void>. Improve doxygen comments.
2969 * include/bits/allocator.h (allocator<void>): Restore for the
2970 versioned namespace.
2971 (allocator<void>::construct, allocator<void>::destroy): Remove.
2972 * include/ext/extptr_allocator.h (_Extptr_allocator<void>):
2973 Add default constructor and converting constructor.
2975 2021-08-28 Jonathan Wakely <jwakely@redhat.com>
2977 * include/bits/stl_uninitialized.h: Fix typo in comment.
2979 2021-08-28 Jonathan Wakely <jwakely@redhat.com>
2982 * src/c++17/fs_ops.cc (fs::absolute): Call non-throwing form,
2983 to avoid unnecessary current_path() call.
2985 2021-08-28 Jonathan Wakely <jwakely@redhat.com>
2987 * include/bits/std_function.h (function::function(F&&)): Give
2988 name to defaulted template parameter, to improve diagnostics.
2989 Use markdown for more doxygen comments.
2991 2021-08-26 Jonathan Wakely <jwakely@redhat.com>
2993 * include/bits/std_function.h (function): Adjust doxygen
2995 * include/bits/unique_ptr.h (make_unique_for_overwrite):
2996 Change parameter name to match doxygen comment.
2998 2021-08-26 Jonathan Wakely <jwakely@redhat.com>
3000 * include/bits/std_function.h (_function_base::_Base_manager):
3001 Replace _M_init_functor with a function template using a
3002 forwarding reference, and a pair of _M_create function
3003 templates. Reuse _M_create for the clone operation.
3004 (function::_Decay_t): New alias template.
3005 (function::_Callable): Simplify by using _Decay.
3006 (function::function(F)): Change parameter to forwarding
3007 reference, as per LWG 2447. Add noexcept-specifier. Simplify
3009 (function::operator=(F&&)): Add noexcept-specifier.
3010 * testsuite/20_util/function/cons/lwg2774.cc: New test.
3011 * testsuite/20_util/function/cons/noexcept.cc: New test.
3013 2021-08-26 Jonathan Wakely <jwakely@redhat.com>
3015 * include/bits/std_function.h (function::function(F)): Add
3016 static assertions to check constructibility requirements.
3018 2021-08-26 Jonathan Wakely <jwakely@redhat.com>
3021 * configure.ac: Check for O_NONBLOCK.
3022 * configure: Regenerate.
3023 * include/experimental/internet: Include <ws2tcpip.h> for
3024 Windows. Use preprocessor conditions around more constants.
3025 * include/experimental/socket: Use preprocessor conditions
3026 around more constants.
3027 * testsuite/experimental/net/internet/resolver/base.cc: Only use
3028 constants when the corresponding C macro is defined.
3029 * testsuite/experimental/net/socket/basic_socket.cc: Likewise.
3030 * testsuite/experimental/net/socket/socket_base.cc: Likewise.
3031 Make preprocessor checks more fine-grained.
3033 2021-08-25 Jonathan Wakely <jwakely@redhat.com>
3035 * testsuite/17_intro/names.cc: Check 'sz'.
3037 2021-08-25 Jonathan Wakely <jwakely@redhat.com>
3039 * testsuite/17_intro/names.cc: Adjust for Windows.
3041 2021-08-25 Jonathan Wakely <jwakely@redhat.com>
3043 * include/std/valarray: Uglify 'func' parameters.
3044 * testsuite/17_intro/names.cc: Add 'func' to checks.
3046 2021-08-25 Jonathan Wakely <jwakely@redhat.com>
3049 * include/bits/stl_uninitialized.h (_GLIBCXX_USE_ASSIGN_FOR_INIT):
3050 Define macro to check conditions for optimizing trivial cases.
3051 (__check_constructible): New function to do static assert.
3052 (uninitialized_copy, uninitialized_fill, uninitialized_fill_n):
3054 * testsuite/20_util/specialized_algorithms/uninitialized_copy/1.cc:
3055 Adjust dg-error pattern.
3056 * testsuite/23_containers/vector/cons/89164.cc: Likewise. Add
3057 C++17-specific checks from 89164_c++17.cc.
3058 * testsuite/23_containers/vector/cons/89164_c++17.cc: Removed.
3059 * testsuite/20_util/specialized_algorithms/uninitialized_copy/102064.cc:
3061 * testsuite/20_util/specialized_algorithms/uninitialized_copy_n/102064.cc:
3063 * testsuite/20_util/specialized_algorithms/uninitialized_fill/102064.cc:
3065 * testsuite/20_util/specialized_algorithms/uninitialized_fill_n/102064.cc:
3068 2021-08-25 Jonathan Wakely <jwakely@redhat.com>
3071 * include/ext/rope (rope::erase(size_type)): Remove broken
3074 2021-08-24 Jonathan Wakely <jwakely@redhat.com>
3076 * doc/xml/manual/status_cxx2020.xml: Update table.
3077 * doc/html/manual/status.html: Regenerate.
3079 2021-08-24 Jonathan Wakely <jwakely@redhat.com>
3081 * include/std/type_traits (is_layout_compatible): Define.
3082 (is_corresponding_member): Define.
3083 * include/std/version (__cpp_lib_is_layout_compatible): Define.
3084 * testsuite/20_util/is_layout_compatible/is_corresponding_member.cc:
3086 * testsuite/20_util/is_layout_compatible/value.cc: New test.
3087 * testsuite/20_util/is_layout_compatible/version.cc: New test.
3088 * testsuite/20_util/is_pointer_interconvertible/with_class.cc:
3090 * testsuite/23_containers/span/layout_compat.cc: Do not use real
3091 std::is_layout_compatible trait if available.
3093 2021-08-24 Jonathan Wakely <jwakely@redhat.com>
3095 * src/c++11/cxx11-shim_facets.cc: Fix mismatched class-key in
3096 explicit instantiation definitions.
3098 2021-08-23 Jonathan Wakely <jwakely@redhat.com>
3100 * include/std/ranges (basic_istream_view): Add default template
3102 * testsuite/std/ranges/istream_view.cc: Check it.
3104 2021-08-23 Jonathan Wakely <jwakely@redhat.com>
3106 * libsupc++/dyncast.cc (__dynamic_cast): Add __builtin_expect to
3109 2021-08-23 Jonathan Wakely <jwakely@redhat.com>
3112 * testsuite/util/testsuite_fs.h (permissions_are_testable):
3115 2021-08-20 Jonathan Wakely <jwakely@redhat.com>
3118 * testsuite/27_io/filesystem/iterators/directory_iterator.cc:
3119 Use new __gnu_test::permissions_are_testable() function.
3120 * testsuite/27_io/filesystem/iterators/recursive_directory_iterator.cc:
3122 * testsuite/27_io/filesystem/operations/exists.cc: Likewise.
3123 * testsuite/27_io/filesystem/operations/is_empty.cc: Likewise.
3124 * testsuite/27_io/filesystem/operations/remove.cc: Likewise.
3125 * testsuite/27_io/filesystem/operations/remove_all.cc: Likewise.
3126 * testsuite/27_io/filesystem/operations/status.cc: Likewise.
3127 * testsuite/27_io/filesystem/operations/symlink_status.cc:
3129 * testsuite/27_io/filesystem/operations/temp_directory_path.cc:
3131 * testsuite/experimental/filesystem/iterators/directory_iterator.cc:
3133 * testsuite/experimental/filesystem/iterators/recursive_directory_iterator.cc:
3135 * testsuite/experimental/filesystem/operations/exists.cc:
3137 * testsuite/experimental/filesystem/operations/is_empty.cc:
3139 * testsuite/experimental/filesystem/operations/remove.cc:
3141 * testsuite/experimental/filesystem/operations/remove_all.cc:
3143 * testsuite/experimental/filesystem/operations/temp_directory_path.cc:
3145 * testsuite/util/testsuite_fs.h (__gnu_test::permissions_are_testable):
3146 New function to guess whether testing permissions will work.
3148 2021-08-19 Jonathan Wakely <jwakely@redhat.com>
3150 * doc/xml/manual/status_cxx2020.xml: Move row earlier in table.
3151 * doc/html/manual/status.html: Regenerate.
3153 2021-08-19 Jonathan Wakely <jwakely@redhat.com>
3155 * doc/doxygen/user.cfg.in: Update to Doxygen 1.9.2
3157 2021-08-19 Jonathan Wakely <jwakely@redhat.com>
3160 * include/std/charconv (__to_chars_i): Remove redundant check.
3162 2021-08-19 Jonathan Wakely <jwakely@redhat.com>
3165 * include/std/tuple (_Tuple_impl(_Tuple_impl&&)): Use base
3166 class' move constructor. Define as defaulted for versioned
3168 * testsuite/20_util/tuple/cons/101960.cc: New test.
3170 2021-08-19 Jonathan Wakely <jwakely@redhat.com>
3173 * doc/xml/manual/status_cxx2020.xml: Add P1739R4 to status table.
3174 * doc/html/manual/status.html: Regenerate.
3176 2021-08-19 Jonathan Wakely <jwakely@redhat.com>
3178 * include/bits/shared_ptr.h: Add @since and @headerfile tags.
3179 * include/bits/unique_ptr.h: Add @headerfile tags.
3181 2021-08-19 Jonathan Wakely <jwakely@redhat.com>
3183 * src/filesystem/ops-common.h (filesystem::file_time): Improve
3184 overflow check by using system_clock::duration::max().
3186 2021-08-19 Jonathan Wakely <jwakely@redhat.com>
3188 * include/bits/stl_tree.h: Tweak whitespace.
3190 2021-08-18 Jonathan Wakely <jwakely@redhat.com>
3192 * include/bits/unique_ptr.h (default_delete): Add @since tag.
3193 (unique_ptr, unique_ptr<T[]>): Likewise. Improve @brief.
3194 (make_unique, make_unique_for_overwrite): Likewise. Add @tparam,
3195 @param, and @returns.
3196 (_MakeUniq): Move to __detail namespace. Add alias template
3199 2021-08-18 Jonathan Wakely <jwakely@redhat.com>
3201 * include/bits/stl_function.h: Improve doxygen comments.
3203 2021-08-18 Jonathan Wakely <jwakely@redhat.com>
3205 * doc/doxygen/user.cfg.in (PREDEFINED): Enable doxygen
3206 processing for C++20 components and components that depend on
3208 * include/bits/stl_algo.h (random_shuffle): Use @deprecated.
3209 * include/std/type_traits: Improve doxygen comments for C++20
3212 2021-08-18 Jonathan Wakely <jwakely@redhat.com>
3214 * include/ext/type_traits.h (__promote_2, __promote_3)
3215 (__promote_4): Redfine as alias templates using __promoted_t.
3216 * include/std/complex (__promote_2): Remove partial
3217 specializations for std::complex.
3219 2021-08-18 Jonathan Wakely <jwakely@redhat.com>
3221 * include/bits/stl_algo.h (min(initializer_list<T>))
3222 (min(initializer_list<T>, Compare)): Call __min_element directly to
3223 avoid redundant debug checks for valid ranges.
3224 (max(initializer_list<T>), max(initializer_list<T>, Compare)):
3225 Likewise, for __max_element.
3226 (minmax(initializer_list<T>), minmax(initializer_list<T>, Compare)):
3227 Likewise, for __minmax_element.
3229 2021-08-18 Jonathan Wakely <jwakely@redhat.com>
3231 * include/debug/deque (deque(size_type, const T&, const A&)):
3232 Prevent class template argument deduction and replace with a
3234 * include/debug/forward_list (forward_list(size_type, const T&, const A&)):
3236 * include/debug/list (list(size_type, const T&, const A&)):
3238 * include/debug/vector (vector(size_type, const T&, const A&)):
3241 2021-08-18 Jonathan Wakely <jwakely@redhat.com>
3243 * python/libstdcxx/v6/printers.py (StdBitReferencePrinter): Use
3244 'std::vector<bool>::reference' as type name, not _Bit_reference.
3245 (build_libstdcxx_dictionary): Register printers for vector<bool>
3246 types in debug mode too.
3247 * testsuite/libstdc++-prettyprinters/simple.cc: Adjust expected
3248 output for invalid _Bit_reference. Use vector<bool>::reference
3249 instead of _Bit_reference.
3250 * testsuite/libstdc++-prettyprinters/simple11.cc: Likewise.
3252 2021-08-17 Thomas Schwinge <thomas@codesourcery.com>
3254 * testsuite/lib/libstdc++.exp: Avoid illegal argument to verbose,
3257 2021-08-17 Luc Michel <lmichel@kalray.eu>
3258 Marc Poulhies <mpoulhies@kalrayinc.com>
3260 * testsuite/lib/gdb-test.exp (gdb_version_check)
3261 (gdb_version_check_xmethods): Only check the GDB version for
3262 local native targets.
3264 2021-08-17 Antony Polukhin <antoshkka@gmail.com>
3265 Jonathan Wakely <jwakely@redhat.com>
3267 * include/bits/random.tcc (seed_seq::seed_seq): Reserve capacity
3268 if distance is O(1).
3269 * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error
3272 2021-08-17 Jonathan Wakely <jwakely@redhat.com>
3274 * testsuite/26_numerics/random/seed_seq/cons/range.cc: Check
3275 construction from input iterators.
3277 2021-08-17 Jonathan Wakely <jwakely@redhat.com>
3279 * python/libstdcxx/v6/printers.py (StdErrorCatPrinter): Remove.
3281 2021-08-17 Jonathan Wakely <jwakely@redhat.com>
3284 * include/bits/std_function.h (function(function&&)): Check for
3285 non-empty parameter before doing any work.
3287 2021-08-17 Jonathan Wakely <jwakely@redhat.com>
3289 * include/bits/cow_string.h (basic_string::contains): Do not
3290 define for -std=gnu++20.
3292 2021-08-17 Jonathan Wakely <jwakely@redhat.com>
3294 * include/bits/ranges_util.h (__not_same_as): Rename to
3296 * include/std/ranges (__not_same_as): Likewise.
3298 2021-08-17 Jonathan Wakely <jwakely@redhat.com>
3300 * include/std/utility (exchange): Add noexcept-specifier.
3301 * testsuite/20_util/exchange/noexcept.cc: New test.
3303 2021-08-17 Jonathan Wakely <jwakely@redhat.com>
3305 * python/libstdcxx/v6/printers.py (StdErrorCodePrinter): Define.
3306 (build_libstdcxx_dictionary): Register printer for
3307 std::error_code and std::error_condition.
3308 * testsuite/libstdc++-prettyprinters/cxx11.cc: Test it.
3310 2021-08-16 Jonathan Wakely <jwakely@redhat.com>
3313 * src/c++11/debug.cc (PrintContext::_M_indent): Replace with a
3315 (print_word): Use qualified-id to access it.
3317 2021-08-16 Jonathan Wakely <jwakely@redhat.com>
3319 * python/Makefile.am [GLIBCXX_BUILD_DEBUG] (install-data-local):
3320 Install another copy of the GDB hook.
3321 * python/Makefile.in: Regenerate.
3323 2021-08-12 Jonathan Wakely <jwakely@redhat.com>
3326 * include/c_global/cmath (hypot): Use __promoted_t.
3327 (lerp): Add new overload accepting any arithmetic types.
3328 * include/ext/type_traits.h (__promoted_t): New alias template.
3329 * testsuite/26_numerics/lerp.cc: Moved to...
3330 * testsuite/26_numerics/lerp/1.cc: ...here.
3331 * testsuite/26_numerics/lerp/constexpr.cc: New test.
3332 * testsuite/26_numerics/lerp/version.cc: New test.
3334 2021-08-12 Jonathan Wakely <jwakely@redhat.com>
3336 * testsuite/26_numerics/lerp.cc: Add header name to #error.
3337 * testsuite/26_numerics/midpoint/integral.cc: Likewise.
3338 * testsuite/26_numerics/midpoint/version.cc: New test.
3340 2021-08-12 Jonathan Wakely <jwakely@redhat.com>
3342 * include/experimental/random (experimental::randint): Add
3343 nodiscard attribute.
3345 2021-08-12 Jonathan Wakely <jwakely@redhat.com>
3347 * src/c++98/locale_init.cc: Require C++11.
3348 * src/c++98/localename.cc: Likewise.
3349 * src/c++98/misc-inst.cc: Require C++98.
3351 2021-08-11 Jonathan Wakely <jwakely@redhat.com>
3354 * testsuite/experimental/random/randint.cc: Loop and retry if
3355 reseed() produces the same sequence.
3357 2021-08-11 Jonathan Wakely <jwakely@redhat.com>
3359 * include/std/type_traits (__cpp_lib_is_pointer_interconvertible)
3360 (is_pointer_interconvertible_base_of_v)
3361 (is_pointer_interconvertible_base_of): Define for C++20.
3362 * include/std/version (__cpp_lib_is_pointer_interconvertible):
3364 * testsuite/23_containers/span/layout_compat.cc: Use correct
3365 feature test macro for std::is_layout_compatible_v.
3366 * testsuite/20_util/is_pointer_interconvertible/value.cc: New test.
3367 * testsuite/20_util/is_pointer_interconvertible/version.cc: New test.
3369 2021-08-09 Jonathan Wakely <jwakely@redhat.com>
3371 * include/bits/regex.h (basic_regex::transform_primary): Use
3372 _GLIBCXX_STD_C::vector for local variable.
3373 * include/bits/regex.tcc (__regex_algo_impl): Use reference to
3374 _GLIBCXX_STD_C::vector base class of match_results.
3375 * include/bits/regex_automaton.tcc (_StateSeq:_M_clone): Use
3376 _GLIBCXX_STD_C::map and _GLIBCXX_STD_C::deque for local
3378 * include/bits/regex_compiler.h (_BracketMatcher): Use
3379 _GLIBCXX_STD_C::vector for data members.
3380 * include/bits/regex_executor.h (_Executor): Likewise.
3381 * include/std/regex [_GLIBCXX_DEBUG]: Include <debug/vector>.
3383 2021-08-09 François Dumont <fdumont@gcc.gnu.org>
3385 * include/debug/safe_container.h
3386 (_Safe_container(_Safe_container&&, const _Alloc&, std::true_type)): New.
3387 (_Safe_container(_Safe_container&&, const _Alloc&, std::false_type)): New.
3388 (_Safe_container(_Safe_container&&, const _Alloc&)): Use latters.
3390 2021-08-09 Jonathan Wakely <jwakely@redhat.com>
3392 * testsuite/23_containers/unordered_map/cons/default.cc: Add
3393 equality comparison operators to allocator.
3394 * testsuite/23_containers/unordered_set/cons/default.cc:
3397 2021-08-08 François Dumont <fdumont@gcc.gnu.org>
3399 * testsuite/25_algorithms/copy/debug/constexpr_neg.cc: Replace 'failed_assertion'
3400 dg-prune-output reason with 'builtin_unreachable'.
3401 * testsuite/25_algorithms/copy_backward/debug/constexpr_neg.cc: Likewise.
3402 * testsuite/25_algorithms/equal/debug/constexpr_neg.cc: Likewise.
3403 * testsuite/25_algorithms/lower_bound/debug/constexpr_partitioned_neg.cc: Likewise.
3404 * testsuite/25_algorithms/lower_bound/debug/constexpr_partitioned_pred_neg.cc: Likewise.
3405 * testsuite/25_algorithms/lower_bound/debug/constexpr_valid_range_neg.cc: Likewise.
3406 * testsuite/25_algorithms/upper_bound/debug/constexpr_partitioned_neg.cc: Likewise.
3407 * testsuite/25_algorithms/upper_bound/debug/constexpr_partitioned_pred_neg.cc: Likewise.
3408 * testsuite/25_algorithms/upper_bound/debug/constexpr_valid_range_neg.cc: Likewise.
3410 2021-08-08 Hans-Peter Nilsson <hp@bitrange.com>
3412 * testsuite/std/ranges/iota/max_size_type.cc: Set
3413 dg-timeout-factor to 4.
3415 2021-08-06 Jonathan Wakely <jwakely@redhat.com>
3417 * libsupc++/compare (compare_three_way, strong_order)
3418 (weak_order, partial_order, compare_strong_order_fallback)
3419 (compare_weak_order_fallback, compare_partial_order_fallback):
3420 Move nodiscard attributes to correct location.
3422 2021-08-05 Jonathan Wakely <jwakely@redhat.com>
3425 * include/bits/ranges_base.h (ranges::begin, ranges::end)
3426 (ranges::rbegin, ranges::rend, ranges::size, ranges::ssize)
3427 (ranges::empty, ranges::data): Move attribute after the
3428 declarator-id instead of at the end of the declarator.
3429 * include/bits/stl_iterator.h (__gnu_cxx::__normal_iterator):
3430 Move attributes back to the start of the function declarator,
3431 but move the requires-clause to the end.
3432 (common_iterator): Move attribute after the declarator-id.
3433 * include/bits/stl_queue.h (queue): Remove ill-formed attributes
3434 from friend declaration that are not definitions.
3435 * include/std/ranges (views::all, views::filter)
3436 (views::transform, views::take, views::take_while,
3437 views::drop) (views::drop_while, views::join,
3438 views::lazy_split) (views::split, views::counted,
3439 views::common, views::reverse) (views::elements): Move
3440 attributes after the declarator-id.
3442 2021-08-05 Jonathan Wakely <jwakely@redhat.com>
3444 * libsupc++/compare (partial_ordering, weak_ordering)
3445 (strong_ordering, is_eq, is_neq, is_lt, is_lteq, is_gt, is_gteq)
3446 (compare_three_way, strong_order, weak_order, partial_order)
3447 (compare_strong_order_fallback, compare_weak_order_fallback)
3448 (compare_partial_order_fallback, __detail::__synth3way): Add
3449 nodiscard attribute.
3450 * testsuite/18_support/comparisons/categories/zero_neg.cc: Add
3451 -Wno-unused-result to options.
3453 2021-08-05 Jonathan Wakely <jwakely@redhat.com>
3456 * include/bits/ranges_base.h (ranges::begin, ranges::end)
3457 (ranges::rbegin, ranges::rend, ranges::size, ranges::ssize)
3458 (ranges::empty, ranges::data): Move attribute to the end of
3460 * include/bits/stl_iterator.h (__gnu_cxx::__normal_iterator)
3461 (common_iterator): Likewise for non-member operator functions.
3462 * include/std/ranges (views::all, views::filter)
3463 (views::transform, views::take, views::take_while, views::drop)
3464 (views::drop_while, views::join, views::lazy_split)
3465 (views::split, views::counted, views::common, views::reverse)
3466 (views::elements): Likewise.
3467 * testsuite/std/ranges/access/101782.cc: New test.
3469 2021-08-04 Jonathan Wakely <jwakely@redhat.com>
3471 * include/bits/forward_list.h: Add [[nodiscard]] to functions
3472 with no side-effects.
3473 * include/bits/stl_bvector.h: Likewise.
3474 * include/bits/stl_deque.h: Likewise.
3475 * include/bits/stl_list.h: Likewise.
3476 * include/bits/stl_queue.h: Likewise.
3477 * include/bits/stl_stack.h: Likewise.
3478 * include/bits/stl_vector.h: Likewise.
3479 * include/debug/deque: Likewise.
3480 * include/debug/forward_list: Likewise.
3481 * include/debug/list: Likewise.
3482 * include/debug/safe_iterator.h: Likewise.
3483 * include/debug/vector: Likewise.
3484 * include/std/array: Likewise.
3485 * testsuite/23_containers/array/creation/3_neg.cc: Use
3487 * testsuite/23_containers/array/debug/back1_neg.cc: Cast result
3489 * testsuite/23_containers/array/debug/back2_neg.cc: Likewise.
3490 * testsuite/23_containers/array/debug/front1_neg.cc: Likewise.
3491 * testsuite/23_containers/array/debug/front2_neg.cc: Likewise.
3492 * testsuite/23_containers/array/debug/square_brackets_operator1_neg.cc:
3494 * testsuite/23_containers/array/debug/square_brackets_operator2_neg.cc:
3496 * testsuite/23_containers/array/tuple_interface/get_neg.cc:
3497 Adjust dg-error line numbers.
3498 * testsuite/23_containers/deque/cons/clear_allocator.cc: Cast
3500 * testsuite/23_containers/deque/debug/invalidation/4.cc:
3502 * testsuite/23_containers/deque/types/1.cc: Use
3504 * testsuite/23_containers/list/types/1.cc: Cast result to void.
3505 * testsuite/23_containers/priority_queue/members/7161.cc:
3507 * testsuite/23_containers/queue/members/7157.cc: Likewise.
3508 * testsuite/23_containers/vector/59829.cc: Likewise.
3509 * testsuite/23_containers/vector/ext_pointer/types/1.cc:
3511 * testsuite/23_containers/vector/ext_pointer/types/2.cc:
3513 * testsuite/23_containers/vector/types/1.cc: Use
3516 2021-08-04 Jonathan Wakely <jwakely@redhat.com>
3518 * include/bits/iterator_concepts.h (iter_move): Add
3520 * include/bits/range_access.h (begin, end, cbegin, cend)
3521 (rbegin, rend, crbegin, crend, size, data, ssize): Likewise.
3522 * include/bits/ranges_base.h (ranges::begin, ranges::end)
3523 (ranges::cbegin, ranges::cend, ranges::rbegin, ranges::rend)
3524 (ranges::crbegin, ranges::crend, ranges::size, ranges::ssize)
3525 (ranges::empty, ranges::data, ranges::cdata): Likewise.
3526 * include/bits/stl_iterator.h (reverse_iterator, __normal_iterator)
3527 (back_insert_iterator, front_insert_iterator, insert_iterator)
3528 (move_iterator, move_sentinel, common_iterator)
3529 (counted_iterator): Likewise.
3530 * include/bits/stl_iterator_base_funcs.h (distance, next, prev):
3532 * include/bits/stream_iterator.h (istream_iterator)
3533 (ostream_iterartor): Likewise.
3534 * include/bits/streambuf_iterator.h (istreambuf_iterator)
3535 (ostreambuf_iterator): Likewise.
3536 * include/std/ranges (views::single, views::iota, views::all)
3537 (views::filter, views::transform, views::take, views::take_while)
3538 (views::drop, views::drop_while, views::join, views::lazy_split)
3539 (views::split, views::counted, views::common, views::reverse)
3540 (views::elements): Likewise.
3541 * testsuite/20_util/rel_ops.cc: Use -Wno-unused-result.
3542 * testsuite/24_iterators/move_iterator/greedy_ops.cc: Likewise.
3543 * testsuite/24_iterators/normal_iterator/greedy_ops.cc:
3545 * testsuite/24_iterators/reverse_iterator/2.cc: Likewise.
3546 * testsuite/24_iterators/reverse_iterator/greedy_ops.cc:
3548 * testsuite/21_strings/basic_string/range_access/char/1.cc:
3549 Cast result to void.
3550 * testsuite/21_strings/basic_string/range_access/wchar_t/1.cc:
3552 * testsuite/21_strings/basic_string_view/range_access/char/1.cc:
3554 * testsuite/21_strings/basic_string_view/range_access/wchar_t/1.cc:
3556 * testsuite/23_containers/array/range_access.cc: Likewise.
3557 * testsuite/23_containers/deque/range_access.cc: Likewise.
3558 * testsuite/23_containers/forward_list/range_access.cc:
3560 * testsuite/23_containers/list/range_access.cc: Likewise.
3561 * testsuite/23_containers/map/range_access.cc: Likewise.
3562 * testsuite/23_containers/multimap/range_access.cc: Likewise.
3563 * testsuite/23_containers/multiset/range_access.cc: Likewise.
3564 * testsuite/23_containers/set/range_access.cc: Likewise.
3565 * testsuite/23_containers/unordered_map/range_access.cc:
3567 * testsuite/23_containers/unordered_multimap/range_access.cc:
3569 * testsuite/23_containers/unordered_multiset/range_access.cc:
3571 * testsuite/23_containers/unordered_set/range_access.cc:
3573 * testsuite/23_containers/vector/range_access.cc: Likewise.
3574 * testsuite/24_iterators/customization_points/iter_move.cc:
3576 * testsuite/24_iterators/istream_iterator/sentinel.cc:
3578 * testsuite/24_iterators/istreambuf_iterator/sentinel.cc:
3580 * testsuite/24_iterators/move_iterator/dr2061.cc: Likewise.
3581 * testsuite/24_iterators/operations/prev_neg.cc: Likewise.
3582 * testsuite/24_iterators/ostreambuf_iterator/2.cc: Likewise.
3583 * testsuite/24_iterators/range_access/range_access.cc:
3585 * testsuite/24_iterators/range_operations/100768.cc: Likewise.
3586 * testsuite/26_numerics/valarray/range_access2.cc: Likewise.
3587 * testsuite/28_regex/range_access.cc: Likewise.
3588 * testsuite/experimental/string_view/range_access/char/1.cc:
3590 * testsuite/experimental/string_view/range_access/wchar_t/1.cc:
3592 * testsuite/ext/vstring/range_access.cc: Likewise.
3593 * testsuite/std/ranges/adaptors/take.cc: Likewise.
3594 * testsuite/std/ranges/p2259.cc: Likewise.
3596 2021-08-03 Jonathan Wakely <jwakely@redhat.com>
3598 * include/bits/random.tcc (linear_congruential_engine): Do not
3599 define static constexpr members when they are implicitly inline.
3600 * include/std/ratio (ratio, __ratio_multiply, __ratio_divide)
3601 (__ratio_add, __ratio_subtract): Likewise.
3602 * include/std/type_traits (integral_constant): Likewise.
3603 * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error
3606 2021-08-03 Jonathan Wakely <jwakely@redhat.com>
3608 * testsuite/util/testsuite_common_types.h: Replace uses of
3609 tr1::unordered_map and tr1::unordered_set with their C++11
3611 * testsuite/29_atomics/atomic/cons/assign_neg.cc: Adjust
3612 dg-error line number.
3613 * testsuite/29_atomics/atomic/cons/copy_neg.cc: Likewise.
3614 * testsuite/29_atomics/atomic_integral/cons/assign_neg.cc:
3616 * testsuite/29_atomics/atomic_integral/cons/copy_neg.cc:
3618 * testsuite/29_atomics/atomic_integral/operators/bitwise_neg.cc:
3620 * testsuite/29_atomics/atomic_integral/operators/decrement_neg.cc:
3622 * testsuite/29_atomics/atomic_integral/operators/increment_neg.cc:
3625 2021-08-03 Jonathan Wakely <jwakely@redhat.com>
3627 * include/std/memory_resource (polymorphic_allocator::delete_object):
3628 Call destructor directly instead of using destroy.
3629 (allocator_traits<polymorphic_allocator<T>>): Define partial
3632 2021-08-03 Jonathan Wakely <jwakely@redhat.com>
3634 * testsuite/20_util/function_objects/binders/3113.cc: Remove
3635 trailing whitespace.
3636 * testsuite/20_util/shared_ptr/assign/auto_ptr.cc: Likewise.
3637 * testsuite/20_util/shared_ptr/assign/auto_ptr_neg.cc: Likewise.
3638 * testsuite/20_util/shared_ptr/assign/auto_ptr_rvalue.cc:
3640 * testsuite/20_util/shared_ptr/creation/dr925.cc: Likewise.
3641 * testsuite/25_algorithms/headers/algorithm/synopsis.cc:
3643 * testsuite/25_algorithms/random_shuffle/requirements/explicit_instantiation/2.cc:
3645 * testsuite/25_algorithms/random_shuffle/requirements/explicit_instantiation/pod.cc:
3648 2021-08-03 Jonathan Wakely <jwakely@redhat.com>
3650 * doc/xml/manual/evolution.xml: Document deprecation.
3651 * doc/html/*: Regenerate.
3652 * include/bits/c++config (_GLIBCXX14_DEPRECATED): Define.
3653 (_GLIBCXX14_DEPRECATED_SUGGEST): Define.
3654 * include/bits/stl_algo.h (random_shuffle): Deprecate for C++14
3656 * testsuite/25_algorithms/headers/algorithm/synopsis.cc: Adjust
3657 for C++11 and C++14 changes to std::random_shuffle and
3659 * testsuite/25_algorithms/random_shuffle/1.cc: Add options to
3660 use deprecated algorithms.
3661 * testsuite/25_algorithms/random_shuffle/59603.cc: Likewise.
3662 * testsuite/25_algorithms/random_shuffle/moveable.cc: Likewise.
3663 * testsuite/25_algorithms/random_shuffle/requirements/explicit_instantiation/2.cc:
3665 * testsuite/25_algorithms/random_shuffle/requirements/explicit_instantiation/pod.cc:
3668 2021-08-03 Jonathan Wakely <jwakely@redhat.com>
3670 * testsuite/23_containers/forward_list/operations/3.cc:
3671 Use lambda instead of std::bind2nd.
3672 * testsuite/20_util/function_objects/binders/3113.cc: Add
3673 options for testing deprecated features.
3674 * testsuite/20_util/pair/cons/99957.cc: Likewise.
3675 * testsuite/20_util/shared_ptr/assign/auto_ptr.cc: Likewise.
3676 * testsuite/20_util/shared_ptr/assign/auto_ptr_neg.cc: Likewise.
3677 * testsuite/20_util/shared_ptr/assign/auto_ptr_rvalue.cc:
3679 * testsuite/20_util/shared_ptr/cons/43820_neg.cc: Likewise.
3680 * testsuite/20_util/shared_ptr/cons/auto_ptr.cc: Likewise.
3681 * testsuite/20_util/shared_ptr/cons/auto_ptr_neg.cc: Likewise.
3682 * testsuite/20_util/shared_ptr/creation/dr925.cc: Likewise.
3683 * testsuite/20_util/unique_ptr/cons/auto_ptr.cc: Likewise.
3684 * testsuite/20_util/unique_ptr/cons/auto_ptr_neg.cc: Likewise.
3685 * testsuite/ext/pb_ds/example/priority_queue_erase_if.cc:
3687 * testsuite/ext/pb_ds/example/priority_queue_split_join.cc:
3689 * testsuite/lib/dg-options.exp (dg_add_options_using-deprecated):
3692 2021-08-03 Jonathan Wakely <jwakely@redhat.com>
3694 * include/bits/regex_executor.h (_State_info): Replace
3695 unique_ptr<bool[]> with array of bool.
3696 * include/bits/regex_executor.tcc: Likewise.
3697 * include/bits/regex_scanner.tcc: Replace std::strchr with
3699 * include/std/regex: Replace standard headers with smaller
3701 * testsuite/28_regex/traits/char/lookup_classname.cc: Include
3702 <string.h> for strlen.
3703 * testsuite/28_regex/traits/char/lookup_collatename.cc:
3706 2021-08-03 Jonathan Wakely <jwakely@redhat.com>
3708 * include/bits/locale_conv.h (__detail::_Scoped_ptr): Define new
3709 RAII class template.
3710 (wstring_convert, wbuffer_convert): Use __detail::_Scoped_ptr
3711 instead of unique_ptr.
3713 2021-08-02 Patrick Palka <ppalka@redhat.com>
3716 * include/bits/ranges_algo.h (__reverse_copy_fn::operator()):
3717 Add missing std::move in return statement.
3718 (__partition_copy_fn::operator()): Rename templtae parameter
3719 _O2 to _Out2. Uglify function parameters out_true and out_false.
3720 * include/bits/ranges_algobase.h (__copy_or_move): Add missing
3721 std::move to recursive call that unwraps a __normal_iterator
3723 * testsuite/25_algorithms/copy/constrained.cc (test06): New test.
3724 * testsuite/25_algorithms/move/constrained.cc (test05): New test.
3726 2021-08-02 Patrick Palka <ppalka@redhat.com>
3729 * include/std/ranges (lazy_split_view::_InnerIter::base): Make
3730 the const& overload unconstrained and return a const reference
3731 as per LWG 3533. Make unconditionally noexcept.
3732 (elements_view::base): Revert accidental r12-569 change.
3733 (elements_view::_Iterator::base): Make the const& overload
3734 unconstrained and return a const reference as per LWG 3533.
3735 Make unconditionally noexcept.
3737 2021-08-02 Patrick Palka <ppalka@redhat.com>
3740 * include/std/ranges (join_view::_Iterator::_Iterator): Add
3743 2021-08-02 Jonathan Wakely <jwakely@redhat.com>
3746 * src/filesystem/ops-common.h (get_temp_directory_from_env):
3747 Add error_code parameter.
3748 * src/c++17/fs_ops.cc (fs::temp_directory_path): Pass error_code
3749 argument to get_temp_directory_from_env and check it.
3750 * src/filesystem/ops.cc (fs::temp_directory_path): Likewise.
3752 2021-08-02 Jonathan Wakely <jwakely@redhat.com>
3754 * testsuite/20_util/tuple/comparison_operators/overloaded2.cc:
3755 Add dg-error for c++11_only target.
3757 2021-07-30 Jonathan Wakely <jwakely@redhat.com>
3760 * configure.ac: Check for secure_getenv.
3761 * config.h.in: Regenerate.
3762 * configure: Regenerate.
3763 * src/filesystem/ops-common.h (get_temp_directory_from_env): New
3764 helper function to obtain path from the environment.
3765 * src/c++17/fs_ops.cc (fs::temp_directory_path): Use new helper.
3766 * src/filesystem/ops.cc (fs::temp_directory_path): Likewise.
3767 * testsuite/27_io/filesystem/operations/temp_directory_path.cc:
3768 Print messages if test cannot be run.
3769 * testsuite/experimental/filesystem/operations/temp_directory_path.cc:
3770 Likewise. Fix incorrect condition. Use "TMP" to work with
3771 Windows as well as POSIX.
3773 2021-07-29 Hans-Peter Nilsson <hp@bitrange.com>
3775 * src/c++17/memory_resource.cc: Use __exchange instead
3778 2021-07-27 Jonathan Wakely <jwakely@redhat.com>
3780 * include/experimental/optional (__throw_bad_optional_access):
3781 Replace GNU attribute with C++11 attribute.
3782 (optional::value, optional::value_or): Use if statements
3783 instead of conditional expressions.
3784 * include/std/optional (__throw_bad_optional_access)
3785 (optional::value, optional::value_or): Likewise.
3787 2021-07-27 Marek Polacek <polacek@redhat.com>
3791 * testsuite/20_util/tuple/comparison_operators/overloaded.cc:
3793 * testsuite/20_util/tuple/comparison_operators/overloaded2.cc:
3796 2021-07-27 Jonathan Wakely <jwakely@redhat.com>
3798 * include/bits/cow_string.h: Consistently use tab for
3801 2021-07-27 Jonathan Wakely <jwakely@redhat.com>
3803 * include/Makefile.am: Add new header.
3804 * include/Makefile.in: Regenerate.
3805 * include/bits/basic_string.h [!_GLIBCXX_USE_CXX11_ABI]
3806 (basic_string): Move definition of Copy-on-Write string to
3808 * include/bits/basic_string.tcc: Likewise.
3809 * include/bits/cow_string.h: New file.
3811 2021-07-27 Jonathan Wakely <jwakely@redhat.com>
3813 * include/std/algorithm: Do not include <utility>.
3814 * include/std/functional: Likewise.
3815 * include/std/regex: Include <bits/stl_pair.h> instead of
3817 * include/debug/map.h: Likewise.
3818 * include/debug/multimap.h: Likewise.
3819 * include/debug/multiset.h: Likewise.
3820 * include/debug/set.h: Likewise.
3821 * include/debug/vector: Likewise.
3822 * include/bits/fs_path.h: Likewise.
3823 * include/bits/unique_ptr.h: Do not include <utility>.
3824 * include/experimental/any: Likewise.
3825 * include/experimental/executor: Likewise.
3826 * include/experimental/memory: Likewise.
3827 * include/experimental/optional: Likewise.
3828 * include/experimental/socket: Use __exchange instead
3830 * src/filesystem/ops-common.h: Likewise.
3831 * testsuite/20_util/default_delete/48631_neg.cc: Adjust expected
3832 errors to not use a hardcoded line number.
3833 * testsuite/20_util/default_delete/void_neg.cc: Likewise.
3834 * testsuite/20_util/specialized_algorithms/uninitialized_copy/constrained.cc:
3835 Include <utility> for std::as_const.
3836 * testsuite/20_util/specialized_algorithms/uninitialized_default_construct/constrained.cc:
3838 * testsuite/20_util/specialized_algorithms/uninitialized_move/constrained.cc:
3840 * testsuite/20_util/specialized_algorithms/uninitialized_value_construct/constrained.cc:
3842 * testsuite/23_containers/vector/cons/destructible_debug_neg.cc:
3843 Adjust dg-error line number.
3845 2021-07-27 Jonathan Wakely <jwakely@redhat.com>
3847 * include/Makefile.am: Add bits/utility.h header.
3848 * include/Makefile.in: Regenerate.
3849 * include/bits/utility.h: New file.
3850 * include/std/utility (tuple_size, tuple_element): Move
3852 * include/std/type_traits (__is_tuple_like_impl<tuple<T...>>):
3854 (_Index_tuple, _Build_index_tuple, integer_sequence): Likewise.
3855 (in_place_t, in_place_index_t, in_place_type_t): Likewise.
3856 * include/bits/ranges_util.h: Include new header instead of
3858 * include/bits/stl_pair.h (tuple_size, tuple_element): Move
3859 partial specializations for std::pair here.
3860 (get): Move overloads for std::pair here.
3861 * include/std/any: Include new header instead of <utility>.
3862 * include/std/array: Likewise.
3863 * include/std/memory_resource: Likewise.
3864 * include/std/optional: Likewise.
3865 * include/std/variant: Likewise.
3866 * include/std/tuple: Likewise.
3867 (__is_tuple_like_impl<tuple<T...>>): Move here.
3868 (get) Declare overloads for std::array.
3869 * include/std/version (__cpp_lib_tuples_by_type): Change type
3871 * testsuite/20_util/optional/84601.cc: Include <utility>.
3872 * testsuite/20_util/specialized_algorithms/uninitialized_fill/constrained.cc:
3874 * testsuite/23_containers/array/tuple_interface/get_neg.cc:
3875 Adjust dg-error line numbers.
3876 * testsuite/std/ranges/access/cbegin.cc: Include <utility>.
3877 * testsuite/std/ranges/access/cend.cc: Likewise.
3878 * testsuite/std/ranges/access/end.cc: Likewise.
3879 * testsuite/std/ranges/single_view.cc: Likewise.
3881 2021-07-23 Jonathan Wakely <jwakely@redhat.com>
3883 * include/std/future: Include <bits/atomic_base.h> instead of
3886 2021-07-23 Jonathan Wakely <jwakely@redhat.com>
3888 * include/bits/stl_relops.h: Update documentation comments.
3890 2021-07-22 Jonathan Wakely <jwakely@redhat.com>
3893 * include/bits/hashtable.h (_Hashtable): Replace mixin with
3894 _Enable_default_ctor. Construct it explicitly in all
3895 non-forwarding, non-defaulted constructors.
3896 * testsuite/23_containers/unordered_map/cons/default.cc: Check
3897 non-default constructors can be used.
3898 * testsuite/23_containers/unordered_set/cons/default.cc:
3901 2021-07-22 David Edelsohn <dje.gcc@gmail.com>
3903 * config/os/aix/os_defines.h (__LIBC_NO_CPP_MATH_OVERLOADS__): Define.
3905 2021-07-22 Jonathan Wakely <jwakely@redhat.com>
3908 * include/ext/new_allocator.h (_GLIBCXX_OPERATOR_NEW)
3909 (_GLIBCXX_OPERATOR_DELETE, _GLIBCXX_SIZED_DEALLOC): Define.
3910 (allocator::allocate, allocator::deallocate): Use new macros.
3912 2021-07-22 Jonathan Wakely <jwakely@redhat.com>
3915 * include/bits/ranges_uninitialized.h (_DestroyGuard): Change
3916 constructor parameter to reference and use addressof.
3917 * testsuite/util/testsuite_iterators.h: Define deleted operator&
3918 overloads for test iterators.
3920 2021-07-22 Jonathan Wakely <jwakely@redhat.com>
3922 * include/bits/std_function.h (_Function_base): Add
3923 default member initializers and define constructor as defaulted.
3924 (function::_M_invoker): Add default member initializer.
3926 2021-07-22 Jonathan Wakely <jwakely@redhat.com>
3929 * doc/xml/manual/debug_mode.xml: Update documentation about
3930 debug capability of std::array.
3931 * doc/html/*: Regenerate.
3932 * include/debug/array: New file.
3934 2021-07-21 Jonathan Wakely <jwakely@redhat.com>
3937 * include/ext/rope (sequence_buffer): Add move constructor and
3938 move assignment operator.
3939 * testsuite/ext/rope/101542.cc: New test.
3941 2021-07-20 Jonathan Wakely <jwakely@redhat.com>
3944 * src/c++17/fs_ops.cc (fs::create_directories): Use status
3945 instead of symlink_status.
3946 * src/filesystem/ops.cc (fs::create_directories): Likewise.
3947 * testsuite/27_io/filesystem/operations/create_directories.cc:
3948 Check symlink to existing directory.
3949 * testsuite/27_io/filesystem/operations/create_directory.cc: Do
3950 not test with symlinks on Windows.
3951 * testsuite/experimental/filesystem/operations/create_directories.cc:
3952 Check symlink to existing directory.
3953 * testsuite/experimental/filesystem/operations/create_directory.cc:
3954 Do not test with symlinks on Windows.
3956 2021-07-20 Jonathan Wakely <jwakely@redhat.com>
3959 * include/bits/hashtable.h (_Hashtable): Conditionally delete
3960 default constructor by deriving from _Enable_special_members.
3961 * testsuite/23_containers/unordered_map/cons/default.cc: New test.
3962 * testsuite/23_containers/unordered_set/cons/default.cc: New test.
3964 2021-07-20 Jonathan Wakely <jwakely@redhat.com>
3967 * src/c++17/fs_ops.cc (create_dir): Adjust whitespace.
3968 * testsuite/27_io/filesystem/operations/create_directory.cc:
3969 Test creating directory with name of existing symlink to
3971 * testsuite/experimental/filesystem/operations/create_directory.cc:
3974 2021-07-16 Jonathan Wakely <jwakely@redhat.com>
3976 * include/std/tuple (get<I>): Add deleted overload for bad
3978 * testsuite/20_util/tuple/element_access/get_neg.cc: Adjust
3981 2021-07-16 Jonathan Wakely <jwakely@redhat.com>
3983 * include/bits/max_size_type.h (numeric_limits<__max_size_type>):
3984 Use __int_traits unconditionally.
3986 2021-07-16 Jonathan Wakely <jwakely@redhat.com>
3988 * include/bits/random.h (_Shift::__value): Use constexpr.
3989 (_Select_uint_least_t::type): Use using-declaration.
3991 * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error
3994 2021-07-16 Jonathan Wakely <jwakely@redhat.com>
3996 * include/bits/cpp_type_traits.h (__INT_N): Use __extension__
3997 instead of diagnostic pragmas.
3998 * include/bits/functional_hash.h: Likewise.
3999 * include/bits/iterator_concepts.h (__is_signed_int128)
4000 (__is_unsigned_int128): Likewise.
4001 * include/bits/max_size_type.h (__max_size_type): Likewise.
4002 (numeric_limits<__max_size_type>): Likewise.
4003 * include/bits/std_abs.h (abs): Likewise.
4004 * include/bits/stl_algobase.h (__size_to_integer): Likewise.
4005 * include/bits/uniform_int_dist.h (uniform_int_distribution):
4007 * include/ext/numeric_traits.h (_GLIBCXX_INT_N_TRAITS):
4009 * include/std/type_traits (__is_integral_helper<INT_N>)
4010 (__is_signed_integer, __is_unsigned_integer)
4011 (__make_unsigned<INT_N>, __make_signed<INT_N>): Likewise.
4012 * include/std/limits (__INT_N): Add __extension__ keyword.
4013 * include/bits/random.h (_Select_uint_least_t)
4014 (random_device): Likewise.
4016 2021-07-16 Patrick Palka <ppalka@redhat.com>
4019 * include/std/ranges (_CachedPosition::_M_get): For non-forward
4020 ranges, just call __builtin_unreachable.
4021 * testsuite/std/ranges/istream_view.cc (test05): New test.
4023 2021-07-16 Patrick Palka <ppalka@redhat.com>
4026 * include/std/ranges (split_view::split_view): Use std::move.
4027 (split_view::_Iterator::_Iterator): Remove redundant
4028 default_initializable constraint.
4029 (split_view::_Sentinel::_Sentinel): Declare.
4030 * testsuite/std/ranges/adaptors/split.cc (test02): New test.
4032 2021-07-16 Marek Polacek <polacek@redhat.com>
4034 * testsuite/20_util/ratio/operations/ops_overflow_neg.cc: Add
4037 2021-07-16 Jonathan Wakely <jwakely@redhat.com>
4039 * include/bits/unique_ptr.h: Adjust doxygen markup.
4041 2021-07-16 Jonathan Wakely <jwakely@redhat.com>
4044 * include/std/type_traits: Adjust doxygen markup.
4046 2021-07-16 Jonathan Wakely <jwakely@redhat.com>
4048 * include/bits/cpp_type_traits.h: Add diagnostic pragmas around
4049 uses of non-standard integer types.
4050 * include/bits/functional_hash.h: Likewise.
4051 * include/bits/iterator_concepts.h: Likewise.
4052 * include/bits/max_size_type.h: Likewise.
4053 * include/bits/std_abs.h: Likewise.
4054 * include/bits/stl_algobase.h: Likewise.
4055 * include/bits/uniform_int_dist.h: Likewise.
4056 * include/ext/numeric_traits.h: Likewise.
4057 * include/std/type_traits: Likewise.
4059 2021-07-15 Jonathan Wakely <jwakely@redhat.com>
4062 * include/std/tuple (tuple_element): Improve static_assert text.
4063 (__get_helper): Add deleted overload.
4064 (get<i>(tuple<T...>&&), get<i>(const tuple<T...>&&)): Use
4065 __get_helper directly.
4066 (__get_helper2): Remove.
4067 (__find_uniq_type_in_pack): New constexpr helper function.
4068 (get<T>): Use __find_uniq_type_in_pack and __get_helper instead
4070 * testsuite/20_util/tuple/element_access/get_neg.cc: Adjust
4072 * testsuite/20_util/tuple/element_access/101427.cc: New test.
4074 2021-07-15 Jonathan Wakely <jwakely@redhat.com>
4077 * include/bits/c++config (__replacement_assert): Add noexcept.
4078 [!_GLIBCXX_VERBOSE] (__glibcxx_assert_impl): Use __builtin_abort
4079 instead of __replacement_assert.
4081 2021-07-14 Jonathan Wakely <jwakely@redhat.com>
4083 * include/std/string_view (basic_string_view(It, End)): Add
4085 * testsuite/21_strings/basic_string_view/cons/char/range.cc:
4086 Check noexcept-specifier. Also check construction without CTAD.
4088 2021-07-13 Jonathan Wakely <jwakely@redhat.com>
4091 * include/std/string_view (ends_with): Use traits_type::compare
4094 2021-07-13 Jonathan Wakely <jwakely@redhat.com>
4096 * include/std/string_view: Only include <bits/ranges_base.h>
4097 once, and only for C++20 and later.
4099 2021-07-12 Jonathan Wakely <jwakely@redhat.com>
4102 * include/std/span (as_writable_bytes): Add requires-clause.
4103 * testsuite/23_containers/span/101411.cc: New test.
4105 2021-07-09 Matheus Castanho <msc@linux.ibm.com>
4107 * include/std/mutex (__lock_impl): Check
4108 _GLIBCXX_HAS_GTHREADS before using __gthread_yield.
4110 2021-07-02 Jonathan Wakely <jwakely@redhat.com>
4113 * include/bits/unique_ptr.h (unique_ptr<T[],D>::operator[]):
4114 Remove noexcept-specifier.
4115 (unique_ptr<T[],D>::_S_nothrow_deref): Remove.
4116 * testsuite/20_util/unique_ptr/lwg2762.cc: Remove checks for
4119 2021-07-01 Jonathan Wakely <jwakely@redhat.com>
4121 * doc/doxygen/doxygroups.cc: Fix docs for std::literals.
4122 * doc/doxygen/user.cfg.in: Exclude the Networking TS header.
4123 Add some more predefined macros.
4124 * include/bits/fs_fwd.h: Move @addtogroup commands inside
4125 namespaces. Add better documentation.
4126 * include/bits/fs_path.h: Likewise.
4127 * include/experimental/bits/fs_fwd.h: Likewise.
4128 * include/experimental/bits/fs_path.h: Likewise.
4129 * include/ext/throw_allocator.h: Fix typo and improve docs.
4130 * include/std/chrono: Move @addtogroup commands.
4131 * include/std/system_error: Move @addtogroup commands.
4132 * libsupc++/exception: Improve documentation.
4133 * libsupc++/exception.h: Add @since documentation.
4135 2021-06-30 Jonathan Wakely <jwakely@redhat.com>
4138 * doc/doxygen/user.cfg.in (INPUT): Add <experimental/simd>.
4139 (COLS_IN_ALPHA_INDEX): Remove obsolete tag.
4140 (PREDEFINED): Add/fix some more macros that need to be expanded.
4141 * include/bits/random.h: Stop Doxygen from documenting internal
4142 implementation details.
4143 * include/bits/random.tcc: Likewise.
4144 * include/bits/this_thread_sleep.h: Fix @file name.
4145 * include/experimental/bits/simd.h: Add to Doxygen group. Do not
4146 document internal implementation details.
4147 * include/experimental/bits/simd_detail.h: Do not document
4148 internal implementation details.
4149 * include/experimental/simd: Define Doxygen groups.
4150 * include/experimental/type_traits: Improve documentation for
4151 the header file. Define groups. Use @since commands.
4152 * include/std/scoped_allocator (scoped_allocator_adaptor): Move
4153 declaration before undocumented region.
4154 * include/std/type_traits (true_type, false_type): Use using
4155 declaration instead of typedef.
4156 (is_invocable_v, is_nothrow_invocable_v, is_invocable_r_v)
4157 (is_nothrow_invocable_r_v): Move definitions next to other C++17
4159 Do not document internal implementation details. Move misplaced
4160 group-end command. Define group for variable templates.
4161 * include/std/variant: Do not document internal implementation
4163 * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error
4166 2021-06-30 Jonathan Wakely <jwakely@redhat.com>
4168 * include/experimental/simd: Do not define anything pre-C++17.
4170 2021-06-30 Jonathan Wakely <jwakely@redhat.com>
4172 * include/bits/random.tcc [__cpp_inline_variables]: Remove
4173 redundant definitions of static constexpr member variables.
4174 * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error
4177 2021-06-28 Jonathan Wakely <jwakely@redhat.com>
4179 * include/bits/streambuf.tcc (__copy_streambufs_eof): Remove
4180 explicit instantiation declarations.
4181 * src/c++11/streambuf-inst.cc (__copy_streambufs_eof): Remove
4182 explicit instantiation definitions.
4184 2021-06-28 Jonathan Wakely <jwakely@redhat.com>
4187 * testsuite/17_intro/names.cc: Fix #if condition for names used
4190 2021-06-28 Jonathan Wakely <jwakely@redhat.com>
4193 * include/bits/unique_ptr.h (unique_ptr<T[], D>::operator[]):
4194 Fail gracefully if element_type is incomplete.
4195 * testsuite/20_util/unique_ptr/cons/incomplete.cc: Clarify that
4196 the standard doesn't require this test to work for array types.
4197 * testsuite/20_util/unique_ptr/lwg2762.cc: Check that incomplete
4198 types can be used with array specialization.
4199 * testsuite/20_util/unique_ptr/101236.cc: New test.
4201 2021-06-28 Jonathan Wakely <jwakely@redhat.com>
4203 * doc/xml/manual/intro.xml: Document LWG 415 change.
4204 * doc/html/manual/bugs.html: Regenerate.
4205 * include/bits/istream.tcc (ws): Create sentry and catch
4207 * testsuite/27_io/basic_istream/ws/char/lwg415.cc: New test.
4208 * testsuite/27_io/basic_istream/ws/wchar_t/lwg415.cc: New test.
4210 2021-06-25 Jonathan Wakely <jwakely@redhat.com>
4212 * include/bits/ostream.tcc (basic_ostream::write): Call sputn
4213 directly instead of using _M_write. Do setstate(__err) all
4214 outside the try-catch block.
4215 * include/std/ostream (basic_ostream::_M_write): Declare
4216 private. Use __ostream_insert. Do not define for the versioned
4219 2021-06-25 Jonathan Wakely <jwakely@redhat.com>
4221 * doc/xml/manual/intro.xml: Document LWG 581 change.
4222 * doc/html/manual/bugs.html: Regenerate.
4223 * include/bits/basic_ios.tcc: Whitespace.
4224 * include/bits/ostream.tcc (basic_ostream::flush()): Construct
4226 * testsuite/27_io/basic_ostream/flush/char/2.cc: Check
4228 * testsuite/27_io/basic_ostream/flush/char/exceptions_badbit_throw.cc:
4230 * testsuite/27_io/basic_ostream/flush/wchar_t/2.cc: Likewise.
4231 * testsuite/27_io/basic_ostream/flush/wchar_t/exceptions_badbit_throw.cc:
4234 2021-06-25 Jonathan Wakely <jwakely@redhat.com>
4236 * include/bits/ostream.tcc (sentry): Only set failbit if badbit
4237 is set, not if eofbit is set.
4238 (tellp, seekp, seekp): Create sentry object. Do not set badbit
4240 * testsuite/27_io/basic_ostream/seekp/char/exceptions_badbit_throw.cc:
4241 Adjust expected behaviour.
4242 * testsuite/27_io/basic_ostream/seekp/wchar_t/exceptions_badbit_throw.cc:
4244 * testsuite/27_io/basic_ostream/tellp/char/exceptions_badbit_throw.cc:
4246 * testsuite/27_io/basic_ostream/tellp/wchar_t/exceptions_badbit_throw.cc:
4248 * testsuite/27_io/basic_ostream/seekp/char/n3168.cc: New test.
4249 * testsuite/27_io/basic_ostream/seekp/wchar_t/n3168.cc: New test.
4250 * testsuite/27_io/basic_ostream/tellp/char/n3168.cc: New test.
4251 * testsuite/27_io/basic_ostream/tellp/wchar_t/n3168.cc: New test.
4253 2021-06-25 Jonathan Wakely <jwakely@redhat.com>
4255 * include/std/syncstream (basic_syncbuf::swap()): Remove
4256 noexcept, as per LWG 3498.
4258 2021-06-25 Jonathan Wakely <jwakely@redhat.com>
4261 * testsuite/17_intro/names.cc: Undef more names for newlib and
4262 also for arm-none-linux-gnueabi.
4263 * testsuite/experimental/names.cc: Disable PCH.
4265 2021-06-25 Matthias Kretz <m.kretz@gsi.de>
4267 * include/experimental/bits/simd.h (__bit_cast): Implement via
4268 __builtin_bit_cast #if available.
4269 (__proposed::simd_bit_cast): Add overloads for simd and
4270 simd_mask, which use __builtin_bit_cast (or __bit_cast #if not
4271 available), which return an object of the requested type with
4272 the same bits as the argument.
4273 * include/experimental/bits/simd_math.h: Use simd_bit_cast
4274 instead of __bit_cast to allow casts to fixed_size_simd.
4275 (copysign): Remove branch that was only required if __bit_cast
4276 cannot be constexpr.
4277 * testsuite/experimental/simd/tests/bits/test_values.h: Switch
4278 from __bit_cast to __proposed::simd_bit_cast since the former
4279 will not cast fixed_size objects anymore.
4281 2021-06-24 Matthias Kretz <m.kretz@gsi.de>
4283 * include/experimental/bits/simd_math.h
4284 (_GLIBCXX_SIMD_MATH_CALL2_): Rename arg2_ to __arg2.
4285 (_GLIBCXX_SIMD_MATH_CALL3_): Rename arg2_ to __arg2 and arg3_ to
4288 2021-06-24 Matthias Kretz <m.kretz@gsi.de>
4290 * include/experimental/bits/simd.h (__execute_on_index_sequence)
4291 (__execute_on_index_sequence_with_return)
4292 (__call_with_n_evaluations, __call_with_subscripts): Add flatten
4295 2021-06-24 Matthias Kretz <m.kretz@gsi.de>
4297 * include/experimental/bits/simd_x86.h (_S_trunc, _S_floor)
4298 (_S_ceil): Set bit 8 (_MM_FROUND_NO_EXC) on AVX and SSE4.1
4301 2021-06-24 Matthias Kretz <m.kretz@gsi.de>
4303 * include/experimental/bits/simd_x86.h (_S_ldexp): The AVX512F
4304 implementation doesn't require a _VecBltnBtmsk ABI tag, it
4305 requires either a 64-Byte input (in which case AVX512F must be
4306 available) or AVX512VL.
4308 2021-06-24 Matthias Kretz <m.kretz@gsi.de>
4310 * include/experimental/bits/simd_math.h: Undefine internal
4312 (frexp): Move #if to a more sensible position and reformat
4314 (logb): Call _SimdImpl::_S_logb for fixed_size instead of
4315 duplicating the code here.
4316 (modf): Simplify condition.
4318 2021-06-24 Matthias Kretz <m.kretz@gsi.de>
4320 * include/experimental/bits/simd_math.h (fabs): Remove
4321 fabs(simd<integral>) overload.
4323 2021-06-24 Matthias Kretz <m.kretz@gsi.de>
4325 * include/experimental/bits/simd_converter.h
4326 (_SimdConverter::operator()): Pass _SimdTuple by const-ref.
4327 * include/experimental/bits/simd_fixed_size.h
4328 (_GLIBCXX_SIMD_FIXED_OP): Pass binary operator _SimdTuple
4329 arguments by const-ref.
4330 (_S_masked_unary): Pass _SimdTuple by const-ref.
4332 2021-06-24 Matthias Kretz <m.kretz@gsi.de>
4334 * include/experimental/bits/simd_fixed_size.h
4335 (_AbisInSimdTuple): Removed.
4337 2021-06-24 Matthias Kretz <m.kretz@gsi.de>
4339 * include/experimental/bits/simd.h: Add missing operator~
4340 overload for simd<floating-point> to __float_bitwise_operators.
4341 * include/experimental/bits/simd_builtin.h
4342 (_SimdImplBuiltin::_S_complement): Bitcast to int (and back) to
4343 implement complement for floating-point vectors.
4344 * include/experimental/bits/simd_fixed_size.h
4345 (_SimdImplFixedSize::_S_copysign): New function, forwarding to
4346 copysign implementation of _SimdTuple members.
4347 * include/experimental/bits/simd_math.h (copysign): Call
4348 _SimdImpl::_S_copysign for fixed_size arguments. Simplify
4349 generic copysign implementation using the new ~ operator.
4351 2021-06-24 Jonathan Wakely <jwakely@redhat.com>
4353 * testsuite/experimental/simd/README.md: Fix typos.
4355 2021-06-24 Jonathan Wakely <jwakely@redhat.com>
4357 * include/bits/shared_ptr_base.h (__shared_ptr_access::operator[]):
4359 * include/bits/unique_ptr.h (unique_ptr::operator*): Add
4360 conditional noexcept as per LWG 2762.
4361 * testsuite/20_util/shared_ptr/observers/array.cc: Check that
4362 dereferencing cannot throw.
4363 * testsuite/20_util/shared_ptr/observers/get.cc: Likewise.
4364 * testsuite/20_util/optional/observers/lwg2762.cc: New test.
4365 * testsuite/20_util/unique_ptr/lwg2762.cc: New test.
4367 2021-06-23 Patrick Palka <ppalka@redhat.com>
4370 * testsuite/23_containers/multiset/cons/deduction.cc:
4371 Uncomment CTAD example that was rejected by this bug.
4372 * testsuite/23_containers/set/cons/deduction.cc: Likewise.
4374 2021-06-23 Jonathan Wakely <jwakely@redhat.com>
4376 * include/std/chrono (chrono::year::is_leap()): Fix incorrect
4379 2021-06-23 Matthias Kretz <m.kretz@gsi.de>
4381 * testsuite/experimental/simd/README.md: New file.
4383 2021-06-23 Matthias Kretz <m.kretz@gsi.de>
4385 * testsuite/experimental/simd/driver.sh: Rewrite output
4386 verbosity logic. Add -p/--percentage option. Allow -v/--verbose
4387 to be used twice. Add -x and -o short options. Parse long
4388 options with = instead of separating space generically. Parce
4389 contracted short options. Make unrecognized options an error.
4390 If same-line output is active, trap on EXIT to increment the
4391 progress (only with --percentage), erase the line and print the
4393 * testsuite/experimental/simd/generate_makefile.sh: Initialize
4394 helper files for progress account keeping. Update help target
4395 for changes to DRIVEROPTS.
4397 2021-06-23 Matthias Kretz <m.kretz@gsi.de>
4399 * testsuite/Makefile.am (check-simd): Remove -fno-tree-vrp flag
4400 and associated warning.
4401 * testsuite/Makefile.in: Regenerate.
4403 2021-06-23 Cassio Neri <cassio.neri@gmail.com>
4404 Jonathan Wakely <jwakely@redhat.com>
4405 Ulrich Drepper <drepper@redhat.com>
4407 * include/std/chrono (chrono::year::is_leap()): Optimize.
4409 2021-06-23 Patrick Palka <ppalka@redhat.com>
4412 * testsuite/23_containers/map/cons/deduction.cc: Replace ambiguous
4414 * testsuite/23_containers/multimap/cons/deduction.cc: Likewise.
4415 * testsuite/23_containers/multiset/cons/deduction.cc: Likewise.
4416 Mention one of the replaced examples is broken due to PR101174.
4417 * testsuite/23_containers/set/cons/deduction.cc: Likewise.
4418 * testsuite/23_containers/unordered_map/cons/deduction.cc: Replace
4419 ambiguous CTAD examples.
4420 * testsuite/23_containers/unordered_multimap/cons/deduction.cc:
4422 * testsuite/23_containers/unordered_multiset/cons/deduction.cc:
4424 * testsuite/23_containers/unordered_set/cons/deduction.cc: Likewise.
4426 2021-06-23 Jonathan Wakely <jwakely@redhat.com>
4428 * include/std/mutex (__detail::__try_lock_impl): Rename
4429 parameter to avoid clashing with newlib's __lockable macro.
4430 (try_lock): Add 'inline' specifier.
4431 * testsuite/17_intro/names.cc: Add check for __lockable.
4432 * testsuite/30_threads/try_lock/5.cc: Add options for pthreads.
4434 2021-06-22 Jonathan Wakely <jwakely@redhat.com>
4435 Matthias Kretz <m.kretz@gsi.de>
4437 * include/std/mutex (lock): Replace recursion with iteration
4438 when lockables all have the same type.
4439 (__detail::__try_lock_impl): Likewise. Pass lockables as
4440 parameters, instead of a tuple. Always lock the first one, and
4441 recurse for the rest.
4442 (__detail::__lock_impl): Adjust call to __try_lock_impl.
4443 (__detail::__try_to_lock): Remove.
4444 * testsuite/30_threads/lock/3.cc: Check that mutexes are locked.
4445 * testsuite/30_threads/lock/4.cc: Also test non-heterogeneous
4447 * testsuite/30_threads/unique_lock/cons/60497.cc: Also check
4449 * testsuite/30_threads/try_lock/5.cc: New test.
4451 2021-06-22 Jonathan Wakely <jwakely@redhat.com>
4453 * include/std/memory (declare_reachable, undeclare_reachable)
4454 (declare_no_pointers, undeclare_no_pointers, get_pointer_safety)
4455 (pointer_safety): Only define for C++11 to C++20 inclusive.
4456 * testsuite/20_util/pointer_safety/1.cc: Do not run for C++23.
4458 2021-06-22 Jonathan Wakely <jwakely@redhat.com>
4460 * include/bits/random.h (seed_seq): Constrain initializer-list
4462 * include/bits/random.tcc (seed_seq): Add template parameter.
4463 * testsuite/26_numerics/random/seed_seq/cons/default.cc: Check
4465 * testsuite/26_numerics/random/seed_seq/cons/initlist.cc: Check
4468 2021-06-22 Thomas Rodgers <rodgert@appliantology.com>
4471 * include/bits/semaphore_base.h (__atomic_semaphore::_M_release):
4472 Force _M_release() to wake all waiting threads.
4473 * testsuite/30_threads/semaphore/100806.cc: New test.
4475 2021-06-21 Jonathan Wakely <jwakely@redhat.com>
4477 * include/std/mutex (__try_to_lock): Move to __detail namespace.
4478 (struct __try_lock_impl): Replace with ...
4479 (__detail::__try_lock_impl<Idx>(tuple<Lockables...>&)): New
4480 function templates to implement std::try_lock.
4481 (try_lock): Use new __try_lock_impl.
4482 (__detail::__lock_impl(int, int&, L0&, L1&...)): New function
4483 template to implement std::lock.
4484 (lock): Use __lock_impl.
4486 2021-06-21 Patrick Palka <ppalka@redhat.com>
4488 * include/bits/ranges_cmp.h (__cpp_lib_ranges): Adjust value.
4490 2021-06-20 Patrick Palka <ppalka@redhat.com>
4492 * include/std/ranges (__non_propagating_cache::operator bool):
4493 Define for split_view::begin().
4494 (split_view): Define as per P2210.
4495 (views::__detail::__can_split_view): Define.
4496 (views::_Split, views::split): Define.
4497 * testsuite/std/ranges/adaptors/100577.cc (test01, test02):
4499 * testsuite/std/ranges/adaptors/split.cc: New test.
4500 * testsuite/std/ranges/p2325.cc (test08a): New test.
4501 * testsuite/std/ranges/p2367.cc (test01): Test views::split.
4503 2021-06-20 Patrick Palka <ppalka@redhat.com>
4505 * include/std/ranges: Rename views::split to views::lazy_split,
4506 split_view to lazy_split_view, etc. throughout.
4507 * testsuite/std/ranges/*: Likewise.
4508 * testsuite/std/ranges/adaptors/lazy_split.cc: New file.
4509 * testsuite/std/ranges/adaptors/lazy_split_neg.cc: New file.
4511 2021-06-20 Patrick Palka <ppalka@redhat.com>
4513 * include/std/ranges (split_view::_OuterIter::__at_end):
4514 Check _M_trailing_empty.
4515 (split_view::_OuterIter::_M_trailing_empty): Define this
4517 (split_view::_OuterIter::operator++): Set _M_trailing_empty
4519 (split_view::_OuterIter::operator==): Compare
4521 * testsuite/std/ranges/adaptors/100479.cc (test03): Expect two
4522 split parts instead of one.
4523 * testsuite/std/ranges/adaptors/split.cc (test11): New test.
4525 2021-06-20 Patrick Palka <ppalka@redhat.com>
4527 * include/std/ranges (split_view::_InnerIter::base): Define as
4530 2021-06-19 Patrick Palka <ppalka@redhat.com>
4532 * include/std/ranges (transform_view::_Iterator::_S_iter_concept):
4533 Consider _Base instead of _Vp as per LWG 3555.
4534 (elements_view::_Iterator::_S_iter_concept): Likewise.
4536 2021-06-19 Patrick Palka <ppalka@redhat.com>
4538 * include/std/ranges (split_view::_OuterIter::value_type::begin):
4539 Remove the non-const overload, and remove the copyable constraint
4540 on the const overload as per LWG 3553.
4542 2021-06-19 Patrick Palka <ppalka@redhat.com>
4544 * include/bits/stl_iterator.h
4545 (__detail::__common_iter_use_postfix_proxy): Add
4546 move_constructible constraint as per LWG 3546.
4547 (common_iterator::__postfix_proxy): Adjust initializer of
4548 _M_keep as per LWG 3546.
4550 2021-06-18 Patrick Palka <ppalka@redhat.com>
4553 * include/bits/ranges_algo.h (__minmax_fn::operator()): Rewrite
4554 to limit comparison complexity to 3*N/2.
4555 (__minmax_element_fn::operator()): Likewise.
4556 (shift_right): Avoid premature std::move of __result.
4557 * testsuite/25_algorithms/minmax/constrained.cc (test04, test05):
4559 * testsuite/25_algorithms/minmax_element/constrained.cc (test02):
4562 2021-06-18 Patrick Palka <ppalka@redhat.com>
4564 * include/std/concepts (convertible_to): Just use declval as per
4567 2021-06-18 Jonathan Wakely <jwakely@redhat.com>
4570 * include/std/numeric (reduce(Iter, Iter, T, BinaryOp)): Replace
4571 incorrect static_assert with ones matching the 'Mandates'
4572 conditions in the standard.
4573 * testsuite/26_numerics/reduce/95833.cc: New test.
4575 2021-06-18 Jonathan Wakely <jwakely@redhat.com>
4577 * testsuite/21_strings/basic_string/cons/char/1.cc: Use
4578 diagnostic pragma to suppress -Wstringop-overread error.
4580 2021-06-18 Patrick Palka <ppalka@redhat.com>
4582 * include/bits/ranges_algo.h (__find_fn, find, __find_if_fn)
4583 (find_if, __find_if_not_fn, find_if_not, _in_in_result)
4584 (__mismatch_fn, mismatch, __search_fn, search): Move to ...
4585 * include/bits/ranges_util.h: ... here.
4586 * include/std/ranges (__detail::find, __detail::find_if)
4587 (__detail::find_if_not, __detail::mismatch): Remove.
4588 (filter_view): Use ranges::find_if instead.
4589 (drop_while_view): Use ranges::find_if_not instead.
4590 (split_view): Use ranges::find and ranges::mismatch instead.
4592 2021-06-18 Patrick Palka <ppalka@redhat.com>
4594 * include/bits/iterator_concepts.h (weakly_incrementable): Remove
4595 default_initializable requirement.
4596 * include/bits/ranges_base.h (ranges::view): Likewise.
4597 * include/bits/ranges_util.h (subrange): Constrain the default
4599 * include/bits/stl_iterator.h (back_insert_iterator): Remove the
4601 (front_insert_iterator): Likewise.
4602 (insert_iterator): Likewise. Remove NSDMIs.
4603 (common_iterator): Constrain the default ctor.
4604 (counted_iterator): Likewise.
4605 * include/bits/stream_iterator.h (ostream_iterator): Remove the
4607 * include/std/ranges (__detail::__box::operator=): Handle
4608 self-assignment in the primary template.
4609 (__detail::__box): In the partial specialization: adjust
4610 constraints as per P2325. Add specialized operator= for the
4611 case when the wrapped type is not copyable. Constrain the
4612 default ctor. Avoid list-initialization.
4613 (single_view): Constraint the default ctor.
4614 (iota_view): Relax semiregular constraint to copyable.
4615 Constrain the default ctor.
4616 (iota_view::_Iterator): Constraint the default ctor.
4617 (basic_istream_view): Remove the default ctor. Remove NSDMIs.
4618 Remove redundant checks for empty _M_stream.
4619 (basic_istream_view::_Iterator): Likewise.
4620 (ref_view): Remove the default ctor. Remove NSDMIs.
4621 (ref_view::_Iterator): Constrain the default ctor.
4622 (__detail::__non_propagating_cache::operator=): Define overload
4623 for assigning from a value of the underlying type.
4624 (filter_view): Likewise.
4625 (filter_view::_Iterator): Likewise.
4626 (transform_view): Likewise.
4627 (transform_view::_Iterator): Likewise.
4628 (take_view): Likewise.
4629 (take_view::_Iterator): Likewise.
4630 (take_while_view): Likewise.
4631 (take_while_view::_Iterator): Likewise.
4632 (drop_while_view): Likewise.
4633 (drop_while_view::_Iterator): Likewise.
4634 (join_view): Likewise.
4635 (split_view::_OuterIter::__current): Adjust after changing the
4637 (split_view::_M_current): Wrap it in a __non_propagating_cache.
4638 (split_view::split_view): Constrain the default ctor.
4639 (common_view): Constrain the default ctor.
4640 (reverse_view): Likewise.
4641 (elements_view): Likewise.
4642 * include/std/span (enable_view<span<_ElementType, _Extent>>):
4643 Define this partial specialization to true unconditionally.
4644 * include/std/version (__cpp_lib_ranges): Adjust value.
4645 * testsuite/24_iterators/back_insert_iterator/constexpr.cc:
4646 Don't attempt to default construct a back_insert_iterator.
4647 * testsuite/24_iterators/front_insert_iterator/constexpr.cc:
4648 Don't attempt to default construct a front_insert_iterator.
4649 * testsuite/24_iterators/insert_iterator/constexpr.cc:
4650 Don't attempt to default construct an insert_iterator.
4651 * testsuite/24_iterators/ostream_iterator/requirements/constexpr.cc:
4652 Remove this test for default constructibility of ostream_iterator.
4653 * testsuite/std/ranges/97600.cc: Don't attempt to default
4654 construct a basic_istream_view.
4655 * testsuite/std/ranges/adaptors/detail/semiregular_box.cc:
4657 * testsuite/std/ranges/adaptors/detail/copyable_box.cc: ... this.
4658 (test02): Adjust now that __box is copyable-box not
4661 * testsuite/std/ranges/p2325.cc: New test.
4662 * testsuite/std/ranges/single_view.cc (test06): New test.
4663 * testsuite/std/ranges/view.cc: Adjust now that view doesn't
4664 require default_initializable.
4666 2021-06-17 Jonathan Wakely <jwakely@redhat.com>
4669 * include/bits/basic_string.h (__cpp_lib_constexpr_string): Only
4670 define when is_constant_evaluated is available.
4671 * include/bits/char_traits.h (__cpp_lib_constexpr_char_traits):
4673 (__constant_string_p, __constant_array_p): Remove.
4674 (char_traits): Use is_constant_evaluated directly.
4675 * include/std/version (__cpp_lib_constexpr_char_traits)
4676 (__cpp_lib_constexpr_string): Only define when
4677 is_constant_evaluated is available.
4679 2021-06-17 Patrick Palka <ppalka@redhat.com>
4682 * include/std/ranges (__adaptor::_Partial): For the "simple"
4683 forwarding partial specializations, also require that
4684 the extra arguments are trivially copyable.
4685 * testsuite/std/ranges/adaptors/100577.cc (test04): New test.
4687 2021-06-17 Patrick Palka <ppalka@redhat.com>
4690 * include/std/ranges (__adaptor::_RangeAdaptor): Document the
4691 template form of _S_has_simple_extra_args.
4692 (__adaptor::__adaptor_has_simple_extra_args): Add _Args template
4693 parameter pack. Try to treat _S_has_simple_extra_args as a
4694 variable template parameterized by _Args.
4695 (__adaptor::_Partial): Pass _Arg/_Args to the constraint
4696 __adaptor_has_simple_extra_args.
4697 (views::_Take::_S_has_simple_extra_args): Templatize according
4698 to the type of the extra argument.
4699 (views::_Drop::_S_has_simple_extra_args): Likewise.
4700 (views::_Split::_S_has_simple_extra_args): Define.
4701 * testsuite/std/ranges/adaptors/100577.cc (test01, test02):
4702 Adjust after changes to _S_has_simple_extra_args mechanism.
4705 2021-06-16 Jonathan Wakely <jwakely@redhat.com>
4707 * include/bits/iterator_concepts.h (__decay_copy): Name type.
4709 2021-06-16 Jonathan Wakely <jwakely@redhat.com>
4711 * include/bits/ranges_base.h (ranges::begin, ranges::end)
4712 (ranges::cbegin, ranges::cend, ranges::rbeing, ranges::rend)
4713 (ranges::crbegin, ranges::crend, ranges::size, ranges::ssize)
4714 (ranges::empty, ranges::data, ranges::cdata): Remove final
4715 keywords and deleted operator& overloads.
4716 * testsuite/24_iterators/customization_points/iter_move.cc: Use
4717 new is_customization_point_object function.
4718 * testsuite/24_iterators/customization_points/iter_swap.cc:
4720 * testsuite/std/concepts/concepts.lang/concept.swappable/swap.cc:
4722 * testsuite/std/ranges/access/begin.cc: Likewise.
4723 * testsuite/std/ranges/access/cbegin.cc: Likewise.
4724 * testsuite/std/ranges/access/cdata.cc: Likewise.
4725 * testsuite/std/ranges/access/cend.cc: Likewise.
4726 * testsuite/std/ranges/access/crbegin.cc: Likewise.
4727 * testsuite/std/ranges/access/crend.cc: Likewise.
4728 * testsuite/std/ranges/access/data.cc: Likewise.
4729 * testsuite/std/ranges/access/empty.cc: Likewise.
4730 * testsuite/std/ranges/access/end.cc: Likewise.
4731 * testsuite/std/ranges/access/rbegin.cc: Likewise.
4732 * testsuite/std/ranges/access/rend.cc: Likewise.
4733 * testsuite/std/ranges/access/size.cc: Likewise.
4734 * testsuite/std/ranges/access/ssize.cc: Likewise.
4735 * testsuite/util/testsuite_iterators.h
4736 (is_customization_point_object): New function.
4738 2021-06-15 Jonathan Wakely <jwakely@redhat.com>
4740 * include/bits/ranges_base.h (ranges::begin, ranges::end)
4741 (ranges::cbegin, ranges::cend, ranges::rbeing, ranges::rend)
4742 (ranges::crbegin, ranges::crend, ranges::size, ranges::ssize)
4743 (ranges::empty, ranges::data, ranges::cdata): Make types final.
4744 Add deleted operator& overloads.
4745 (ranges::advance, ranges::distance, ranges::next, ranges::prev):
4747 * testsuite/std/ranges/headers/ranges/synopsis.cc: Replace
4748 ill-formed & expressions with using-declarations. Add checks for
4749 other function objects.
4751 2021-06-15 Jonathan Wakely <jwakely@redhat.com>
4753 * include/bits/ranges_util.h (view_interface): Add noexcept to
4754 empty, operator bool, data and size members.
4755 (subrange): Add noexcept to constructors.
4756 * include/std/ranges (single_view, ref_view): Add noexcept to
4758 (views::single, views::all): Add noexcept.
4759 * testsuite/std/ranges/adaptors/all.cc: Check noexcept.
4760 * testsuite/std/ranges/single_view.cc: Likewise.
4762 2021-06-15 Jonathan Wakely <jwakely@redhat.com>
4764 * include/bits/ranges_util.h (subrange): Add __size_type typedef
4765 and use it to simplify declarations.
4766 (subrange(i, s, n)): Remove assertion.
4767 * testsuite/std/ranges/subrange/constexpr.cc: New test.
4769 2021-06-15 Jonathan Wakely <jwakely@redhat.com>
4771 * include/bits/iterator_concepts.h (__cust_access::__decay_copy):
4772 Replace with function object.
4773 (__cust_access::__member_begin, ___cust_access::_adl_begin): Use
4774 __decay_copy unqualified.
4775 * include/bits/ranges_base.h (__member_end, __adl_end):
4776 Likewise. Use __range_iter_t for type of ranges::begin.
4777 (__member_rend): Use correct value category for rbegin argument.
4778 (__member_data): Use __decay_copy unqualified.
4779 (__begin_data): Use __range_iter_t for type of ranges::begin.
4781 2021-06-14 Jonathan Wakely <jwakely@redhat.com>
4783 * include/bits/ranges_base.h (ranges::empty): Check whether
4784 conversion to bool can throw.
4785 * testsuite/std/ranges/access/empty.cc: Check for correct
4788 2021-06-14 Jonathan Wakely <jwakely@redhat.com>
4791 * include/std/type_traits (__common_ref_impl<X&, Y&>): Only
4792 use the type if it's a reference.
4793 * testsuite/20_util/common_reference/100894.cc: New test.
4795 2021-06-14 Jonathan Wakely <jwakely@redhat.com>
4797 * testsuite/experimental/filesystem/path/native/conv_c++23.cc:
4798 Add dg-require-filesystem-ts directive.
4800 2021-06-14 Jonathan Wakely <jwakely@redhat.com>
4803 * include/std/any (any(in_place_t<T>, initializer_list<U>, A&&...))
4804 (any::emplace<T>(initializer_list<U>, A&&...)): Fix constraint
4806 * testsuite/20_util/any/cons/101034.cc: New test.
4808 2021-06-14 Jonathan Wakely <jwakely@redhat.com>
4810 * testsuite/17_intro/headers/c++2017/all_attributes.cc: Add
4811 -std=gnu++17 option.
4813 2021-06-14 Jonathan Wakely <jwakely@redhat.com>
4816 * libsupc++/compare (compare_partial_order_fallback): Add
4817 constraint using reversed parameter order, as per LWG 3465.
4818 * testsuite/18_support/comparisons/algorithms/fallback.cc:
4819 Adjust expected result.
4821 2021-06-14 Jonathan Wakely <jwakely@redhat.com>
4823 * libsupc++/compare (__decayed_same_as): New helper concept.
4824 (strong_order, weak_order, partial_order): Constrain with new
4825 concept instead of using static_assert.
4826 (compare_strong_order_fallback, compare_weak_order_fallback)
4827 (compare_partial_order_fallback): Likewise. Do not deduce return
4828 types. Remove redundant if-constexpr checks.
4829 * testsuite/18_support/comparisons/algorithms/fallback.cc: New test.
4831 2021-06-14 Jonathan Wakely <jwakely@redhat.com>
4834 * include/std/tuple: Use reserved form of attribute name.
4835 * testsuite/17_intro/headers/c++2011/all_attributes.cc: Add
4836 check for no_unique_address.
4837 * testsuite/17_intro/headers/c++2014/all_attributes.cc:
4839 * testsuite/17_intro/headers/c++2017/all_attributes.cc:
4842 2021-06-11 Jonathan Wakely <jwakely@redhat.com>
4844 * include/bits/fs_path.h (operator==, operator<=>): Use new
4845 _S_compare function.
4846 (path::_S_compare): New function to call path::compare in a
4847 context where path::iterator is complete.
4848 * include/experimental/bits/fs_path.h (operator<, operator==):
4849 Define after path::iterator is complete.
4850 * testsuite/27_io/filesystem/path/native/conv_c++23.cc: New
4852 * testsuite/experimental/filesystem/path/native/conv_c++23.cc:
4855 2021-06-09 Thomas Rodgers <rodgert@appliantology.com>
4857 * testsuite/29_atomics/atomic_ref/wait_notify.cc: Guard
4858 test logic with constexpr check for is_always_lock_free.
4860 2021-06-09 Jonathan Wakely <jwakely@redhat.com>
4863 * include/std/optional (optional::operator=(const optional<U>&)):
4864 Fix value category used in is_assignable check.
4865 * testsuite/20_util/optional/assignment/100982.cc: New test.
4867 2021-06-09 Jonathan Wakely <jwakely@redhat.com>
4869 * include/bits/allocator.h (allocator::is_always_equal): Deprecate.
4870 * include/bits/iterator_concepts.h (indirectly_readable_traits):
4871 Add LWG issue number to comment.
4872 * include/std/memory_resource (polymorphic_allocator::release):
4874 * testsuite/20_util/allocator/requirements/typedefs.cc: Add
4875 dg-warning for deprecation. Also check std::allocator<void>.
4877 2021-06-08 Thomas Rodgers <rodgert@appliantology.com>
4880 * include/bits/atomic_base.h (atomic_ref<_Tp*>::wait):
4881 Change parameter type from _Tp to _Tp*.
4882 * testsuite/29_atomics/atomic_ref/wait_notify.cc: Extend
4883 coverage of types tested.
4885 2021-06-08 Thomas Rodgers <rodgert@appliantology.com>
4887 * include/std/barrier (__tree_barrier::_M_arrive): Remove
4888 unnecessary hasher instantiation.
4890 2021-06-08 Jonathan Wakely <jwakely@redhat.com>
4892 * include/experimental/propagate_const (swap): Constrain.
4893 * testsuite/experimental/propagate_const/swap/lwg3413.cc: New test.
4895 2021-06-07 Avi Kivity <avi@scylladb.com>
4898 * include/std/ranges (elements_view::__iter_cat::_S_iter_cat):
4899 Add missing typename.
4901 2021-06-07 Jonathan Wakely <jwakely@redhat.com>
4904 * include/std/optional (operator<=>(const optional<T>& const U&)):
4905 Add missing constraint and add workaround for template
4907 * testsuite/20_util/optional/relops/three_way.cc: Check that
4908 type without equality comparison cannot be compared when wrapped
4911 2021-06-05 Jonathan Wakely <jwakely@redhat.com>
4914 * include/bits/ranges_base.h (_SSize): Return signed type.
4915 * testsuite/std/ranges/access/ssize.cc: Check with __int128.
4917 2021-06-04 Jonathan Wakely <jwakely@redhat.com>
4919 * include/bits/ranges_base.h (_SSize): Return the result of
4920 ranges::size converted to the wider of make-signed-like-t<S> and
4921 ptrdiff_t, rather than the ranges different type.
4922 * testsuite/std/ranges/access/ssize.cc: Adjust expected result
4923 for an iota_view that uses an integer class type for its
4926 2021-06-04 Jonathan Wakely <jwakely@redhat.com>
4929 * include/bits/ranges_base.h (__member_data): Use __decay_copy.
4930 * testsuite/std/ranges/access/data.cc: Add testcase from PR.
4932 2021-06-04 Jonathan Wakely <jwakely@redhat.com>
4935 * include/bits/iterator_concepts.h (__detail::__decay_copy)
4936 (__detail::__member_begin, __detail::__adl_begin): Move to
4937 namespace ranges::__cust_access.
4938 (__detail::__ranges_begin): Likewise, and rename to __begin.
4939 Remove redundant static assertion.
4940 * include/bits/ranges_base.h (_Begin, _End, _RBegin, _REnd):
4941 Use lvalue in noexcept specifier.
4942 (__as_const): Add non-deduced parameter for value category.
4943 (_CBegin, _CEnd, _CRBegin, _CREnd, _CData): Adjust uses of
4945 (__member_size, __adl_size, __member_empty, __size0_empty):
4946 (__eq_iter_empty, __adl_data): Use lvalue objects in
4948 (__sentinel_size): Likewise. Add check for conversion to
4950 (__member_data): Allow non-lvalue types to satisfy the concept,
4951 but use lvalue object in requirements.
4952 (_Size, _SSize): Remove forwarding to always use an lvalue.
4953 (_Data): Likewise. Add static assertion for arrays.
4954 * testsuite/std/ranges/access/cdata.cc: Adjust expected
4955 behaviour for rvalues. Add negative tests for ill-formed
4957 * testsuite/std/ranges/access/data.cc: Likewise.
4958 * testsuite/std/ranges/access/empty.cc: Adjust expected
4959 behaviour for rvalues.
4960 * testsuite/std/ranges/access/size.cc: Likewise.
4962 2021-06-04 Tim Adye <Tim.Adye@cern.ch>
4964 * include/std/any (any::_Manager::_S_access): New static
4965 function to access the contained value.
4966 (any::emplace, __any_caster): Use _S_access member of the
4969 2021-06-04 Jonathan Wakely <jwakely@redhat.com>
4971 * doc/xml/manual/status_cxx2020.xml:
4972 * doc/html/*: Regenerate.
4973 * include/bits/hashtable.h (__cpp_lib_generic_unordered_lookup):
4975 * include/std/version (__cpp_lib_generic_unordered_lookup):
4977 * testsuite/23_containers/unordered_map/operations/1.cc: Check
4979 * testsuite/23_containers/unordered_set/operations/1.cc:
4982 2021-06-03 Patrick Palka <ppalka@redhat.com>
4984 * include/bits/ranges_algo.h (__detail::__can_reread_output):
4985 Factor out this concept from ...
4986 (__unique_copy_fn::operator()): ... here. Use the concept
4988 * testsuite/std/ranges/range.cc: Remove now ill-formed use
4989 of range_value_t on an output_range.
4990 * testsuite/util/testsuite_iterators.h (output_iterator_wrapper):
4991 Define value_type, pointer and reference member types to void.
4993 2021-06-03 Patrick Palka <ppalka@redhat.com>
4996 * include/std/ranges (_RangeAdaptorClosure): Document
4997 _S_has_simple_call_op mechanism.
4998 (_RangeAdaptor): Document _S_has_simple_extra_args mechanism.
4999 (__closure_has_simple_call_op): New concept.
5000 (__adaptor_has_simple_extra_args): Likewise.
5001 (_Partial<_Adaptor, _Args...>): New partial specialization.
5002 (_Partial<_Adaptor, _Arg>): Likewise.
5003 (_Pipe<_Lhs, _Rhs>): Likewise.
5004 (views::_All::_S_has_simple_call_op): Define to true.
5005 (views::_Filter::_S_has_simple_extra_args): Likewise.
5006 (views::_Transform::_S_has_simple_extra_args): Likewise.
5007 (views::_Take::_S_has_simple_extra_args): Likewise.
5008 (views::_TakeWhile::_S_has_simple_extra_args): Likewise.
5009 (views::_Drop::_S_has_simple_extra_args): Likewise.
5010 (views::_DropWhile::_S_has_simple_extra_args): Likewise.
5011 (views::_Join::_S_has_simple_call_op): Likewise.
5012 (views::_Split): Document why we don't define
5013 _S_has_simple_extra_args to true for this adaptor.
5014 (views::_Common::_S_has_simple_call_op): Define to true.
5015 (views::_Reverse::_S_has_simple_call_op): Likewise.
5016 (views::_Elements::_S_has_simple_call_op): Likewise.
5017 * testsuite/std/ranges/adaptors/100577.cc: New test.
5019 2021-06-02 Jonathan Wakely <jwakely@redhat.com>
5023 * include/bits/hashtable_policy.h (_Hashtable_ebo_helper):
5024 Value-initialize subobject.
5025 * testsuite/23_containers/unordered_map/allocator/default_init.cc:
5027 * testsuite/23_containers/unordered_set/allocator/default_init.cc:
5030 2021-06-02 Jonathan Wakely <jwakely@redhat.com>
5033 * testsuite/23_containers/unordered_map/96088.cc: Adjust
5034 expected number of allocations.
5035 * testsuite/23_containers/unordered_set/96088.cc: Likewise.
5037 2021-06-02 Jonathan Wakely <jwakely@redhat.com>
5039 * doc/xml/manual/status_cxxis29124.xml: Improve punctuation.
5040 * doc/xml/manual/status_cxxtr1.xml: Likewise.
5041 * doc/xml/manual/status_cxxtr24733.xml: Likewise.
5042 * doc/html/*: Regenerate.
5044 2021-06-01 Patrick Palka <ppalka@redhat.com>
5047 * testsuite/23_containers/deque/allocator/default_init.cc,
5048 testsuite/23_containers/forward_list/allocator/default_init.cc,
5049 testsuite/23_containers/list/allocator/default_init.cc,
5050 testsuite/23_containers/map/allocator/default_init.cc,
5051 testsuite/23_containers/set/allocator/default_init.cc,
5052 testsuite/23_containers/vector/allocator/default_init.cc,
5053 testsuite/23_containers/vector/bool/allocator/default_init.cc:
5056 2021-06-01 Jonathan Wakely <jwakely@redhat.com>
5058 * testsuite/23_containers/unordered_map/96088.cc: Change
5059 effective target to c++17.
5060 * testsuite/23_containers/unordered_set/96088.cc: Likewise.
5062 2021-06-01 Jonathan Wakely <jwakely@redhat.com>
5064 * testsuite/22_locale/ctype/is/string/89728_neg.cc: Only test
5065 isblank for C++11 and later.
5067 2021-06-01 Jonathan Wakely <jwakely@redhat.com>
5070 * include/bits/ranges_base.h (ranges::advance(iter, n, sentinel)):
5071 Fix return value for no-op case.
5072 * testsuite/24_iterators/range_operations/advance.cc: Test
5073 return values of three-argument overload.
5075 2021-06-01 Jonathan Wakely <jwakely@redhat.com>
5078 * python/Makefile.am: Use archive name for printer hook if no
5079 dynamic library name is available.
5080 * python/Makefile.in: Regenerate.
5082 2021-05-30 Gerald Pfeifer <gerald@pfeifer.com>
5084 * doc/xml/manual/abi.xml: Remove dead reference to "Intel
5085 Compilers for Linux: Compatibility with GNU Compilers" article.
5086 * doc/html/manual/abi.html: Regenerate.
5088 2021-05-26 François Dumont <fdumont@gcc.gnu.org>
5090 * include/debug/formatter.h
5091 (_Error_formatter::_Parameter::_Named): New.
5092 (_Error_formatter::_Parameter::_Type): Inherit latter.
5093 (_Error_formatter::_Parameter::_M_integer): Likewise.
5094 (_Error_formatter::_Parameter::_M_string): Likewise.
5095 * src/c++11/debug.cc: Include <cstring>.
5096 (_Print_func_t): New.
5097 (print_raw(PrintContext&, const char*, ptrdiff_t)): New.
5098 (print_word): Use '%.*s' format in fprintf to render only expected number of chars.
5099 (pretty_print(PrintContext&, const char*, _Print_func_t)): New.
5100 (print_type): Rename in...
5101 (print_type_info): ...this. Use pretty_print.
5102 (print_address, print_integer): New.
5103 (print_named_name, print_iterator_constness, print_iterator_state): New.
5104 (print_iterator_seq_type): New.
5105 (print_named_field, print_type_field, print_instance_field, print_iterator_field): New.
5106 (print_field): Use latters.
5107 (print_quoted_named_name, print_type_type, print_type, print_instance): New.
5108 (print_string(PrintContext&, const char*, const _Parameter*, size_t)):
5109 Change signature to...
5110 (print_string(PrintContext&, const char*, ptrdiff_t, const _Parameter*, size_t)):
5111 ...this and adapt. Remove intermediate buffer to render input string.
5112 (print_string(PrintContext&, const char*, ptrdiff_t)): New.
5114 2021-05-26 Jonathan Wakely <jwakely@redhat.com>
5117 * include/bits/ranges_base.h (advance, distance, next, prev):
5118 Replace function templates with function objects.
5119 * testsuite/24_iterators/headers/iterator/synopsis_c++20.cc:
5120 Adjust for changes to function objects.
5121 * testsuite/std/ranges/adaptors/elements.cc: Add using
5122 declarations for names from namespace ranges.
5123 * testsuite/std/ranges/adaptors/transform.cc: Likewise.
5124 * testsuite/24_iterators/range_operations/100768.cc: New test.
5126 2021-05-24 François Dumont <fdumont@gcc.gnu.org>
5129 * include/bits/hashtable_policy.h (_Select2nd): New.
5130 (_NodeBuilder<>): New.
5131 (_ReuseOrAllocNode<>::operator()): Use variadic template args.
5132 (_AllocNode<>::operator()): Likewise.
5133 * include/bits/hashtable.h
5134 (_Hashtable<>::__node_builder_t): New.
5135 (_Hashtable<>::_M_insert_unique<>(_Kt&&, _Arg&&, const _NodeGenerator&)):
5137 (_Hashtable<>::_S_forward_key): New.
5138 (_Hashtable<>::_M_insert): Use latter.
5139 (_Hashtable<>::_M_insert(const_iterator, _Arg&&, const _NodeGenerator&, false_type)):
5140 Instantiate node first, compute hash code second.
5141 * testsuite/23_containers/unordered_map/96088.cc: New test.
5142 * testsuite/23_containers/unordered_multimap/96088.cc: New test.
5143 * testsuite/23_containers/unordered_multiset/96088.cc: New test.
5144 * testsuite/23_containers/unordered_set/96088.cc: New test.
5145 * testsuite/util/replacement_memory_operators.h
5146 (counter::_M_increment): New.
5147 (counter::_M_decrement): New.
5148 (counter::reset()): New.
5150 2021-05-24 Patrick Palka <ppalka@redhat.com>
5153 * include/std/ranges (__detail::__non_propagating_cache): Move
5154 definition up to before that of _CachedPosition. Make base
5155 class _Optional_base protected instead of private. Add const
5156 overload for operator*.
5157 (__detail::_CachedPosition): Rewrite the partial specialization
5158 for forward ranges as a derived class of __non_propagating_cache.
5159 Remove the size constraint on the partial specialization for
5160 random access ranges. Add copy/move/copy-assignment/move-assignment
5161 members to the offset partial specialization for random
5162 access ranges that propagate the cached value but additionally
5163 invalidate it in the source object on move.
5164 * testsuite/std/ranges/adaptors/100479.cc: New test.
5166 2021-05-24 Jonathan Wakely <jwakely@redhat.com>
5168 * testsuite/25_algorithms/inplace_merge/constrained.cc: Qualify
5169 call to ranges::next.
5170 * testsuite/25_algorithms/is_sorted/constrained.cc: Likewise.
5171 * testsuite/25_algorithms/is_sorted_until/constrained.cc:
5173 * testsuite/25_algorithms/swap_ranges/1.cc: Qualify call to
5176 2021-05-21 Patrick Palka <ppalka@redhat.com>
5179 * include/std/ranges (drop_while_view::begin): Assert the
5180 precondition added by LWG 3490.
5182 2021-05-21 Patrick Palka <ppalka@redhat.com>
5185 * include/std/ranges (iota_view::_Sentinel::_M_distance_from):
5186 Split out this member function from ...
5187 (iota_view::_Sentinel::operator-): ... here, for sake of access
5189 * testsuite/std/ranges/iota/iota_view.cc (test05): New test.
5191 2021-05-20 Jonathan Wakely <jwakely@redhat.com>
5193 * include/bits/random.tcc (__representable_as_double)
5194 (__p1_representable_as_double): Add "" to static asserts.
5196 2021-05-20 Jonathan Wakely <jwakely@redhat.com>
5199 * include/bits/c++config (__glibcxx_assert_1): Rename to ...
5200 (__glibcxx_constexpr_assert): ... this.
5201 (__glibcxx_assert_impl): Use __glibcxx_constexpr_assert.
5202 (__glibcxx_assert): Define as either __glibcxx_constexpr_assert
5203 or __glibcxx_assert_impl.
5204 (__glibcxx_assert_2): Remove
5205 * include/debug/macros.h (_GLIBCXX_DEBUG_VERIFY_AT_F): Use
5206 __glibcxx_constexpr_assert instead of __glibcxx_assert_1.
5207 * testsuite/21_strings/basic_string_view/element_access/char/back_constexpr_neg.cc:
5208 Adjust expected error.
5209 * testsuite/21_strings/basic_string_view/element_access/char/constexpr_neg.cc:
5211 * testsuite/21_strings/basic_string_view/element_access/char/front_constexpr_neg.cc:
5214 * testsuite/21_strings/basic_string_view/element_access/wchar_t/back_constexpr_neg.cc:
5216 * testsuite/21_strings/basic_string_view/element_access/wchar_t/constexpr_neg.cc:
5218 * testsuite/21_strings/basic_string_view/element_access/wchar_t/front_constexpr_neg.cc:
5220 * testsuite/23_containers/span/back_neg.cc: Likewise.
5221 * testsuite/23_containers/span/front_neg.cc: Likewise.
5222 * testsuite/23_containers/span/index_op_neg.cc: Likewise.
5224 2021-05-20 Patrick Palka <ppalka@redhat.com>
5227 * include/bits/stl_iterator.h (reverse_iterator::difference_type):
5228 In C++20 mode, define in terms of iter_difference_t as per P0896R4.
5229 (reverse_iterator::reference): Likewise, but with iter_reference_t.
5230 (reverse_iterator::value_type): Likewise, but with iter_value_t.
5231 * testsuite/std/ranges/adaptors/reverse.cc (test08): New test.
5232 * testsuite/24_iterators/reverse_iterator/100639.cc: New test.
5234 2021-05-20 Joern Rennecke <joern.rennecke@riscy-ip.com>
5237 * include/std/charconv (to_chars): Hide the overloads for
5238 floating-point types for 16 bit targets.
5239 * src/c++17/floating_to_chars.cc: Don't compile for 16 bit targets.
5240 * testsuite/20_util/to_chars/double.cc: Run this test only on
5242 * testsuite/20_util/to_chars/float.cc: Likewise.
5243 * testsuite/20_util/to_chars/long_double.cc: Likewise.
5245 2021-05-18 Patrick Palka <ppalka@redhat.com>
5248 * include/std/ranges (elements_view::_Sentinel::operator-): Use
5249 _M_distance_from in the other operator- overload too.
5250 * testsuite/std/ranges/adaptors/elements.cc (test06): Augment test.
5252 2021-05-18 Thomas Schwinge <thomas@codesourcery.com>
5254 * testsuite/lib/prune.exp: Add note about 'dg-note'.
5256 2021-05-18 Patrick Palka <ppalka@redhat.com>
5259 * include/std/ranges (__box::__box): Use non-list-initialization
5260 in member initializer list of in-place constructor of the
5261 partial specialization for semiregular types.
5262 (__box::operator->): Use std::__addressof.
5263 * testsuite/std/ranges/adaptors/detail/semiregular_box.cc
5265 * testsuite/std/ranges/single_view.cc (test04): New test.
5267 2021-05-18 Patrick Palka <ppalka@redhat.com>
5270 * include/std/ranges (reverse_view::_S_needs_cached_begin):
5271 Set to true if the underlying non-common random-access range
5272 doesn't have a sized sentinel.
5274 2021-05-18 Patrick Palka <ppalka@redhat.com>
5277 * include/std/ranges (elements_view::_Iterator): Also befriend
5279 (elements_view::_Sentinel::_M_equal): Templatize.
5280 (elements_view::_Sentinel::_M_distance_from): Split out from ...
5281 (elements_view::_Sentinel::operator-): ... here. Depend on
5282 _Base2 instead of _Base in the return type.
5283 * testsuite/std/ranges/adaptors/elements.cc (test06, test07):
5286 2021-05-17 Thomas Rodgers <rodgert@twrodgers.com>
5288 * include/bits/atomic_wait.h (__waiter::_M_do_wait_v): loop
5289 until value change observed.
5290 (__waiter_base::_M_laundered): New member.
5291 (__waiter_base::_M_notify): Check _M_laundered to determine
5292 whether to wake one or all.
5293 (__detail::__atomic_compare): Return true if call to
5294 __builtin_memcmp() == 0.
5295 (__waiter_base::_S_do_spin_v): Adjust predicate.
5296 * testsuite/29_atomics/atomic/wait_notify/100334.cc: New
5299 2021-05-17 Jonathan Wakely <jwakely@redhat.com>
5302 * include/experimental/bits/fs_path.h (__is_constructible_from):
5303 Test construction from a const lvalue, not an rvalue.
5304 * testsuite/27_io/filesystem/path/construct/100630.cc: New test.
5305 * testsuite/experimental/filesystem/path/construct/100630.cc:
5308 2021-05-17 Antony Polukhin <antoshkka@gmail.com>
5311 * include/bits/locale_facets.h (ctype<basic_string<C,T,A>>):
5312 Declare (but do not define) partial specialization.
5313 * testsuite/22_locale/ctype/is/string/89728_neg.cc: New test.
5315 2021-05-17 Jonathan Wakely <jwakely@redhat.com>
5317 * include/std/thread (jthread::_S_create): Fix static assert
5319 * testsuite/30_threads/jthread/95989.cc: Re-enable test.
5320 * testsuite/30_threads/jthread/jthread.cc: Do not require
5321 pthread effective target.
5322 * testsuite/30_threads/jthread/2.cc: Moved to...
5323 * testsuite/30_threads/jthread/version.cc: ...here.
5325 2021-05-17 Jonathan Wakely <jwakely@redhat.com>
5327 * doc/Makefile.am: Simplify doxygen recipes and use --latex_cmd.
5328 * doc/Makefile.in: Regenerate.
5329 * doc/doxygen/user.cfg.in (LATEX_CMD_NAME): Add placeholder
5331 * scripts/run_doxygen (print_usage): Always print to stdout and
5333 (fail): New function for exiting on error.
5334 (parse_options): Handle --latex_cmd. Do not treat --help the
5335 same as errors. Simplify handling of required arguments.
5337 2021-05-12 Jonathan Wakely <jwakely@redhat.com>
5339 * testsuite/25_algorithms/pstl/alg_nonmodifying/find_end.cc:
5340 Increase dg-timeout-factor to 4. Fix -Wunused-parameter
5341 warnings. Replace bitwise AND with logical AND in loop
5343 * testsuite/25_algorithms/pstl/alg_nonmodifying/search_n.cc:
5344 Replace bitwise AND with logical AND in loop condition.
5345 * testsuite/util/pstl/test_utils.h: Remove unused parameter
5348 2021-05-11 Patrick Palka <ppalka@redhat.com>
5350 * src/c++17/ryu/LOCAL_PATCHES: Update.
5351 * src/c++17/ryu/ryu_generic_128.h: Remove extern "C".
5352 Remove declarations for never-defined functions.
5353 * testsuite/20_util/to_chars/4.cc: New test.
5355 2021-05-11 Jonathan Wakely <jwakely@redhat.com>
5357 * testsuite/20_util/headers/memory/synopsis.cc: Define C++98
5358 alternative for macro.
5359 * testsuite/20_util/shared_ptr/creation/99006.cc: Add effective
5361 * testsuite/25_algorithms/copy/debug/99402.cc: Avoid C++11
5364 2021-05-11 Jonathan Wakely <jwakely@redhat.com>
5366 * include/bits/allocator.h (allocator<void>) [C++20]: Add
5367 missing noexcept to constructor. Restore missing POCMA and
5368 is_always_equal_traits.
5369 [C++17]: Make construct and destroy members private and
5370 declare allocator_traits as a friend.
5371 * include/bits/memoryfwd.h (allocator_traits): Declare.
5372 * include/ext/malloc_allocator.h (malloc_allocator::allocate):
5373 Add nodiscard attribute. Add static assertion for LWG 3307.
5374 * include/ext/new_allocator.h (new_allocator::allocate): Add
5375 static assertion for LWG 3307.
5376 * testsuite/20_util/allocator/void.cc: Check that converting
5377 constructor is noexcept. Check for propagation traits and
5378 size_type and difference_type. Check that pointer and
5379 const_pointer are gone in C++20.
5381 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
5383 * include/std/stop_token: Remove TODO comment.
5385 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
5387 * include/bits/shared_ptr_base.h (__shared_count(unique_ptr&&)):
5388 Initialize a non-reference deleter from an rvalue, as per LWG
5390 (__shared_ptr::_UniqCompatible): Add missing constraint.
5391 * testsuite/20_util/shared_ptr/cons/lwg3548.cc: New test.
5392 * testsuite/20_util/shared_ptr/cons/unique_ptr_deleter.cc: Check
5395 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
5397 * testsuite/17_intro/headers/c++2017/all_attributes.cc: Remove
5398 -std=gnu++17 from dg-options directive.
5399 * testsuite/17_intro/headers/c++2017/all_no_exceptions.cc:
5401 * testsuite/17_intro/headers/c++2017/all_pedantic_errors.cc:
5403 * testsuite/17_intro/headers/c++2017/operator_names.cc:
5405 * testsuite/17_intro/headers/c++2017/parallel_mode.cc: Likewise.
5406 * testsuite/17_intro/headers/c++2017/stdc++.cc: Likewise.
5407 * testsuite/17_intro/headers/c++2017/stdc++_multiple_inclusion.cc:
5409 * testsuite/18_support/aligned_alloc/aligned_alloc.cc: Likewise.
5410 * testsuite/18_support/byte/81076.cc: Likewise.
5411 * testsuite/18_support/byte/global_neg.cc: Likewise.
5412 * testsuite/18_support/byte/ops.cc: Likewise.
5413 * testsuite/18_support/byte/requirements.cc: Likewise.
5414 * testsuite/18_support/headers/cfloat/values_c++17.cc: Likewise.
5415 * testsuite/18_support/launder/1.cc: Likewise.
5416 * testsuite/18_support/launder/nodiscard.cc: Likewise.
5417 * testsuite/18_support/launder/requirements.cc: Likewise.
5418 * testsuite/18_support/launder/requirements_neg.cc: Likewise.
5419 * testsuite/18_support/new_aligned.cc: Likewise.
5420 * testsuite/18_support/uncaught_exceptions/uncaught_exceptions.cc:
5422 * testsuite/19_diagnostics/error_code/is_error_code_v.cc:
5424 * testsuite/19_diagnostics/error_condition/hash.cc: Likewise.
5425 * testsuite/20_util/addressof/requirements/constexpr.cc:
5427 * testsuite/20_util/as_const/1.cc: Likewise.
5428 * testsuite/20_util/as_const/rvalue_neg.cc: Likewise.
5429 * testsuite/20_util/bind/83427.cc: Likewise.
5430 * testsuite/20_util/bind/is_placeholder_v.cc: Likewise.
5431 * testsuite/20_util/bool_constant/requirements.cc: Likewise.
5432 * testsuite/20_util/duration/arithmetic/constexpr_c++17.cc:
5434 * testsuite/20_util/duration/requirements/treat_as_floating_point_v.cc:
5436 * testsuite/20_util/duration_cast/rounding.cc: Likewise.
5437 * testsuite/20_util/enable_shared_from_this/members/weak_from_this.cc:
5439 * testsuite/20_util/from_chars/1_neg.cc: Likewise.
5440 * testsuite/20_util/from_chars/requirements.cc: Likewise.
5441 * testsuite/20_util/function/91456.cc: Likewise.
5442 * testsuite/20_util/function/cons/deduction.cc: Likewise.
5443 * testsuite/20_util/function_objects/83607.cc: Likewise.
5444 * testsuite/20_util/function_objects/invoke/59768.cc: Likewise.
5445 * testsuite/20_util/function_objects/mem_fn/80478.cc: Likewise.
5446 * testsuite/20_util/function_objects/not_fn/1.cc: Likewise.
5447 * testsuite/20_util/function_objects/not_fn/87538.cc: Likewise.
5448 * testsuite/20_util/has_unique_object_representations/requirements/explicit_instantiation.cc:
5450 * testsuite/20_util/has_unique_object_representations/requirements/typedefs.cc:
5452 * testsuite/20_util/has_unique_object_representations/value.cc:
5454 * testsuite/20_util/hash/nullptr.cc: Likewise.
5455 * testsuite/20_util/in_place/requirements.cc: Likewise.
5456 * testsuite/20_util/is_aggregate/incomplete_neg.cc: Likewise.
5457 * testsuite/20_util/is_aggregate/requirements/explicit_instantiation.cc:
5459 * testsuite/20_util/is_aggregate/requirements/typedefs.cc:
5461 * testsuite/20_util/is_aggregate/value.cc: Likewise.
5462 * testsuite/20_util/is_invocable/83395.cc: Likewise.
5463 * testsuite/20_util/is_invocable/91456.cc: Likewise.
5464 * testsuite/20_util/is_invocable/requirements/explicit_instantiation.cc:
5466 * testsuite/20_util/is_invocable/requirements/typedefs.cc:
5468 * testsuite/20_util/is_invocable/value.cc: Likewise.
5469 * testsuite/20_util/is_literal_type/deprecated-1z.cc: Likewise.
5470 * testsuite/20_util/is_nothrow_constructible/94003.cc: Likewise.
5471 * testsuite/20_util/is_nothrow_invocable/83395.cc: Likewise.
5472 * testsuite/20_util/is_nothrow_invocable/requirements/explicit_instantiation.cc:
5474 * testsuite/20_util/is_nothrow_invocable/requirements/typedefs.cc: Likewise.
5475 * testsuite/20_util/is_nothrow_invocable/value.cc: Likewise.
5476 * testsuite/20_util/is_nothrow_swappable/requirements/explicit_instantiation.cc:
5478 * testsuite/20_util/is_nothrow_swappable/requirements/typedefs.cc:
5480 * testsuite/20_util/is_nothrow_swappable/value.cc: Likewise.
5481 * testsuite/20_util/is_nothrow_swappable_with/requirements/explicit_instantiation.cc:
5483 * testsuite/20_util/is_nothrow_swappable_with/requirements/typedefs.cc:
5485 * testsuite/20_util/is_nothrow_swappable_with/value.cc:
5487 * testsuite/20_util/is_swappable/requirements/explicit_instantiation.cc:
5489 * testsuite/20_util/is_swappable/requirements/typedefs.cc:
5491 * testsuite/20_util/is_swappable/value.cc: Likewise.
5492 * testsuite/20_util/is_swappable_with/requirements/explicit_instantiation.cc:
5494 * testsuite/20_util/is_swappable_with/requirements/typedefs.cc:
5496 * testsuite/20_util/is_swappable_with/value.cc: Likewise.
5497 * testsuite/20_util/logical_traits/83134.cc: Likewise.
5498 * testsuite/20_util/logical_traits/requirements/explicit_instantiation.cc:
5500 * testsuite/20_util/logical_traits/requirements/typedefs.cc:
5502 * testsuite/20_util/logical_traits/value.cc: Likewise.
5503 * testsuite/20_util/pair/cons/deduction.cc: Likewise.
5504 * testsuite/20_util/pair/swap_cxx17.cc: Likewise.
5505 * testsuite/20_util/ratio/requirements/ratio_equal_v.cc:
5507 * testsuite/20_util/reference_wrapper/83427.cc: Likewise.
5508 * testsuite/20_util/reference_wrapper/deduction.cc: Likewise.
5509 * testsuite/20_util/shared_ptr/casts/reinterpret.cc: Likewise.
5510 * testsuite/20_util/shared_ptr/cons/deduction.cc: Likewise.
5511 * testsuite/20_util/shared_ptr/requirements/weak_type.cc:
5513 * testsuite/20_util/time_point/arithmetic/constexpr.cc:
5515 * testsuite/20_util/time_point_cast/rounding.cc: Likewise.
5516 * testsuite/20_util/to_chars/3.cc: Likewise.
5517 * testsuite/20_util/to_chars/chars_format.cc: Likewise.
5518 * testsuite/20_util/to_chars/lwg3266.cc: Likewise.
5519 * testsuite/20_util/to_chars/requirements.cc: Likewise.
5520 * testsuite/20_util/tuple/78939.cc: Likewise.
5521 * testsuite/20_util/tuple/apply/1.cc: Likewise.
5522 * testsuite/20_util/tuple/apply/2.cc: Likewise.
5523 * testsuite/20_util/tuple/cons/deduction.cc: Likewise.
5524 * testsuite/20_util/tuple/make_from_tuple/1.cc: Likewise.
5525 * testsuite/20_util/tuple/make_from_tuple/2.cc: Likewise.
5526 * testsuite/20_util/tuple/swap_cxx17.cc: Likewise.
5527 * testsuite/20_util/tuple/tuple_size_v.cc: Likewise.
5528 * testsuite/20_util/unique_ptr/cons/deduction_neg.cc: Likewise.
5529 * testsuite/20_util/uses_allocator/requirements/uses_allocator_v.cc:
5531 * testsuite/20_util/variable_templates_for_traits.cc: Likewise.
5532 * testsuite/20_util/void_t/1.cc: Likewise.
5533 * testsuite/20_util/weak_ptr/cons/deduction.cc: Likewise.
5534 * testsuite/24_iterators/container_access.cc: Likewise.
5535 * testsuite/24_iterators/headers/iterator/range_access_c++17.cc:
5537 * testsuite/24_iterators/headers/iterator/synopsis_c++17.cc:
5539 * testsuite/24_iterators/range_access/range_access_cpp17.cc:
5541 * testsuite/24_iterators/range_access/range_access_cpp17_neg.cc:
5543 * testsuite/26_numerics/gcd/gcd_neg.cc: Likewise.
5544 * testsuite/26_numerics/headers/cmath/functions_std_c++17.cc:
5546 * testsuite/26_numerics/headers/cmath/hypot.cc: Likewise.
5547 * testsuite/26_numerics/headers/cmath/special_functions_global.cc:
5549 * testsuite/26_numerics/lcm/1.cc: Likewise.
5550 * testsuite/26_numerics/lcm/lcm_neg.cc: Likewise.
5551 * testsuite/26_numerics/valarray/deduction.cc: Likewise.
5552 * testsuite/27_io/basic_ostream/inserters_other/char/lwg2221.cc:
5554 * testsuite/27_io/manipulators/standard/char/quoted_sv.cc:
5556 * testsuite/27_io/manipulators/standard/wchar_t/quoted_sv.cc:
5558 * testsuite/27_io/types/4.cc: Likewise.
5559 * testsuite/28_regex/basic_regex/ctors/deduction.cc: Likewise.
5560 * testsuite/libstdc++-prettyprinters/91997.cc: Likewise.
5561 * testsuite/libstdc++-prettyprinters/cxx17.cc: Likewise.
5563 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
5565 * testsuite/20_util/function_objects/searchers.cc: Remove
5566 -std=gnu++17 from dg-options directive.
5567 * testsuite/20_util/specialized_algorithms/memory_management_tools/1.cc:
5569 * testsuite/20_util/specialized_algorithms/memory_management_tools/destroy_neg.cc:
5571 * testsuite/20_util/specialized_algorithms/uninitialized_value_construct/94540.cc:
5573 * testsuite/20_util/specialized_algorithms/uninitialized_value_construct/94831.cc:
5575 * testsuite/20_util/specialized_algorithms/uninitialized_value_construct_n/94540.cc:
5577 * testsuite/20_util/specialized_algorithms/uninitialized_value_construct_n/sizes.cc:
5579 * testsuite/20_util/unique_ptr/specialized_algorithms/swap_cxx17.cc:
5581 * testsuite/25_algorithms/clamp/1.cc: Likewise.
5582 * testsuite/25_algorithms/clamp/2.cc: Likewise.
5583 * testsuite/25_algorithms/clamp/constexpr.cc: Likewise.
5584 * testsuite/25_algorithms/clamp/requirements/explicit_instantiation/1.cc:
5586 * testsuite/25_algorithms/clamp/requirements/explicit_instantiation/pod.cc:
5588 * testsuite/25_algorithms/for_each/for_each_n.cc: Likewise.
5589 * testsuite/25_algorithms/for_each/for_each_n_debug.cc:
5591 * testsuite/25_algorithms/sample/1.cc: Likewise.
5592 * testsuite/25_algorithms/sample/2.cc: Likewise.
5593 * testsuite/25_algorithms/sample/3.cc: Likewise.
5594 * testsuite/25_algorithms/sample/81221.cc: Likewise.
5595 * testsuite/25_algorithms/search/searcher.cc: Likewise.
5596 * testsuite/26_numerics/exclusive_scan/1.cc: Likewise.
5597 * testsuite/26_numerics/inclusive_scan/1.cc: Likewise.
5598 * testsuite/26_numerics/reduce/1.cc: Likewise.
5599 * testsuite/26_numerics/reduce/2.cc: Likewise.
5600 * testsuite/26_numerics/transform_exclusive_scan/1.cc: Likewise.
5601 * testsuite/26_numerics/transform_inclusive_scan/1.cc: Likewise.
5602 * testsuite/26_numerics/transform_reduce/1.cc: Likewise.
5604 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
5606 * testsuite/23_containers/array/cons/deduction.cc: Remove
5607 -std=gnu++17 from dg-options directive.
5608 * testsuite/23_containers/array/cons/deduction_neg.cc: Likewise.
5609 * testsuite/23_containers/array/element_access/constexpr_c++17.cc:
5611 * testsuite/23_containers/array/requirements/constexpr_iter.cc:
5613 * testsuite/23_containers/array/specialized_algorithms/swap_cxx17.cc:
5615 * testsuite/23_containers/deque/cons/deduction.cc: Likewise.
5616 * testsuite/23_containers/deque/modifiers/emplace/cxx17_return.cc:
5618 * testsuite/23_containers/forward_list/cons/deduction.cc:
5620 * testsuite/23_containers/forward_list/modifiers/emplace_cxx17_return.cc:
5622 * testsuite/23_containers/list/cons/deduction.cc: Likewise.
5623 * testsuite/23_containers/list/modifiers/emplace/cxx17_return.cc:
5625 * testsuite/23_containers/map/cons/deduction.cc: Likewise.
5626 * testsuite/23_containers/map/modifiers/extract.cc: Likewise.
5627 * testsuite/23_containers/map/modifiers/insert/83226.cc:
5629 * testsuite/23_containers/map/modifiers/insert_or_assign/1.cc:
5631 * testsuite/23_containers/map/modifiers/merge.cc: Likewise.
5632 * testsuite/23_containers/map/modifiers/try_emplace/1.cc:
5634 * testsuite/23_containers/multimap/cons/deduction.cc: Likewise.
5635 * testsuite/23_containers/multimap/modifiers/extract.cc:
5637 * testsuite/23_containers/multimap/modifiers/merge.cc: Likewise.
5638 * testsuite/23_containers/multiset/cons/deduction.cc: Likewise.
5639 * testsuite/23_containers/multiset/modifiers/extract.cc:
5641 * testsuite/23_containers/multiset/modifiers/merge.cc: Likewise.
5642 * testsuite/23_containers/priority_queue/deduction.cc: Likewise.
5643 * testsuite/23_containers/queue/deduction.cc: Likewise.
5644 * testsuite/23_containers/queue/members/emplace_cxx17_return.cc:
5646 * testsuite/23_containers/set/cons/deduction.cc: Likewise.
5647 * testsuite/23_containers/set/modifiers/extract.cc: Likewise.
5648 * testsuite/23_containers/set/modifiers/merge.cc: Likewise.
5649 * testsuite/23_containers/set/modifiers/node_swap.cc: Likewise.
5650 * testsuite/23_containers/stack/deduction.cc: Likewise.
5651 * testsuite/23_containers/stack/members/emplace_cxx17_return.cc:
5653 * testsuite/23_containers/unordered_map/cons/deduction.cc:
5655 * testsuite/23_containers/unordered_map/modifiers/extract.cc:
5657 * testsuite/23_containers/unordered_map/modifiers/insert_or_assign.cc:
5659 * testsuite/23_containers/unordered_map/modifiers/merge.cc:
5661 * testsuite/23_containers/unordered_map/modifiers/try_emplace.cc:
5663 * testsuite/23_containers/unordered_multimap/cons/deduction.cc:
5665 * testsuite/23_containers/unordered_multimap/modifiers/extract.cc:
5667 * testsuite/23_containers/unordered_multimap/modifiers/merge.cc:
5669 * testsuite/23_containers/unordered_multiset/cons/deduction.cc:
5671 * testsuite/23_containers/unordered_multiset/modifiers/extract.cc:
5673 * testsuite/23_containers/unordered_multiset/modifiers/merge.cc:
5675 * testsuite/23_containers/unordered_set/cons/deduction.cc:
5677 * testsuite/23_containers/unordered_set/modifiers/extract.cc:
5679 * testsuite/23_containers/unordered_set/modifiers/merge.cc:
5681 * testsuite/23_containers/vector/bool/emplace_cxx17_return.cc:
5683 * testsuite/23_containers/vector/cons/89164_c++17.cc: Likewise.
5684 * testsuite/23_containers/vector/cons/deduction.cc: Likewise.
5685 * testsuite/23_containers/vector/modifiers/emplace/cxx17_return.cc:
5688 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
5690 * testsuite/21_strings/basic_string/79162.cc: Remove
5691 -std=gnu++17 from dg-options directive.
5692 * testsuite/21_strings/basic_string/cons/char/7.cc: Likewise.
5693 * testsuite/21_strings/basic_string/cons/char/79162.cc:
5695 * testsuite/21_strings/basic_string/cons/char/86138.cc:
5697 * testsuite/21_strings/basic_string/cons/char/9.cc: Likewise.
5698 * testsuite/21_strings/basic_string/cons/char/deduction.cc:
5700 * testsuite/21_strings/basic_string/cons/char/moveable2_c++17.cc:
5702 * testsuite/21_strings/basic_string/cons/wchar_t/7.cc: Likewise.
5703 * testsuite/21_strings/basic_string/cons/wchar_t/79162.cc:
5705 * testsuite/21_strings/basic_string/cons/wchar_t/86138.cc:
5707 * testsuite/21_strings/basic_string/cons/wchar_t/9.cc: Likewise.
5708 * testsuite/21_strings/basic_string/cons/wchar_t/deduction.cc:
5710 * testsuite/21_strings/basic_string/cons/wchar_t/moveable2_c++17.cc:
5712 * testsuite/21_strings/basic_string/hash/hash.cc: Likewise.
5713 * testsuite/21_strings/basic_string/lwg2758.cc: Likewise.
5714 * testsuite/21_strings/basic_string/lwg2946.cc: Likewise.
5715 * testsuite/21_strings/basic_string/modifiers/append/char/4.cc:
5717 * testsuite/21_strings/basic_string/modifiers/append/wchar_t/4.cc:
5719 * testsuite/21_strings/basic_string/modifiers/assign/char/4.cc:
5721 * testsuite/21_strings/basic_string/modifiers/assign/wchar_t/4.cc:
5723 * testsuite/21_strings/basic_string/modifiers/insert/char/3.cc:
5725 * testsuite/21_strings/basic_string/modifiers/insert/wchar_t/3.cc:
5727 * testsuite/21_strings/basic_string/modifiers/replace/char/7.cc:
5729 * testsuite/21_strings/basic_string/modifiers/replace/wchar_t/7.cc:
5731 * testsuite/21_strings/basic_string/operations/compare/char/2.cc:
5733 * testsuite/21_strings/basic_string/operations/compare/wchar_t/2.cc:
5735 * testsuite/21_strings/basic_string/operations/data/char/2.cc:
5737 * testsuite/21_strings/basic_string/operations/data/char/86169.cc:
5739 * testsuite/21_strings/basic_string/operations/data/wchar_t/2.cc:
5741 * testsuite/21_strings/basic_string/operations/find/char/5.cc:
5743 * testsuite/21_strings/basic_string/operations/find/wchar_t/5.cc:
5745 * testsuite/21_strings/basic_string/operators/char/5.cc:
5747 * testsuite/21_strings/basic_string/operators/wchar_t/5.cc:
5749 * testsuite/21_strings/basic_string_view/capacity/1.cc:
5751 * testsuite/21_strings/basic_string_view/capacity/empty_neg.cc:
5753 * testsuite/21_strings/basic_string_view/cons/char/1.cc:
5755 * testsuite/21_strings/basic_string_view/cons/char/2.cc:
5757 * testsuite/21_strings/basic_string_view/cons/char/3.cc:
5759 * testsuite/21_strings/basic_string_view/cons/char/nonnull.cc:
5761 * testsuite/21_strings/basic_string_view/cons/wchar_t/1.cc:
5763 * testsuite/21_strings/basic_string_view/cons/wchar_t/2.cc:
5765 * testsuite/21_strings/basic_string_view/cons/wchar_t/3.cc:
5767 * testsuite/21_strings/basic_string_view/cons/wchar_t/nonnull.cc:
5769 * testsuite/21_strings/basic_string_view/element_access/char/1.cc:
5771 * testsuite/21_strings/basic_string_view/element_access/char/2.cc:
5773 * testsuite/21_strings/basic_string_view/element_access/char/back_constexpr_neg.cc:
5775 * testsuite/21_strings/basic_string_view/element_access/char/constexpr.cc:
5777 * testsuite/21_strings/basic_string_view/element_access/char/constexpr_neg.cc:
5779 * testsuite/21_strings/basic_string_view/element_access/char/empty.cc:
5781 * testsuite/21_strings/basic_string_view/element_access/char/front_back.cc:
5783 * testsuite/21_strings/basic_string_view/element_access/char/front_back_constexpr.cc:
5785 * testsuite/21_strings/basic_string_view/element_access/char/front_constexpr_neg.cc:
5787 * testsuite/21_strings/basic_string_view/element_access/wchar_t/1.cc:
5789 * testsuite/21_strings/basic_string_view/element_access/wchar_t/2.cc:
5791 * testsuite/21_strings/basic_string_view/element_access/wchar_t/back_constexpr_neg.cc:
5793 * testsuite/21_strings/basic_string_view/element_access/wchar_t/constexpr.cc:
5795 * testsuite/21_strings/basic_string_view/element_access/wchar_t/constexpr_neg.cc:
5797 * testsuite/21_strings/basic_string_view/element_access/wchar_t/empty.cc:
5799 * testsuite/21_strings/basic_string_view/element_access/wchar_t/front_back.cc:
5801 * testsuite/21_strings/basic_string_view/element_access/wchar_t/front_constexpr_neg.cc:
5803 * testsuite/21_strings/basic_string_view/include.cc: Likewise.
5804 * testsuite/21_strings/basic_string_view/inserters/94051.cc:
5806 * testsuite/21_strings/basic_string_view/inserters/char/1.cc:
5808 * testsuite/21_strings/basic_string_view/inserters/char/2.cc:
5810 * testsuite/21_strings/basic_string_view/inserters/char/3.cc:
5812 * testsuite/21_strings/basic_string_view/inserters/pod/10081-out.cc:
5814 * testsuite/21_strings/basic_string_view/inserters/wchar_t/1.cc:
5816 * testsuite/21_strings/basic_string_view/inserters/wchar_t/2.cc:
5818 * testsuite/21_strings/basic_string_view/inserters/wchar_t/3.cc:
5820 * testsuite/21_strings/basic_string_view/literals/types-char8_t.cc:
5822 * testsuite/21_strings/basic_string_view/literals/types.cc:
5824 * testsuite/21_strings/basic_string_view/literals/values-char8_t.cc:
5826 * testsuite/21_strings/basic_string_view/literals/values.cc:
5828 * testsuite/21_strings/basic_string_view/modifiers/remove_prefix/char/1.cc:
5830 * testsuite/21_strings/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc:
5832 * testsuite/21_strings/basic_string_view/modifiers/remove_suffix/char/1.cc:
5834 * testsuite/21_strings/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc:
5836 * testsuite/21_strings/basic_string_view/modifiers/swap/char/1.cc:
5838 * testsuite/21_strings/basic_string_view/modifiers/swap/wchar_t/1.cc:
5840 * testsuite/21_strings/basic_string_view/operations/compare/char/1.cc:
5842 * testsuite/21_strings/basic_string_view/operations/compare/char/13650.cc:
5844 * testsuite/21_strings/basic_string_view/operations/compare/char/2.cc:
5846 * testsuite/21_strings/basic_string_view/operations/compare/char/70483.cc:
5848 * testsuite/21_strings/basic_string_view/operations/compare/char/nonnull.cc:
5850 * testsuite/21_strings/basic_string_view/operations/compare/wchar_t/1.cc:
5852 * testsuite/21_strings/basic_string_view/operations/compare/wchar_t/13650.cc:
5854 * testsuite/21_strings/basic_string_view/operations/compare/wchar_t/2.cc:
5856 * testsuite/21_strings/basic_string_view/operations/copy/char/1.cc:
5858 * testsuite/21_strings/basic_string_view/operations/copy/char/2.cc:
5860 * testsuite/21_strings/basic_string_view/operations/copy/wchar_t/1.cc:
5862 * testsuite/21_strings/basic_string_view/operations/copy/wchar_t/2.cc:
5864 * testsuite/21_strings/basic_string_view/operations/data/char/1.cc:
5866 * testsuite/21_strings/basic_string_view/operations/data/wchar_t/1.cc:
5868 * testsuite/21_strings/basic_string_view/operations/find/char/1.cc:
5870 * testsuite/21_strings/basic_string_view/operations/find/char/2.cc:
5872 * testsuite/21_strings/basic_string_view/operations/find/char/3.cc:
5874 * testsuite/21_strings/basic_string_view/operations/find/char/4.cc:
5876 * testsuite/21_strings/basic_string_view/operations/find/char/nonnull.cc:
5878 * testsuite/21_strings/basic_string_view/operations/find/wchar_t/1.cc:
5880 * testsuite/21_strings/basic_string_view/operations/find/wchar_t/2.cc:
5882 * testsuite/21_strings/basic_string_view/operations/find/wchar_t/3.cc:
5884 * testsuite/21_strings/basic_string_view/operations/find/wchar_t/4.cc:
5886 * testsuite/21_strings/basic_string_view/operations/rfind/char/1.cc:
5888 * testsuite/21_strings/basic_string_view/operations/rfind/char/2.cc:
5890 * testsuite/21_strings/basic_string_view/operations/rfind/char/3.cc:
5892 * testsuite/21_strings/basic_string_view/operations/rfind/char/nonnull.cc:
5894 * testsuite/21_strings/basic_string_view/operations/rfind/wchar_t/1.cc:
5896 * testsuite/21_strings/basic_string_view/operations/rfind/wchar_t/2.cc:
5898 * testsuite/21_strings/basic_string_view/operations/rfind/wchar_t/3.cc:
5900 * testsuite/21_strings/basic_string_view/operations/string_conversion/1.cc:
5902 * testsuite/21_strings/basic_string_view/operations/substr/char/1.cc:
5904 * testsuite/21_strings/basic_string_view/operations/substr/char/83511.cc:
5906 * testsuite/21_strings/basic_string_view/operations/substr/wchar_t/1.cc:
5908 * testsuite/21_strings/basic_string_view/operations/substr/wchar_t/83511.cc:
5910 * testsuite/21_strings/basic_string_view/operators/char/2.cc:
5912 * testsuite/21_strings/basic_string_view/operators/char/89446.cc:
5914 * testsuite/21_strings/basic_string_view/operators/wchar_t/2.cc:
5916 * testsuite/21_strings/basic_string_view/operators/wchar_t/89446.cc:
5918 * testsuite/21_strings/basic_string_view/range_access/char/1.cc:
5920 * testsuite/21_strings/basic_string_view/range_access/wchar_t/1.cc:
5922 * testsuite/21_strings/basic_string_view/requirements/explicit_instantiation/1.cc:
5924 * testsuite/21_strings/basic_string_view/requirements/explicit_instantiation/char/1.cc:
5926 * testsuite/21_strings/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc:
5928 * testsuite/21_strings/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc:
5930 * testsuite/21_strings/basic_string_view/requirements/explicit_instantiation/char8_t/1.cc:
5932 * testsuite/21_strings/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc:
5934 * testsuite/21_strings/basic_string_view/requirements/traits_neg.cc:
5936 * testsuite/21_strings/basic_string_view/requirements/typedefs.cc:
5938 * testsuite/21_strings/basic_string_view/typedefs.cc: Likewise.
5939 * testsuite/21_strings/basic_string_view/types/1.cc: Likewise.
5940 * testsuite/21_strings/char_traits/requirements/char/99181.cc:
5942 * testsuite/21_strings/char_traits/requirements/constexpr_functions_c++17.cc:
5944 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
5946 * testsuite/20_util/memory_resource/1.cc: Remove -std=gnu++17
5947 from dg-options directive.
5948 * testsuite/20_util/memory_resource/2.cc: Likewise.
5949 * testsuite/20_util/monotonic_buffer_resource/1.cc: Likewise.
5950 * testsuite/20_util/monotonic_buffer_resource/93208.cc:
5952 * testsuite/20_util/monotonic_buffer_resource/allocate.cc:
5954 * testsuite/20_util/monotonic_buffer_resource/deallocate.cc:
5956 * testsuite/20_util/monotonic_buffer_resource/release.cc:
5958 * testsuite/20_util/monotonic_buffer_resource/upstream_resource.cc:
5960 * testsuite/20_util/polymorphic_allocator/1.cc: Likewise.
5961 * testsuite/20_util/polymorphic_allocator/construct_pair.cc:
5963 * testsuite/20_util/polymorphic_allocator/resource.cc: Likewise.
5964 * testsuite/20_util/polymorphic_allocator/select.cc: Likewise.
5965 * testsuite/20_util/synchronized_pool_resource/allocate.cc:
5967 * testsuite/20_util/synchronized_pool_resource/allocate_single.cc:
5969 * testsuite/20_util/synchronized_pool_resource/cons.cc:
5971 * testsuite/20_util/synchronized_pool_resource/cons_single.cc:
5973 * testsuite/20_util/synchronized_pool_resource/is_equal.cc:
5975 * testsuite/20_util/synchronized_pool_resource/multithreaded.cc:
5977 * testsuite/20_util/synchronized_pool_resource/options.cc:
5979 * testsuite/20_util/synchronized_pool_resource/release.cc:
5981 * testsuite/20_util/synchronized_pool_resource/release_single.cc:
5983 * testsuite/20_util/unsynchronized_pool_resource/allocate-max-chunks.cc:
5985 * testsuite/20_util/unsynchronized_pool_resource/allocate.cc:
5987 * testsuite/20_util/unsynchronized_pool_resource/cons.cc:
5989 * testsuite/20_util/unsynchronized_pool_resource/is_equal.cc:
5991 * testsuite/20_util/unsynchronized_pool_resource/options.cc:
5993 * testsuite/20_util/unsynchronized_pool_resource/release.cc:
5995 * testsuite/21_strings/basic_string/types/pmr_typedefs.cc:
5997 * testsuite/23_containers/deque/types/pmr_typedefs.cc: Likewise.
5998 * testsuite/23_containers/deque/types/pmr_typedefs_debug.cc:
6000 * testsuite/23_containers/forward_list/pmr_typedefs.cc:
6002 * testsuite/23_containers/forward_list/pmr_typedefs_debug.cc:
6004 * testsuite/23_containers/list/pmr_typedefs.cc: Likewise.
6005 * testsuite/23_containers/list/pmr_typedefs_debug.cc: Likewise.
6006 * testsuite/23_containers/map/pmr_typedefs.cc: Likewise.
6007 * testsuite/23_containers/map/pmr_typedefs_debug.cc: Likewise.
6008 * testsuite/23_containers/multimap/pmr_typedefs.cc: Likewise.
6009 * testsuite/23_containers/multimap/pmr_typedefs_debug.cc:
6011 * testsuite/23_containers/multiset/pmr_typedefs.cc: Likewise.
6012 * testsuite/23_containers/multiset/pmr_typedefs_debug.cc:
6014 * testsuite/23_containers/set/pmr_typedefs.cc: Likewise.
6015 * testsuite/23_containers/set/pmr_typedefs_debug.cc: Likewise.
6016 * testsuite/23_containers/unordered_map/pmr_typedefs.cc:
6018 * testsuite/23_containers/unordered_map/pmr_typedefs_debug.cc:
6020 * testsuite/23_containers/unordered_multimap/pmr_typedefs.cc:
6022 * testsuite/23_containers/unordered_multimap/pmr_typedefs_debug.cc:
6024 * testsuite/23_containers/unordered_multiset/pmr_typedefs.cc:
6026 * testsuite/23_containers/unordered_multiset/pmr_typedefs_debug.cc:
6028 * testsuite/23_containers/unordered_set/pmr_typedefs.cc:
6030 * testsuite/23_containers/unordered_set/pmr_typedefs_debug.cc:
6032 * testsuite/23_containers/vector/pmr_typedefs.cc: Likewise.
6033 * testsuite/23_containers/vector/types/pmr_typedefs_debug.cc:
6035 * testsuite/28_regex/match_results/pmr_typedefs.cc: Likewise.
6037 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
6039 * testsuite/29_atomics/atomic/69769.cc: Remove -std=gnu++17 from
6041 * testsuite/29_atomics/atomic/is_always_lock_free.cc:
6042 * testsuite/29_atomics/atomic/requirements/typedefs.cc:
6043 * testsuite/29_atomics/atomic_integral/is_always_lock_free.cc:
6044 * testsuite/29_atomics/atomic_integral/requirements/typedefs.cc:
6045 * testsuite/30_threads/lock_guard/cons/deduction.cc: Likewise.
6046 * testsuite/30_threads/scoped_lock/cons/1.cc: Likewise.
6047 * testsuite/30_threads/scoped_lock/cons/deduction.cc: Likewise.
6048 * testsuite/30_threads/scoped_lock/requirements/explicit_instantiation.cc:
6050 * testsuite/30_threads/scoped_lock/requirements/typedefs.cc:
6052 * testsuite/30_threads/shared_lock/70766.cc: Likewise.
6053 * testsuite/30_threads/shared_mutex/cons/1.cc: Likewise.
6054 * testsuite/30_threads/shared_mutex/cons/assign_neg.cc:
6056 * testsuite/30_threads/shared_mutex/cons/copy_neg.cc: Likewise.
6057 * testsuite/30_threads/shared_mutex/requirements/standard_layout.cc:
6059 * testsuite/30_threads/shared_mutex/try_lock/1.cc: Likewise.
6060 * testsuite/30_threads/shared_mutex/try_lock/2.cc: Likewise.
6061 * testsuite/30_threads/shared_mutex/unlock/1.cc: Likewise.
6062 * testsuite/30_threads/unique_lock/cons/deduction.cc: Likewise.
6064 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
6066 * testsuite/20_util/any/assign/1.cc: Remove -std=gnu++17 from
6067 dg-options directive.
6068 * testsuite/20_util/any/assign/2.cc: Likewise.
6069 * testsuite/20_util/any/assign/emplace.cc: Likewise.
6070 * testsuite/20_util/any/assign/exception.cc: Likewise.
6071 * testsuite/20_util/any/assign/self.cc: Likewise.
6072 * testsuite/20_util/any/cons/1.cc: Likewise.
6073 * testsuite/20_util/any/cons/2.cc: Likewise.
6074 * testsuite/20_util/any/cons/90415.cc: Likewise.
6075 * testsuite/20_util/any/cons/92156.cc: Likewise.
6076 * testsuite/20_util/any/cons/aligned.cc: Likewise.
6077 * testsuite/20_util/any/cons/explicit.cc: Likewise.
6078 * testsuite/20_util/any/cons/in_place.cc: Likewise.
6079 * testsuite/20_util/any/cons/nontrivial.cc: Likewise.
6080 * testsuite/20_util/any/make_any.cc: Likewise.
6081 * testsuite/20_util/any/misc/any_cast.cc: Likewise.
6082 * testsuite/20_util/any/misc/any_cast_neg.cc: Likewise.
6083 * testsuite/20_util/any/misc/any_cast_no_rtti.cc: Likewise.
6084 * testsuite/20_util/any/misc/swap.cc: Likewise.
6085 * testsuite/20_util/any/modifiers/1.cc: Likewise.
6086 * testsuite/20_util/any/modifiers/83658.cc: Likewise.
6087 * testsuite/20_util/any/modifiers/92156.cc: Likewise.
6088 * testsuite/20_util/any/observers/type.cc: Likewise.
6089 * testsuite/20_util/any/requirements.cc: Likewise.
6090 * testsuite/20_util/any/typedefs.cc: Likewise.
6091 * testsuite/20_util/optional/77288.cc: Likewise.
6092 * testsuite/20_util/optional/84601.cc: Likewise.
6093 * testsuite/20_util/optional/assignment/1.cc: Likewise.
6094 * testsuite/20_util/optional/assignment/2.cc: Likewise.
6095 * testsuite/20_util/optional/assignment/3.cc: Likewise.
6096 * testsuite/20_util/optional/assignment/4.cc: Likewise.
6097 * testsuite/20_util/optional/assignment/5.cc: Likewise.
6098 * testsuite/20_util/optional/assignment/6.cc: Likewise.
6099 * testsuite/20_util/optional/assignment/7.cc: Likewise.
6100 * testsuite/20_util/optional/assignment/8.cc: Likewise.
6101 * testsuite/20_util/optional/assignment/9.cc: Likewise.
6102 * testsuite/20_util/optional/bad_access.cc: Likewise.
6103 * testsuite/20_util/optional/cons/77727.cc: Likewise.
6104 * testsuite/20_util/optional/cons/85642.cc: Likewise.
6105 * testsuite/20_util/optional/cons/copy.cc: Likewise.
6106 * testsuite/20_util/optional/cons/deduction.cc: Likewise.
6107 * testsuite/20_util/optional/cons/default.cc: Likewise.
6108 * testsuite/20_util/optional/cons/move.cc: Likewise.
6109 * testsuite/20_util/optional/cons/trivial.cc: Likewise.
6110 * testsuite/20_util/optional/cons/value.cc: Likewise.
6111 * testsuite/20_util/optional/cons/value_neg.cc: Likewise.
6112 * testsuite/20_util/optional/constexpr/cons/default.cc:
6114 * testsuite/20_util/optional/constexpr/cons/value.cc: Likewise.
6115 * testsuite/20_util/optional/constexpr/in_place.cc: Likewise.
6116 * testsuite/20_util/optional/constexpr/make_optional.cc:
6118 * testsuite/20_util/optional/constexpr/nullopt.cc: Likewise.
6119 * testsuite/20_util/optional/constexpr/observers/1.cc: Likewise.
6120 * testsuite/20_util/optional/constexpr/observers/2.cc: Likewise.
6121 * testsuite/20_util/optional/constexpr/observers/3.cc: Likewise.
6122 * testsuite/20_util/optional/constexpr/observers/4.cc: Likewise.
6123 * testsuite/20_util/optional/constexpr/observers/5.cc: Likewise.
6124 * testsuite/20_util/optional/constexpr/relops/1.cc: Likewise.
6125 * testsuite/20_util/optional/constexpr/relops/2.cc: Likewise.
6126 * testsuite/20_util/optional/constexpr/relops/3.cc: Likewise.
6127 * testsuite/20_util/optional/constexpr/relops/4.cc: Likewise.
6128 * testsuite/20_util/optional/constexpr/relops/5.cc: Likewise.
6129 * testsuite/20_util/optional/constexpr/relops/6.cc: Likewise.
6130 * testsuite/20_util/optional/hash.cc: Likewise.
6131 * testsuite/20_util/optional/in_place.cc: Likewise.
6132 * testsuite/20_util/optional/make_optional.cc: Likewise.
6133 * testsuite/20_util/optional/nullopt.cc: Likewise.
6134 * testsuite/20_util/optional/observers/1.cc: Likewise.
6135 * testsuite/20_util/optional/observers/2.cc: Likewise.
6136 * testsuite/20_util/optional/observers/3.cc: Likewise.
6137 * testsuite/20_util/optional/observers/4.cc: Likewise.
6138 * testsuite/20_util/optional/observers/5.cc: Likewise.
6139 * testsuite/20_util/optional/observers/6.cc: Likewise.
6140 * testsuite/20_util/optional/relops/1.cc: Likewise.
6141 * testsuite/20_util/optional/relops/2.cc: Likewise.
6142 * testsuite/20_util/optional/relops/3.cc: Likewise.
6143 * testsuite/20_util/optional/relops/4.cc: Likewise.
6144 * testsuite/20_util/optional/relops/5.cc: Likewise.
6145 * testsuite/20_util/optional/relops/6.cc: Likewise.
6146 * testsuite/20_util/optional/relops/7.cc: Likewise.
6147 * testsuite/20_util/optional/requirements.cc: Likewise.
6148 * testsuite/20_util/optional/swap/1.cc: Likewise.
6149 * testsuite/20_util/optional/swap/2.cc: Likewise.
6150 * testsuite/20_util/optional/typedefs.cc: Likewise.
6151 * testsuite/20_util/variant/80165.cc: Likewise.
6152 * testsuite/20_util/variant/85183.cc: Likewise.
6153 * testsuite/20_util/variant/86874.cc: Likewise.
6154 * testsuite/20_util/variant/87431.cc: Likewise.
6155 * testsuite/20_util/variant/87619.cc: Likewise.
6156 * testsuite/20_util/variant/91807.cc: Likewise.
6157 * testsuite/20_util/variant/any.cc: Likewise.
6158 * testsuite/20_util/variant/compile.cc: Likewise.
6159 * testsuite/20_util/variant/deduction.cc: Likewise.
6160 * testsuite/20_util/variant/exception_safety.cc: Likewise.
6161 * testsuite/20_util/variant/hash.cc: Likewise.
6162 * testsuite/20_util/variant/index_type.cc: Likewise.
6163 * testsuite/20_util/variant/relops/89851.cc: Likewise.
6164 * testsuite/20_util/variant/relops/90008.cc: Likewise.
6165 * testsuite/20_util/variant/run.cc: Likewise.
6166 * testsuite/20_util/variant/visit.cc: Likewise.
6168 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
6170 * testsuite/27_io/basic_filebuf/open/char/path.cc: Remove
6171 -std=gnu++17 from dg-options directive.
6172 * testsuite/27_io/basic_fstream/cons/char/path.cc: Likewise.
6173 * testsuite/27_io/basic_fstream/open/char/path.cc: Likewise.
6174 * testsuite/27_io/basic_ifstream/cons/char/path.cc: Likewise.
6175 * testsuite/27_io/basic_ifstream/open/char/path.cc: Likewise.
6176 * testsuite/27_io/basic_ofstream/cons/char/path.cc: Likewise.
6177 * testsuite/27_io/basic_ofstream/open/char/path.cc: Likewise.
6178 * testsuite/27_io/filesystem/directory_entry/86597.cc: Likewise.
6179 * testsuite/27_io/filesystem/directory_entry/lwg3171.cc:
6181 * testsuite/27_io/filesystem/file_status/1.cc: Likewise.
6182 * testsuite/27_io/filesystem/filesystem_error/cons.cc: Likewise.
6183 * testsuite/27_io/filesystem/filesystem_error/copy.cc: Likewise.
6184 * testsuite/27_io/filesystem/iterators/91067.cc: Likewise.
6185 * testsuite/27_io/filesystem/iterators/caching.cc: Likewise.
6186 * testsuite/27_io/filesystem/iterators/directory_iterator.cc:
6188 * testsuite/27_io/filesystem/iterators/pop.cc: Likewise.
6189 * testsuite/27_io/filesystem/iterators/recursion_pending.cc:
6191 * testsuite/27_io/filesystem/iterators/recursive_directory_iterator.cc:
6193 * testsuite/27_io/filesystem/operations/absolute.cc: Likewise.
6194 * testsuite/27_io/filesystem/operations/all.cc: Likewise.
6195 * testsuite/27_io/filesystem/operations/canonical.cc: Likewise.
6196 * testsuite/27_io/filesystem/operations/copy.cc: Likewise.
6197 * testsuite/27_io/filesystem/operations/copy_file.cc: Likewise.
6198 * testsuite/27_io/filesystem/operations/create_directories.cc:
6200 * testsuite/27_io/filesystem/operations/create_directory.cc:
6202 * testsuite/27_io/filesystem/operations/create_symlink.cc:
6204 * testsuite/27_io/filesystem/operations/current_path.cc:
6206 * testsuite/27_io/filesystem/operations/equivalent.cc: Likewise.
6207 * testsuite/27_io/filesystem/operations/exists.cc: Likewise.
6208 * testsuite/27_io/filesystem/operations/file_size.cc: Likewise.
6209 * testsuite/27_io/filesystem/operations/is_empty.cc: Likewise.
6210 * testsuite/27_io/filesystem/operations/last_write_time.cc:
6212 * testsuite/27_io/filesystem/operations/permissions.cc:
6214 * testsuite/27_io/filesystem/operations/proximate.cc: Likewise.
6215 * testsuite/27_io/filesystem/operations/read_symlink.cc:
6217 * testsuite/27_io/filesystem/operations/relative.cc: Likewise.
6218 * testsuite/27_io/filesystem/operations/remove.cc: Likewise.
6219 * testsuite/27_io/filesystem/operations/remove_all.cc: Likewise.
6220 * testsuite/27_io/filesystem/operations/rename.cc: Likewise.
6221 * testsuite/27_io/filesystem/operations/resize_file.cc:
6223 * testsuite/27_io/filesystem/operations/space.cc: Likewise.
6224 * testsuite/27_io/filesystem/operations/status.cc: Likewise.
6225 * testsuite/27_io/filesystem/operations/symlink_status.cc:
6227 * testsuite/27_io/filesystem/operations/temp_directory_path.cc:
6229 * testsuite/27_io/filesystem/operations/weakly_canonical.cc:
6231 * testsuite/27_io/filesystem/path/append/path.cc: Likewise.
6232 * testsuite/27_io/filesystem/path/append/source.cc: Likewise.
6233 * testsuite/27_io/filesystem/path/assign/assign.cc: Likewise.
6234 * testsuite/27_io/filesystem/path/assign/copy.cc: Likewise.
6235 * testsuite/27_io/filesystem/path/compare/compare.cc: Likewise.
6236 * testsuite/27_io/filesystem/path/compare/lwg2936.cc: Likewise.
6237 * testsuite/27_io/filesystem/path/compare/path.cc: Likewise.
6238 * testsuite/27_io/filesystem/path/compare/strings.cc: Likewise.
6239 * testsuite/27_io/filesystem/path/concat/92853.cc: Likewise.
6240 * testsuite/27_io/filesystem/path/concat/94063.cc: Likewise.
6241 * testsuite/27_io/filesystem/path/concat/path.cc: Likewise.
6242 * testsuite/27_io/filesystem/path/concat/strings.cc: Likewise.
6243 * testsuite/27_io/filesystem/path/construct/80762.cc: Likewise.
6244 * testsuite/27_io/filesystem/path/construct/90281.cc: Likewise.
6245 * testsuite/27_io/filesystem/path/construct/90634.cc: Likewise.
6246 * testsuite/27_io/filesystem/path/construct/copy.cc: Likewise.
6247 * testsuite/27_io/filesystem/path/construct/default.cc:
6249 * testsuite/27_io/filesystem/path/construct/format.cc: Likewise.
6250 * testsuite/27_io/filesystem/path/construct/locale.cc: Likewise.
6251 * testsuite/27_io/filesystem/path/construct/range.cc: Likewise.
6252 * testsuite/27_io/filesystem/path/construct/string_view.cc:
6254 * testsuite/27_io/filesystem/path/decompose/extension.cc:
6256 * testsuite/27_io/filesystem/path/decompose/filename.cc:
6258 * testsuite/27_io/filesystem/path/decompose/parent_path.cc:
6260 * testsuite/27_io/filesystem/path/decompose/relative_path.cc:
6262 * testsuite/27_io/filesystem/path/decompose/root_directory.cc:
6264 * testsuite/27_io/filesystem/path/decompose/root_name.cc:
6266 * testsuite/27_io/filesystem/path/decompose/root_path.cc:
6268 * testsuite/27_io/filesystem/path/decompose/stem.cc: Likewise.
6269 * testsuite/27_io/filesystem/path/factory/u8path-char8_t.cc:
6271 * testsuite/27_io/filesystem/path/factory/u8path.cc: Likewise.
6272 * testsuite/27_io/filesystem/path/generation/normal.cc:
6274 * testsuite/27_io/filesystem/path/generation/normal2.cc:
6276 * testsuite/27_io/filesystem/path/generation/proximate.cc:
6278 * testsuite/27_io/filesystem/path/generation/relative.cc:
6280 * testsuite/27_io/filesystem/path/generic/94242.cc: Likewise.
6281 * testsuite/27_io/filesystem/path/generic/generic_string.cc:
6283 * testsuite/27_io/filesystem/path/generic/utf.cc: Likewise.
6284 * testsuite/27_io/filesystem/path/generic/wchar_t.cc: Likewise.
6285 * testsuite/27_io/filesystem/path/io/dr2989.cc: Likewise.
6286 * testsuite/27_io/filesystem/path/itr/components.cc: Likewise.
6287 * testsuite/27_io/filesystem/path/itr/traversal.cc: Likewise.
6288 * testsuite/27_io/filesystem/path/modifiers/clear.cc: Likewise.
6289 * testsuite/27_io/filesystem/path/modifiers/make_preferred.cc:
6291 * testsuite/27_io/filesystem/path/modifiers/remove_filename.cc:
6293 * testsuite/27_io/filesystem/path/modifiers/replace_extension.cc:
6295 * testsuite/27_io/filesystem/path/modifiers/replace_filename.cc:
6297 * testsuite/27_io/filesystem/path/modifiers/swap.cc: Likewise.
6298 * testsuite/27_io/filesystem/path/native/alloc.cc: Likewise.
6299 * testsuite/27_io/filesystem/path/native/string-char8_t.cc:
6301 * testsuite/27_io/filesystem/path/native/string.cc: Likewise.
6302 * testsuite/27_io/filesystem/path/nonmember/append.cc: Likewise.
6303 * testsuite/27_io/filesystem/path/nonmember/cmp.cc: Likewise.
6304 * testsuite/27_io/filesystem/path/nonmember/hash_value.cc:
6306 * testsuite/27_io/filesystem/path/query/empty.cc: Likewise.
6307 * testsuite/27_io/filesystem/path/query/empty_neg.cc:
6308 * testsuite/27_io/filesystem/path/query/has_extension.cc:
6310 * testsuite/27_io/filesystem/path/query/has_filename.cc:
6312 * testsuite/27_io/filesystem/path/query/has_parent_path.cc:
6314 * testsuite/27_io/filesystem/path/query/has_relative_path.cc:
6316 * testsuite/27_io/filesystem/path/query/has_root_directory.cc:
6318 * testsuite/27_io/filesystem/path/query/has_root_name.cc:
6320 * testsuite/27_io/filesystem/path/query/has_root_path.cc:
6322 * testsuite/27_io/filesystem/path/query/has_stem.cc: Likewise.
6323 * testsuite/27_io/filesystem/path/query/is_absolute.cc:
6325 * testsuite/27_io/filesystem/path/query/is_relative.cc:
6327 * testsuite/experimental/filesystem/path/construct/string_view.cc:
6330 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
6332 * testsuite/20_util/specialized_algorithms/pstl/uninitialized_construct.cc:
6333 Remove -std=gnu++17 from dg-options.
6334 * testsuite/20_util/specialized_algorithms/pstl/uninitialized_copy_move.cc:
6336 * testsuite/20_util/specialized_algorithms/pstl/uninitialized_fill_destroy.cc:
6338 * testsuite/25_algorithms/pstl/alg_merge/inplace_merge.cc:
6340 * testsuite/25_algorithms/pstl/alg_merge/merge.cc: Likewise.
6341 * testsuite/25_algorithms/pstl/alg_modifying_operations/copy_if.cc:
6343 * testsuite/25_algorithms/pstl/alg_modifying_operations/copy_move.cc:
6345 * testsuite/25_algorithms/pstl/alg_modifying_operations/fill.cc:
6347 * testsuite/25_algorithms/pstl/alg_modifying_operations/generate.cc:
6349 * testsuite/25_algorithms/pstl/alg_modifying_operations/is_partitioned.cc:
6351 * testsuite/25_algorithms/pstl/alg_modifying_operations/partition.cc:
6353 * testsuite/25_algorithms/pstl/alg_modifying_operations/partition_copy.cc:
6355 * testsuite/25_algorithms/pstl/alg_modifying_operations/remove.cc:
6357 * testsuite/25_algorithms/pstl/alg_modifying_operations/remove_copy.cc:
6359 * testsuite/25_algorithms/pstl/alg_modifying_operations/replace.cc:
6361 * testsuite/25_algorithms/pstl/alg_modifying_operations/replace_copy.cc:
6363 * testsuite/25_algorithms/pstl/alg_modifying_operations/rotate.cc:
6365 * testsuite/25_algorithms/pstl/alg_modifying_operations/rotate_copy.cc:
6367 * testsuite/25_algorithms/pstl/alg_modifying_operations/swap_ranges.cc:
6369 * testsuite/25_algorithms/pstl/alg_modifying_operations/transform_binary.cc:
6371 * testsuite/25_algorithms/pstl/alg_modifying_operations/transform_unary.cc:
6373 * testsuite/25_algorithms/pstl/alg_modifying_operations/unique.cc:
6375 * testsuite/25_algorithms/pstl/alg_modifying_operations/unique_copy_equal.cc:
6377 * testsuite/25_algorithms/pstl/alg_nonmodifying/adjacent_find.cc:
6379 * testsuite/25_algorithms/pstl/alg_nonmodifying/all_of.cc:
6381 * testsuite/25_algorithms/pstl/alg_nonmodifying/any_of.cc:
6383 * testsuite/25_algorithms/pstl/alg_nonmodifying/count.cc:
6385 * testsuite/25_algorithms/pstl/alg_nonmodifying/equal.cc:
6387 * testsuite/25_algorithms/pstl/alg_nonmodifying/find.cc:
6389 * testsuite/25_algorithms/pstl/alg_nonmodifying/find_end.cc:
6391 * testsuite/25_algorithms/pstl/alg_nonmodifying/find_first_of.cc:
6393 * testsuite/25_algorithms/pstl/alg_nonmodifying/find_if.cc:
6395 * testsuite/25_algorithms/pstl/alg_nonmodifying/for_each.cc:
6397 * testsuite/25_algorithms/pstl/alg_nonmodifying/mismatch.cc:
6399 * testsuite/25_algorithms/pstl/alg_nonmodifying/none_of.cc:
6401 * testsuite/25_algorithms/pstl/alg_nonmodifying/nth_element.cc:
6403 * testsuite/25_algorithms/pstl/alg_nonmodifying/reverse.cc:
6405 * testsuite/25_algorithms/pstl/alg_nonmodifying/reverse_copy.cc:
6407 * testsuite/25_algorithms/pstl/alg_nonmodifying/search_n.cc:
6409 * testsuite/25_algorithms/pstl/alg_sorting/includes.cc:
6411 * testsuite/25_algorithms/pstl/alg_sorting/is_heap.cc: Likewise.
6412 * testsuite/25_algorithms/pstl/alg_sorting/is_sorted.cc:
6414 * testsuite/25_algorithms/pstl/alg_sorting/lexicographical_compare.cc:
6416 * testsuite/25_algorithms/pstl/alg_sorting/minmax_element.cc:
6418 * testsuite/25_algorithms/pstl/alg_sorting/partial_sort.cc:
6420 * testsuite/25_algorithms/pstl/alg_sorting/partial_sort_copy.cc:
6422 * testsuite/25_algorithms/pstl/alg_sorting/set.cc: Likewise.
6423 * testsuite/25_algorithms/pstl/alg_sorting/sort.cc: Likewise.
6424 * testsuite/25_algorithms/pstl/feature_test-2.cc: Likewise.
6425 * testsuite/25_algorithms/pstl/feature_test-3.cc: Likewise.
6426 * testsuite/25_algorithms/pstl/feature_test-4.cc: Likewise.
6427 * testsuite/25_algorithms/pstl/feature_test-5.cc: Likewise.
6428 * testsuite/25_algorithms/pstl/feature_test.cc: Likewise.
6429 * testsuite/26_numerics/pstl/numeric_ops/adjacent_difference.cc:
6431 * testsuite/26_numerics/pstl/numeric_ops/reduce.cc: Likewise.
6432 * testsuite/26_numerics/pstl/numeric_ops/scan.cc: Likewise.
6433 * testsuite/26_numerics/pstl/numeric_ops/transform_reduce.cc:
6435 * testsuite/26_numerics/pstl/numeric_ops/transform_scan.cc:
6438 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
6440 * testsuite/20_util/scoped_allocator/69293_neg.cc: Add dg-error
6441 for additional errors in C++20.
6442 * testsuite/20_util/specialized_algorithms/memory_management_tools/destroy_neg.cc:
6444 * testsuite/20_util/uses_allocator/69293_neg.cc: Likewise.
6445 * testsuite/27_io/filesystem/path/io/dr2989.cc: Likewise.
6447 2021-05-10 Jonathan Wakely <jwakely@redhat.com>
6449 * testsuite/20_util/variant/compile.cc: Rename 'any' to avoid
6450 clash with std::any.
6452 2021-05-07 Jonathan Wakely <jwakely@redhat.com>
6454 * include/std/istream (__rvalue_stream_extraction_t): Replace
6455 use of __rval_streamable.
6456 * include/std/ostream (__rvalue_stream_insertion_t): Likewise.
6457 (__rval_streamable): Remove.
6458 (_Require_derived_from_ios_base, __derived_from_ios_base): New
6459 helper for checking constraints.
6460 * testsuite/27_io/basic_istream/extractors_other/char/4.cc: Fix
6461 reference to the wrong subclause of the standard.
6462 * testsuite/27_io/basic_istream/extractors_other/wchar_t/4.cc:
6464 * testsuite/27_io/basic_ostream/inserters_other/char/6.cc:
6466 * testsuite/27_io/basic_ostream/inserters_other/wchar_t/6.cc:
6468 * testsuite/27_io/basic_ostream/inserters_other/char/99692.cc:
6470 * testsuite/27_io/filesystem/path/io/dr2989.cc: Adjust pruned
6473 2021-05-06 Jonathan Wakely <jwakely@redhat.com>
6475 * include/bits/stl_algobase.h (__copy_move, __copy_move_backward):
6476 Improve static_assert messages.
6477 * testsuite/25_algorithms/copy/58982.cc: Adjust expected output.
6478 * testsuite/25_algorithms/copy_n/58982.cc: Likewise.
6480 2021-05-06 Patrick Palka <ppalka@redhat.com>
6482 * include/std/ranges (filter_view::_Iterator::base): Make the
6483 const& overload unconstrained and return a const reference as
6484 per LWG 3533. Make unconditionally noexcept.
6485 (transform_view::_Iterator::base): Likewise.
6486 (elements_view::_Iterator::base): Likewise.
6488 2021-05-06 Patrick Palka <ppalka@redhat.com>
6490 * include/bits/stl_iterator.h (move_iterator::base): Make the
6491 const& overload unconstrained and return a const reference as
6492 per LWG 3391. Make unconditionally noexcept.
6493 (counted_iterator::base): Likewise.
6494 * testsuite/24_iterators/move_iterator/lwg3391.cc: New test.
6495 * testsuite/24_iterators/move_iterator/move_only.cc: Adjust
6496 has_member_base concept to decay-copy the result of base().
6498 2021-05-06 Jonathan Wakely <jwakely@redhat.com>
6500 * include/std/type_traits (remove_cvref_t): Define in terms of
6502 * testsuite/20_util/remove_cvref/value.cc: Check alias.
6504 2021-05-06 Jonathan Wakely <jwakely@redhat.com>
6507 2021-05-05 Jonathan Wakely <jwakely@redhat.com>
6509 * include/std/charconv (__from_chars_alnum): Pass unsigned
6510 char to std::isdigit.
6512 2021-05-05 Patrick Palka <ppalka@redhat.com>
6514 * include/bits/ranges_util.h (enable_borrowed_range<subrange>):
6515 Remove constraints on this partial specialization.
6516 * include/std/ranges (enable_borrowed_range<iota_view>):
6519 2021-05-05 Patrick Palka <ppalka@redhat.com>
6521 * include/std/ranges (transform_view::_Iterator::iter_swap):
6522 Remove as per LWG 3520.
6523 (join_view::_Iterator::iter_swap): Add indirectly_swappable
6524 constraint as per LWG 3517.
6526 2021-05-05 Jonathan Wakely <jwakely@redhat.com>
6528 * testsuite/20_util/function_objects/invoke/3.cc: Check feature
6530 * testsuite/20_util/function_objects/invoke/version.cc: New test.
6532 2021-05-05 Jonathan Wakely <jwakely@redhat.com>
6534 * include/std/charconv (__from_chars_alnum): Pass unsigned
6535 char to std::isdigit.
6537 2021-05-05 Corentin Gay <gay@adacore.com>
6539 * acinclude.m4: Add VxWorks-specific case for the
6540 configuration of ctypes.
6541 * configure: Regenerate.
6542 * config/locale/vxworks/ctype_members.cc: Add VxWorks-specific
6544 * config/os/vxworks/ctype_base.h: Adjust for VxWorks7+.
6545 * config/os/vxworks/ctype_configure_char.cc: Likewise.
6546 * config/os/vxworks/ctype_inline.h: Likewise.
6547 * testsuite/28_regex/traits/char/isctype.cc: Defines
6548 NEWLINE_IN_CLASS_BLANK if the target is VxWorks.
6549 * testsuite/28_regex/traits/wchar_t/isctype.cc: Likewise.
6551 2021-05-04 Jonathan Wakely <jwakely@redhat.com>
6553 * include/std/future (promise::set_value): Check for existence
6554 of shared state before dereferncing it.
6555 (promise::set_exception, promise::set_value_at_thread_exit)
6556 (promise::set_exception_at_thread_exit): Likewise.
6557 (promise<R&>::set_value, promise<R&>::set_exception)
6558 (promise<R&>::set_value_at_thread_exit)
6559 (promise<R&>::set_exception_at_thread_exit): Likewise.
6560 (promise<void>::set_value, promise<void>::set_exception)
6561 (promise<void>::set_value_at_thread_exit)
6562 (promise<void>::set_exception_at_thread_exit): Likewise.
6563 * testsuite/30_threads/promise/members/at_thread_exit2.cc:
6564 Remove unused variable.
6566 2021-05-04 Jonathan Wakely <jwakely@redhat.com>
6568 * include/bits/basic_string.h (basic_string(const CharT*, const A&)):
6569 Do not do arithmetic on null pointer.
6571 2021-05-04 Jonathan Wakely <jwakely@redhat.com>
6573 * include/ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp
6574 (find_key_pointer(key_const_reference, false_type))
6575 (find_key_pointer(key_const_reference, true_type)): Do not
6576 dereference null pointer.
6578 2021-05-04 Jonathan Wakely <jwakely@redhat.com>
6580 * testsuite/20_util/from_chars/3.cc: Use unsigned type to avoid
6582 * testsuite/24_iterators/reverse_iterator/2.cc: Do not add
6583 non-zero value to null pointer.
6584 * testsuite/25_algorithms/copy_backward/move_iterators/69478.cc:
6585 Use past-the-end iterator for result.
6586 * testsuite/25_algorithms/move_backward/69478.cc: Likewise.
6587 * testsuite/25_algorithms/move_backward/93872.cc: Likewise.
6589 2021-05-04 Jonathan Wakely <jwakely@redhat.com>
6592 * include/std/variant (__get_t): New alias template yielding the
6593 return type of std::get<N> on a variant.
6594 (__visit_result_t): New alias template yielding the result of
6596 (__same_types): Move into namespace __detail::__variant.
6597 (__check_visitor_results): Likewise. Use __invoke_result_t and
6599 (__check_visitor_result): Remove.
6600 (visit): Use __visit_result_t for return type.
6601 * testsuite/20_util/variant/100384.cc: New test.
6603 2021-05-04 Jonathan Wakely <jwakely@redhat.com>
6605 * acinclude.m4 (GLIBCXX_ENABLE_INT128_FLOAT128): Remove
6606 checks for __int128 and rename to GLIBCXX_ENABLE_FLOAT128.
6607 * config.h.in: Regenerate.
6608 * configure: Regenerate.
6609 * configure.ac: Adjust to use GLIBCXX_ENABLE_FLOAT128.
6610 * include/bits/random.h (_Select_uint_least_t<s, 1>):
6611 Use __SIZEOF_INT128__ to decide whether to use __int128.
6612 * include/std/charconv (__to_chars_unsigned_type): Likewise.
6614 2021-05-03 Gerald Pfeifer <gerald@pfeifer.com>
6616 * doc/xml/manual/ctype.xml: Move unix.org reference to https.
6617 * doc/html/manual/facets.html: Regenerate.
6619 2021-04-30 Patrick Palka <ppalka@redhat.com>
6621 * include/std/ranges (__detail::__non_propating_cache): Define
6623 (join_view): Remove constraints on the value and reference types
6624 of the wrapped iterator type as per P2328.
6625 (join_view::_Iterator::_M_satisfy): Adjust as per P2328.
6626 (join_view::_Iterator::operator++): Likewise.
6627 (join_view::_M_inner): Use __non_propating_cache as per P2328.
6628 Remove now-redundant use of __maybe_present_t.
6629 * testsuite/std/ranges/adaptors/join.cc: Include <array>.
6632 2021-04-30 Jonathan Wakely <jwakely@redhat.com>
6634 * include/bits/basic_string.h (__cpp_lib_constexpr_string):
6635 Only define for C++17 and later.
6636 * include/std/version (__cpp_lib_semaphore): Fix condition
6637 to match the one in <semaphore>.
6639 2021-04-30 Jonathan Wakely <jwakely@redhat.com>
6641 * acinclude.m4 (GLIBCXX_CHECK_INT64_T): Delete.
6642 * config.h.in: Regenerate.
6643 * configure: Regenerate.
6644 * configure.ac: Do not use GLIBCXX_CHECK_INT64_T.
6645 * include/bits/postypes.h: Remove include of <stdint.h> and
6646 definition/undefinition of the __STDC_LIMIT_MACROS and
6647 __STDC_CONSTANT_MACROS macros.
6648 (streamoff): Use __INT64_TYPE__ if defined.
6650 2021-04-30 Patrick Palka <ppalka@redhat.com>
6652 * include/std/ranges (split_view::_InnerIter::operator++):
6653 Depend on _Base instead of _Vp directly, as per LWG 3532.
6655 2021-04-30 Patrick Palka <ppalka@redhat.com>
6657 * include/bits/ranges_util.h (subrange::subrange): Avoid
6658 list-initialization in delegating constructor.
6659 * include/std/ranges (single_view): Replace implicit guide
6660 with explicit deduction guide that decays its argument.
6661 (_Single::operator()): Avoid CTAD when constructing the
6663 (_Iota::operator()): Avoid list-initialization.
6664 (__detail::__can_filter_view, _Filter::operator()): Likewise.
6665 (__detail::__can_transform_view, _Transform::operator()): Likewise.
6666 (take_view::begin): Likewise.
6667 (__detail::__can_take_view, _Take::operator()): Likewise.
6668 (__detail::__can_take_while_view, _TakeWhile::operator()): Likewise.
6669 (__detail::__can_drop_view, _Drop::operator()): Likewise.
6670 (__detail::__can_drop_while_view, _DropWhile::operator()): Likewise.
6671 (split_view::split_view): Use views::single when initializing
6673 (__detail::__can_split_view, _Split::operator()): Avoid
6674 list-initialization.
6675 (_Counted::operator()): Likewise.
6676 * testsuite/std/ranges/p2367.cc: New test.
6678 2021-04-30 Jonathan Wakely <jwakely@redhat.com>
6681 * include/bits/basic_ios.tcc (basic_ios::copyfmt): use
6683 * include/bits/basic_string.tcc (basic_string::swap)
6684 (basic_string::assign): Likewise.
6685 * include/bits/deque.tcc (deque::operator=(const deque&)):
6687 * include/bits/stl_tree.h (_Rb_tree::operator=(const * _Rb_tree&)):
6689 * include/bits/vector.tcc (vector::operator=(const vector&)):
6692 2021-04-30 Jonathan Wakely <jwakely@redhat.com>
6694 * include/std/istream (operator>>(Istream&&, x&)): Simplify, as
6696 * include/std/ostream (operator<<(Ostream&&, const x&)):
6698 * testsuite/27_io/basic_istream/extractors_character/char/lwg2499_neg.cc:
6699 Adjust dg-error pattern.
6700 * testsuite/27_io/basic_istream/extractors_character/wchar_t/lwg2499_neg.cc:
6702 * testsuite/27_io/basic_istream/extractors_other/char/4.cc: Define
6703 is_extractable trait to replace std::__is_extractable. Make it
6704 work with rvalue streams as well as lvalues, to replace f() and
6705 g() helper functions.
6706 * testsuite/27_io/basic_istream/extractors_other/wchar_t/4.cc:
6708 * testsuite/27_io/basic_ostream/inserters_other/char/6.cc:
6709 Define is_insertable trait to replace std::__is_insertable. Make
6710 it work with rvalue streams as well as lvalues, to replace f()
6711 and g() helper functions.
6712 * testsuite/27_io/basic_ostream/inserters_other/wchar_t/6.cc:
6714 * testsuite/27_io/filesystem/path/io/dr2989.cc: Prune additional
6715 errors from new constraints.
6716 * testsuite/27_io/rvalue_streams-2.cc: Remove PR 80675 checks,
6717 which are no longer expected to compile.
6718 * testsuite/27_io/rvalue_streams.cc: Adjust existing test.
6719 Verify LWG 1203 changes.
6721 2021-04-30 Jonathan Wakely <jwakely@redhat.com>
6724 * include/experimental/socket (__basic_socket_impl::set_option)
6725 (__basic_socket_impl::get_option) [!_GLIBCXX_HAVE_SYS_SOCKET_H]:
6726 Just set error code.
6727 * testsuite/experimental/net/socket/socket_base.cc: CHeck
6728 for <sys/socket.h> not <socket.h>.
6730 2021-04-30 Jonathan Wakely <jwakely@redhat.com>
6735 * testsuite/experimental/net/internet/address/v4/comparisons.cc:
6736 Use new effective-target keyword.
6737 * testsuite/experimental/net/internet/address/v4/cons.cc:
6739 * testsuite/experimental/net/internet/address/v4/creation.cc:
6741 * testsuite/experimental/net/internet/address/v4/members.cc:
6743 * testsuite/experimental/net/internet/address/v6/members.cc:
6745 * testsuite/experimental/net/internet/resolver/base.cc:
6747 * testsuite/experimental/net/internet/resolver/ops/lookup.cc:
6749 * testsuite/experimental/net/internet/resolver/ops/reverse.cc:
6751 * testsuite/experimental/net/internet/socket/opt.cc:
6753 * testsuite/experimental/net/internet/tcp.cc:
6755 * testsuite/experimental/net/internet/udp.cc:
6757 * testsuite/lib/libstdc++.exp (check_effective_target_net_ts_ip):
6758 New proc to check net_ts_ip et.
6760 2021-04-28 Jonathan Wakely <jwakely@redhat.com>
6763 * testsuite/20_util/pair/requirements/structural.cc: New test.
6765 2021-04-28 Jonathan Wakely <jwakely@redhat.com>
6767 * include/bits/stl_pair.h (pair) [__cplusplus > 202002]: Add
6768 new definitions for constructors and assignment operators using
6769 concepts for constraints.
6770 * testsuite/20_util/pair/cons/99957.cc: Disable for C++20 and
6772 * testsuite/20_util/pair/cons/explicit_construct.cc: Adjust
6773 expected error messages to also match C++20 errors.
6775 2021-04-28 Jonathan Wakely <jwakely@redhat.com>
6778 * include/bits/stl_pair.h (_PCC::_MoveCopyPair, _PCC::_CopyMovePair):
6779 Combine and replace with ...
6780 (_PCC::_DeprConsPair): New SFINAE helper function.
6781 (pair): Merge preprocessor blocks so that all C++03 members
6782 are defined together at the end.
6783 (pair::pair(const _T1&, _U2&&), pair::pair(_U1&&, const _T2&)):
6784 Replace _T1 and _T2 parameters with __null_ptr_constant and
6786 * testsuite/20_util/pair/40925.cc: Use nullptr instead of 0.
6787 * testsuite/20_util/pair/cons/explicit_construct.cc: Likewise.
6788 * testsuite/20_util/pair/cons/99957.cc: New test.
6790 2021-04-28 Jonathan Wakely <jwakely@redhat.com>
6792 * include/bits/basic_string.h (__cpp_lib_constexpr_string): Define.
6793 * include/std/version (__cpp_lib_constexpr_string): Define.
6794 * testsuite/21_strings/char_traits/requirements/constexpr_functions_c++17.cc:
6795 Check for __cpp_lib_constexpr_string.
6796 * testsuite/21_strings/char_traits/requirements/constexpr_functions_c++20.cc:
6798 * testsuite/21_strings/char_traits/requirements/version.cc: New test.
6800 2021-04-28 Jonathan Wakely <jwakely@redhat.com>
6802 * doc/Makefile.am (stamp-pdf-doxygen): Improve comment about
6803 dealing with errors. Use '@' to prevent shell command being
6805 * doc/Makefile.in: Regenerate.
6807 2021-04-28 Jonathan Wakely <jwakely@redhat.com>
6810 * include/bits/std_thread.h (thread::hardware_concurrency): Add
6811 missing noexcept to inline definition for non-gthreads targets.
6813 2021-04-28 Patrick Palka <ppalka@redhat.com>
6819 * include/bits/ranges_algo.h (__search_n_fn::operator()): Give
6820 the __value_comp lambda an explicit bool return type.
6821 (__is_permutation_fn::operator()): Give the __proj_scan local
6822 variable auto&& return type. Give the __comp_scan lambda an
6823 explicit bool return type.
6824 (__remove_fn::operator()): Give the __pred lambda an explicit
6826 (__partition_fn::operator()): Don't std::move __first twice
6827 when returning an empty subrange.
6828 (__min_fn::operator()): Don't std::move __comp.
6829 (__max_fn::operator()): Likewise.
6830 (__minmax_fn::operator()): Likewise.
6832 2021-04-27 Patrick Palka <ppalka@redhat.com>
6835 * include/std/ranges (join_view::_Iterator::operator++): Correct
6836 the return type of the lambda to avoid returning a copy of
6837 _M_parent->_M_inner.
6838 * testsuite/std/ranges/adaptors/join.cc (test10): New test.
6840 2021-04-27 Jakub Jelinek <jakub@redhat.com>
6843 2021-04-22 Jakub Jelinek <jakub@redhat.com>
6846 * testsuite/29_atomics/atomic_float/1.cc: Add dg-xfail-run-if for
6848 * testsuite/29_atomics/atomic_float/wait_notify.cc: Add dg-skip-if for
6851 2021-04-27 Jonathan Wakely <jwakely@redhat.com>
6853 * include/experimental/internet (address_v6::bytes_type): Adjust
6855 (basic_endpoint): Define _M_is_v6() to put all checks for
6856 AF_INET6 in one place.
6857 (basic_endpoint::resize): Simplify.
6858 (operator==(const tcp&, const tcp&)): Add constexpr and noexcept.
6859 (operator!=(const tcp&, const tcp&)): Likewise.
6860 (operator==(const udp&, const udp&)): Likewise.
6861 (operator!=(const udp&, const udp&)): Likewise.
6862 * testsuite/experimental/net/internet/tcp.cc: New test.
6863 * testsuite/experimental/net/internet/udp.cc: New test.
6865 2021-04-27 Jonathan Wakely <jwakely@redhat.com>
6868 * include/experimental/internet (resolver_errc, resolver_category())
6869 (make_error_code, make_error_condition): Define unconditionally,
6870 only make enumerators and use of gai_strerror depend on the
6871 availability of <netdb.h>.
6872 (address_v4::to_string): Use correct constant for string length.
6873 (address_v4::to_string, address_v6::to_string): Define
6874 unconditionally, throw if unsupported.
6875 (make_address_v4, make_address_v6): Define unconditionally.
6876 Return an error if unsupported.
6877 (tcp, udp, v6_only, unicast::hops, multicast::*): Define
6879 * testsuite/experimental/net/internet/socket/opt.cc: Check for
6880 <netinet/in.h> and <netinet/tcp.h> before using types from
6883 2021-04-27 Jonathan Wakely <jwakely@redhat.com>
6886 * include/experimental/internet (resolver_base::flags):
6887 Define overloaded operators as hidden friends.
6888 * include/experimental/socket (socket_base::message_flags):
6891 2021-04-26 Jonathan Wakely <jwakely@redhat.com>
6893 * include/experimental/internet (tcp::no_delay, v6_only)
6894 (unicast::hops, multicast::hops, multicast::enable_loopback):
6895 Change access of base class and static data members. Add
6896 using-declaration for __socket_crtp::operator=(_Tp).
6897 (multicast::__mcastopt): New type.
6898 (multicast::join_group, multicast::leave_group): Derive from
6899 __mcastopt for common implementation.
6900 * include/experimental/socket: Add comment.
6901 * testsuite/experimental/net/internet/socket/opt.cc: New test.
6902 * testsuite/experimental/net/socket/socket_base.cc: Check for
6903 protected constructor/destructor of socket_base. Check for
6904 explicit constructors of socket option classes.
6906 2021-04-26 Jonathan Wakely <jwakely@redhat.com>
6908 * include/experimental/bits/net.h (__socket_base): Add
6909 bool template parameter to allow BooleanSocketOption and
6910 IntegerSocketOption to have different __socket_base<int>
6912 (__socket_base<bool>): Adjust base class.
6913 (__socket_base<int>): Add partial specialization.
6914 (__socket_crtp::operator=(_Tp)): Add noexcept-specifier.
6915 * include/experimental/socket (socket_base::broadcast)
6916 (socket_base::debug, socket_base::do_not_route)
6917 (socket_base::keep_alive, socket_base::linger)
6918 (socket_base::out_of_band_inline)
6919 (socket_base::receive_buffer_size)
6920 (socket_base::receive_low_watermark)
6921 (socket_base::reuse_address, socket_base::send_buffer_size)
6922 (socket_base::send_low_watermark): Add using-declaration for
6923 __socket_crtp::operator=(_Tp).
6924 * testsuite/experimental/net/socket/socket_base.cc: Check
6925 properties of socket option types.
6927 2021-04-26 Jonathan Wakely <jwakely@redhat.com>
6929 * include/experimental/internet (resolver_base::flags): Remove
6930 enumerators. Initialize constants directly with desired values.
6931 Make all operators constexpr and noexcept.
6932 * testsuite/experimental/net/internet/resolver/base.cc: Use
6933 __gnu_test::test_bitmask_values for bitmask type. Check
6934 construction and destruction is protected.
6936 2021-04-26 Jonathan Wakely <jwakely@redhat.com>
6938 * include/bits/semaphore_base.h: Include <exception> and <errno.h>.
6940 2021-04-26 Jonathan Wakely <jwakely@redhat.com>
6943 * include/experimental/internet (net::ip::make_error_code)
6944 (net::ip::make_error_condition, net::ip::make_network_v4)
6945 (net::ip::operator==(const udp&, const udp&)): Add 'inline'.
6947 2021-04-24 David Edelsohn <dje.gcc@gmail.com>
6949 * testsuite/lib/dg-options.exp (atomic_link_flags): New.
6950 (add_options_for_libatomic): Use atomic_link_flags.
6952 2021-04-23 Jonathan Wakely <jwakely@redhat.com>
6955 * include/experimental/io_context (io_context): Define
6956 dummy_pollfd type so that most member functions still compile
6957 without <poll.h> and struct pollfd.
6959 2021-04-23 Jonathan Wakely <jwakely@redhat.com>
6961 * include/experimental/io_context (io_context::async_wait): Add
6963 * include/experimental/socket (basic_socket::async_connect):
6964 Cast wait_type constant to int.
6965 (basic_datagram_socket::async_receive): Likewise.
6966 (basic_datagram_socket::async_receive_from): Likewise.
6967 (basic_datagram_socket::async_send): Likewise.
6968 (basic_datagram_socket::async_send_to): Likewise.
6969 (basic_stream_socket::async_receive): Likewise.
6970 (basic_stream_socket::async_send): Likewise. Use io_context
6971 parameter directly, instead of via an executor.
6972 (basic_socket_acceptor::async_accept): Likewise.
6974 2021-04-23 Jonathan Wakely <jwakely@redhat.com>
6976 * include/experimental/socket (socket_base::shutdown_type):
6977 (socket_base::wait_type, socket_base::message_flags):
6978 Remove enumerators. Initialize constants directly with desired
6980 (socket_base::message_flags): Make all operators constexpr and
6982 * testsuite/util/testsuite_common_types.h (test_bitmask_values):
6984 * testsuite/experimental/net/socket/socket_base.cc: New test.
6986 2021-04-22 David Edelsohn <dje.gcc@gmail.com>
6988 * config/os/aix/atomicity.h: Delete.
6990 2021-04-22 Jonathan Wakely <jwakely@redhat.com>
6992 * include/bits/atomic_timed_wait.h (__cond_wait_until_impl):
6993 Handle system_clock as well as steady_clock.
6994 * testsuite/30_threads/semaphore/try_acquire_for.cc: Re-enable.
6995 * testsuite/30_threads/semaphore/try_acquire_until.cc:
6998 2021-04-22 Jonathan Wakely <jwakely@redhat.com>
7000 * testsuite/30_threads/semaphore/try_acquire_posix.cc: Add
7001 options for libatomic.
7003 2021-04-22 Jonathan Wakely <jwakely@redhat.com>
7005 * config/os/gnu-linux/os_defines.h: Fix type in comment.
7007 2021-04-22 Jonathan Wakely <jwakely@redhat.com>
7010 * include/bits/shared_ptr.h (allocate_shared): Assert that _Tp
7011 is not an array type.
7012 * include/bits/shared_ptr_base.h (__allocate_shared): Likewise.
7013 * testsuite/20_util/shared_ptr/creation/99006.cc: New test.
7015 2021-04-22 Thomas Rodgers <rodgert@twrodgers.com>
7017 * include/bits/atomic_wait.h: Always notify waiters in the
7018 case of 'bare' address notification.
7020 2021-04-22 Jakub Jelinek <jakub@redhat.com>
7023 * testsuite/29_atomics/atomic_float/1.cc: Add dg-xfail-run-if for
7025 * testsuite/29_atomics/atomic_float/wait_notify.cc: Add dg-skip-if for
7028 2021-04-22 Jonathan Wakely <jwakely@redhat.com>
7031 * include/bits/semaphore_base.h: Remove #error.
7032 * include/std/semaphore: Do not define anything unless one of
7033 the implementations is available.
7035 2021-04-21 Thomas Rodgers <rodgert@twrodgers.com>
7037 * include/bits/semaphore_base.h: Always reload __old in
7038 __atomic_semaphore::_S_do_try_acquire().
7039 * testsuite/30_threads/stop_token/stop_callback/destroy.cc:
7042 2021-04-21 Philippe Blain <levraiphilippeblain@gmail.com>
7043 Jonathan Wakely <jwakely@redhat.com>
7046 * python/Makefile.am: Install libstdc++*-gdb.py more robustly.
7047 * python/Makefile.in: Regenerate.
7049 2021-04-21 Thomas Rodgers <rodgert@twrodgers.com>
7051 * include/bits/semaphore_base.h: Add missing _M_try_acquire()
7052 member to __platform_wait.
7054 2021-04-21 Jonathan Wakely <jwakely@redhat.com>
7056 * include/std/latch: Replace tab characters in license text.
7057 * include/std/semaphore: Likewise.
7059 2021-04-21 Jakub Jelinek <jakub@redhat.com>
7062 * acinclude.m4: For POSIX semaphores AC_DEFINE HAVE_POSIX_SEMAPHORE
7063 rather than _GLIBCXX_HAVE_POSIX_SEMAPHORE.
7064 * configure: Regenerated.
7065 * config.h.in: Regenerated.
7067 2021-04-20 Jonathan Wakely <jwakely@redhat.com>
7069 * testsuite/30_threads/semaphore/try_acquire_for.cc: Disable
7070 test for targets not using futexes for semaphores.
7071 * testsuite/30_threads/semaphore/try_acquire_until.cc: Likewise.
7072 * testsuite/30_threads/stop_token/stop_callback/destroy.cc:
7073 Disable for all targets.
7075 2021-04-20 Thomas Rodgers <trodgers@redhat.com>
7077 * include/Makefile.am: Add new <bits/this_thread_sleep.h> header.
7078 * include/Makefile.in: Regenerate.
7079 * include/bits/this_thread_sleep.h: New file.
7080 * include/bits/atomic_base.h: Adjust all calls
7081 to __atomic_wait/__atomic_notify for new call signatures.
7082 * include/bits/atomic_timed_wait.h: Extensive rewrite.
7083 * include/bits/atomic_wait.h: Likewise.
7084 * include/bits/semaphore_base.h: Adjust all calls
7085 to __atomic_wait/__atomic_notify for new call signatures.
7086 * include/std/atomic: Likewise.
7087 * include/std/barrier: Likewise.
7088 * include/std/latch: Likewise.
7089 * include/std/semaphore: Likewise.
7090 * include/std/thread (this_thread::sleep_for)
7091 (this_thread::sleep_until): Move to new header.
7092 * testsuite/29_atomics/atomic/wait_notify/bool.cc: Simplify
7094 * testsuite/29_atomics/atomic/wait_notify/generic.cc: Likewise.
7095 * testsuite/29_atomics/atomic/wait_notify/pointers.cc: Likewise.
7096 * testsuite/29_atomics/atomic_flag/wait_notify/1.cc: Likewise.
7097 * testsuite/29_atomics/atomic_float/wait_notify.cc: Likewise.
7098 * testsuite/29_atomics/atomic_integral/wait_notify.cc: Likewise.
7099 * testsuite/29_atomics/atomic_ref/wait_notify.cc: Likewise.
7101 2021-04-20 Patrick Palka <ppalka@redhat.com>
7104 * include/bits/stl_iterator.h (__detail::__move_iter_cat):
7106 (move_iterator): Derive from the above in C++20 in order to
7107 conditionally define iterator_category as per P2259.
7108 (move_iterator::__base_cat): No longer used, so remove.
7109 (move_iterator::iterator_category): Remove in C++20.
7110 (__detail::__common_iter_use_postfix_proxy): Define.
7111 (common_iterator::_Proxy): Rename to ...
7112 (common_iterator:__arrow_proxy): ... this.
7113 (common_iterator::__postfix_proxy): Define as per P2259.
7114 (common_iterator::operator->): Adjust.
7115 (common_iterator::operator++): Adjust as per P2259.
7116 (iterator_traits<common_iterator>::_S_iter_cat): Define.
7117 (iterator_traits<common_iterator>::iterator_category): Change as
7119 (__detail::__counted_iter_value_type): Define.
7120 (__detail::__counted_iter_concept): Define.
7121 (__detail::__counted_iter_cat): Define.
7122 (counted_iterator): Derive from the above three classes in order
7123 to conditionally define value_type, iterator_concept and
7124 iterator category respectively as per P2259.
7125 (counted_iterator::operator->): Define as per P2259.
7126 (incrementable_traits<counted_iterator>): Remove as per P2259.
7127 (iterator_traits<counted_iterator>): Adjust as per P2259.
7128 * include/std/ranges (__detail::__iota_view_iter_cat): Define.
7129 (iota_view::_Iterator): Derive from the above in order to
7130 conditionally define iterator_category as per P2259.
7131 (iota_view::_S_iter_cat): Rename to ...
7132 (iota_view::_S_iter_concept): ... this.
7133 (iota_view::iterator_concept): Use it to apply LWG 3291 changes.
7134 (iota_view::iterator_category): Remove.
7135 (__detail::__filter_view_iter_cat): Define.
7136 (filter_view::_Iterator): Derive from the above in order to
7137 conditionally define iterator_category as per P2259.
7138 (filter_view::_Iterator): Move to struct __filter_view_iter_cat.
7139 (filter_view::_Iterator::iterator_category): Remove.
7140 (transform_view::_Base): Define.
7141 (transform_view::__iter_cat): Define.
7142 (transform_view::_Iterator): Derive from the above in order to
7143 conditionally define iterator_category as per P2259.
7144 (transform_view::_Iterator::_Base): Just alias
7145 transform_view::_Base.
7146 (transform_view::_Iterator::_S_iter_cat): Move to struct
7147 transform_view::__iter_cat.
7148 (transform_view::_Iterator::iterator_category): Remove.
7149 (transform_view::_Sentinel::_Base): Just alias
7150 transform_view::_Base.
7151 (join_view::_Base): Define.
7152 (join_view::_Outer_iter): Define.
7153 (join_view::_Inner_iter): Define.
7154 (join_view::_S_ref_is_glvalue): Define.
7155 (join_view::__iter_cat): Define.
7156 (join_view::_Iterator): Derive from it in order to conditionally
7157 define iterator_category as per P2259.
7158 (join_view::_Iterator::_Base): Just alias join_view::_Base.
7159 (join_view::_Iterator::_S_ref_is_glvalue): Just alias
7160 join_view::_S_ref_is_glvalue.
7161 (join_view::_Iterator::_S_iter_cat): Move to struct
7162 transform_view::__iter_cat.
7163 (join_view::_Iterator::_Outer_iter): Just alias
7164 join_view::_Outer_iter.
7165 (join_view::_Iterator::_Inner_iter): Just alias
7166 join_view::_Inner_iter.
7167 (join_view::_Iterator::iterator_category): Remove.
7168 (join_view::_Sentinel::_Base): Just alias join_view::_Base.
7169 (__detail::__split_view_outer_iter_cat): Define.
7170 (__detail::__split_view_inner_iter_cat): Define.
7171 (split_view::_Base): Define.
7172 (split_view::_Outer_iter): Derive from __split_view_outer_iter_cat
7173 in order to conditionally define iterator_category as per P2259.
7174 (split_view::_Outer_iter::iterator_category): Remove.
7175 (split_view::_Inner_iter): Derive from __split_view_inner_iter_cat
7176 in order to conditionally define iterator_category as per P2259.
7177 (split_view::_Inner_iter::_S_iter_cat): Move to
7178 __split_view_inner_iter_cat.
7179 (split_view::_Inner_iter::iterator_category): Remove.
7180 (elements_view::_Base): Define.
7181 (elements_view::__iter_cat): Define.
7182 (elements_view::_Iterator): Derive from the above in order to
7183 conditionall define iterator_category as per P2259.
7184 (elements_view::_Iterator::_Base): Just alias
7185 elements_view::_Base.
7186 (elements_view::_Iterator::_S_iter_concept)
7187 (elements_view::_Iterator::iterator_concept): Define as per
7189 (elements_view::_Iterator::iterator_category): Remove.
7190 (elements_view::_Sentinel::_Base): Just alias
7191 elements_view::_Base.
7192 * testsuite/24_iterators/headers/iterator/synopsis_c++20.cc:
7193 Adjust constraints on iterator_traits<counted_iterator>.
7194 * testsuite/std/ranges/p2259.cc: New test.
7196 2021-04-20 Jonathan Wakely <jwakely@redhat.com>
7199 * include/std/charconv (__cpp_lib_to_chars): Define
7201 * include/std/version (__cpp_lib_to_chars): Likewise..
7202 * testsuite/20_util/from_chars/4.cc: Only check feature test
7203 macro, not _GLIBCXX_HAVE_USELOCALE.
7204 * testsuite/20_util/from_chars/5.cc: Likewise.
7205 * testsuite/20_util/from_chars/6.cc: Likewise.
7206 * testsuite/20_util/to_chars/long_double.cc: Likewise.
7208 2021-04-20 Jakub Jelinek <jakub@redhat.com>
7210 * testsuite/util/testsuite_abi.cc (compare_symbols): If any symbol
7211 versions with _IEEE128_ substring are found, set ieee_version_found
7212 to true. Ignore missing symbols with _IEEE128_ in version name if
7213 !ieee_version_found. Use i->first as version_name instead of
7214 i->second.version_name if the latter is empty.
7215 * config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt: Update.
7217 2021-04-19 H.J. Lu <hjl.tools@gmail.com>
7219 * config/abi/post/x86_64-linux-gnu/x32/baseline_symbols.txt:
7222 2021-04-17 Jakub Jelinek <jakub@redhat.com>
7224 * config/abi/post/powerpc-linux-gnu/baseline_symbols.txt: Update.
7225 * config/abi/post/powerpc64-linux-gnu/32/baseline_symbols.txt: Update.
7227 2021-04-17 Jakub Jelinek <jakub@redhat.com>
7229 * config/abi/post/x86_64-linux-gnu/baseline_symbols.txt: Update.
7230 * config/abi/post/x86_64-linux-gnu/32/baseline_symbols.txt: Update.
7231 * config/abi/post/i386-linux-gnu/baseline_symbols.txt: Update.
7232 * config/abi/post/i486-linux-gnu/baseline_symbols.txt: Update.
7233 * config/abi/post/s390x-linux-gnu/baseline_symbols.txt: Update.
7234 * config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt: Update.
7236 2021-04-15 Jonathan Wakely <jwakely@redhat.com>
7238 * testsuite/lib/dg-options.exp (add_options_for_libatomic): Also
7239 add libatomic options for 32-bit sparc*-*-linux-gnu.
7241 2021-04-15 Jonathan Wakely <jwakely@redhat.com>
7244 * libsupc++/Makefile.am: Add atomicity.cc here.
7245 * src/c++98/Makefile.am: Remove it from here.
7246 * libsupc++/Makefile.in: Regenerate.
7247 * src/c++98/Makefile.in: Regenerate.
7248 * testsuite/18_support/exception_ptr/96657.cc: New test.
7250 2021-04-13 Jonathan Wakely <jwakely@redhat.com>
7253 * include/std/bit: Only include <ext/numeric_traits.h> for
7254 hosted build, use <limits> otherwise.
7256 2021-04-13 Jonathan Wakely <jwakely@redhat.com>
7258 * doc/xml/manual/backwards_compatibility.xml: Remove porting
7259 notes for libg++ and libstdc++-v2, and bibliography.
7260 * doc/html/*: Regenerated.
7262 2021-04-12 Jonathan Wakely <jwakely@redhat.com>
7265 * include/bits/ranges_util.h (__detail::__iterator_sentinel_pair):
7266 Remove helper concept.
7267 (subrange(_Pr), subrange(Pr, __make_unsigned_like<...>)): Remove
7268 deduction guides, as per LWG 3404.
7269 * testsuite/std/ranges/subrange/lwg3282_neg.cc: Check that class
7270 template argument deduction fails.
7272 2021-04-12 Jonathan Wakely <jwakely@redhat.com>
7274 * testsuite/26_numerics/random/linear_congruential_engine/requirements/non_uint_neg.cc:
7275 Adjust expected error for C++20 mode.
7276 * testsuite/tr1/5_numerical_facilities/random/linear_congruential/requirements/non_uint_neg.cc:
7279 2021-04-12 Jonathan Wakely <jwakely@redhat.com>
7282 * testsuite/17_intro/headers/c++1998/49745.cc: Include all
7283 standard headers and XFAIL for effective-target c++20.
7285 2021-04-09 François Dumont <fdumont@gcc.gnu.org>
7288 * include/debug/helper_functions.h (__can_advance(_InputIterator,
7289 const std::pair<_Diff, _Distance_precision>&, int)): New.
7290 (__can_advance(const _Safe_iterator<>&,
7291 const std::pair<_Diff, _Distance_precision>&, int)): New.
7292 * include/debug/macros.h (__glibcxx_check_can_increment_dist): New,
7294 (__glibcxx_check_can_increment_range): Adapt to use latter.
7295 (__glibcxx_check_can_decrement_range): Likewise.
7296 * include/debug/safe_iterator.h
7297 (_Safe_iterator<>::_M_can_advance(const std::pair<_Diff, _Distance_precision>&,
7299 (__can_advance(const _Safe_iterator<>&,
7300 const std::pair<_Diff, _Distance_precision>&, int)): New.
7301 * include/debug/safe_iterator.tcc
7302 (_Safe_iterator<>::_M_can_advance(const std::pair<_Diff, _Distance_precision>&,
7304 (_Safe_iterator<>::_M_valid_range(const _Safe_iterator<>&,
7305 std::pair<difference_type, _Distance_precision>&, bool)): Adapt for
7307 (__copy_move_a): Adapt to use __glibcxx_check_can_increment_dist.
7308 (__copy_move_backward_a): Likewise.
7309 (__equal_aux): Likewise.
7310 * include/debug/stl_iterator.h (__can_advance(const std::reverse_iterator<>&,
7311 const std::pair<_Diff, _Distance_precision>&, int)): New.
7312 (__can_advance(const std::move_iterator<>&,
7313 const std::pair<_Diff, _Distance_precision>&, int)): New.
7314 * testsuite/25_algorithms/copy/debug/99402.cc: New test.
7316 2021-04-09 Jonathan Wakely <jwakely@redhat.com>
7319 * include/bits/hashtable.h (_Hashtable::_S_nothrow_move()): Fix
7320 to be a valid constexpr function in C++11.
7321 * testsuite/23_containers/unordered_set/cons/99985.cc: New test.
7323 2021-04-09 Jonathan Wakely <jwakely@redhat.com>
7325 * include/bits/fs_fwd.h: Fix doxygen group command.
7326 * include/bits/streambuf_iterator.h: Likewise.
7327 * include/bits/uses_allocator_args.h: Likewise.
7328 * include/std/memory: Likewise.
7329 * include/tr1/complex: Likewise.
7331 2021-04-08 Jonathan Wakely <jwakely@redhat.com>
7333 * include/bits/basic_string.h: Tweak doxygen comment.
7335 2021-04-08 Patrick Palka <ppalka@redhat.com>
7337 * include/std/ranges (__detail::find): Define.
7338 (split_view::_OuterIter::operator++): Apply proposed resolution
7340 * testsuite/std/ranges/adaptors/split.cc (test10): New test.
7342 2021-04-08 Patrick Palka <ppalka@redhat.com>
7344 * include/std/ranges (__detail::find_if): Simplify.
7345 (__detail::find_if_not): Likewise.
7346 (__detail::min): Remove.
7347 (__detail::mismatch): Simplify.
7348 (take_view::size): Use std::min instead of __detail::min.
7350 2021-04-08 Patrick Palka <ppalka@redhat.com>
7352 * include/std/ranges (__detail::__returnable_element): New
7354 (elements_view): Use this concept in its constraints. Add
7355 missing private access specifier.
7356 (elements_view::_S_get_element): Define as per LWG 3502.
7357 (elements_view::operator*, elements_view::operator[]): Use
7359 (elements_view::operator++): Remove unnecessary constraint
7361 * testsuite/std/ranges/adaptors/elements.cc (test05): New test.
7363 2021-04-08 Jonathan Wakely <jwakely@redhat.com>
7365 * doc/Makefile.am (stamp-pdf-doxygen): Also grep for
7366 out-of-memory error in log file.
7367 * doc/Makefile.in: Regenerate.
7369 2021-04-08 Jonathan Wakely <jwakely@redhat.com>
7371 * configure: Regenerate.
7373 2021-04-08 Jonathan Wakely <jwakely@redhat.com>
7375 * include/bits/random.h: Fix doxygen group commands.
7376 * include/bits/regex_constants.h: Likewise.
7377 * include/tr1/random.h: Likewise.
7379 2021-04-08 Jonathan Wakely <jwakely@redhat.com>
7381 * include/bits/hashtable.h (_Hashtable::_S_nothrow_move()):
7382 New function to determine noexcept-specifier for move
7384 (_Hashtable): Use _S_nothrow_move() on move constructors.
7385 * testsuite/23_containers/unordered_map/cons/noexcept_move_construct.cc:
7386 Correct static assertion message.
7387 * testsuite/23_containers/unordered_multimap/cons/noexcept_move_construct.cc:
7389 * testsuite/23_containers/unordered_multiset/cons/noexcept_move_construct.cc:
7391 * testsuite/23_containers/unordered_set/cons/noexcept_move_construct.cc:
7394 2021-04-08 Patrick Palka <ppalka@redhat.com>
7397 * testsuite/20_util/to_chars/long_double.cc: Don't run the test
7398 on targets without a large long double. XFAIL the execution on
7399 targets with a non-conforming printf.
7401 2021-04-08 Patrick Palka <ppalka@redhat.com>
7404 * include/std/ranges (__adaptor::__maybe_refwrap): Remove.
7405 (__adaptor::__adaptor_invocable): New concept.
7406 (__adaptor::__adaptor_partial_app_viable): New concept.
7407 (__adaptor::_RangeAdaptorClosure): Rewrite, turning it into a
7408 non-template base class.
7409 (__adaptor::_RangeAdaptor): Rewrite, turning it into a CRTP base
7411 (__adaptor::_Partial): New class template that represents
7412 partial application of a range adaptor non-closure.
7413 (__adaptor::__pipe_invocable): New concept.
7414 (__adaptor::_Pipe): New class template.
7415 (__detail::__can_ref_view): New concept.
7416 (__detail::__can_subrange): New concept.
7417 (all): Replace the lambda here with ...
7418 (_All): ... this functor. Add appropriate constraints.
7419 (__detail::__can_filter_view): New concept.
7420 (filter, _Filter): As in all/_All.
7421 (__detail::__can_transform): New concept.
7422 (transform, _Transform): As in all/_All.
7423 (__detail::__can_take_view): New concept.
7424 (take, _Take): As in all/_All.
7425 (__detail::__can_take_while_view): New concept.
7426 (take_while, _TakeWhile): As in all/_All.
7427 (__detail::__can_drop_view): New concept.
7428 (drop, _Drop): As in all/_All.
7429 (__detail::__can_drop_while_view): New concept.
7430 (drop_while, _DropWhile): As in all/_All.
7431 (__detail::__can_join_view): New concept.
7432 (join, _Join): As in all/_All.
7433 (__detail::__can_split_view): New concept.
7434 (split, _Split): As in all/_All. Rename template parameter
7436 (__detail::__already_common): New concept.
7437 (__detail::__can_common_view): New concept.
7438 (common, _Common): As in all/_All.
7439 (__detail::__can_reverse_view): New concept.
7440 (reverse, _Reverse): As in all/_All.
7441 (__detail::__can_elements_view): New concept.
7442 (elements, _Elements): As in all/_All.
7443 (keys, values): Adjust.
7444 * testsuite/std/ranges/adaptors/99433.cc: New test.
7445 * testsuite/std/ranges/adaptors/all.cc: No longer expect that
7446 adding empty range adaptor closure objects to a pipeline doesn't
7447 increase the size of the pipeline.
7449 * testsuite/std/ranges/adaptors/common.cc (test03): New test.
7450 * testsuite/std/ranges/adaptors/drop.cc (test09): New test.
7451 * testsuite/std/ranges/adaptors/drop_while.cc (test04): New test.
7452 * testsuite/std/ranges/adaptors/elements.cc (test04): New test.
7453 * testsuite/std/ranges/adaptors/filter.cc (test06): New test.
7454 * testsuite/std/ranges/adaptors/join.cc (test09): New test.
7455 * testsuite/std/ranges/adaptors/p2281.cc: New test.
7456 * testsuite/std/ranges/adaptors/reverse.cc (test07): New test.
7457 * testsuite/std/ranges/adaptors/split.cc (test01, test04):
7460 * testsuite/std/ranges/adaptors/split_neg.cc (test01): Adjust
7461 expected error message.
7462 (test02): Likewise. Extend test.
7463 * testsuite/std/ranges/adaptors/take.cc (test06): New test.
7464 * testsuite/std/ranges/adaptors/take_while.cc (test05): New test.
7465 * testsuite/std/ranges/adaptors/transform.cc (test07, test08):
7468 2021-04-08 Jonathan Wakely <jwakely@redhat.com>
7470 * include/std/string_view: Adjust Doxygen @file comment.
7472 2021-04-08 Jonathan Wakely <jwakely@redhat.com>
7474 * include/std/type_traits (is_scoped_enum<T>): Constrain partial
7475 specialization to not match incomplete enum types. Use a
7476 requires-expression instead of instantiating is_convertible.
7477 (is_scoped_enum<const T>): Add as workaround for PR c++/99968.
7478 * testsuite/20_util/is_scoped_enum/value.cc: Check with
7479 incomplete types and opaque-enum-declarations.
7481 2021-04-07 Jonathan Wakely <jwakely@redhat.com>
7484 * src/c++17/fs_path.cc (path::_M_split_cmpts): Do not call
7485 non-const member on _M_pathname, to avoid copy-on-write.
7486 * testsuite/27_io/filesystem/path/decompose/parent_path.cc:
7487 Check construction from strings that might be shared.
7489 2021-04-06 Jonathan Wakely <jwakely@redhat.com>
7491 * include/bits/move.h (forward, move, move_if_noexcept)
7492 (addressof): Add _GLIBCXX_NODISCARD.
7493 * include/bits/ranges_cmp.h (identity::operator()): Add
7494 nodiscard attribute.
7495 * include/c_global/cstddef (to_integer): Likewise.
7496 * include/std/bit (bit_cast): Likewise.
7497 * include/std/utility (as_const, to_underlying): Likewise.
7499 2021-04-06 Jonathan Wakely <jwakely@redhat.com>
7501 * include/bits/move.h (forward): Change static_assert message
7502 to be unambiguous about what must be true.
7503 * testsuite/20_util/forward/c_neg.cc: Adjust dg-error.
7504 * testsuite/20_util/forward/f_neg.cc: Likewise.
7506 2021-04-06 Jonathan Wakely <jwakely@redhat.com>
7508 * include/bits/alloc_traits.h: Use markdown for code font.
7509 * include/bits/basic_string.h: Fix @param names.
7510 * include/bits/max_size_type.h: Remove period after @file.
7511 * include/bits/regex.h: Fix duplicate @retval names, and rename.
7512 * include/ext/pb_ds/detail/priority_queue_base_dispatch.hpp: Add
7513 group open to match existing group close.
7514 * include/ext/pb_ds/priority_queue.hpp: Add blank line before group
7517 2021-04-06 Jonathan Wakely <jwakely@redhat.com>
7519 * include/bits/atomic_base.h: Fix doxygen group close.
7520 * include/bits/basic_ios.h: Likewise.
7521 * include/bits/forward_list.h: Likewise.
7522 * include/bits/fs_dir.h: Likewise.
7523 * include/bits/fs_ops.h: Likewise.
7524 * include/bits/fs_path.h: Likewise.
7525 * include/bits/functional_hash.h: Likewise.
7526 * include/bits/gslice.h: Likewise.
7527 * include/bits/gslice_array.h: Likewise.
7528 * include/bits/hashtable_policy.h: Likewise.
7529 * include/bits/indirect_array.h: Likewise.
7530 * include/bits/locale_classes.h: Likewise.
7531 * include/bits/locale_facets.h: Likewise.
7532 * include/bits/locale_facets_nonio.h: Likewise.
7533 * include/bits/mask_array.h: Likewise.
7534 * include/bits/refwrap.h: Likewise.
7535 * include/bits/regex.h: Likewise.
7536 * include/bits/regex_automaton.h: Likewise.
7537 * include/bits/regex_compiler.h: Likewise.
7538 * include/bits/regex_constants.h: Likewise.
7539 * include/bits/regex_error.h: Likewise.
7540 * include/bits/regex_executor.h: Likewise.
7541 * include/bits/regex_scanner.h: Likewise.
7542 * include/bits/shared_ptr.h: Likewise.
7543 * include/bits/shared_ptr_atomic.h: Likewise.
7544 * include/bits/shared_ptr_base.h: Likewise.
7545 * include/bits/slice_array.h: Likewise.
7546 * include/bits/specfun.h: Likewise.
7547 * include/bits/std_function.h: Likewise.
7548 * include/bits/std_mutex.h: Likewise.
7549 * include/bits/stl_deque.h: Likewise.
7550 * include/bits/stl_iterator.h: Likewise.
7551 * include/bits/stl_iterator_base_types.h: Likewise.
7552 * include/bits/stl_map.h: Likewise.
7553 * include/bits/stl_multimap.h: Likewise.
7554 * include/bits/stl_multiset.h: Likewise.
7555 * include/bits/stl_numeric.h: Likewise.
7556 * include/bits/stl_pair.h: Likewise.
7557 * include/bits/stl_set.h: Likewise.
7558 * include/bits/stl_uninitialized.h: Likewise.
7559 * include/bits/stream_iterator.h: Likewise.
7560 * include/bits/streambuf_iterator.h: Likewise.
7561 * include/bits/unique_ptr.h: Likewise.
7562 * include/bits/unordered_map.h: Likewise.
7563 * include/bits/unordered_set.h: Likewise.
7564 * include/decimal/decimal: Likewise.
7565 * include/experimental/any: Likewise.
7566 * include/experimental/array: Likewise.
7567 * include/experimental/bits/fs_dir.h: Likewise.
7568 * include/experimental/bits/fs_fwd.h: Likewise.
7569 * include/experimental/bits/fs_ops.h: Likewise.
7570 * include/experimental/bits/fs_path.h: Likewise.
7571 * include/experimental/buffer: Likewise.
7572 * include/experimental/internet: Likewise.
7573 * include/experimental/optional: Likewise.
7574 * include/experimental/propagate_const: Likewise.
7575 * include/experimental/socket: Likewise.
7576 * include/ext/pb_ds/assoc_container.hpp: Likewise.
7577 * include/ext/pb_ds/detail/priority_queue_base_dispatch.hpp:
7579 * include/ext/pb_ds/detail/tree_policy/node_metadata_selector.hpp: Likewise.
7580 * include/ext/pb_ds/detail/trie_policy/node_metadata_selector.hpp: Likewise.
7581 * include/ext/pb_ds/detail/types_traits.hpp: Likewise.
7582 * include/ext/pb_ds/exception.hpp: Likewise.
7583 * include/ext/pb_ds/priority_queue.hpp: Likewise.
7584 * include/ext/pb_ds/tag_and_trait.hpp: Likewise.
7585 * include/ext/random: Likewise.
7586 * include/std/any: Likewise.
7587 * include/std/atomic: Likewise.
7588 * include/std/bitset: Likewise.
7589 * include/std/chrono: Likewise.
7590 * include/std/complex: Likewise.
7591 * include/std/condition_variable: Likewise.
7592 * include/std/fstream: Likewise.
7593 * include/std/future: Likewise.
7594 * include/std/iostream: Likewise.
7595 * include/std/istream: Likewise.
7596 * include/std/mutex: Likewise.
7597 * include/std/numeric: Likewise.
7598 * include/std/ostream: Likewise.
7599 * include/std/ratio: Likewise.
7600 * include/std/shared_mutex: Likewise.
7601 * include/std/stdexcept: Likewise.
7602 * include/std/streambuf: Likewise.
7603 * include/std/system_error: Likewise.
7604 * include/std/thread: Likewise.
7605 * include/std/valarray: Likewise.
7606 * include/std/variant: Likewise.
7607 * include/tr1/cmath: Likewise.
7608 * include/tr1/regex: Likewise.
7609 * include/tr2/dynamic_bitset: Likewise.
7610 * libsupc++/atomic_lockfree_defines.h: Likewise.
7611 * libsupc++/exception: Likewise.
7612 * libsupc++/exception.h: Likewise.
7613 * libsupc++/exception_ptr.h: Likewise.
7614 * libsupc++/nested_exception.h: Likewise.
7616 2021-03-31 Alexandre Oliva <oliva@adacore.com>
7618 * testsuite/30_threads/future/members/poll.cc: Use faster
7619 after-ready call in the calibration loop.
7621 2021-03-29 Jonathan Wakely <jwakely@redhat.com>
7623 * doc/xml/manual/status_cxx2017.xml: Adjust link for PSTL.
7624 * doc/html/manual/status.html: Regenerate.
7626 2021-03-28 François Dumont <fdumont@gcc.gnu.org>
7628 * include/debug/forward_list
7629 (forward_list(forward_list&&, const allocator_type&)): Add noexcept qualification.
7630 * include/debug/list (list(list&&, const allocator_type&)): Likewise and add
7631 call to safe container allocator aware move constructor.
7632 * include/debug/vector (vector(vector&&, const allocator_type&)):
7633 Fix noexcept qualification.
7634 * testsuite/23_containers/forward_list/cons/noexcept_move_construct.cc:
7635 Add allocator-extended move constructor noexceot qualification check.
7636 * testsuite/23_containers/list/cons/noexcept_move_construct.cc: Likewise.
7638 2021-03-26 Jonathan Wakely <jwakely@redhat.com>
7640 * src/c++11/random.cc (USE_LCG): Define when a pseudo-random
7642 [USE_LCG] (bad_seed, construct_lcg_at, destroy_lcg_at, __lcg):
7643 New helper functions and callback.
7644 (random_device::_M_init): Add 'prng' and 'all' enumerators.
7645 Replace switch with fallthrough with a series of 'if' statements.
7646 [USE_LCG]: Construct an lcg_type engine and use __lcg when cpuid
7648 (random_device::_M_init_pretr1) [USE_MT19937]: Accept "prng"
7650 (random_device::_M_getval): Check for callback unconditionally
7651 and always pass _M_file pointer.
7652 * testsuite/26_numerics/random/random_device/85494.cc: Remove
7653 effective-target check. Use new random_device_available helper.
7654 * testsuite/26_numerics/random/random_device/94087.cc: Likewise.
7655 * testsuite/26_numerics/random/random_device/cons/default-cow.cc:
7656 Remove effective-target check.
7657 * testsuite/26_numerics/random/random_device/cons/default.cc:
7659 * testsuite/26_numerics/random/random_device/cons/token.cc: Use
7660 new random_device_available helper. Test "prng" token.
7661 * testsuite/util/testsuite_random.h (random_device_available):
7662 New helper function.
7664 2021-03-25 François Dumont <fdumont@gcc.gnu.org>
7666 * include/debug/string
7667 (basic_string(const basic_string&, const _Alloc&)): Define even if !_GLIBCXX_USE_CXX11_ABI.
7668 (basic_string(basic_string&&, const _Alloc&)): Likewise and add noexcept qualification.
7669 (basic_string<>::erase): Adapt to take __const_iterator.
7670 (basic_string(const _CharT*, const _Allocator&)): Remove assign call.
7671 (basic_string<>::insert(const_iterator, _InputIte, _InputIte)): Try to
7672 remove iterator debug layer even if !_GLIBCXX_USE_CXX11_ABI.
7673 [_GLIBCXX_USE_CHAR8_T] (__gnu_debug::u8string): New.
7674 (__gnu_debug::u16string, __gnu_debug::u32string): New.
7675 (std::hash<__gnu_debug::basic_string<>>): New partial specialization.
7676 (std::__is_fast_hash<__gnu_debug::basic_string<>>): Likewise.
7677 * testsuite/util/exception/safety.h
7678 (erase_base<__gnu_debug::basic_string<>>): New partial specialization.
7679 (insert_base<__gnu_debug::basic_string<>>): Likewise.
7680 * testsuite/util/testsuite_container_traits.h (traits<__gnu_debug::basic_string<>>):
7681 New partial specialization.
7682 * testsuite/21_strings/basic_string/hash/debug.cc: New test.
7683 * testsuite/21_strings/basic_string/requirements/citerators.cc:
7684 Add test on __gnu_debug::string.
7685 * testsuite/21_strings/basic_string/requirements/dr438/constructor.cc: Likewise.
7686 * testsuite/21_strings/basic_string/requirements/exception/basic.cc: Likewise.
7687 * testsuite/21_strings/basic_string/requirements/exception/generation_prohibited.cc:
7689 * testsuite/21_strings/basic_string/requirements/exception/propagation_consistent.cc:
7691 * testsuite/21_strings/basic_string/requirements/explicit_instantiation/char/1.cc:
7693 * testsuite/21_strings/basic_string/requirements/explicit_instantiation/char16_t/1.cc:
7695 * testsuite/21_strings/basic_string/requirements/explicit_instantiation/char32_t/1.cc:
7697 * testsuite/21_strings/basic_string/requirements/explicit_instantiation/char8_t/1.cc:
7699 * testsuite/21_strings/basic_string/requirements/explicit_instantiation/wchar_t/1.cc:
7701 * testsuite/21_strings/basic_string/requirements/typedefs.cc: Likewise.
7703 2021-03-25 Jakub Jelinek <jakub@redhat.com>
7706 * testsuite/18_support/source_location/consteval.cc (main): Adjust
7707 expected column numbers.
7708 * testsuite/18_support/source_location/1.cc (main): Likewise.
7710 2021-03-25 Jonathan Wakely <jwakely@redhat.com>
7712 * libsupc++/new_opa.cc [!_GLIBCXX_HOSTED]: Declare malloc.
7714 2021-03-25 Jonathan Wakely <jwakely@redhat.com>
7716 * testsuite/util/exception/safety.h (setup_base::generate):
7717 Support seeding random engine.
7718 (erase_point, erase_range): Adjust range of random numbers to
7719 ensure dereferenceable iterators are used where required.
7720 (generation_prohibited::run): Do not try to erase from empty
7722 * testsuite/util/testsuite_containergen.h (test_containers):
7723 Support seeding random engine.
7725 2021-03-23 Jonathan Wakely <jwakely@redhat.com>
7727 * testsuite/std/ranges/adaptors/reverse.cc: Replace duplicated
7728 line with a check that uses the const being/end overloads.
7730 2021-03-23 Moritz Sichert <sichert@in.tum.de>
7732 * include/std/ranges (reverse_view::begin, reverse_view::end):
7733 Qualify make_reverse_iterator calls to avoid ADL.
7734 * testsuite/std/ranges/adaptors/reverse.cc: Test that
7735 views::reverse works when make_reverse_iterator is defined
7736 in an associated namespace.
7738 2021-03-23 Jonathan Wakely <jwakely@redhat.com>
7740 * include/bits/c++config (_GLIBCXX_LONG_DOUBLE_ALT128_COMPAT):
7741 Do not define when compiling with Clang.
7743 2021-03-22 Jonathan Wakely <jwakely@redhat.com>
7745 * include/std/string_view (basic_string_view(Range&&)): Define new
7746 constructor and deduction guide.
7747 * testsuite/21_strings/basic_string_view/cons/char/range_c++20.cc: New test.
7748 * testsuite/21_strings/basic_string_view/cons/wchar_t/range_c++20.cc: New test.
7750 2021-03-22 Jonathan Wakely <jwakely@redhat.com>
7752 * include/bits/range_access.h (begin(T (&)[N]), end(T (&)[N])):
7753 Add missing 'noexcept' as per LWG 2280.
7754 (rbegin(T (&)[N]), rend(T (&)[N]), rbegin(initializer_list<T>))
7755 (rend(initializer_list<T>)): Add 'noexcept' as per LWG 3537.
7756 * testsuite/24_iterators/range_access/range_access.cc: Check for
7757 expected noexcept specifiers. Check result types of generic
7758 std::begin and std::end overloads.
7759 * testsuite/24_iterators/range_access/range_access_cpp14.cc:
7760 Check for expected noexcept specifiers.
7761 * testsuite/24_iterators/range_access/range_access_cpp17.cc:
7764 2021-03-19 Jonathan Wakely <jwakely@redhat.com>
7766 * include/std/type_traits (is_scoped_enum): Define.
7767 * include/std/version (__cpp_lib_is_scoped_enum): Define.
7768 * testsuite/20_util/is_scoped_enum/value.cc: New test.
7769 * testsuite/20_util/is_scoped_enum/version.cc: New test.
7771 2021-03-16 Jonathan Wakely <jwakely@redhat.com>
7774 * config/abi/post/aarch64-linux-gnu/baseline_symbols.txt: Remove
7775 std::once_flag symbols.
7776 * config/abi/post/ia64-linux-gnu/baseline_symbols.txt: Likewise.
7777 * config/abi/post/m68k-linux-gnu/baseline_symbols.txt: Likewise.
7778 * config/abi/post/riscv64-linux-gnu/baseline_symbols.txt:
7780 * config/abi/pre/gnu.ver: Likewise.
7781 * src/c++11/mutex.cc [_GLIBCXX_HAVE_LINUX_FUTEX]
7782 (struct __once_flag_compat): Remove.
7783 (_ZNSt9once_flag11_M_activateEv): Remove.
7784 (_ZNSt9once_flag9_M_finishEb): Remove.
7786 2021-03-16 Jonathan Wakely <jwakely@redhat.com>
7789 * include/std/mutex [_GLIBCXX_HAVE_LINUX_FUTEX] (once_flag):
7790 Revert to pthread_once_t implementation.
7791 [_GLIBCXX_HAVE_LINUX_FUTEX] (call_once): Likewise.
7792 * src/c++11/mutex.cc [_GLIBCXX_HAVE_LINUX_FUTEX]
7793 (struct __once_flag_compat): New type matching the reverted
7794 implementation of once_flag using futexes.
7795 (once_flag::_M_activate): Remove, replace with ...
7796 (_ZNSt9once_flag11_M_activateEv): ... alias symbol.
7797 (once_flag::_M_finish): Remove, replace with ...
7798 (_ZNSt9once_flag9_M_finishEb): ... alias symbol.
7799 * testsuite/30_threads/call_once/66146.cc: Removed.
7801 2021-03-15 Iain Sandoe <iain@sandoe.co.uk>
7803 * testsuite/17_intro/names.cc: Exclude j from the list
7804 of test symbols for Darwin.
7806 2021-03-15 Iain Sandoe <iain@sandoe.co.uk>
7808 * config/os/bsd/darwin/ppc-extra.ver: Add matching for
7809 to_chars and from_chars for long double.
7811 2021-03-15 Patrick Palka <ppalka@redhat.com>
7813 * include/bits/max_size_type.h (__max_size_type::operator _Tp):
7815 (__max_size_type::operator++): Define.
7816 (__max_size_type::operator--): Likewise.
7817 (__max_size_type::operator<=>): Conditionally define (in place
7818 of the other comparison operators).
7819 (__max_diff_type::operator _Tp): Fix formatting.
7820 (__max_diff_type::operator++): Define.
7821 (__max_diff_type::operator--): Likewise.
7822 (__max_diff_type::operator<=>): Conditionally define (in place
7823 of the other comparison operators).
7824 * testsuite/std/ranges/iota/max_size_type.cc (test01): Test
7825 these operator overloads.
7827 2021-03-15 Caroline Tice <cmtice@google.com>
7830 * src/Makefile.am (AM_CXXFLAGS_PRE, AM_CXXFLAGS): Add
7831 AM_CXXFLAGS_PRE with the old definition of AM_CXXFLAGS; make
7832 AM_CXXFLAGS to be AM_CXXFLAGS_PRE with '-fvtable-verify=std'
7834 * src/Makefile.in: Regenerate.
7836 2021-03-11 Patrick Palka <ppalka@redhat.com>
7838 * src/c++17/floating_to_chars.cc: Simplify the file as if
7839 __SIZEOF_INT128__ is always defined.
7840 [!defined __SIZEOF_INT128__]: Include "uint128_t.h". Define
7841 a base-10 to_chars overload for the uint128_t class type.
7842 * src/c++17/uint128_t.h: New file.
7843 * testsuite/20_util/to_chars/long_double.cc: No longer expect an
7844 execution FAIL on targets that have a large long double type
7847 2021-03-11 Patrick Palka <ppalka@redhat.com>
7849 * src/c++17/ryu/LOCAL_PATCHES: Update.
7850 * src/c++17/ryu/d2s_intrinsics.h: Don't define uint128_t.
7851 * src/c++17/ryu/generic_128.h: Likewise.
7852 * src/c++17/ryu/ryu_generic_128.h (struct floating_decimal_128):
7853 Use uint128_t instead of __uint128_t.
7854 (generic_binary_to_decimal): Likewise.
7856 2021-03-11 Patrick Palka <ppalka@redhat.com>
7858 * src/c++17/ryu/LOCAL_PATCHES: New file.
7860 2021-03-11 Patrick Palka <ppalka@redhat.com>
7862 * src/c++17/floating_to_chars.cc (uint128_t): New conditionally
7863 defined alias of unsigned __int128.
7864 (floating_type_traits_binary128::mantissa_t): Use uint128_t
7865 instead of unsigned __int128.
7866 (floating_type_traits<long double>::mantissa_t)
7867 [LONG_DOUBLE_KIND == LDK_IBM128]: Likewise.
7868 (get_ieee_repr): Likewise. Make casts from uint_t to mantissa_t
7869 and uint32_t explicit. Simplify the extraction of mantissa,
7870 exponent and sign bit.
7872 2021-03-11 Jonathan Wakely <jwakely@redhat.com>
7874 * include/std/barrier (barrier::arrival_token): New move-only
7875 class that encapsulates the underlying token value.
7877 2021-03-11 Jonathan Wakely <jwakely@redhat.com>
7879 * python/libstdcxx/v6/printers.py (find_type): Use tag attribute
7880 instead of unqualified() method.
7882 2021-03-11 Jonathan Wakely <jwakely@redhat.com>
7885 * include/std/stop_token (_Stop_state_t::_M_release_ownership):
7886 Use acq_rel memory ordering.
7888 2021-03-11 Jonathan Wakely <jwakely@redhat.com>
7891 * src/c++17/fs_dir.cc (recursive_directory_iterator): Use new
7892 helper function to check for permission denied errors.
7893 * src/filesystem/dir.cc (recursive_directory_iterator):
7895 * src/filesystem/dir-common.h (is_permission_denied_error): New
7898 2021-03-11 Jonathan Wakely <jwakely@redhat.com>
7901 * include/bits/random.h (normal_distribution): Use
7902 default-initializer for _M_saved and _M_saved_available.
7904 2021-03-10 John David Anglin <danglin@gcc.gnu.org>
7906 * testsuite/29_atomics/atomic/wait_notify/bool.cc: Add options to
7907 link with libatomic.
7908 * testsuite/29_atomics/atomic/wait_notify/generic.cc: Likewise.
7909 * testsuite/29_atomics/atomic/wait_notify/pointers.cc: Likewise.
7910 * testsuite/29_atomics/atomic_flag/wait_notify/1.cc: Likewise.
7911 * testsuite/30_threads/barrier/arrive.cc: Likewise.
7912 * testsuite/30_threads/barrier/arrive_and_drop.cc: Likewise.
7913 * testsuite/30_threads/barrier/arrive_and_wait.cc: Likewise.
7914 * testsuite/30_threads/barrier/completion.cc: Likewise.
7915 * testsuite/30_threads/latch/3.cc: Likewise.
7916 * testsuite/30_threads/semaphore/try_acquire.cc: Likewise.
7917 * testsuite/30_threads/semaphore/try_acquire_for.cc: Likewise.
7918 * testsuite/30_threads/semaphore/try_acquire_until.cc: Likewise.
7920 2021-03-10 Jonathan Wakely <jwakely@redhat.com>
7923 * include/bits/align.h: Include debug/assertions.h.
7924 * include/bits/codecvt.h: Include bits/c++config.h.
7925 * include/bits/enable_special_members.h: Likewise.
7926 * include/bits/erase_if.h: Likewise.
7927 * include/bits/functional_hash.h: Include <type_traits>.
7928 * include/bits/invoke.h: Include bits/move.h.
7929 * include/bits/ostream_insert.h: Include bits/exception_defines.h.
7930 * include/bits/parse_numbers.h: Include <type_traits>.
7931 * include/bits/predefined_ops.h: Include bits/c++config.h.
7932 * include/bits/range_access.h: Include bits/stl_iterator.h.
7933 * include/bits/stl_bvector.h: Do not include bits/stl_vector.h.
7934 * include/bits/stl_iterator.h: Include bits/stl_iterator_base_types.h.
7935 * include/bits/stl_uninitialized.h: Include bits/stl_algobase.h.
7936 * include/bits/uniform_int_dist.h: Include bits/concept_check.h.
7937 * include/bits/unique_lock.h: Include bits/std_mutex.h.
7938 * include/debug/assertions.h: Include bits/c++config.h.
7940 2021-03-10 Jonathan Wakely <jwakely@redhat.com>
7942 * include/bits/ranges_cmp.h (__eq_builtin_ptr_cmp): Remove.
7943 (ranges::equal_to, ranges::not_equal_to): Do not constrain
7944 with __eq_builtin_ptr_cmp.
7945 (ranges::less, ranges::greater, ranges::less_equal)
7946 (ranges::greater_equal): Do not constrain with
7947 __less_builtin_ptr_cmp.
7948 * libsupc++/compare (compare_three_way): Do not constrain with
7949 __3way_builtin_ptr_cmp.
7950 * testsuite/18_support/comparisons/object/builtin-ptr-three-way.cc: Moved to...
7951 * testsuite/18_support/comparisons/object/lwg3530.cc: ...here.
7952 * testsuite/20_util/function_objects/range.cmp/lwg3530.cc: New test.
7954 2021-03-10 Jonathan Wakely <jwakely@redhat.com>
7956 * testsuite/std/time/syn_c++20.cc: Enable synopsis checks for
7957 C++20 calendar types.
7959 2021-03-06 Jakub Jelinek <jakub@redhat.com>
7962 * include/std/bit (__rotl, __rotr): Add optimized variants for power of
7963 two _Nd which the compiler can pattern match the rotates.
7965 2021-03-04 Jonathan Wakely <jwakely@redhat.com>
7968 * testsuite/20_util/specialized_algorithms/uninitialized_default_n/sizes.cc:
7969 Make storage larger than required. Verify no write to the last
7971 * testsuite/20_util/specialized_algorithms/uninitialized_value_construct_n/sizes.cc:
7974 2021-03-03 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7976 * config/abi/post/i386-solaris/baseline_symbols.txt: Regenerate.
7977 * config/abi/post/i386-solaris/amd64/baseline_symbols.txt:
7979 * config/abi/post/sparc-solaris/baseline_symbols.txt: Likewise.
7980 * config/abi/post/sparc-solaris/sparcv9/baseline_symbols.txt:
7983 2021-03-03 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7985 * include/experimental/bits/simd.h: Replace reserved _X, _B by
7987 * include/experimental/bits/simd_builtin.h: Likewise.
7988 * include/experimental/bits/simd_x86.h: Likewise.
7990 2021-02-27 Jonathan Wakely <jwakely@redhat.com>
7993 * include/std/chrono (year_month_day::_M_days_since_epoch()):
7994 Convert chrono::month and chrono::day to unsigned before
7995 converting to uint32_t.
7997 2021-02-25 Jonathan Wakely <jwakely@redhat.com>
7999 * include/std/chrono (year_month_day::_S_from_days): Perform
8000 all calculations with type uint32_t.
8002 2021-02-25 Jonathan Wakely <jwakely@redhat.com>
8004 * doc/xml/manual/abi.xml: Document versioning for GCC 11.
8005 * doc/html/manual/abi.html: Regenerate.
8007 2021-02-25 Jonathan Wakely <jwakely@redhat.com>
8010 * testsuite/27_io/headers/cstdio/types_std.cc: Use pointer to
8011 FILE instead of FILE.
8013 2021-02-25 Andreas Schwab <schwab@suse.de>
8015 * config/abi/post/aarch64-linux-gnu/baseline_symbols.txt: Update.
8016 * config/abi/post/ia64-linux-gnu/baseline_symbols.txt: Update.
8017 * config/abi/post/m68k-linux-gnu/baseline_symbols.txt: Update.
8018 * config/abi/post/riscv64-linux-gnu/baseline_symbols.txt: Update.
8020 2021-02-25 Jonathan Wakely <jwakely@redhat.com>
8023 * include/std/chrono (year_month_day::_S_from_days): Cast long
8026 2021-02-25 Jonathan Wakely <jwakely@redhat.com>
8028 * include/std/utility (to_underlying): Define.
8029 * include/std/version (__cpp_lib_to_underlying): Define.
8030 * testsuite/20_util/to_underlying/1.cc: New test.
8031 * testsuite/20_util/to_underlying/version.cc: New test.
8033 2021-02-24 Jonathan Wakely <jwakely@redhat.com>
8036 * src/c++17/floating_to_chars.cc (sprintf_ld): Add extra args
8037 before value to be printed.
8039 2021-02-24 Patrick Palka <ppalka@redhat.com>
8041 * src/c++17/floating_to_chars.cc (__floating_to_chars_precision):
8042 Relax the condition that guards the printf code path to accept
8043 F128_type as well as long double.
8045 2021-02-24 Cassio Neri <cassio.neri@gmail.com>
8047 * include/std/chrono (year_month_day_last:day): New
8050 2021-02-24 Cassio Neri <cassio.neri@gmail.com>
8052 * include/std/chrono (year::is_leap): New implementation.
8053 * testsuite/std/time/year/2.cc: New test.
8055 2021-02-24 Cassio Neri <cassio.neri@gmail.com>
8057 * include/std/chrono (year_month_day::_M_days_since_epoch):
8059 * testsuite/std/time/year_month_day/4.cc: New test.
8061 2021-02-24 Cassio Neri <cassio.neri@gmail.com>
8063 * include/std/chrono (year_month_day::_S_from_days): New
8065 * testsuite/std/time/year_month_day/3.cc: New test.
8067 2021-02-24 Patrick Palka <ppalka@redhat.com>
8070 * testsuite/20_util/to_chars/long_double.cc: Include <optional>.
8071 (test01): Simplify verifying the nearby values by using a
8072 2-iteration loop and a dedicated output buffer to check that the
8073 nearby values are different. Factor out the printf-based
8074 verification into a local function, and check that the leading
8075 hex digits agree before comparing to the output of printf. Also
8076 verify the output by round-tripping it through from_chars.
8078 2021-02-24 Jonathan Wakely <jwakely@redhat.com>
8081 * config/abi/pre/gnu.ver (GLIBCXX_3.4.29): Do not match to_chars
8082 symbols for long double arguments mangled as 'g'.
8083 * config/os/gnu-linux/ldbl-extra.ver: Likewise.
8084 * config/os/gnu-linux/ldbl-ieee128-extra.ver: Likewise.
8085 * src/c++17/Makefile.am [GLIBCXX_LDBL_ALT128_COMPAT_TRUE]:
8086 Use -mabi=ibmlongdouble for floating_to_chars.cc.
8087 * src/c++17/Makefile.in: Regenerate.
8088 * src/c++17/floating_to_chars.cc (floating_type_traits_binary128):
8089 New type defining type traits of IEEE binary128 format.
8090 (floating_type_traits<__float128>): Define specialization.
8091 (floating_type_traits<long double>): Define in terms of
8092 floating_type_traits_binary128 when appropriate.
8093 (floating_to_shortest_scientific): Handle __float128.
8094 (sprintf_ld): New function template for printing a long double
8095 or __ieee128 value using sprintf.
8096 (__floating_to_chars_shortest, __floating_to_chars_precision):
8098 (to_chars): Define overloads for __float128.
8100 2021-02-24 Jonathan Wakely <jwakely@redhat.com>
8102 * testsuite/17_intro/names.cc: Undefine 'u' on powerpc*-linux*.
8104 2021-02-23 Martin Sebor <msebor@redhat.com>
8107 * libsupc++/dyncast.cc (__dynamic_cast): Return null when
8108 first argument is null.
8110 2021-02-23 Jakub Jelinek <jakub@redhat.com>
8113 * testsuite/21_strings/char_traits/requirements/char/99181.cc: New
8116 2021-02-23 Jakub Jelinek <jakub@redhat.com>
8119 * include/bits/char_traits.h (char_traits<char>::compare): For
8120 constexpr evaluation don't call
8121 __gnu_cxx::char_traits<char_type>::compare but do the comparison loop
8124 2021-02-23 Jakub Jelinek <jakub@redhat.com>
8127 * include/pstl/parallel_backend_serial.h: Remove __pstl::__par_backend.
8129 2021-02-23 Patrick Palka <ppalka@redhat.com>
8132 * src/c++17/floating_to_chars.cc (get_ieee_repr): Extract
8133 the high- and low-order parts from an IBM long double value
8134 in an endian-agnostic way.
8136 2021-02-19 Jonathan Wakely <jwakely@redhat.com>
8138 * include/bits/atomic_wait.h (__thread_relax()): Call
8139 __thread_yield() not __gthread_yield().
8141 2021-02-15 Jonathan Wakely <jwakely@redhat.com>
8143 * include/bits/atomic_wait.h (__thread_yield()): Check
8144 _GLIBCXX_HAS_GTHREADS before using __gthread_yield.
8145 (__thread_relax()): Use __thread_yield() instead of repeating
8146 the preprocessor checks for __gthread_yield.
8148 2021-02-15 Jonathan Wakely <jwakely@redhat.com>
8150 * include/std/mutex (once_flag::_M_activate()): Add explicit
8151 return statement for passive case.
8152 (once_flag::_M_finish(bool)): Use reserved name for parameter.
8154 2021-02-14 Jonathan Wakely <jwakely@redhat.com>
8157 * testsuite/util/testsuite_fs.h: Always include <unistd.h>.
8159 2021-02-12 Jonathan Wakely <jwakely@redhat.com>
8162 * src/c++17/fs_ops.cc (fs::symlink_status): Re-enable workaround.
8164 2021-02-12 Jonathan Wakely <jwakely@redhat.com>
8166 * doc/xml/manual/status_cxx2014.xml: Document implementation
8167 specific properties of std::experimental::filesystem::rename.
8168 * doc/xml/manual/status_cxx2017.xml: Document implementation
8169 specific properties of std::filesystem::rename.
8170 * doc/html/*: Regenerate.
8171 * src/c++17/fs_ops.cc (fs::rename): Implement correct behaviour
8172 for directories on Windows.
8173 * src/filesystem/ops-common.h (__gnu_posix::rename): Use
8174 MoveFileExW on Windows.
8175 * testsuite/27_io/filesystem/operations/rename.cc: New test.
8176 * testsuite/experimental/filesystem/operations/rename.cc: New test.
8178 2021-02-12 Jonathan Wakely <jwakely@redhat.com>
8180 * testsuite/util/testsuite_fs.h (nonexistent_path): Add
8181 random number to the path.
8183 2021-02-12 Jonathan Wakely <jwakely@redhat.com>
8185 * include/experimental/internet (address_v6::to_string): Include
8187 * testsuite/experimental/net/internet/address/v6/members.cc:
8188 Test to_string() results.
8190 2021-02-12 Jonathan Wakely <jwakely@redhat.com>
8192 * include/experimental/internet (address_v6::any): Avoid using
8193 memcpy in constexpr function.
8194 (address_v6::loopback): Likewise.
8195 (make_address_v6): Fix missing return statements on error paths.
8196 * include/experimental/io_context: Avoid -Wdangling-else
8198 * testsuite/experimental/net/internet/address/v4/members.cc:
8199 Remove unused variables.
8200 * testsuite/experimental/net/internet/address/v6/members.cc:
8203 2021-02-12 Jonathan Wakely <jwakely@redhat.com>
8205 * include/bits/shared_ptr_base.h (__shared_ptr::_M_get_deleter):
8206 Add unused attribute to parameter.
8207 * src/c++11/shared_ptr.cc (_Sp_make_shared_tag::_S_eq):
8210 2021-02-12 Jonathan Wakely <jwakely@redhat.com>
8212 * testsuite/27_io/basic_ostream/emit/1.cc: Expect test to fail
8213 if -fno-rtti is used.
8214 * testsuite/30_threads/async/forced_unwind.cc: Expect test
8215 to abort if -fno-rtti is used.
8217 2021-02-12 Jonathan Wakely <jwakely@redhat.com>
8219 * testsuite/util/testsuite_allocator.h (memory_resource):
8220 Remove requirement for RTTI and exceptions to be enabled.
8222 2021-02-12 Jonathan Wakely <jwakely@redhat.com>
8224 * testsuite/27_io/basic_istringstream/rdbuf/char/2832.cc: Use
8225 static_cast when RTTI is disabled.
8226 * testsuite/27_io/basic_istringstream/rdbuf/wchar_t/2832.cc:
8228 * testsuite/27_io/basic_ostringstream/rdbuf/char/2832.cc:
8230 * testsuite/27_io/basic_ostringstream/rdbuf/wchar_t/2832.cc:
8232 * testsuite/27_io/basic_stringstream/str/char/2.cc:
8234 * testsuite/27_io/basic_stringstream/str/wchar_t/2.cc:
8237 2021-02-12 Jonathan Wakely <jwakely@redhat.com>
8239 * include/std/ostream (__syncbuf_base::_S_get): Mark parameter
8240 as unused and only use dynamic_cast when RTTI is enabled.
8242 2021-02-12 Jonathan Wakely <jwakely@redhat.com>
8245 * src/c++11/cxx11-ios_failure.cc (__ios_failure(const char*, int)):
8246 Change int parameter to error_code, to match std::ios_failure.
8247 (__throw_ios_failure(const char*, int)): Construct error_code
8250 2021-02-11 Jonathan Wakely <jwakely@redhat.com>
8252 * libsupc++/eh_ptr.cc (_GLIBCXX_EH_PTR_RELOPS_COMPAT): Define
8254 * libsupc++/exception_ptr.h (_GLIBCXX_EH_PTR_USED): Check new
8255 macro instead of _GLIBCXX_EH_PTR_COMPAT.
8256 (operator==): Likewise.
8258 2021-02-11 Jonathan Wakely <jwakely@redhat.com>
8261 * doc/xml/manual/status_cxx2011.xml: Document when support
8263 * doc/xml/manual/status_cxx2014.xml: Likewise.
8264 * doc/xml/manual/status_cxx2017.xml: Likewise.
8265 * doc/html/manual/status.html: Regenerate.
8267 2021-02-10 Jonathan Wakely <jwakely@redhat.com>
8270 * src/c++17/fs_ops.cc (fs::status): Re-enable workaround.
8272 2021-02-10 Jonathan Wakely <jwakely@redhat.com>
8274 * src/c++17/fs_ops.cc (fs::create_hard_link, fs::equivalent)
8275 (fs::remove): Use std::system_category() for error codes from
8277 * src/filesystem/ops.cc (fs::create_hard_link, fs::remove):
8280 2021-02-10 Jonathan Wakely <jwakely@redhat.com>
8282 * testsuite/27_io/filesystem/operations/proximate.cc: Fix typo
8283 in __MINGW32__ macro name.
8284 * testsuite/27_io/filesystem/path/compare/lwg2936.cc: Likewise.
8285 * testsuite/27_io/filesystem/path/generation/proximate.cc:
8287 * testsuite/27_io/filesystem/path/generation/relative.cc:
8289 * testsuite/util/testsuite_fs.h: Likewise.
8291 2021-02-09 François Dumont <fdumont@gcc.gnu.org>
8293 * include/bits/stl_tree.h
8294 (__has_is_transparent, __has_is_transparent_t): Move...
8295 * include/bits/stl_function.h: ...here.
8296 * include/bits/hashtable_policy.h (_Hash_code_base<>::_M_hash_code_tr): New..
8297 (_Hashtable_base<>::_M_equals_tr): New.
8298 * include/bits/hashtable.h (_Hashtable<>::_M_find_tr, _Hashtable<>::_M_count_tr,
8299 _Hashtable<>::_M_equal_range_tr): New member function templates to perform
8300 heterogeneous lookup.
8301 (_Hashtable<>::_M_find_before_node_tr): New.
8302 (_Hashtable<>::_M_find_node_tr): New.
8303 * include/bits/unordered_map.h (unordered_map::find<>, unordered_map::count<>,
8304 unordered_map::contains<>, unordered_map::equal_range<>): New member function
8305 templates to perform heterogeneous lookup.
8306 (unordered_multimap::find<>, unordered_multimap::count<>,
8307 unordered_multimap::contains<>, unordered_multimap::equal_range<>): Likewise.
8308 * include/bits/unordered_set.h (unordered_set::find<>, unordered_set::count<>,
8309 unordered_set::contains<>, unordered_set::equal_range<>): Likewise.
8310 (unordered_multiset::find<>, unordered_multiset::count<>,
8311 unordered_multiset::contains<>, unordered_multiset::equal_range<>): Likewise.
8312 * include/debug/unordered_map
8313 (unordered_map::find<>, unordered_map::equal_range<>): Likewise.
8314 (unordered_multimap::find<>, unordered_multimap::equal_range<>): Likewise.
8315 * include/debug/unordered_set
8316 (unordered_set::find<>, unordered_set::equal_range<>): Likewise.
8317 (unordered_multiset::find<>, unordered_multiset::equal_range<>): Likewise.
8318 * testsuite/23_containers/unordered_map/operations/1.cc: New test.
8319 * testsuite/23_containers/unordered_multimap/operations/1.cc: New test.
8320 * testsuite/23_containers/unordered_multiset/operations/1.cc: New test.
8321 * testsuite/23_containers/unordered_set/operations/1.cc: New test.
8323 2021-02-09 François Dumont <fdumont@gcc.gnu.org>
8325 * include/bits/stl_deque.h
8326 (std::operator-(deque::iterator, deque::iterator)): Replace if/then with
8327 a null pointer test.
8329 2021-02-09 Jonathan Wakely <jwakely@redhat.com>
8331 * testsuite/27_io/filesystem/operations/remove_all.cc: Remove
8332 test directory after making it writable again.
8333 * testsuite/experimental/filesystem/operations/remove_all.cc:
8336 2021-02-09 Jonathan Wakely <jwakely@redhat.com>
8339 * include/std/coroutine (coroutine_handle<P>::from_address): Add
8342 2021-02-09 Vladimir Vishnevsky <vv.os.swe@gmail.com>
8344 * include/ext/stdio_sync_filebuf.h: Remove unused <unistd.h>.
8345 * src/c++17/fs_ops.cc (fs::permissions): Qualify mode_t.
8347 2021-02-09 Jakub Jelinek <jakub@redhat.com>
8350 * include/bits/basic_string.tcc (basic_string::_M_replace): When __s
8351 points to the characters moved by earlier _S_move, compute the source
8352 address using expression based on the __p pointer rather than __s
8355 2021-02-03 Jonathan Wakely <jwakely@redhat.com>
8357 * testsuite/19_diagnostics/error_code/operators/not_equal.cc:
8358 Add comparison with same category and different values.
8359 * testsuite/19_diagnostics/error_code/operators/less.cc:
8360 Likewise. Fix comparison involving different categories.
8361 * testsuite/19_diagnostics/error_code/operators/three_way.cc:
8363 * testsuite/19_diagnostics/error_condition/operators/less.cc:
8365 * testsuite/19_diagnostics/error_condition/operators/three_way.cc:
8368 2021-02-03 yaozhongxiao <yaozhongxiao@linux.alibaba.com>
8370 * include/experimental/bits/simd_neon.h: Replace repeated vpadd
8371 calls with a single vaddv for aarch64.
8373 2021-02-03 Matthias Kretz <kretz@kde.org>
8375 * testsuite/Makefile.am: Warn about the workaround. Add
8376 -fno-tree-vrp to CXXFLAGS passed to the check_simd script.
8377 Improve initial user feedback from make check-simd.
8378 * testsuite/Makefile.in: Regenerated.
8380 2021-02-03 Matthias Kretz <kretz@kde.org>
8382 * include/experimental/bits/simd.h: Add __detail::_Minimum and
8383 __detail::_Maximum to use them as _BinaryOperation to _S_reduce.
8384 Add hmin and hmax overloads for simd and const_where_expression.
8385 * include/experimental/bits/simd_scalar.h
8386 (_SimdImplScalar::_S_reduce): Make unused _BinaryOperation
8387 parameter const-ref to allow calling _S_reduce with an rvalue.
8388 * testsuite/experimental/simd/tests/reductions.cc: Add tests for
8389 hmin and hmax. Since the compiler statically determined that all
8390 tests pass, repeat the test after a call to make_value_unknown.
8392 2021-02-03 Matthias Kretz <kretz@kde.org>
8394 * testsuite/experimental/simd/tests/bits/verify.h (verify): Add
8395 instruction pointer data member. Ensure that the `if (m_failed)`
8396 branch is always inlined into the calling code. The body of the
8397 conditional can still be a function call. Move the get_ip call
8398 into the verify ctor to simplify the ctor calls.
8399 (COMPARE): Don't mention the use of all_of for reduction of a
8400 simd_mask. It only distracts from the real issue.
8402 2021-02-03 Matthias Kretz <kretz@kde.org>
8404 * testsuite/experimental/simd/driver.sh: Abstract reading test
8405 options into read_src_option function. Read skip, only,
8406 expensive, and xfail via read_src_option. Add timeout and
8407 timeout-factor options and adjust timeout variable accordingly.
8408 * testsuite/experimental/simd/tests/loadstore.cc: Set
8411 2021-02-03 Matthias Kretz <kretz@kde.org>
8413 * testsuite/experimental/simd/driver.sh: When handling the pipe
8414 to log (and on verbose to stdout) count the lines. If it exceeds
8415 1000 log the issue and exit 125, which is then handled as a
8418 2021-02-03 Matthias Kretz <kretz@kde.org>
8420 * testsuite/experimental/simd/tests/hypot3_fma.cc: Add skip:
8421 markup for long double on powerpc64*.
8423 2021-02-03 Matthias Kretz <kretz@kde.org>
8425 * include/experimental/bits/simd.h: Add __have_power10vec
8426 conditional on _ARCH_PWR10.
8427 * include/experimental/bits/simd_builtin.h: Forward declare
8428 _MaskImplPpc and use it as _MaskImpl when __ALTIVEC__ is
8430 (_MaskImplBuiltin::_S_some_of): Call _S_popcount from the
8431 _SuperImpl for optimizations and correctness.
8432 * include/experimental/bits/simd_ppc.h: Add _MaskImplPpc.
8433 (_MaskImplPpc::_S_popcount): Implement via vec_cntm for POWER10.
8434 Otherwise, for >=int use -vec_sums divided by a sizeof factor.
8435 For <int use -vec_sums(vec_sum4s(...)) to sum all mask entries.
8437 2021-02-03 Matthias Kretz <kretz@kde.org>
8439 * testsuite/experimental/simd/driver.sh: Remove executable on
8440 SIGINT. Process compiler and test executable output: In verbose
8441 mode print messages immediately, limited to 1000 lines and
8442 breaking long lines to below $COLUMNS (or 1024 if not set).
8443 Communicating the exit status of the compiler / test with the
8444 necessary pipe is done via a message through stdout/-in.
8446 2021-02-03 Matthias Kretz <kretz@kde.org>
8448 * testsuite/Makefile.am: Ensure .simd.summary is empty before
8449 collecting a new summary.
8450 * testsuite/Makefile.in: Regenerate.
8452 2021-02-03 Matthias Kretz <kretz@kde.org>
8454 * testsuite/experimental/simd/generate_makefile.sh: Use
8455 different variables internally than documented for user
8456 overrides. This makes internal append/prepend work as intended.
8458 2021-02-03 Matthias Kretz <kretz@kde.org>
8460 * testsuite/experimental/simd/driver.sh (verify_test): Print
8461 test output on run xfail. Do not repeat lines from the log that
8462 were already printed on stdout.
8463 (test_selector): Make the compiler flags pattern usable as a
8465 (toplevel): Trap on SIGINT and remove the log and sum files.
8466 Call timout with --foreground to quickly terminate on SIGINT.
8467 * testsuite/experimental/simd/generate_makefile.sh: Simplify run
8468 targets via target patterns. Default DRIVEROPTS to -v for run
8469 targets. Remove log and sum files after completion of the run
8470 target (so that it's always recompiled).
8471 Place help text into text file for reasonable 'make help'
8474 2021-02-03 Matthias Kretz <kretz@kde.org>
8476 * include/experimental/bits/simd.h: Remove unnecessary static
8477 assertion. Allow sizeof(8) integer __intrinsic_type to enable
8478 the necessary mask type.
8480 2021-02-03 Matthias Kretz <kretz@kde.org>
8482 * include/experimental/bits/simd.h: Let __intrinsic_type<long
8483 double, N> be valid if sizeof(long double) == sizeof(double) and
8484 use a __vector double as member type.
8486 2021-02-03 Matthias Kretz <kretz@kde.org>
8488 * include/experimental/bits/simd.h (__is_intrinsic_type): New
8489 internal type trait. Alias for __is_vector_type on x86.
8490 (_VectorTraitsImpl): Enable for __intrinsic_type in addition for
8492 (__intrin_bitcast): Allow casting to & from vector & intrinsic
8494 (__intrinsic_type): Explicitly specialize for NEON intrinsic
8497 2021-02-03 Matthias Kretz <kretz@kde.org>
8499 * testsuite/experimental/simd/driver.sh: Implement skip, only,
8500 expensive, and xfail markers. They can select on type, ABI tag
8501 subset number, target-triplet, and compiler flags.
8502 * testsuite/experimental/simd/generate_makefile.sh: The summary
8503 now includes lines for unexpected passes and expected failures.
8504 If the skip or only markers are only conditional on the type, do
8505 not generate rules for those types.
8506 * testsuite/experimental/simd/tests/abs.cc: Mark test expensive
8507 for ABI tag subsets 1-9.
8508 * testsuite/experimental/simd/tests/algorithms.cc: Ditto.
8509 * testsuite/experimental/simd/tests/broadcast.cc: Ditto.
8510 * testsuite/experimental/simd/tests/casts.cc: Ditto.
8511 * testsuite/experimental/simd/tests/generator.cc: Ditto.
8512 * testsuite/experimental/simd/tests/integer_operators.cc: Ditto.
8513 * testsuite/experimental/simd/tests/loadstore.cc: Ditto.
8514 * testsuite/experimental/simd/tests/mask_broadcast.cc: Ditto.
8515 * testsuite/experimental/simd/tests/mask_conversions.cc: Ditto.
8516 * testsuite/experimental/simd/tests/mask_implicit_cvt.cc: Ditto.
8517 * testsuite/experimental/simd/tests/mask_loadstore.cc: Ditto.
8518 * testsuite/experimental/simd/tests/mask_operator_cvt.cc: Ditto.
8519 * testsuite/experimental/simd/tests/mask_operators.cc: Ditto.
8520 * testsuite/experimental/simd/tests/mask_reductions.cc: Ditto.
8521 * testsuite/experimental/simd/tests/operator_cvt.cc: Ditto.
8522 * testsuite/experimental/simd/tests/operators.cc: Ditto.
8523 * testsuite/experimental/simd/tests/reductions.cc: Ditto.
8524 * testsuite/experimental/simd/tests/simd.cc: Ditto.
8525 * testsuite/experimental/simd/tests/split_concat.cc: Ditto.
8526 * testsuite/experimental/simd/tests/splits.cc: Ditto.
8527 * testsuite/experimental/simd/tests/where.cc: Ditto.
8528 * testsuite/experimental/simd/tests/fpclassify.cc: Ditto. In
8529 addition replace "test only floattypes" marker by unconditional
8530 "float|double|ldouble" only marker.
8531 * testsuite/experimental/simd/tests/frexp.cc: Ditto.
8532 * testsuite/experimental/simd/tests/hypot3_fma.cc: Ditto.
8533 * testsuite/experimental/simd/tests/ldexp_scalbn_scalbln_modf.cc:
8535 * testsuite/experimental/simd/tests/logarithm.cc: Ditto.
8536 * testsuite/experimental/simd/tests/math_1arg.cc: Ditto.
8537 * testsuite/experimental/simd/tests/math_2arg.cc: Ditto.
8538 * testsuite/experimental/simd/tests/remqo.cc: Ditto.
8539 * testsuite/experimental/simd/tests/trigonometric.cc: Ditto.
8540 * testsuite/experimental/simd/tests/trunc_ceil_floor.cc: Ditto.
8541 * testsuite/experimental/simd/tests/sincos.cc: Ditto. In
8542 addition, xfail on run because the reference data is missing.
8544 2021-02-02 Jonathan Wakely <jwakely@redhat.com>
8546 * doc/xml/manual/status_cxx2011.xml: Remove stray table cell.
8547 * doc/xml/manual/status_cxx2014.xml: Likewise.
8548 * doc/xml/manual/status_cxx2017.xml: Likewise.
8549 * doc/html/manual/status.html: Regenerate.
8551 2021-02-01 François Dumont <fdumont@gcc.gnu.org>
8554 * include/bits/stl_deque.h (std::deque<>::operator-(iterator, iterator)):
8555 Return 0 if both iterators are value-initialized.
8556 * testsuite/23_containers/deque/70303.cc: New test.
8557 * testsuite/23_containers/vector/70303.cc: New test.
8559 2021-02-01 Jonathan Wakely <jwakely@redhat.com>
8561 * doc/xml/manual/status_cxx2011.xml: Update std::call_once
8563 * doc/xml/manual/status_cxx2014.xml: Likewise.
8564 * doc/xml/manual/status_cxx2017.xml: Likewise. Update
8565 std::from_chars and std::to_chars status. Fix formatting.
8566 * doc/html/manual/status.html: Regenerate.
8568 2021-01-28 Jonathan Wakely <jwakely@redhat.com>
8570 * include/experimental/bits/numeric_traits.h: Update copyright
8572 * include/experimental/bits/simd.h: Likewise.
8573 * include/experimental/bits/simd_builtin.h: Likewise.
8574 * include/experimental/bits/simd_converter.h: Likewise.
8575 * include/experimental/bits/simd_detail.h: Likewise.
8576 * include/experimental/bits/simd_fixed_size.h: Likewise.
8577 * include/experimental/bits/simd_math.h: Likewise.
8578 * include/experimental/bits/simd_neon.h: Likewise.
8579 * include/experimental/bits/simd_ppc.h: Likewise.
8580 * include/experimental/bits/simd_scalar.h: Likewise.
8581 * include/experimental/bits/simd_x86.h: Likewise.
8582 * include/experimental/bits/simd_x86_conversions.h: Likewise.
8583 * include/experimental/simd: Likewise.
8584 * testsuite/experimental/simd/*: Likewise.
8586 2021-01-27 Jonathan Wakely <jwakely@redhat.com>
8588 * doc/xml/manual/status_cxx2017.xml: Replace invalid entity.
8589 * doc/html/*: Regenerate.
8591 2021-01-27 Jonathan Wakely <jwakely@redhat.com>
8593 * testsuite/experimental/simd/generate_makefile.sh: Use printf
8594 instead of echo when printing escape characters.
8596 2021-01-27 Matthias Kretz <kretz@kde.org>
8598 * scripts/check_simd: New file. This script is called from the
8599 the check-simd target. It determines a set of compiler flags and
8600 simulator setups for calling generate_makefile.sh and passes the
8601 information back to the check-simd target, which recurses to the
8602 generated Makefiles.
8603 * scripts/create_testsuite_files: Remove files below simd/tests/
8604 from testsuite_files and place them in testsuite_files_simd.
8605 * testsuite/Makefile.am: Add testsuite_files_simd. Add
8607 * testsuite/Makefile.in: Regenerate.
8608 * testsuite/experimental/simd/driver.sh: New file. This script
8609 compiles and runs a given simd test, logging its output and
8610 status. It uses the timeout command to implement compile and
8612 * testsuite/experimental/simd/generate_makefile.sh: New file.
8613 This script generates a Makefile which uses driver.sh to compile
8614 and run the tests and collect the logs into a single log file.
8615 * testsuite/experimental/simd/tests/abs.cc: New file. Tests
8617 * testsuite/experimental/simd/tests/algorithms.cc: New file.
8618 Tests min/max(simd, simd).
8619 * testsuite/experimental/simd/tests/bits/conversions.h: New
8620 file. Contains functions to support tests involving conversions.
8621 * testsuite/experimental/simd/tests/bits/make_vec.h: New file.
8622 Support functions make_mask and make_vec.
8623 * testsuite/experimental/simd/tests/bits/mathreference.h: New
8624 file. Support functions to supply precomputed math function
8626 * testsuite/experimental/simd/tests/bits/metahelpers.h: New
8627 file. Support code for SFINAE testing.
8628 * testsuite/experimental/simd/tests/bits/simd_view.h: New file.
8629 * testsuite/experimental/simd/tests/bits/test_values.h: New
8630 file. Test functions to easily drive a test with simd objects
8631 initialized from a given list of values and a range of random
8633 * testsuite/experimental/simd/tests/bits/ulp.h: New file.
8634 Support code to determine the ULP distance of simd objects.
8635 * testsuite/experimental/simd/tests/bits/verify.h: New file.
8636 Test framework for COMPARE'ing simd objects and instantiating
8637 the test templates with value_type and ABI tag.
8638 * testsuite/experimental/simd/tests/broadcast.cc: New file. Test
8640 * testsuite/experimental/simd/tests/casts.cc: New file. Test
8642 * testsuite/experimental/simd/tests/fpclassify.cc: New file.
8643 Test floating-point classification functions.
8644 * testsuite/experimental/simd/tests/frexp.cc: New file. Test
8646 * testsuite/experimental/simd/tests/generator.cc: New file. Test
8647 simd generator constructor.
8648 * testsuite/experimental/simd/tests/hypot3_fma.cc: New file.
8649 Test 3-arg hypot(simd,simd,simd) and fma(simd,simd,sim).
8650 * testsuite/experimental/simd/tests/integer_operators.cc: New
8651 file. Test integer operators.
8652 * testsuite/experimental/simd/tests/ldexp_scalbn_scalbln_modf.cc:
8653 New file. Test ldexp(simd), scalbn(simd), scalbln(simd), and
8655 * testsuite/experimental/simd/tests/loadstore.cc: New file. Test
8656 (converting) simd loads and stores.
8657 * testsuite/experimental/simd/tests/logarithm.cc: New file. Test
8659 * testsuite/experimental/simd/tests/mask_broadcast.cc: New file.
8660 Test simd_mask broadcasts.
8661 * testsuite/experimental/simd/tests/mask_conversions.cc: New
8662 file. Test simd_mask conversions.
8663 * testsuite/experimental/simd/tests/mask_implicit_cvt.cc: New
8664 file. Test simd_mask implicit conversions.
8665 * testsuite/experimental/simd/tests/mask_loadstore.cc: New file.
8666 Test simd_mask loads and stores.
8667 * testsuite/experimental/simd/tests/mask_operator_cvt.cc: New
8668 file. Test simd_mask operators convert as specified.
8669 * testsuite/experimental/simd/tests/mask_operators.cc: New file.
8670 Test simd_mask compares, subscripts, and negation.
8671 * testsuite/experimental/simd/tests/mask_reductions.cc: New
8672 file. Test simd_mask reductions.
8673 * testsuite/experimental/simd/tests/math_1arg.cc: New file. Test
8674 1-arg math functions on simd.
8675 * testsuite/experimental/simd/tests/math_2arg.cc: New file. Test
8676 2-arg math functions on simd.
8677 * testsuite/experimental/simd/tests/operator_cvt.cc: New file.
8678 Test implicit conversions on simd binary operators behave as
8680 * testsuite/experimental/simd/tests/operators.cc: New file. Test
8681 simd compares, subscripts, not, unary minus, plus, minus,
8682 multiplies, divides, increment, and decrement.
8683 * testsuite/experimental/simd/tests/reductions.cc: New file.
8685 * testsuite/experimental/simd/tests/remqo.cc: New file. Test
8687 * testsuite/experimental/simd/tests/simd.cc: New file. Basic
8688 sanity checks of simd types.
8689 * testsuite/experimental/simd/tests/sincos.cc: New file. Test
8690 sin(simd) and cos(simd).
8691 * testsuite/experimental/simd/tests/split_concat.cc: New file.
8692 Test split(simd) and concat(simd, simd).
8693 * testsuite/experimental/simd/tests/splits.cc: New file. Test
8695 * testsuite/experimental/simd/tests/trigonometric.cc: New file.
8696 Test remaining trigonometric functions on simd.
8697 * testsuite/experimental/simd/tests/trunc_ceil_floor.cc: New
8698 file. Test trunc(simd), ceil(simd), and floor(simd).
8699 * testsuite/experimental/simd/tests/where.cc: New file. Test
8700 masked operations using where.
8702 2021-01-27 Matthias Kretz <kretz@kde.org>
8704 * doc/xml/manual/status_cxx2017.xml: Add implementation status
8705 of the Parallelism TS 2. Document implementation-defined types
8707 * include/Makefile.am: Add new headers.
8708 * include/Makefile.in: Regenerate.
8709 * include/experimental/simd: New file. New header for
8711 * include/experimental/bits/numeric_traits.h: New file.
8712 Implementation of P1841R1 using internal naming. Addition of
8713 missing IEC559 functionality query.
8714 * include/experimental/bits/simd.h: New file. Definition of the
8715 public simd interfaces and general implementation helpers.
8716 * include/experimental/bits/simd_builtin.h: New file.
8717 Implementation of the _VecBuiltin simd_abi.
8718 * include/experimental/bits/simd_converter.h: New file. Generic
8720 * include/experimental/bits/simd_detail.h: New file. Internal
8721 macros for the simd implementation.
8722 * include/experimental/bits/simd_fixed_size.h: New file. Simd
8723 fixed_size ABI specific implementations.
8724 * include/experimental/bits/simd_math.h: New file. Math
8726 * include/experimental/bits/simd_neon.h: New file. Simd NEON
8727 specific implementations.
8728 * include/experimental/bits/simd_ppc.h: New file. Implement bit
8729 shifts to avoid invalid results for integral types smaller than
8731 * include/experimental/bits/simd_scalar.h: New file. Simd scalar
8732 ABI specific implementations.
8733 * include/experimental/bits/simd_x86.h: New file. Simd x86
8734 specific implementations.
8735 * include/experimental/bits/simd_x86_conversions.h: New file.
8736 x86 specific conversion optimizations. The conversion patterns
8737 work around missing conversion patterns in the compiler and
8738 should be removed as soon as PR85048 is resolved.
8739 * testsuite/experimental/simd/standard_abi_usable.cc: New file.
8740 Test that all (not all fixed_size<N>, though) standard simd and
8741 simd_mask types are usable.
8742 * testsuite/experimental/simd/standard_abi_usable_2.cc: New
8743 file. As above but with -ffast-math.
8744 * testsuite/libstdc++-dg/conformance.exp: Don't build simd tests
8745 from the standard test loop. Instead use
8746 check_vect_support_and_set_flags to build simd tests with the
8747 relevant machine flags.
8749 2021-01-27 Jonathan Wakely <jwakely@redhat.com>
8752 * include/bits/string_view.tcc
8753 (basic_string_view::find(const CharT*, size_type, size_type)):
8756 2021-01-27 Paul Fee <paul.f.fee@gmail.com>
8758 * include/bits/basic_string.h (basic_string::contains): New
8760 * include/std/string_view (basic_string_view::contains):
8762 * include/std/version (__cpp_lib_string_contains): Define.
8763 * testsuite/21_strings/basic_string/operations/starts_with/char/1.cc:
8764 Remove trailing whitespace.
8765 * testsuite/21_strings/basic_string/operations/starts_with/wchar_t/1.cc:
8767 * testsuite/21_strings/basic_string/operations/contains/char/1.cc: New test.
8768 * testsuite/21_strings/basic_string/operations/contains/wchar_t/1.cc: New test.
8769 * testsuite/21_strings/basic_string_view/operations/contains/char/1.cc: New test.
8770 * testsuite/21_strings/basic_string_view/operations/contains/char/2.cc: New test.
8771 * testsuite/21_strings/basic_string_view/operations/contains/wchar_t/1.cc: New test.
8773 2021-01-21 Jonathan Wakely <jwakely@redhat.com>
8775 * src/c++17/Makefile.in: Regenerate.
8777 2021-01-20 David Edelsohn <dje.gcc@gmail.com>
8779 * config/os/aix/ctype_inline.h (bool ctype<char>:: is): Cast
8780 _OBJ_DATA subscript to unsigned char. Add _THREAD_SAFE access to
8782 (const char* ctype<char>:: is): Same.
8784 2021-01-18 Jonathan Wakely <jwakely@redhat.com>
8787 * testsuite/20_util/unique_ptr/io/lwg2948.cc: Do not try to
8788 write to a wide character stream if wide character support is
8789 disabled in the library.
8791 2021-01-18 Jonathan Wakely <jwakely@redhat.com>
8793 * testsuite/27_io/basic_stringstream/cons/char/1.cc: Use
8794 stringbuf not wstringbuf.
8796 2021-01-18 Jakub Jelinek <jakub@redhat.com>
8799 * src/c++11/Makefile.am (cxx11-ios_failure-lt.s, cxx11-ios_failure.s):
8800 Compile with -gno-as-loc-support.
8801 * src/c++11/Makefile.in: Regenerated.
8803 2021-01-16 H.J. Lu <hjl.tools@gmail.com>
8805 * testsuite/29_atomics/atomic_flag/test_and_set/explicit-hle.cc:
8806 Add -fcf-protection=none to -march=i486.
8808 2021-01-14 François Dumont <fdumont@gcc.gnu.org>
8810 * testsuite/23_containers/deque/debug/98466.cc: Make it pre-C++11
8813 2021-01-14 Alexandre Oliva <oliva@adacore.com>
8815 * testsuite/30_threads/future/members/poll.cc: Calibrate
8818 2021-01-14 François Dumont <fdumont@gcc.gnu.org>
8821 * include/bits/hashtable_policy.h (_Node_iterator_base()): Set _M_cur to nullptr.
8822 (_Node_iterator()): Make default.
8823 (_Node_const_iterator()): Make default.
8824 * include/debug/macros.h (__glibcxx_check_erae_range_after): Add _M_singular
8826 * include/debug/safe_iterator.h
8827 (_GLIBCXX_DEBUG_VERIFY_OPERANDS): Accept if both iterator are value initialized.
8828 * include/debug/safe_local_iterator.h (_GLIBCXX_DEBUG_VERIFY_OPERANDS):
8830 * include/debug/safe_iterator.tcc (_Safe_iterator<>::_M_valid_range): Add
8831 _M_singular checks on input iterators.
8832 * src/c++11/debug.cc (_Safe_iterator_base::_M_can_compare): Remove _M_singular
8834 * testsuite/23_containers/deque/debug/98466.cc: New test.
8835 * testsuite/23_containers/unordered_map/debug/98466.cc: New test.
8837 2021-01-14 Jonathan Wakely <jwakely@redhat.com>
8840 * include/bits/fs_path.h (__throw_conversion_error): New
8841 function to throw or abort on character conversion errors.
8842 (__wstr_from_utf8): Move definition after filesystem_error has
8843 been defined. Use __throw_conversion_error.
8844 (path::_S_convert<_EcharT>): Use __throw_conversion_error.
8845 (path::_S_str_convert<_CharT, _Traits, _Allocator>): Likewise.
8846 (path::u8string): Likewise.
8848 2021-01-14 Jonathan Wakely <jwakely@redhat.com>
8850 * include/std/barrier: Update copyright years. Fix whitespace.
8851 * include/std/version: Fix whitespace.
8852 * testsuite/30_threads/barrier/1.cc: Update copyright years.
8853 * testsuite/30_threads/barrier/2.cc: Likewise.
8854 * testsuite/30_threads/barrier/arrive.cc: Likewise.
8855 * testsuite/30_threads/barrier/arrive_and_drop.cc: Likewise.
8856 * testsuite/30_threads/barrier/arrive_and_wait.cc: Likewise.
8857 * testsuite/30_threads/barrier/completion.cc: Likewise.
8859 2021-01-13 Jonathan Wakely <jwakely@redhat.com>
8861 * doc/doxygen/user.cfg.in (INPUT): Remove include/debug/array.
8863 2021-01-10 David Edelsohn <dje.gcc@gmail.com>
8866 * testsuite/ext/vstring/cons/moveable.cc: Suppress false positive
8868 * testsuite/ext/vstring/modifiers/assign/move_assign.cc: Same.
8870 2021-01-08 Olivier Hainque <hainque@adacore.com>
8872 * testsuite/20_util/bind/ref_neg.cc: Tweak the
8873 dg-prune-output regex for out-of-build-tree contexts.
8875 2021-01-07 Thomas Rodgers <trodgers@redhat.com>
8877 * doc/doxygen/user.cfg.in: Add new header.
8878 * include/Makefile.am (std_headers): likewise.
8879 * include/Makefile.in: Regenerate.
8880 * include/precompiled/stdc++.h: Add new header.
8881 * include/std/barrier: New file.
8882 * include/std/version: Add __cpp_lib_barrier feature test macro.
8883 * testsuite/30_threads/barrier/1.cc: New test.
8884 * testsuite/30_threads/barrier/2.cc: Likewise.
8885 * testsuite/30_threads/barrier/arrive_and_drop.cc: Likewise.
8886 * testsuite/30_threads/barrier/arrive_and_wait.cc: Likewise.
8887 * testsuite/30_threads/barrier/arrive.cc: Likewise.
8888 * testsuite/30_threads/barrier/completion.cc: Likewise.
8890 2021-01-07 Patrick Palka <ppalka@redhat.com>
8893 * testsuite/20_util/to_chars/long_double.cc: Use nexttowardl
8894 instead of the non-standard nextupl and nextdownl.
8896 2021-01-05 Samuel Thibault <samuel.thibault@ens-lyon.org>
8898 * configure: Re-generate.
8900 2021-01-05 Ed Smith-Rowland <3dw4rd@verizon.net>
8902 * include/precompiled/stdc++.h: Add <source_location> to C++20 section.
8904 2021-01-01 Jakub Jelinek <jakub@redhat.com>
8906 * ChangeLog-2020: Rotate ChangeLog. New file.
8909 Copyright (C) 2021 Free Software Foundation, Inc.
8911 Copying and distribution of this file, with or without modification,
8912 are permitted in any medium without royalty provided the copyright
8913 notice and this notice are preserved.