1 2022-05-04 Jonathan Wakely <jwakely@redhat.com>
4 * include/std/array (array::size(), array::max_size())
5 (array::empty(), array::data()): Add always_inline attribute.
7 2022-05-04 Jonathan Wakely <jwakely@redhat.com>
10 * include/std/array (__array_traits::_S_ref): Remove.
11 (__array_traits::_S_ptr): Remove.
12 (__array_traits<T, 0>::_Type): Define operator[] and operator T*
13 to provide an array-like API.
14 (array::_AT_Type): Remove public typeef.
15 (array::operator[], array::at, array::front, array::back): Use
16 index operator to access _M_elems instead of _S_ref.
17 (array::data): Use implicit conversion from _M_elems to pointer.
18 (swap(array&, array&)): Use __enable_if_t helper.
19 (get<I>): Use index operator to access _M_elems.
20 * testsuite/23_containers/array/tuple_interface/get_neg.cc:
21 Adjust dg-error line numbers.
23 2022-05-03 Alexandre Oliva <oliva@adacore.com>
26 * testsuite/20_util/from_chars/pr105324.cc: Guard test body
27 with conditional for floating-point overloads of from_char.
29 2022-05-02 Patrick Palka <ppalka@redhat.com>
32 * src/c++17/floating_from_chars.cc (find_end_of_float): Accept
33 two delimeters for the exponent part in the form of a possibly
34 NULL string of length two. Don't use std::tolower.
35 (pattern): Adjust calls to find_end_of_float accordingly.
37 2022-05-02 Patrick Palka <ppalka@redhat.com>
40 * src/c++17/floating_from_chars.cc (__floating_from_chars_hex):
41 Also accept 'P' as the start of the exponent.
42 * testsuite/20_util/from_chars/7.cc: Add corresponding testcase.
44 2022-04-29 Jonathan Wakely <jwakely@redhat.com>
47 * config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt:
49 * src/c++11/compatibility-ldbl-alt128.cc [_GLIBCXX_USE_DUAL_ABI]:
50 Define __gnu_ieee128::num_get<C>::_M_extract_int[abi:cxx11]<I>
51 symbols as aliases for corresponding symbols without abi-tag.
53 2022-04-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
55 * config/abi/post/i386-solaris/baseline_symbols.txt: Regenerate.
56 * config/abi/post/i386-solaris/amd64/baseline_symbols.txt:
58 * config/abi/post/sparc-solaris/baseline_symbols.txt: Likewise.
59 * config/abi/post/sparc-solaris/sparcv9/baseline_symbols.txt:
62 2022-04-28 Jonathan Wakely <jwakely@redhat.com>
65 * src/c++17/fs_ops.cc (fs::copy): Pass error_code to
66 directory_iterator constructor, and check on each iteration.
67 * src/filesystem/ops.cc (fs::copy): Likewise.
68 * testsuite/27_io/filesystem/operations/copy.cc: Check for
69 errors during recursion.
70 * testsuite/experimental/filesystem/operations/copy.cc:
73 2022-04-28 François Dumont <fdumont@gcc.gnu.org>
75 * config/abi/pre/gnu-versioned-namespace.ver: Remove
76 std::random_device::* pattern.
78 2022-04-27 Jakub Jelinek <jakub@redhat.com>
80 * config/abi/post/x86_64-linux-gnu/baseline_symbols.txt: Update.
81 * config/abi/post/x86_64-linux-gnu/32/baseline_symbols.txt: Update.
82 * config/abi/post/i486-linux-gnu/baseline_symbols.txt: Update.
83 * config/abi/post/aarch64-linux-gnu/baseline_symbols.txt: Update.
84 * config/abi/post/s390x-linux-gnu/baseline_symbols.txt: Update.
85 * config/abi/post/powerpc-linux-gnu/baseline_symbols.txt: Update.
86 * config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt: Update.
87 * config/abi/post/powerpc64-linux-gnu/32/baseline_symbols.txt: Update.
89 2022-04-27 Jonathan Wakely <jwakely@redhat.com>
91 * python/libstdcxx/v6/printers.py (SharedPointerPrinter): Add
92 support for atomic<shared_ptr<T>> and atomic<weak_ptr<T>>.
93 (StdAtomicPrinter): New printer.
94 (build_libstdcxx_dictionary): Register new printer.
95 * testsuite/libstdc++-prettyprinters/cxx11.cc: Test std::atomic.
96 * testsuite/libstdc++-prettyprinters/cxx20.cc: Test atomic smart
99 2022-04-26 Jonathan Wakely <jwakely@redhat.com>
101 * include/bits/shared_ptr_atomic.h (atomic<shared_ptr>): Add
102 constructor for constant initialization from nullptr_t.
103 * testsuite/20_util/shared_ptr/atomic/atomic_shared_ptr.cc:
104 Check for new constructor.
106 2022-04-26 Jonathan Wakely <jwakely@redhat.com>
108 * include/bits/fs_path.h (hash<filesystem::path>): Define.
109 * testsuite/27_io/filesystem/path/nonmember/hash_value.cc:
110 Check std::hash specialization.
112 2022-04-25 Jonathan Wakely <jwakely@redhat.com>
114 * include/bits/ptr_traits.h (__cpp_lib_constexpr_memory): Define
116 * include/bits/unique_ptr.h (__cpp_lib_constexpr_memory):
118 (default_delete, default_delete<T[]>, __uniq_ptr_impl)
119 (unique_ptr, unique_ptr<T[], D>): Add constexpr to all member
121 * include/std/version (__cpp_lib_constexpr_memory): Define new
123 * testsuite/20_util/unique_ptr/assign/constexpr.cc: New test.
124 * testsuite/20_util/unique_ptr/comparison/constexpr.cc: New test.
125 * testsuite/20_util/unique_ptr/cons/constexpr_c++20.cc: New test.
126 * testsuite/20_util/unique_ptr/creation/constexpr.cc: New test.
127 * testsuite/20_util/unique_ptr/modifiers/constexpr.cc: New test.
128 * testsuite/20_util/unique_ptr/specialized_algorithms/constexpr.cc:
131 2022-04-25 Jonathan Wakely <jwakely@redhat.com>
134 * include/std/future (packaged_task): Add deduction guides.
135 * testsuite/30_threads/packaged_task/cons/deduction.cc: New test.
137 2022-04-25 Philipp Fent <fent@in.tum.de>
139 * python/libstdcxx/v6/printers.py (StdSpanPrinter._iterator):
141 (StdInitializerListPrinter): Define new printer.
142 (build_libstdcxx_dictionary): Register new printer.
143 * testsuite/libstdc++-prettyprinters/cxx11.cc: Check printer for
146 2022-04-22 Thomas W Rodgers <trodgers@redhat.com>
149 * include/bits/atomic_base.h (atomic_flag::notify_one,
150 notify_all): Remove const qualification.
151 (__atomic_base::notify_one, notify_all): Likewise.
152 * include/std/atomic (atomic<bool>::notify_one, notify_all):
154 (atomic::notify_one, notify_all): Likewise.
155 (atomic<T*>::notify_one, notify_all): Likewise.
156 (atomic_notify_one, atomic_notify_all): Likewise.
157 * testsuite/29_atomics/atomic/wait_notify/102994.cc: Adjust test
158 to account for change in notify_one/notify_all signature.
160 2022-04-21 Patrick Palka <ppalka@redhat.com>
162 * include/std/charconv (__from_chars_alnum_to_val_table):
163 Simplify initialization of __lower/__upper_letters.
164 (__from_chars_alnum_to_val): Default the template parameter to
166 * src/c++17/floating_from_chars.cc (starts_with_ci): Don't
167 assume the uppercase and lowercase letters are contiguous.
168 (__floating_from_chars_hex): Likewise.
170 2022-04-21 Patrick Palka <ppalka@redhat.com>
174 * include/std/charconv (__from_chars_alnum_to_val): Make
175 initializer for __table dependent in an artificial way.
177 2022-04-21 Jonathan Wakely <jwakely@redhat.com>
180 * src/c++17/floating_from_chars.cc (buffer_resource::do_allocate):
182 * testsuite/20_util/from_chars/pr105324.cc: New test.
184 2022-04-20 Jonathan Wakely <jwakely@redhat.com>
186 * testsuite/21_strings/basic_string_view/operations/copy/char/constexpr.cc:
187 Check correct feature test macro.
189 2022-04-20 Jonathan Wakely <jwakely@redhat.com>
192 * doc/xml/manual/prerequisites.xml: Document libiconv
194 * doc/html/manual/setup.html: Regenerate.
195 * src/Makefile.am (CXXLINK): Add $(LTLIBICONV).
196 * src/Makefile.in: Regenerate.
198 2022-04-19 Patrick Palka <ppalka@redhat.com>
200 * src/c++17/floating_to_chars.cc (_GLIBCXX_ASSERTIONS): Don't
202 (__floating_to_chars_shortest): Add __builtin_unreachable calls to
203 squelch false-positive -Wmaybe-uninitialized and -Wreturn-type
205 (__floating_to_chars_precision): Likewise.
207 2022-04-19 Philipp Fent <fent@in.tum.de>
209 * python/libstdcxx/v6/printers.py (StdSpanPrinter): Define.
210 * testsuite/libstdc++-prettyprinters/cxx20.cc: Test it.
212 2022-04-19 Jonathan Wakely <jwakely@redhat.com>
214 * acinclude.m4 (GLIBCXX_ENABLE_BACKTRACE): Fix shell operators.
215 * configure: Regenerate.
217 2022-04-18 Patrick Palka <ppalka@redhat.com>
219 * include/std/charconv (__from_chars_pow2_base): Manually
220 unroll the first iteration of the main loop and simplify
223 2022-04-15 Patrick Palka <ppalka@redhat.com>
226 * include/bits/ranges_algo.h (__minmax_fn): Avoid dereferencing
227 __first twice at the start.
228 * testsuite/25_algorithms/minmax/constrained.cc (test06): New test.
230 2022-04-15 Patrick Palka <ppalka@redhat.com>
232 * include/std/charconv (__from_chars_alnum_to_val_table): Define.
233 (__from_chars_alnum_to_val): Define.
234 (__from_chars_binary): Rename to ...
235 (__from_chars_pow2_base): ... this. Generalize to handle any
236 power-of-two base using __from_chars_alnum_to_val.
237 (__from_chars_digit): Optimize digit recognition to a single
238 test instead of two tests. Use [[__unlikely___]] attribute.
239 (__from_chars_alpha_to_num): Remove.
240 (__from_chars_alnum): Use __from_chars_alnum_to_val. Use a
241 nested loop for the overflow case. Maintain a lower bound
242 on the number of available bits in the result and use it to
243 omit the overflow check.
244 (from_chars): Adjust appropriately.
245 * src/c++17/floating_from_chars.cc (ascii_to_hexit): Remove.
246 (__floating_from_chars_hex): Use __from_chars_alnum_to_val
247 to recognize a hex digit instead.
249 2022-04-14 Palmer Dabbelt <palmer@rivosinc.com>
251 * acinclude.m4 (GLIBCXX_ENABLE_LOCK_POLICY): Force auto to mutex
253 * configure: Regenerate.
255 2022-04-14 Jonathan Wakely <jwakely@redhat.com>
257 * doc/xml/manual/intro.xml: Fix comment.
259 2022-04-14 Jonathan Wakely <jwakely@redhat.com>
261 * include/precompiled/stdc++.h: Include <stacktrace> and
262 <stdatomic.h> for C++23.
264 2022-04-14 Jonathan Wakely <jwakely@redhat.com>
267 * include/bits/stl_vector.h (__cpp_lib_constexpr_vector):
269 * include/c_compatibility/stdatomic.h (__cpp_lib_stdatomic_h):
271 * include/std/optional (__cpp_lib_optional): Define new value
273 (__cpp_lib_monadic_optional): Remove.
274 * include/std/version (__cpp_lib_constexpr_vector): Define.
275 (__cpp_lib_stdatomic_h): Define.
276 (__cpp_lib_optional): Define new value for C++23.
277 (__cpp_lib_monadic_optional): Remove.
278 * testsuite/20_util/optional/monadic/and_then.cc: Adjust.
279 * testsuite/20_util/optional/requirements.cc: Adjust for C++23.
280 * testsuite/20_util/optional/version.cc: Likewise.
281 * testsuite/23_containers/vector/cons/constexpr.cc: Check
283 * testsuite/29_atomics/headers/stdatomic.h/c_compat.cc:
285 * testsuite/20_util/optional/monadic/version.cc: Removed.
286 * testsuite/23_containers/vector/requirements/version.cc: New test.
287 * testsuite/29_atomics/headers/stdatomic.h/version.cc: New test.
289 2022-04-12 Jonathan Wakely <jwakely@redhat.com>
291 * acinclude.m4 (GLIBCXX_ENABLE_BACKTRACE): Check for mmap.
292 * config.h.in: Regenerate.
293 * configure: Regenerate.
295 2022-04-12 Jonathan Wakely <jwakely@redhat.com>
297 * include/std/stacktrace (basic_stacktrace::current): Reallocate
298 a smaller container if the unused capacity is larger than the
301 2022-04-12 Jonathan Wakely <jwakely@redhat.com>
303 * include/std/stacktrace (basic_stacktrace): Use _Impl::_M_clone
304 or _Impl::_M_assign to initialize elements in allocated storage.
305 (basic_stacktrace::_M_clear()): Use _Impl::_M_resize instead of
307 (basic_stacktrace::_Impl::_M_destroy()): Replace with ...
308 (basic_stacktrace::_Impl::_M_resize(size_type, allocator&)): New
310 (basic_stacktrace::_Impl::_M_push_back): Use _M_xclone. Construct
311 new element using allocator.
312 (basic_stacktrace::_Impl::_M_clone): New function.
313 (basic_stacktrace::_Impl::_M_xclone): New function.
314 (basic_stacktrace::_Impl::_M_assign): New function.
316 2022-04-12 Jonathan Wakely <jwakely@redhat.com>
318 * include/std/stacktrace (basic_stacktrace::_Impl::_M_allocate):
319 Use nothrow new instead of try block for std::allocator.
320 (basic_stacktrace::_Impl::_M_deallocate): Use delete for
323 2022-04-12 Jonathan Wakely <jwakely@redhat.com>
325 * include/std/stacktrace (basic_stacktrace::current): Replace
326 calls to _M_reserve and _S_curr_cb with call to _M_prepare.
327 Check return value of backtrace_simple when max depth given.
328 (basic_stacktrace::_M_reserve): Remove.
329 (basic_stacktrace::_S_curr_cb): Remove.
330 (basic_stacktrace::_M_prepare(size_type)): New function to
331 reserve initial capacity and return callback.
332 (basic_stacktrace::_Impl::_M_allocate): Remove check for 0 < n
333 and remove redundant zeroing of _M_frames and _M_capacity.
334 (basic_stacktrace::_Impl::_M_push_back): Add [[unlikely]]
335 attribute. Assign _Impl instead of swapping.
336 * testsuite/19_diagnostics/stacktrace/current.cc: New test.
338 2022-04-11 Jonathan Wakely <jwakely@redhat.com>
340 * include/std/stacktrace (basic_stacktrace::_Impl::_M_allocate):
341 Change [[unlikely]] attribute to [[likely]].
343 2022-04-11 Jonathan Wakely <jwakely@redhat.com>
346 * include/std/stacktrace (basic_stacktrace::basic_stacktrace):
347 Fix allocator usage in constructors.
348 (basic_stacktrace::operator=(const basic_stacktrace&)): Do not
349 try to reallocate using const allocator.
350 (basic_stacktrace::operator=(basic_stacktrace&&)): Fix
351 if-constexpr with non-constant condition. Do not allocate new
352 storage if allocator propagates. Do not set _M_size if
354 (basic_stacktrace::swap(basic_stacktrace&)): Fix typo. Add
355 assertion that non-propagating allocators are equal.
356 * testsuite/19_diagnostics/stacktrace/stacktrace.cc: New test.
358 2022-04-11 Jonathan Wakely <jwakely@redhat.com>
360 * include/std/stacktrace (basic_stacktrace::current): Duplicate
361 implementation into each overload. Add noinline attribute and
363 (basic_stacktrace::max_size()): Call _Impl::_S_max_size.
364 (basic_stacktrace::_S_curr_cb()): New function defining lambda.
365 (basic_stacktrace::_Impl::_S_max_size): New function defining
366 maximum size in terms of allocator and size_type.
367 (basic_stacktrace::_Impl::_M_allocate): Check against
369 * testsuite/19_diagnostics/stacktrace/entry.cc: Call function
370 for non-constexpr checks. Check line number is correct.
372 2022-04-11 Jonathan Wakely <jwakely@redhat.com>
374 * testsuite/20_util/stacktrace/entry.cc: Moved to...
375 * testsuite/19_diagnostics/stacktrace/entry.cc: ...here.
376 * testsuite/20_util/stacktrace/synopsis.cc: Moved to...
377 * testsuite/19_diagnostics/stacktrace/synopsis.cc: ...here.
378 * testsuite/20_util/stacktrace/version.cc: Moved to...
379 * testsuite/19_diagnostics/stacktrace/version.cc: ...here.
381 2022-04-11 Jonathan Wakely <jwakely@redhat.com>
383 * include/experimental/bits/fs_path.h (path): Define special
384 members after path::_Cmpt is complete.
386 2022-04-08 Jonathan Wakely <jwakely@redhat.com>
389 * include/std/expected
390 (expected<void,E>::expected(expected<U,G>&&)): Fix constraints.
391 * testsuite/20_util/expected/cons.cc: Check constructor.
393 2022-04-08 Jonathan Wakely <jwakely@redhat.com>
396 * include/std/expected (expected<void, E>::swap): Set
397 _M_has_value to false for objects that previously had a value.
398 * testsuite/20_util/expected/swap.cc: Fix test to check void
401 2022-04-08 Jonathan Wakely <jwakely@redhat.com>
404 * include/std/expected (bad_expected_access): Move constructor
406 * testsuite/20_util/expected/bad.cc: New test.
408 2022-04-07 Hans-Peter Nilsson <hp@axis.com>
410 * testsuite/20_util/expected/requirements.cc: Correct minimal-size
413 2022-04-02 Jakub Jelinek <jakub@redhat.com>
416 * include/std/source_location (std::source_location::__impl): Move
417 definition before using __builtin_ret_type.
419 2022-04-01 Jonathan Wakely <jwakely@redhat.com>
421 * include/std/utility (unreachable): Define for C++23.
422 * include/std/version (__cpp_lib_unreachable): Define.
423 * src/c++11/debug.cc (__glibcxx_assert_fail): Check for valid
424 arguments. Handle only the function being given.
425 * testsuite/20_util/unreachable/1.cc: New test.
426 * testsuite/20_util/unreachable/version.cc: New test.
428 2022-04-01 Jonathan Wakely <jwakely@redhat.com>
430 * include/experimental/bits/fs_fwd.h (copy_file): Remove
431 incorrect noexcept from declaration.
432 * include/experimental/bits/fs_path.h (path::begin, path::end):
433 Add noexcept to declarations, to match definitions.
435 2022-04-01 Timm Bäder <tbaeder@redhat.com>
437 * include/bits/fs_ops.h: Fix filename in Doxygen comment.
438 * include/experimental/bits/fs_ops.h: Likewise.
440 2022-03-31 Jonathan Wakely <jwakely@redhat.com>
442 * libsupc++/new_opa.cc (aligned_alloc): Add comment.
444 2022-03-29 Jonathan Wakely <jwakely@redhat.com>
446 * testsuite/18_support/exception/38732.cc: Disable for C++23.
447 * testsuite/18_support/headers/exception/synopsis.cc: Likewise.
448 * testsuite/18_support/unexpected_handler.cc: Likewise.
450 2022-03-29 Jonathan Wakely <jwakely@redhat.com>
452 * libsupc++/compare (_Strong_order) [!__cpp_using_enum]: Add
453 static data members for _Fp_fmt enumerators.
455 2022-03-29 Jonathan Wakely <jwakely@redhat.com>
457 * include/std/version (__cpp_lib_variant): Fix conditions to
459 (__cpp_lib_expected): Fix condition to match <expected>.
461 2022-03-28 Jonathan Wakely <jwakely@redhat.com>
463 * testsuite/20_util/optional/monadic/and_then.cc: Fix typo.
464 * testsuite/20_util/optional/monadic/transform.cc: Likewise.
465 * testsuite/22_locale/codecvt/always_noconv/char/1.cc: Likewise.
466 * testsuite/22_locale/codecvt/encoding/char/1.cc: Likewise.
467 * testsuite/22_locale/codecvt/in/char/1.cc: Likewise.
468 * testsuite/22_locale/codecvt/max_length/char/1.cc: Likewise.
469 * testsuite/22_locale/codecvt/out/char/1.cc: Likewise.
470 * testsuite/22_locale/codecvt/unshift/char/1.cc: Likewise.
472 2022-03-27 Jonathan Wakely <jwakely@redhat.com>
474 * doc/doxygen/user.cfg.in: Add new header.
475 * include/Makefile.am: Likewise.
476 * include/Makefile.in: Regenerate.
477 * include/precompiled/stdc++.h: Add new header.
478 * include/std/version (__cpp_lib_expected): Define.
479 * libsupc++/exception [__cplusplus > 202002] (unexpected)
480 (unexpected_handler, set_unexpected): Do not declare for C++23.
481 * include/std/expected: New file.
482 * testsuite/20_util/expected/assign.cc: New test.
483 * testsuite/20_util/expected/cons.cc: New test.
484 * testsuite/20_util/expected/illformed_neg.cc: New test.
485 * testsuite/20_util/expected/observers.cc: New test.
486 * testsuite/20_util/expected/requirements.cc: New test.
487 * testsuite/20_util/expected/swap.cc: New test.
488 * testsuite/20_util/expected/synopsis.cc: New test.
489 * testsuite/20_util/expected/unexpected.cc: New test.
490 * testsuite/20_util/expected/version.cc: New test.
492 2022-03-25 Jonathan Wakely <jwakely@redhat.com>
494 * include/std/bit (bit_cast, byteswap, endian): Add doxygen
497 2022-03-23 Jonathan Wakely <jwakely@redhat.com>
500 * include/std/bit (bit_cast): Add constraints.
501 * testsuite/26_numerics/bit/bit.cast/105027.cc: New test.
503 2022-03-23 Jonathan Wakely <jwakely@redhat.com>
505 * include/std/version [!_GLIBCXX_HOSTED]
506 (__cpp_lib_hardware_interference_size): Define for freestanding.
507 (__cpp_lib_bit_cast): Likewise.
508 (__cpp_lib_is_layout_compatible): Likewise.
509 (__cpp_lib_is_pointer_interconvertible): Likewise.
510 (__cpp_lib_adaptor_iterator_pair_constructor): Do not define for
512 (__cpp_lib_invoke_r): Likewise.
513 (__cpp_lib_ios_noreplace): Likewise.
514 (__cpp_lib_monadic_optional): Likewise.
515 (__cpp_lib_move_only_function): Likewise.
516 (__cpp_lib_spanstream): Likewise.
517 (__cpp_lib_stacktrace): Likewise.
518 (__cpp_lib_string_contains): Likewise.
519 (__cpp_lib_string_resize_and_overwrite): Likewise.
520 (__cpp_lib_to_underlying): Likewise.
522 2022-03-23 Jonathan Wakely <jwakely@redhat.com>
525 * include/bits/atomic_base.h [!_GLIBCXX_HOSTED]: Do not include
526 <bits/atomic_wait.h> for freestanding.
528 2022-03-22 Hans-Peter Nilsson <hp@axis.com>
530 * testsuite/20_util/from_chars/6.cc (test01) [FE_DOWNWARD]:
531 Conditionalize call to fesetround.
533 2022-03-21 Jakub Jelinek <jakub@redhat.com>
536 * include/bits/locale_facets_nonio.tcc (get): Don't check if do_get
537 isn't overloaded if __clang__ is defined.
539 2022-03-18 Jonathan Wakely <jwakely@redhat.com>
542 * include/std/any (any(T&&)): Revert change to constraints.
543 * testsuite/20_util/any/cons/104242.cc: New test.
545 2022-03-18 Jonathan Wakely <jwakely@redhat.com>
548 * include/pstl/glue_algorithm_defs.h: Replace <functional> with
550 * include/pstl/utils.h: Replace <iterator> with <type_traits>.
551 (__pstl::__internal::__except_handler): Use std::__terminate
552 instead of std::terminate.
553 * src/c++17/fs_path.cc: Include <array>.
554 * testsuite/25_algorithms/adjacent_find/constexpr.cc: Include
556 * testsuite/25_algorithms/binary_search/constexpr.cc: Likewise.
557 * testsuite/25_algorithms/clamp/constrained.cc: Likewise.
558 * testsuite/25_algorithms/equal/constrained.cc: Likewise.
559 * testsuite/25_algorithms/for_each/constrained.cc: Likewise.
560 * testsuite/25_algorithms/includes/constrained.cc: Likewise.
561 * testsuite/25_algorithms/is_heap/constexpr.cc: Likewise.
562 * testsuite/25_algorithms/is_heap_until/constexpr.cc: Likewise.
563 * testsuite/25_algorithms/is_permutation/constrained.cc: Include
565 * testsuite/25_algorithms/is_sorted/constexpr.cc: Include
567 * testsuite/25_algorithms/is_sorted_until/constexpr.cc:
569 * testsuite/25_algorithms/lexicographical_compare/constexpr.cc:
571 * testsuite/25_algorithms/lexicographical_compare/constrained.cc:
573 * testsuite/25_algorithms/lexicographical_compare_three_way/1.cc:
575 * testsuite/25_algorithms/lower_bound/constexpr.cc: Include
577 * testsuite/25_algorithms/max/constrained.cc: Likewise.
578 * testsuite/25_algorithms/max_element/constrained.cc: Likewise.
579 * testsuite/25_algorithms/min/constrained.cc: Likewise.
580 * testsuite/25_algorithms/min_element/constrained.cc: Likewise.
581 * testsuite/25_algorithms/minmax_element/constrained.cc:
583 * testsuite/25_algorithms/mismatch/constexpr.cc: Likewise.
584 * testsuite/25_algorithms/move/93872.cc: Likewise.
585 * testsuite/25_algorithms/move_backward/93872.cc: Include
587 * testsuite/25_algorithms/nth_element/constexpr.cc: Include
589 * testsuite/25_algorithms/partial_sort/constexpr.cc: Likewise.
590 * testsuite/25_algorithms/partial_sort_copy/constexpr.cc:
592 * testsuite/25_algorithms/search/constexpr.cc: Likewise.
593 * testsuite/25_algorithms/search_n/constrained.cc: Likewise.
594 * testsuite/25_algorithms/set_difference/constexpr.cc: Likewise.
595 * testsuite/25_algorithms/set_difference/constrained.cc:
597 * testsuite/25_algorithms/set_intersection/constexpr.cc:
599 * testsuite/25_algorithms/set_intersection/constrained.cc:
601 * testsuite/25_algorithms/set_symmetric_difference/constexpr.cc:
603 * testsuite/25_algorithms/set_union/constexpr.cc: Likewise.
604 * testsuite/25_algorithms/set_union/constrained.cc: Likewise.
605 * testsuite/25_algorithms/sort/constexpr.cc: Likewise.
606 * testsuite/25_algorithms/sort_heap/constexpr.cc: Likewise.
607 * testsuite/25_algorithms/transform/constrained.cc: Likewise.
608 * testsuite/25_algorithms/unique/constexpr.cc: Likewise.
609 * testsuite/25_algorithms/unique/constrained.cc: Likewise.
610 * testsuite/25_algorithms/unique_copy/constexpr.cc: Likewise.
611 * testsuite/25_algorithms/upper_bound/constexpr.cc: Likewise.
612 * testsuite/std/ranges/adaptors/elements.cc: Include <vector>.
613 * testsuite/std/ranges/adaptors/lazy_split.cc: Likewise.
614 * testsuite/std/ranges/adaptors/split.cc: Likewise.
616 2022-03-17 Jonathan Wakely <jwakely@redhat.com>
619 * include/bits/fs_path.h (path::make_preferred): Use
620 handwritten loop instead of std::replace.
622 2022-03-17 Jonathan Wakely <jwakely@redhat.com>
625 * include/bits/locale_facets_nonio.tcc
626 (__moneypunct_cache::_M_cache): Replace try-catch with RAII and
627 make all string copies before any stores to *this.
629 2022-03-17 Jonathan Wakely <jwakely@redhat.com>
631 * testsuite/util/testsuite_character.h: Fix comment.
633 2022-03-16 Jonathan Wakely <jwakely@redhat.com>
636 * config/abi/pre/gnu.ver: Make version for std::from_chars
637 depend on HAVE_USELOCALE macro.
638 * testsuite/util/testsuite_abi.cc (compare_symbols): Treat
639 std::from_chars for floating-point types as undesignated if
640 not found in the baseline symbols file.
642 2022-03-16 Jonathan Wakely <jwakely@redhat.com>
644 * include/std/charconv (__cpp_lib_to_chars): Only define when
645 both from_chars and to_chars are supported for floating-point
647 (from_chars, to_chars): Adjust preprocessor conditions guarding
649 * include/std/version (__cpp_lib_to_chars): Adjust condition to
650 match <charconv> definition.
651 * src/c++17/floating_from_chars.cc (from_chars_strtod): New
653 (from_chars): Simplify preprocessor checks and use
654 from_chars_strtod when appropriate.
656 2022-03-14 Jonathan Wakely <jwakely@redhat.com>
659 * src/c++11/codecvt.cc (read_utf8_code_point): Use char32_t to
660 hold octets that will be left-shifted.
662 2022-03-10 Jonathan Wakely <jwakely@redhat.com>
665 * src/c++17/floating_from_chars.cc: Check __SIZE_WIDTH__ >= 32
666 before using fast_float.
668 2022-03-10 Detlef Vollmann <dv@vollmann.ch>
671 * include/bits/this_thread_sleep.h: Fix order of #endif and
672 closing brace of namespace.
674 2022-03-10 Jonathan Wakely <jwakely@redhat.com>
676 * libsupc++/compare (_Strong_order::_S_fp_cmp) [__vax__]:
679 2022-03-10 Jonathan Wakely <jwakely@redhat.com>
681 * libsupc++/compare (_Strong_ordering::_S_fp_cmp) [__vax__]: Use
684 2022-03-09 Patrick Palka <ppalka@redhat.com>
687 * src/c++17/floating_to_chars.cc (__floating_to_chars_hex):
688 Be explicit when narrowing the shifted effective_mantissa,
689 since it may have an integer-class type.
691 2022-03-08 Jonathan Wakely <jwakely@redhat.com>
693 * include/bits/uses_allocator_args.h: Remove incorrect copyright
696 2022-03-07 Jonathan Wakely <jwakely@redhat.com>
699 * include/bits/c++config (__terminate, __glibcxx_assert_fail):
700 Replace _GLIBCXX_VISIBILITY on function with visibility pragma.
701 (__is_constant_evaluated): Add visibility pragma.
703 2022-03-07 Rasmus Villemoes <rasmus.villemoes@prevas.dk>
705 * config/locale/vxworks/ctype_members.cc: Remove <iostream>
708 2022-03-05 Jonathan Wakely <jwakely@redhat.com>
710 * include/bits/c++config (__glibcxx_assert_fail): Add visibility
712 (__terminate): Likewise.
714 2022-03-04 Jonathan Wakely <jwakely@redhat.com>
716 * libsupc++/compare (strong_order::_S_fp_cmp): Move typedef
717 inside #if condition.
719 2022-03-03 Jonathan Wakely <jwakely@redhat.com>
722 * testsuite/std/ranges/adaptors/all.cc: Use non-debug vector for
725 2022-03-03 Jonathan Wakely <jwakely@redhat.com>
727 * testsuite/17_intro/names.cc (func): Undef on AIX.
729 2022-03-03 Jonathan Wakely <jwakely@redhat.com>
732 * libsupc++/compare (strong_order): Add missing support for
733 floating-point types.
734 * testsuite/18_support/comparisons/algorithms/strong_order_floats.cc:
737 2022-03-01 Jonathan Wakely <jwakely@redhat.com>
740 * include/bits/regex_compiler.h (_BracketMatcher::_M_char): Use
741 default member initializer.
743 2022-02-24 Jonathan Wakely <jwakely@redhat.com>
746 * include/std/source_location (source_location::current): Use
747 deduced type of __builtin_source_location().
749 2022-02-22 Patrick Palka <ppalka@redhat.com>
751 * include/bits/ranges_base.h (__detail::__is_initializer_list):
753 (viewable_range): Adjust as per P2415R2.
754 * include/bits/ranges_cmp.h (__cpp_lib_ranges): Adjust value.
755 * include/std/ranges (owning_view): Define as per P2415R2.
756 (enable_borrowed_range<owning_view>): Likewise.
757 (views::__detail::__can_subrange): Replace with ...
758 (views::__detail::__can_owning_view): ... this.
759 (views::_All::_S_noexcept): Sync with operator().
760 (views::_All::operator()): Use owning_view instead of subrange
762 * include/std/version (__cpp_lib_ranges): Adjust value.
763 * testsuite/std/ranges/adaptors/all.cc (test06): Adjust now that
764 views::all uses owning_view instead of subrange.
766 * testsuite/std/ranges/adaptors/lazy_split.cc (test09): Adjust
767 now that rvalue non-view non-borrowed ranges are viewable.
768 * testsuite/std/ranges/adaptors/split.cc (test06): Likewise.
770 2022-02-17 Jonathan Wakely <jwakely@redhat.com>
773 * doc/xml/manual/evolution.xml: Document deprecation.
774 * doc/html/manual/api.html: Regenerate.
775 * include/bits/stl_bvector.h (insert(const_iterator, const bool&)):
776 Remove default argument.
777 (insert(const_iterator)): New overload with deprecated attribute.
778 * testsuite/23_containers/vector/bool/modifiers/insert/104559.cc:
781 2022-02-17 Jonathan Wakely <jwakely@redhat.com>
783 * python/libstdcxx/v6/printers.py (StdErrorCodePrinter): Replace
784 code that call cat->name() on std::error_category objects.
785 Identify known categories by symbol name and use a hardcoded
786 name. Print error code values as enumerators where appopriate.
787 * testsuite/libstdc++-prettyprinters/cxx11.cc: Adjust expected
788 name of custom category. Check io_errc and future_errc errors.
790 2022-02-15 Jonathan Wakely <jwakely@redhat.com>
793 * include/bits/uses_allocator_args.h (make_obj_using_allocator)
794 (uninitialized_construct_using_allocator): Add constexpr.
795 * testsuite/20_util/uses_allocator/make_obj.cc: Check constexpr.
796 * testsuite/20_util/uses_allocator/uninitialized_construct.cc: New test.
798 2022-02-14 Jonathan Wakely <jwakely@redhat.com>
801 * config/locale/gnu/c_locale.h (__convert_from_v): Use inline
802 namespace for IEEE128 long double mode.
803 * config/os/gnu-linux/ldbl-ieee128-extra.ver: Add new symbol
804 version and export __gnu_cxx_ieee128::__convert_from_v.
805 * include/bits/locale_facets_nonio.tcc (money_put::__do_put):
806 Make __ibm128 overload use snprintf directly
807 * testsuite/util/testsuite_abi.cc: Add new symbol version.
808 Remove stable IEEE128/LDBL versions.
810 2022-02-14 Jonathan Wakely <jwakely@redhat.com>
813 * include/bits/c++config (_GLIBCXX_HAVE_COND_TRIVIAL_SPECIAL_MEMBERS):
815 * include/std/variant: Check feature test macros instead.
816 * include/std/version: Likewise.
818 2022-02-14 Jonathan Wakely <jwakely@redhat.com>
820 * testsuite/20_util/unsynchronized_pool_resource/allocate.cc:
823 2022-02-14 Jonathan Wakely <jwakely@redhat.com>
825 * src/c++17/floating_to_chars.cc (FLOAT128_TO_CHARS): Depend on
826 LONG_DOUBLE_ALT128_COMPAT instead of USE_FLOAT128.
828 2022-02-11 Jonathan Wakely <jwakely@redhat.com>
830 * testsuite/20_util/temporary_buffer.cc: Fix dg-warning target
833 2022-02-11 Jonathan Wakely <jwakely@redhat.com>
835 * testsuite/20_util/monotonic_buffer_resource/allocate.cc:
836 Ignore -Walloc-larger-than warning.
837 * testsuite/20_util/unsynchronized_pool_resource/allocate.cc:
839 * testsuite/29_atomics/atomic/cons/user_pod.cc: Compile with -O1
840 to avoid linker error for __atomic_is_lock_free.
842 2022-02-10 Thomas Rodgers <rodgert@appliantology.com>
844 * include/bits/atomic_wait.h (__waiter_base::_S_do_spin,
845 __waiter_base::_S_do_spin_v): Change memory order from relaxed
848 2022-02-10 Jonathan Wakely <jwakely@redhat.com>
850 * include/c_compatibility/stdatomic.h (atomic_fetch_xor): Add
852 (atomic_fetch_xor_explicit): Likewise.
853 * testsuite/29_atomics/headers/stdatomic.h/c_compat.cc: Check
854 arithmetic and logical operations for atomic_int.
856 2022-02-10 Jonathan Wakely <jwakely@redhat.com>
858 * src/filesystem/dir-common.h (_GLIBCXX_HAVE_DIRFD): Undefine
859 when <dirent.h> is not available.
860 (_GLIBCXX_HAVE_UNLINKAT): Likewise.
862 2022-02-09 Thomas Rodgers <rodgert@appliantology.com>
865 * include/bits/atomic_wait.h (__waiter::_M_do_wait_v): Move spin
866 loop inside do loop so that threads failing the wait, reload
869 2022-02-08 Jonathan Wakely <jwakely@redhat.com>
871 * src/c++17/fs_dir.cc (_Dir(DIR*, const path&)): Change first
872 parameter to _Dir_base&&.
873 * src/filesystem/dir-common.h (_Dir_base(DIR*)): Remove.
874 * src/filesystem/dir.cc (_Dir(DIR*, const path&)): Change first
875 parameter to _Dir_base&&.
877 2022-02-08 Jonathan Wakely <jwakely@redhat.com>
879 * acinclude.m4 (GLIBCXX_ENABLE_LOCK_POLICY): Add comment about
880 checking for CAS on correct word size.
882 2022-02-08 Jonathan Wakely <jwakely@redhat.com>
884 * testsuite/experimental/filesystem/operations/create_directories.cc:
885 Adjust expected results for Windows.
887 2022-02-08 Jonathan Wakely <jwakely@redhat.com>
890 * src/c++17/fs_dir.cc (fs::recursive_directory_iterator::__erase):
891 [i_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Refresh entry._M_type member,
892 instead of checking for errno values indicating a directory.
893 * src/c++17/fs_ops.cc (fs::remove_all(const path&)): Use similar
894 logic to non-throwing overload.
895 (fs::remove_all(const path&, error_code&)): Add comments.
896 * src/filesystem/ops-common.h: Likewise.
898 2022-02-04 Jonathan Wakely <jwakely@redhat.com>
900 * src/filesystem/dir-common.h (_Dir_base::openat): Change return
901 type to use portable posix::DIR alias.
903 2022-02-04 Jonathan Wakely <jwakely@redhat.com>
905 * include/c_compatibility/stdatomic.h [__clang__]: Use
906 #include_next <stdatomic.h>.
908 2022-02-04 Jonathan Wakely <jwakely@redhat.com>
910 * include/experimental/bits/fs_ops.h (fs::copy_file): Remove
912 (fs::create_directories): Likewise.
913 (fs::remove_all): Likewise.
914 * src/filesystem/ops.cc (fs::copy_file): Remove noexcept.
915 (fs::create_directories): Likewise.
916 (fs::remove_all): Likewise.
918 2022-02-04 Jonathan Wakely <jwakely@redhat.com>
921 * acinclude.m4 (GLIBCXX_CHECK_FILESYSTEM_DEPS): Check for dirfd
923 * config.h.in: Regenerate.
924 * configure: Regenerate.
925 * include/bits/fs_dir.h (recursive_directory_iterator): Declare
926 remove_all overloads as friends.
927 (recursive_directory_iterator::__erase): Declare new member
929 * include/bits/fs_fwd.h (remove, remove_all): Declare.
930 * src/c++17/fs_dir.cc (_Dir): Add filename_only parameter to
931 constructor. Pass file descriptor argument to base constructor.
932 (_Dir::dir_and_pathname, _Dir::open_subdir, _Dir::do_unlink)
933 (_Dir::unlink, _Dir::rmdir): Define new member functions.
934 (directory_iterator): Pass filename_only argument to _Dir
936 (recursive_directory_iterator::_Dir_stack): Adjust constructor
937 parameters to take a _Dir rvalue instead of creating one.
938 (_Dir_stack::orig): Add data member for storing original path.
939 (_Dir_stack::report_error): Define new member function.
940 (__directory_iterator_nofollow): Move here from dir-common.h and
941 fix value to be a power of two.
942 (__directory_iterator_filename_only): Define new constant.
943 (recursive_directory_iterator): Construct _Dir object and move
944 into _M_dirs stack. Pass skip_permission_denied argument to first
946 (recursive_directory_iterator::increment): Use _Dir::open_subdir.
947 (recursive_directory_iterator::__erase): Define new member
949 * src/c++17/fs_ops.cc (ErrorReporter, do_remove_all): Remove.
950 (fs::remove_all): Use new recursive_directory_iterator::__erase
952 * src/filesystem/dir-common.h (_Dir_base): Add int parameter to
953 constructor and use openat to implement nofollow semantics.
954 (_Dir_base::fdcwd, _Dir_base::set_close_on_exec, _Dir_base::openat):
955 Define new member functions.
956 (__directory_iterator_nofollow): Move to fs_dir.cc.
957 * src/filesystem/dir.cc (_Dir): Pass file descriptor argument to
959 (_Dir::dir_and_pathname, _Dir::open_subdir): Define new member
961 (recursive_directory_iterator::_Dir_stack): Adjust constructor
962 parameters to take a _Dir rvalue instead of creating one.
963 (recursive_directory_iterator): Check for new nofollow option.
964 Construct _Dir object and move into _M_dirs stack. Pass
965 skip_permission_denied argument to first advance call.
966 (recursive_directory_iterator::increment): Use _Dir::open_subdir.
967 * src/filesystem/ops.cc (fs::remove_all): Use C++17 remove_all.
969 2022-02-04 Jonathan Wakely <jwakely@redhat.com>
971 * include/bits/allocator.h: Qualify std::allocator_traits in
973 * libsupc++/exception (uncaught_exception): Add suggestion to
976 2022-02-02 Jonathan Wakely <jwakely@redhat.com>
978 * src/c++17/fs_dir.cc (fs::recursive_directory_iterator::pop):
979 Add [[maybe_unused]] attribute.
980 * src/filesystem/dir.cc (fs::recursive_directory_iterator::pop):
983 2022-02-02 Jonathan Wakely <jwakely@redhat.com>
985 * testsuite/23_containers/multiset/operators/cmp_c++20.cc: Use
986 custom comparison function for multiset.
987 * testsuite/23_containers/set/operators/cmp_c++20.cc: Use custom
988 comparison function for set.
990 2022-02-02 Jonathan Wakely <jwakely@redhat.com>
992 * include/bits/boost_concept_check.h (_OutputIteratorConcept):
993 Change member function to data member of function pointer type.
995 2022-02-02 Martin Sebor <msebor@redhat.com>
998 * include/std/array (begin): Declare const member function attribute
1000 (end, rbegin, rend, size, max_size, empty, data): Same.
1001 * testsuite/23_containers/array/capacity/empty.cc: Add test cases.
1002 * testsuite/23_containers/array/capacity/max_size.cc: Same.
1003 * testsuite/23_containers/array/capacity/size.cc: Same.
1004 * testsuite/23_containers/array/iterators/begin_end.cc: New test.
1006 2022-02-02 Jonathan Wakely <jwakely@redhat.com>
1008 * testsuite/27_io/filesystem/iterators/error_reporting.cc: Use
1009 autoconf macro to check whether d_type is present.
1010 * testsuite/experimental/filesystem/iterators/error_reporting.cc:
1013 2022-02-01 Jonathan Wakely <jwakely@redhat.com>
1015 * testsuite/27_io/filesystem/iterators/97731.cc: New test.
1016 * testsuite/27_io/filesystem/iterators/recursive_directory_iterator.cc:
1017 Check follow_directory_symlink option.
1018 * testsuite/experimental/filesystem/iterators/recursive_directory_iterator.cc:
1021 2022-02-01 Jonathan Wakely <jwakely@redhat.com>
1023 * src/c++17/fs_dir.cc (recursive_directory_iterator::increment):
1024 Reset state to past-the-end iterator on error.
1025 (fs::recursive_directory_iterator::pop(error_code&)): Likewise.
1026 (fs::recursive_directory_iterator::pop()): Check _M_dirs before
1028 * src/filesystem/dir.cc (recursive_directory_iterator): Likewise,
1029 for the TS implementation.
1030 * testsuite/27_io/filesystem/iterators/error_reporting.cc: New test.
1031 * testsuite/experimental/filesystem/iterators/error_reporting.cc: New test.
1033 2022-02-01 Jonathan Wakely <jwakely@redhat.com>
1035 * include/bits/fs_fwd.h (filesystem::perms): Fix comment.
1037 2022-02-01 Jonathan Wakely <jwakely@redhat.com>
1040 * acinclude.m4 (GLIBCXX_ENABLE_CSTDIO): Print different messages
1041 for stdio_pure and stdio_posix options.
1042 * configure: Regenerate.
1044 2022-02-01 Thomas Rodgers <rodgert@appliantology.com>
1046 * include/bits/atomic_wait.h: Change memory order from
1047 Acquire/Release with relaxed loads to SeqCst+Release for
1048 accesses to the waiter's count.
1050 2022-01-31 Martin Liska <mliska@suse.cz>
1052 * acinclude.m4: Detect *_ld_is_mold and use it.
1053 * configure: Regenerate.
1055 2022-01-30 Hans-Peter Nilsson <hp@axis.com>
1057 * testsuite/27_io/basic_istream/get/char/lwg3464.cc: Don't run on
1059 * testsuite/27_io/basic_istream/get/wchar_t/lwg3464.cc: Likewise.
1061 2022-01-27 Jonathan Wakely <jwakely@redhat.com>
1064 * include/bits/deque.tcc (_M_range_initialize<ForwardIterator>):
1065 Add __builtin_unreachable to loop.
1066 * testsuite/23_containers/deque/100516.cc: New test.
1068 2022-01-27 Jonathan Wakely <jwakely@redhat.com>
1070 * include/bits/ranges_base.h (ranges::advance): Avoid signed
1071 overflow. Do nothing if already equal to desired result.
1072 * testsuite/24_iterators/range_operations/advance_overflow.cc:
1075 2022-01-27 Martin Liska <mliska@suse.cz>
1078 * acinclude.m4: Fix typo.
1079 * configure: Regenerate.
1081 2022-01-25 Jonathan Wakely <jwakely@redhat.com>
1084 * include/bits/istream.tcc (basic_istream::sentry): Add braces
1086 * include/bits/shared_ptr_base.h (_Sp_counted_array_base::_M_init):
1087 Add pragmas to disable bogus warnings from PR 61596.
1089 2022-01-25 Jonathan Wakely <jwakely@redhat.com>
1092 * src/c++17/fs_ops.cc (_GNU_SOURCE): Define.
1093 * src/filesystem/dir.cc (_GNU_SOURCE): Define.
1094 * src/filesystem/ops.cc (_GNU_SOURCE): Define.
1096 2022-01-25 Jonathan Wakely <jwakely@redhat.com>
1099 * acinclude.m4 (GLIBCXX_CHECK_FILESYSTEM_DEPS): Check for
1101 * config.h.in: Regenerate.
1102 * configure: Regenerate.
1103 * src/c++17/fs_dir.cc (_Dir): Add nofollow flag to constructor
1104 and pass it to base class constructor.
1105 (directory_iterator): Pass nofollow flag to _Dir constructor.
1106 (fs::recursive_directory_iterator::increment): Likewise.
1107 * src/c++17/fs_ops.cc (do_remove_all): Use nofollow option for
1108 directory_iterator constructor. Move error check outside loop.
1109 * src/filesystem/dir-common.h (_Dir_base): Add nofollow flag to
1110 constructor and when it's set use ::open with O_NOFOLLOW and
1112 * src/filesystem/dir.cc (_Dir): Add nofollow flag to constructor
1113 and pass it to base class constructor.
1114 (directory_iterator): Pass nofollow flag to _Dir constructor.
1115 (fs::recursive_directory_iterator::increment): Likewise.
1116 * src/filesystem/ops.cc (remove_all): Use nofollow option for
1117 directory_iterator constructor. Move error check outside loop.
1119 2022-01-23 Jonathan Wakely <jwakely@redhat.com>
1122 * include/std/spanstream (basic_spanbuf(basic_spanbuf&&)): Use
1123 mem-initializer for _M_buf.
1124 (basic_spanbuf::Operator=(basic_spanbuf&&)): Fix ill-formed
1126 * testsuite/27_io/spanstream/2.cc: New test.
1128 2022-01-23 Jonathan Wakely <jwakely@redhat.com>
1130 * src/c++17/floating_from_chars.cc (USE_STRTOD_FOR_FROM_CHARS):
1131 Define macro for case where std::from_chars is implemented in
1132 terms of strtod, strtof or strtold.
1133 (buffer_resource, valid_fmt, find_end_of_float, pattern)
1134 (from_chars_impl, make_result, reserve_string): Do not define
1135 unless USE_STRTOD_FOR_FROM_CHARS is defined.
1136 (from_chars): Define when at least one of USE_LIB_FAST_FLOAT and
1137 USE_STRTOD_FOR_FROM_CHARS is defined, instead of
1138 _GLIBCXX_HAVE_USELOCALE. Use fast_float for long double when it
1141 2022-01-23 Jonathan Wakely <jwakely@redhat.com>
1144 * include/bits/hashtable_policy.h (_Map_base): Add partial
1145 specialization for maps with const key types.
1146 * testsuite/23_containers/unordered_map/104174.cc: New test.
1148 2022-01-23 Jonathan Wakely <jwakely@redhat.com>
1151 * include/bits/shared_ptr_base.h (_Sp_counted_base<>::_M_release):
1152 Set members to zero without type punning.
1154 2022-01-21 Jonathan Wakely <jwakely@redhat.com>
1156 * testsuite/20_util/shared_ptr/cons/array.cc: Fix comment.
1158 2022-01-21 Jonathan Wakely <jwakely@redhat.com>
1162 * include/bits/alloc_traits.h (__cpp_lib_allocator_traits_is_always_equal):
1163 Define as type long.
1164 * include/bits/allocator.h (__cpp_lib_incomplete_container_elements):
1166 * include/bits/basic_string.h (__cpp_lib_string_udls): Likewise.
1167 * include/bits/chrono.h (__cpp_lib_chrono): Likewise.
1168 (__cpp_lib_chrono_udls): Likewise.
1169 * include/bits/move.h (__cpp_lib_addressof_constexpr): Likewise.
1170 * include/bits/node_handle.h (__cpp_lib_node_extract): Likewise.
1171 * include/bits/range_access.h (__cpp_lib_nonmember_container_access):
1173 * include/bits/shared_ptr.h (__cpp_lib_enable_shared_from_this):
1175 * include/bits/stl_algo.h (__cpp_lib_clamp): Likewise.
1176 (__cpp_lib_sample): Likewise.
1177 * include/bits/stl_algobase.h (__cpp_lib_robust_nonmodifying_seq_ops):
1179 * include/bits/stl_function.h (__cpp_lib_transparent_operators):
1181 * include/bits/stl_iterator.h (__cpp_lib_make_reverse_iterator):
1183 * include/bits/stl_map.h (__cpp_lib_map_try_emplace):
1185 * include/bits/stl_tree.h (__cpp_lib_generic_associative_lookup):
1187 * include/bits/unique_ptr.h (__cpp_lib_make_unique):
1189 * include/bits/unordered_map.h (__cpp_lib_unordered_map_try_emplace):
1191 * include/c_global/cmath (__cpp_lib_hypot): Likewise.
1192 * include/c_global/cstddef (__cpp_lib_byte): Likewise.
1193 * include/std/atomic (__cpp_lib_atomic_is_always_lock_free):
1195 * include/std/complex (__cpp_lib_complex_udls): Likewise.
1196 * include/std/filesystem (__cpp_lib_filesystem): Likewise.
1197 * include/std/functional (__cpp_lib_not_fn): Likewise.
1198 (__cpp_lib_boyer_moore_searcher): Likewise.
1199 * include/std/iomanip (__cpp_lib_quoted_string_io): Likewise.
1200 * include/std/mutex (__cpp_lib_scoped_lock): Likewise.
1201 * include/std/numeric (__cpp_lib_gcd_lcm): Likewise.
1202 (__cpp_lib_gcd, __cpp_lib_lcm): Likewise.
1203 * include/std/tuple (__cpp_lib_apply): Likewise.
1204 (__cpp_lib_make_from_tuple): Likewise.
1205 * include/std/type_traits (__cpp_lib_integral_constant_callable)
1206 (__cpp_lib_bool_constant, __cpp_lib_logical_traits)
1207 (__cpp_lib_is_null_pointer, __cpp_lib_transformation_trait_aliases)
1208 (__cpp_lib_result_of_sfinae, __cpp_lib_void_t)
1209 (__cpp_lib_is_swappable, __cpp_lib_is_invocable)
1210 (__cpp_lib_has_unique_object_representations)
1211 (__cpp_lib_is_aggregate): Likewise.
1212 * include/std/version: Likewise.
1213 * libsupc++/new (__cpp_lib_launder): Likewise.
1215 2022-01-21 Jonathan Wakely <jwakely@redhat.com>
1217 * include/std/version (__cpp_lib_shared_ptr_arrays): Fix
1218 condition for C++17 definition.
1220 2022-01-21 Jonathan Wakely <jwakely@redhat.com>
1222 * include/bits/shared_ptr_atomic.h (_Sp_atomic::_Atomic_count):
1224 (_Sp_atomic::_M_ptr): Add default member-initializer.
1225 * testsuite/20_util/shared_ptr/atomic/atomic_shared_ptr.cc:
1226 Check constant initialization.
1227 * testsuite/20_util/weak_ptr/atomic_weak_ptr.cc: Likewise.
1229 2022-01-20 Jonathan Wakely <jwakely@redhat.com>
1231 * src/c++11/cxx11-ios_failure.cc (__constinit): Define as
1232 equivalent attribute for Clang.
1233 * src/c++11/future.cc (__constinit): Likewise.
1234 * src/c++11/system_error.cc (__constinit): Likewise.
1235 * src/c++17/memory_resource.cc (__constinit): Likewise.
1237 2022-01-20 Jonathan Wakely <jwakely@redhat.com>
1239 * scripts/testsuite_flags.in: Only add src/filesystem/.libs and
1240 src/libbacktrace/.libs to LDFLAGS if those directories exist.
1242 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1244 * configure.ac (GLIBCXX_ENABLE_DEBUG_FLAGS): Remove -gdwarf-4
1246 * configure: Regenerate.
1248 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1251 * testsuite/29_atomics/headers/stdatomic.h/c_compat.cc: Include
1254 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1256 * scripts/testsuite_flags.in: Add src/libbacktrace/.libs to
1257 linker search paths.
1258 * src/Makefile.am: Fix src/debug/libbacktrace build.
1259 * src/Makefile.in: Regenerate.
1260 * src/libbacktrace/Makefile.am: Use per-library CPPFLAGS
1261 variable. Use symlinks for the source files.
1262 * src/libbacktrace/Makefile.in: Regenerate.
1264 2022-01-19 Matthias Kretz <m.kretz@gsi.de>
1266 * include/experimental/bits/simd.h (__floating_point_flags): Do
1267 not rely on math_errhandling to expand to a constant expression.
1269 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1271 * doc/xml/manual/evolution.xml: Document deprecations.
1272 * doc/xml/manual/status_cxx2017.xml: Update status.
1273 * doc/html/*: Regenerate.
1275 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1277 * include/bits/stl_tempbuf.h (get_temporary_buffer): Change
1278 _GLIBCXX14_DEPRECATED to _GLIBCXX17_DEPRECATED.
1280 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1282 * include/bits/stl_pair.h (_PCC::_DeprConsPair): Remove unused
1285 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1288 * include/bits/shared_ptr_atomic.h (_Sp_atomic::_Atomic_count::lock):
1289 Only use __thread_relax if __cpp_lib_atomic_wait is defined.
1291 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1294 * include/bits/basic_string.h (basic_string(nullptr_t)): Only
1296 (operator=(nullptr_t)): Likewise.
1297 * include/bits/cow_string.h: Likewise.
1298 * include/std/string_view (basic_string_view(nullptr_t)):
1300 * testsuite/21_strings/basic_string/cons/char/nullptr.cc: Adjust
1301 expected error. Add examples that become ill-formed in C++23.
1302 * testsuite/21_strings/basic_string_view/cons/char/nonnull.cc:
1303 Adjust expected errors.
1304 * testsuite/21_strings/basic_string_view/cons/wchar_t/nonnull.cc:
1307 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1310 * include/bits/stl_iterator.h (reverse_iterator): Check
1311 __cpp_lib_concepts instead of __cplusplus.
1313 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1316 * include/bits/stl_pair.h (pair): Adjust constraints on
1317 deprecated constructors accepting literal zero as null pointer
1318 constant. Improve wording of deprecated attribute.
1319 * testsuite/20_util/pair/cons/99957.cc: Check that deprecated
1320 constructors do not cause ambiguities for copyable types.
1322 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1324 * include/bits/stl_function.h (ptr_fun): Fix suggestion for
1325 non-deprecated alternative.
1327 2022-01-18 Tom Honermann <tom@honermann.net>
1329 * acinclude.m4: Define config macros if uchar.h provides
1330 c8rtomb() and mbrtoc8().
1331 * config.h.in: Regenerate.
1332 * configure: Regenerate.
1333 * include/c_compatibility/uchar.h (c8rtomb, mbrtoc8): Define.
1334 * include/c_global/cuchar (c8rtomb, mbrtoc8): Likewise.
1335 * include/c_std/cuchar (c8rtomb, mbrtoc8): Likewise.
1336 * testsuite/21_strings/headers/cuchar/functions_std_cxx20.cc:
1338 * testsuite/21_strings/headers/cuchar/functions_std_fchar8_t.cc:
1341 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1343 * include/Makefile.am: Install new header.
1344 * include/Makefile.in: Regenerate.
1345 * include/c_compatibility/stdatomic.h: New file.
1346 * testsuite/29_atomics/headers/stdatomic.h/c_compat.cc: New test.
1348 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1351 * src/c++17/fast_float/LOCAL_PATCHES: Update.
1352 * src/c++17/fast_float/fast_float.h (FASTFLOAT_IS_BIG_ENDIAN):
1353 Define in terms of __BYTE_ORDER__.
1355 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1358 * src/c++17/fast_float/LOCAL_PATCHES: UPDATE.
1359 * src/c++17/fast_float/fast_float.h (round): Use explicit
1360 template argument list for std::min.
1362 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1364 * doc/xml/manual/status_cxx2017.xml: Update C++17 status.
1365 * doc/xml/manual/status_cxx2020.xml: Use 12.1 instead of 12 for
1367 * doc/html/manual/status.html: Regenerate.
1369 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1371 * acinclude.m4 (GLIBCXX_ENABLE_FULLY_DYNAMIC_STRING): Improve
1373 * configure: Regenerate.
1375 2022-01-17 Patrick Palka <ppalka@redhat.com>
1377 * src/c++17/floating_from_chars.cc: (USE_LIB_FAST_FLOAT):
1378 Conditionally define, and use it to conditionally include
1380 (from_chars): Use fast_float for float and double when
1383 2022-01-17 Patrick Palka <ppalka@redhat.com>
1385 * src/c++17/fast_float/LOCAL_PATCHES: Update.
1386 * src/c++17/fast_float/fast_float.h (from_chars_advanced): In
1387 case of over/underflow, return errc::result_out_of_range and don't
1390 2022-01-17 Patrick Palka <ppalka@redhat.com>
1392 * src/c++17/fast_float/LOCAL_PATCHES: Update.
1393 * src/c++17/fast_float/fast_float.h: Apply local modifications.
1395 2022-01-17 Patrick Palka <ppalka@redhat.com>
1397 * src/c++17/fast_float/LOCAL_PATCHES: New file.
1398 * src/c++17/fast_float/MERGE: New file.
1399 * src/c++17/fast_float/README.md: New file, copied from the
1400 fast_float repository.
1401 * src/c++17/fast_float/fast_float.h: New file, an amalgamation
1402 of the fast_float library.
1404 2022-01-17 Patrick Palka <ppalka@redhat.com>
1406 * src/c++17/floating_from_chars.cc: Include <bit>.
1407 (ascii_to_hexit, starts_with_ci): Conditionally define.
1408 (__floating_from_chars_hex): Conditionally define.
1409 (from_chars): Use __floating_from_chars_hex for
1410 chars_format::hex parsing of binary32/64 float/double.
1411 (testsuite/20_util/from_chars/7.cc): New test.
1412 * testsuite/20_util/from_chars/7.cc: New file.
1414 2022-01-17 Jonathan Wakely <jwakely@redhat.com>
1416 * acinclude.m4 (GLIBCXX_ENABLE_BACKTRACE): New macro.
1417 * configure.ac: Use GLIBCXX_ENABLE_BACKTRACE.
1418 * include/Makefile.am: Add new header.
1419 * include/Makefile.in: Regenerate.
1420 * include/std/stacktrace: New header.
1421 * include/std/version (__cpp_lib_stacktrace): Define.
1422 * Makefile.in: Regenerate.
1423 * config.h.in: Regenerate.
1424 * configure: Regenerate.
1425 * doc/Makefile.in: Regenerate.
1426 * libsupc++/Makefile.in: Regenerate.
1427 * po/Makefile.in: Regenerate.
1428 * python/Makefile.in: Regenerate.
1429 * src/Makefile.am: Regenerate.
1430 * src/Makefile.in: Regenerate.
1431 * src/c++11/Makefile.in: Regenerate.
1432 * src/c++17/Makefile.in: Regenerate.
1433 * src/c++20/Makefile.in: Regenerate.
1434 * src/c++98/Makefile.in: Regenerate.
1435 * src/filesystem/Makefile.in: Regenerate.
1436 * testsuite/Makefile.in: Regenerate.
1437 * src/libbacktrace/Makefile.am: New file.
1438 * src/libbacktrace/Makefile.in: New file.
1439 * src/libbacktrace/backtrace-rename.h: New file.
1440 * src/libbacktrace/backtrace-supported.h.in: New file.
1441 * src/libbacktrace/config.h.in: New file.
1442 * testsuite/lib/libstdc++.exp (check_effective_target_stacktrace):
1444 * testsuite/20_util/stacktrace/entry.cc: New test.
1445 * testsuite/20_util/stacktrace/synopsis.cc: New test.
1446 * testsuite/20_util/stacktrace/version.cc: New test.
1448 2022-01-17 Jonathan Wakely <jwakely@redhat.com>
1450 * doc/xml/manual/status_cxx2020.xml: Use final C++20 option
1452 * doc/html/manual/status.html: Regenerate.
1454 2022-01-17 Jonathan Wakely <jwakely@redhat.com>
1457 * include/Makefile.am: Rename LT_OBJDIR and STDC_HEADERS.
1458 * include/Makefile.in: Regenerate.
1459 * testsuite/17_intro/headers/c++1998/103650.cc: New test.
1461 2022-01-17 Matthias Kretz <m.kretz@gsi.de>
1463 * include/experimental/bits/simd.h (__floating_point_flags): Do
1464 not rely on the presence of the math_errhandling macro.
1466 2022-01-17 Jonathan Wakely <jwakely@redhat.com>
1468 * include/bits/shared_ptr_atomic.h (_Sp_atomic): Add typename
1469 to qualified-id for dependent type.
1471 2022-01-17 Jonathan Wakely <jwakely@redhat.com>
1473 * doc/xml/manual/status_cxx2020.xml: Update.
1474 * doc/html/manual/status.html: Regenerate.
1476 2022-01-17 Jonathan Wakely <jwakely@redhat.com>
1477 Thomas Rodgers <trodgers@redhat.com>
1479 * include/bits/shared_ptr_atomic.h (__cpp_lib_atomic_shared_ptr):
1481 (_Sp_atomic): New class template.
1482 (atomic<shared_ptr<T>>, atomic<weak_ptr<T>>): New partial
1484 * include/bits/shared_ptr_base.h (__shared_count, __weak_count)
1485 (__shared_ptr, __weak_ptr): Declare _Sp_atomic as a friend.
1486 * include/std/version (__cpp_lib_atomic_shared_ptr): New macro.
1487 * testsuite/20_util/shared_ptr/atomic/atomic_shared_ptr.cc: New
1489 * testsuite/20_util/weak_ptr/atomic_weak_ptr.cc: New test.
1491 2022-01-15 Matthias Kretz <m.kretz@gsi.de>
1493 * include/experimental/bits/simd.h: Move feature detection bools
1494 and add __have_avx512bitalg, __have_avx512vbmi2,
1495 __have_avx512vbmi, __have_avx512ifma, __have_avx512cd,
1496 __have_avx512vnni, __have_avx512vpopcntdq.
1497 (__detail::__machine_flags): New function which returns a unique
1498 uint64 depending on relevant -m and -f flags.
1499 (__detail::__odr_helper): New type alias for either an anonymous
1500 type or a type specialized with the __machine_flags number.
1501 (_SimdIntOperators): Change template parameters from _Impl to
1502 _Tp, _Abi because _Impl now has an __odr_helper parameter which
1503 may be _OdrEnforcer from the anonymous namespace, which makes
1504 for a bad base class.
1505 (many): Either add __odr_helper template parameter or mark as
1507 * include/experimental/bits/simd_detail.h: Add defines for
1508 AVX512BITALG, AVX512VBMI2, AVX512VBMI, AVX512IFMA, AVX512CD,
1509 AVX512VNNI, AVX512VPOPCNTDQ, and AVX512VP2INTERSECT.
1510 * include/experimental/bits/simd_builtin.h: Add __odr_helper
1511 template parameter or mark as always_inline.
1512 * include/experimental/bits/simd_fixed_size.h: Ditto.
1513 * include/experimental/bits/simd_math.h: Ditto.
1514 * include/experimental/bits/simd_scalar.h: Ditto.
1515 * include/experimental/bits/simd_neon.h: Add __odr_helper
1517 * include/experimental/bits/simd_ppc.h: Ditto.
1518 * include/experimental/bits/simd_x86.h: Ditto.
1520 2022-01-14 Uroš Bizjak <ubizjak@gmail.com>
1522 * testsuite/22_locale/numpunct/members/char/3.cc:
1523 Require pt_PT locale instead of nl_NL.
1524 (test02): Use pt_PT locale instead of nl_NL.
1526 2022-01-14 Jonathan Wakely <jwakely@redhat.com>
1531 * include/backward/binders.h (bind1st, bind2nd): Add deprecated
1533 * include/bits/refwrap.h (_Maybe_unary_or_binary_function):
1534 Disable deprecated warnings for base classes.
1535 (_Reference_wrapper_base): Likewise.
1536 * include/bits/shared_ptr_base.h (_Sp_owner_less): Likewise.
1537 * include/bits/stl_bvector.h (_Bit_iterator_base): Likewise.
1538 * include/bits/stl_function.h (unary_function, binary_function):
1539 Add deprecated attribute.
1540 (unary_negate, not1, binary_negate, not2, ptr_fun)
1541 (pointer_to_unary_function, pointer_to_binary_function)
1542 (mem_fun_t, const_mem_fun_t, mem_fun_ref_t, const_mem_fun_ref_t)
1543 (mem_fun1_t, const_mem_fun1_t, mem_fun_ref1_t)
1544 (const_mem_fun1_ref_t, mem_fun, mem_fun_ref): Add deprecated
1546 * include/bits/stl_iterator.h: Disable deprecated warnings for
1547 std::iterator base classes.
1548 * include/bits/stl_iterator_base_types.h (iterator): Add
1549 deprecated attribute.
1550 * include/bits/stl_map.h (map::value_compare): Disable
1551 deprecated warnings for base class.
1552 * include/bits/stl_multimap.h (multimap::value_compare):
1554 * include/bits/stl_raw_storage_iter.h (raw_storage_iterator):
1555 Add deprecated attribute.
1556 * include/bits/stl_tempbuf.h (get_temporary_buffer): Likewise.
1557 * include/bits/stream_iterator.h: Disable deprecated warnings.
1558 * include/bits/streambuf_iterator.h: Likewise.
1559 * include/ext/bitmap_allocator.h: Remove unary_function base
1561 * include/ext/functional: Disable deprecated warnings.
1562 * include/ext/rope: Likewise.
1563 * include/ext/throw_allocator.h: Likewise.
1564 * include/std/type_traits (result_of): Add deprecated attribute.
1565 * include/tr1/functional: Disable deprecated warnings.
1566 * include/tr1/functional_hash.h: Likewise.
1567 * testsuite/20_util/function_objects/binders/1.cc: Add
1568 -Wno-disable-deprecations.
1569 * testsuite/20_util/function_objects/binders/3113.cc: Likewise.
1570 * testsuite/20_util/function_objects/constexpr.cc: Add
1572 * testsuite/20_util/raw_storage_iterator/base.cc: Likewise.
1573 * testsuite/20_util/raw_storage_iterator/dr2127.cc: Likewise.
1574 * testsuite/20_util/raw_storage_iterator/requirements/base_classes.cc:
1576 * testsuite/20_util/raw_storage_iterator/requirements/explicit_instantiation/1.cc:
1578 * testsuite/20_util/raw_storage_iterator/requirements/typedefs.cc:
1580 * testsuite/20_util/reference_wrapper/24803.cc:
1582 * testsuite/20_util/reference_wrapper/typedefs.cc: Enable for
1583 C++20 and check for absence of nested types.
1584 * testsuite/20_util/shared_ptr/comparison/less.cc: Remove
1585 std::binary_function base class.
1586 * testsuite/20_util/temporary_buffer.cc: Add dg-warning.
1587 * testsuite/21_strings/basic_string/cons/char/69092.cc: Remove
1588 std::iterator base class.
1589 * testsuite/24_iterators/back_insert_iterator/requirements/base_classes.cc:
1591 * testsuite/24_iterators/front_insert_iterator/requirements/base_classes.cc:
1593 * testsuite/24_iterators/insert_iterator/requirements/base_classes.cc:
1595 * testsuite/24_iterators/istream_iterator/requirements/base_classes.cc:
1597 * testsuite/24_iterators/istreambuf_iterator/92285.cc:
1599 * testsuite/24_iterators/istreambuf_iterator/requirements/base_classes.cc:
1601 * testsuite/24_iterators/ostream_iterator/requirements/base_classes.cc:
1603 * testsuite/24_iterators/ostreambuf_iterator/requirements/base_classes.cc:
1605 * testsuite/24_iterators/reverse_iterator/requirements/base_classes.cc:
1607 * testsuite/25_algorithms/copy/34595.cc:
1609 * testsuite/25_algorithms/minmax/3.cc: Remove std::binary_function
1611 * testsuite/25_algorithms/all_of/requirements/explicit_instantiation/2.cc:
1612 Disable deprecated warnings.
1613 * testsuite/25_algorithms/all_of/requirements/explicit_instantiation/pod.cc:
1615 * testsuite/25_algorithms/any_of/requirements/explicit_instantiation/2.cc:
1617 * testsuite/25_algorithms/any_of/requirements/explicit_instantiation/pod.cc:
1619 * testsuite/25_algorithms/copy_if/requirements/explicit_instantiation/2.cc:
1621 * testsuite/25_algorithms/copy_if/requirements/explicit_instantiation/pod.cc:
1623 * testsuite/25_algorithms/count_if/requirements/explicit_instantiation/2.cc:
1625 * testsuite/25_algorithms/count_if/requirements/explicit_instantiation/pod.cc:
1627 * testsuite/25_algorithms/find_end/requirements/explicit_instantiation/2.cc:
1629 * testsuite/25_algorithms/find_end/requirements/explicit_instantiation/pod.cc:
1631 * testsuite/25_algorithms/find_first_of/requirements/explicit_instantiation/2.cc:
1633 * testsuite/25_algorithms/find_first_of/requirements/explicit_instantiation/pod.cc:
1635 * testsuite/25_algorithms/find_if/requirements/explicit_instantiation/2.cc:
1637 * testsuite/25_algorithms/find_if/requirements/explicit_instantiation/pod.cc:
1639 * testsuite/25_algorithms/find_if_not/requirements/explicit_instantiation/2.cc:
1641 * testsuite/25_algorithms/find_if_not/requirements/explicit_instantiation/pod.cc:
1643 * testsuite/25_algorithms/for_each/requirements/explicit_instantiation/2.cc:
1645 * testsuite/25_algorithms/for_each/requirements/explicit_instantiation/pod.cc:
1647 * testsuite/25_algorithms/is_partitioned/requirements/explicit_instantiation/2.cc:
1649 * testsuite/25_algorithms/is_partitioned/requirements/explicit_instantiation/pod.cc:
1651 * testsuite/25_algorithms/is_permutation/requirements/explicit_instantiation/2.cc:
1653 * testsuite/25_algorithms/is_permutation/requirements/explicit_instantiation/pod.cc:
1655 * testsuite/25_algorithms/none_of/requirements/explicit_instantiation/2.cc:
1657 * testsuite/25_algorithms/none_of/requirements/explicit_instantiation/pod.cc:
1659 * testsuite/25_algorithms/partition/requirements/explicit_instantiation/2.cc:
1661 * testsuite/25_algorithms/partition/requirements/explicit_instantiation/pod.cc:
1663 * testsuite/25_algorithms/partition_copy/requirements/explicit_instantiation/2.cc:
1665 * testsuite/25_algorithms/partition_copy/requirements/explicit_instantiation/pod.cc:
1667 * testsuite/25_algorithms/partition_point/requirements/explicit_instantiation/2.cc:
1669 * testsuite/25_algorithms/partition_point/requirements/explicit_instantiation/pod.cc:
1671 * testsuite/25_algorithms/random_shuffle/requirements/explicit_instantiation/2.cc:
1673 * testsuite/25_algorithms/random_shuffle/requirements/explicit_instantiation/pod.cc:
1675 * testsuite/25_algorithms/remove_copy_if/requirements/explicit_instantiation/2.cc:
1677 * testsuite/25_algorithms/remove_copy_if/requirements/explicit_instantiation/pod.cc:
1679 * testsuite/25_algorithms/remove_if/requirements/explicit_instantiation/2.cc:
1681 * testsuite/25_algorithms/remove_if/requirements/explicit_instantiation/pod.cc:
1683 * testsuite/25_algorithms/replace_copy_if/requirements/explicit_instantiation/2.cc:
1685 * testsuite/25_algorithms/replace_copy_if/requirements/explicit_instantiation/pod.cc:
1687 * testsuite/25_algorithms/replace_if/requirements/explicit_instantiation/2.cc:
1689 * testsuite/25_algorithms/replace_if/requirements/explicit_instantiation/pod.cc:
1691 * testsuite/25_algorithms/search/requirements/explicit_instantiation/2.cc:
1693 * testsuite/25_algorithms/search/requirements/explicit_instantiation/pod.cc:
1695 * testsuite/25_algorithms/search_n/requirements/explicit_instantiation/2.cc:
1697 * testsuite/25_algorithms/search_n/requirements/explicit_instantiation/pod.cc:
1699 * testsuite/25_algorithms/stable_partition/requirements/explicit_instantiation/2.cc:
1701 * testsuite/25_algorithms/stable_partition/requirements/explicit_instantiation/pod.cc:
1703 * testsuite/25_algorithms/transform/requirements/explicit_instantiation/2.cc:
1705 * testsuite/25_algorithms/transform/requirements/explicit_instantiation/pod.cc:
1707 * testsuite/27_io/basic_filebuf/underflow/wchar_t/9178.cc: Add
1709 * testsuite/ext/pb_ds/example/priority_queue_erase_if.cc:
1711 * testsuite/ext/pb_ds/example/priority_queue_split_join.cc:
1713 * testsuite/tr1/3_function_objects/reference_wrapper/typedefs.cc:
1714 Disable deprecated warnings.
1715 * testsuite/tr1/6_containers/hash/requirements/base_classes.cc:
1717 * testsuite/util/regression/trait/erase_if_fn.hpp: Remove
1718 std::unary_function base classes.
1719 * testsuite/util/testsuite_iterators.h (output_iterator_wrapper):
1720 Remove std::iterator base classes.
1722 2022-01-14 Jonathan Wakely <jwakely@redhat.com>
1724 * include/bits/shared_ptr.h (__cpp_lib_shared_ptr_weak_type):
1725 Correct type of macro value.
1726 (shared_ptr): Add additional friend declarations.
1727 (make_shared, allocate_shared): Constrain existing overloads and
1728 remove static_assert.
1729 * include/bits/shared_ptr_base.h (__cpp_lib_smart_ptr_for_overwrite):
1731 (_Sp_counted_ptr_inplace<T, Alloc, Lp>): New partial
1732 specialization for use with make_shared_for_overwrite.
1733 (__cpp_lib_shared_ptr_arrays): Update value for C++20.
1734 (_Sp_counted_array_base): New class template.
1735 (_Sp_counted_array): New class template.
1736 (__shared_count(_Tp*&, const _Sp_counted_array_base&, _Init)):
1737 New constructor for allocating shared arrays.
1738 (__shared_ptr(const _Sp_counted_array_base&, _Init)): Likewise.
1739 * include/std/version (__cpp_lib_shared_ptr_weak_type): Correct
1741 (__cpp_lib_shared_ptr_arrays): Update value for C++20.
1742 (__cpp_lib_smart_ptr_for_overwrite): New macro.
1743 * testsuite/20_util/shared_ptr/creation/99006.cc: Adjust
1745 * testsuite/20_util/shared_ptr/creation/array.cc: New test.
1746 * testsuite/20_util/shared_ptr/creation/overwrite.cc: New test.
1747 * testsuite/20_util/shared_ptr/creation/version.cc: New test.
1748 * testsuite/20_util/unique_ptr/creation/for_overwrite.cc: Check
1749 feature test macro. Test non-trivial default-initialization.
1751 2022-01-14 Jonathan Wakely <jwakely@redhat.com>
1753 * include/bits/stl_construct.h (_Construct, _Construct_novalue):
1754 Also cast away cv-qualifiers when converting pointer to void.
1755 * testsuite/20_util/allocator/void.cc: Test construct function
1756 with cv-qualified types.
1758 2022-01-14 Jonathan Wakely <jwakely@redhat.com>
1761 * include/bits/stl_iterator.h (common_iterator): Use
1762 std::construct_at instead of placement new.
1763 * testsuite/24_iterators/common_iterator/1.cc: Check copy
1764 construction is usable in constant expressions.
1766 2022-01-14 Jonathan Wakely <jwakely@redhat.com>
1768 * doc/xml/manual/status_cxx2011.xml: Document new tokens
1769 accepted by std::random_device constructor.
1770 * doc/html/manual/status.html: Regenerate.
1772 2022-01-12 Patrick Palka <ppalka@redhat.com>
1774 * testsuite/20_util/to_chars/103955.cc: Add explicit dg-do
1777 2022-01-12 Patrick Palka <ppalka@redhat.com>
1780 * src/c++17/floating_to_chars.cc (__floating_to_chars_hex):
1781 Track the excess precision separately from the effective
1782 precision. Avoid overflow in bounds check by splitting it into
1784 (__floating_to_chars_precision): Avoid overflow in bounds checks
1786 * testsuite/20_util/to_chars/103955.cc: New test.
1788 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
1791 * include/Makefile.am: Install <source_location> for
1793 * include/Makefile.in: Regenerate.
1794 * include/std/version (__cpp_lib_source_location): Define for
1797 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
1799 * include/std/ranges (ranges::lazy_split_view::_InnerIter::end()):
1800 Add neoxcept (LWG 3593).
1802 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
1804 * include/std/ranges (ranges::__detail::__box): Add constexpr to
1805 assignment operators (LWG 3572).
1806 * testsuite/std/ranges/adaptors/filter.cc: Check assignment of a
1807 view that uses copyable-box.
1809 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
1812 * include/Makefile.am: Install <coroutine> for freestanding.
1813 * include/Makefile.in: Regenerate.
1814 * include/std/coroutine: Adjust headers and preprocessor
1816 (__coroutine_traits_impl): Use concepts when available.
1817 [_GLIBCXX_HOSTED] (hash<coroutine_handle>): Define.
1819 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
1821 * include/std/ostream (operator<<(basic_ostream&, charT)):
1822 Use unformatted input if no padding is needed.
1823 (operator<<(basic_ostream<char>&, char)): Likewise.
1825 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
1828 * include/bits/c++config (_GLIBCXX_HAVE_COND_TRIVIAL_SPECIAL_MEMBERS):
1830 * include/std/variant (__cpp_lib_variant): Only define C++20
1831 value when the compiler is known to support conditionally
1832 trivial destructors.
1833 * include/std/version (__cpp_lib_variant): Likewise.
1835 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
1837 * include/bits/stl_iterator.h (common_iterator): Add constexpr
1838 to all member functions (LWG 3574).
1839 * testsuite/24_iterators/common_iterator/1.cc: Evaluate some
1840 tests as constant expressions.
1841 * testsuite/24_iterators/common_iterator/2.cc: Likewise.
1843 2022-01-10 Jakub Jelinek <jakub@redhat.com>
1846 * include/bits/locale_facets_nonio.h (__time_get_state): New struct.
1847 (time_get::_M_extract_via_format): Declare new method with
1848 __time_get_state& as an extra argument.
1849 * include/bits/locale_facets_nonio.tcc (_M_extract_via_format): Add
1850 __state argument, set various fields in it while parsing. Handle %j,
1851 %U, %w and %W, fix up handling of %y, %Y and %C, don't adjust tm_hour
1852 for %p immediately. Add a wrapper around the method without the
1853 __state argument for backwards compatibility.
1854 (_M_extract_num): Remove all __len == 4 special cases.
1855 (time_get::do_get_time, time_get::do_get_date, time_get::do_get): Zero
1856 initialize __state, pass it to _M_extract_via_format and finalize it
1858 (do_get_year): For 1-2 digit parsed years, map 0-68 to 2000-2068,
1859 69-99 to 1969-1999. For 3-4 digit parsed years use that as year.
1860 (get): If do_get isn't overloaded from the locale_facets_nonio.tcc
1861 version, don't call do_get but call _M_extract_via_format instead to
1863 * config/abi/pre/gnu.ver (GLIBCXX_3.4.30): Export _M_extract_via_format
1864 with extra __time_get_state and __time_get_state::_M_finalize_state.
1865 * src/c++98/locale_facets.cc (is_leap, day_of_the_week,
1866 day_of_the_year): New functions in anon namespace.
1867 (mon_yday): New var in anon namespace.
1868 (__time_get_state::_M_finalize_state): Define.
1869 * testsuite/22_locale/time_get/get/char/4.cc: New test.
1870 * testsuite/22_locale/time_get/get/wchar_t/4.cc: New test.
1871 * testsuite/22_locale/time_get/get_year/char/1.cc (test01): Parse 197
1872 as year 197AD instead of error.
1873 * testsuite/22_locale/time_get/get_year/char/5.cc (test01): Parse 1 as
1874 year 2001 instead of error.
1875 * testsuite/22_locale/time_get/get_year/char/6.cc: New test.
1876 * testsuite/22_locale/time_get/get_year/wchar_t/1.cc (test01): Parse
1877 197 as year 197AD instead of error.
1878 * testsuite/22_locale/time_get/get_year/wchar_t/5.cc (test01): Parse
1879 1 as year 2001 instead of error.
1880 * testsuite/22_locale/time_get/get_year/wchar_t/6.cc: New test.
1882 2022-01-10 Jonathan Wakely <jwakely@redhat.com>
1885 * acinclude.m4 (GLIBCXX_COMPUTE_STDIO_INTEGER_CONSTANTS): Do
1886 nothing for freestanding builds.
1887 (GLIBCXX_ENABLE_HOSTED): Define FREESTANDING_FLAGS.
1888 * configure.ac: Do not use AC_LIBTOOL_DLOPEN when configured
1889 with --without-headers. Do not use GCC_HEADER_STDINT for
1890 freestanding builds.
1891 * libsupc++/Makefile.am (HOSTED_CXXFLAGS): Use -ffreestanding
1892 for freestanding builds.
1893 * configure: Regenerate.
1894 * Makefile.in: Regenerate.
1895 * doc/Makefile.in: Regenerate.
1896 * include/Makefile.in: Regenerate.
1897 * libsupc++/Makefile.in: Regenerate.
1898 * po/Makefile.in: Regenerate.
1899 * python/Makefile.in: Regenerate.
1900 * src/Makefile.in: Regenerate.
1901 * src/c++11/Makefile.in: Regenerate.
1902 * src/c++17/Makefile.in: Regenerate.
1903 * src/c++20/Makefile.in: Regenerate.
1904 * src/c++98/Makefile.in: Regenerate.
1905 * src/filesystem/Makefile.in: Regenerate.
1906 * testsuite/Makefile.in: Regenerate.
1908 2022-01-10 Jonathan Wakely <jwakely@redhat.com>
1910 * testsuite/28_regex/algorithms/regex_replace/char/103664.cc:
1911 Add dg-timeout-factor directive.
1912 * testsuite/28_regex/basic_regex/84110.cc: Likewise.
1913 * testsuite/28_regex/basic_regex/ctors/char/other.cc: Likewise.
1914 * testsuite/28_regex/match_results/102667.cc: Likewise.
1916 2022-01-10 Jonathan Wakely <jwakely@redhat.com>
1918 * doc/xml/manual/using.xml: Update documentation around default
1920 * doc/html/*: Regenerate.
1922 2022-01-10 Jonathan Wakely <jwakely@redhat.com>
1925 * src/c++17/Makefile.am (AM_CXXFLAGS): Add -nostdinc++.
1926 * src/c++17/Makefile.in: Regenerate.
1928 2022-01-09 Sandra Loosemore <sandra@codesourcery.com>
1930 * testsuite/18_support/type_info/constexpr.cc: Add explicit
1931 -fdelete-null-pointer-checks option.
1933 2022-01-06 Pavel I. Kryukov <pavel.kryukov@phystech.edu>
1934 Jonathan Wakely <jwakely@redhat.com>
1937 * include/bits/forward_list.tcc (forward_list::merge): Check for
1939 * testsuite/23_containers/forward_list/operations/merge.cc: New test.
1941 2022-01-06 Jonathan Wakely <jwakely@redhat.com>
1943 * include/bits/regex.h (basic_regex, match_results): Qualify
1944 name in friend declaration, to work around Clang bug.
1946 2022-01-06 Jonathan Wakely <jwakely@redhat.com>
1948 * testsuite/ext/rope/pthread7-rope.cc: Add dg-timeout-factor.
1950 2022-01-06 Jonathan Wakely <jwakely@redhat.com>
1953 * include/std/charconv (__from_chars_alpha_to_num): Return
1954 char instead of unsigned char. Change invalid return value to
1955 127 instead of using numeric trait.
1956 (__from_chars_alnum): Fix comment. Do not use std::isdigit.
1957 Change type of variable to char.
1959 2022-01-05 François Dumont <fdumont@gcc.gnu.org>
1962 * include/bits/hashtable_policy.h
1963 (_Hashtable_hash_traits<_Hash>): New.
1964 (_Hash_code_base<>::_M_hash_code(const _Hash_node_value<>&)): New.
1965 (_Hashtable_base<>::_M_key_equals): New.
1966 (_Hashtable_base<>::_M_equals): Use latter.
1967 (_Hashtable_base<>::_M_key_equals_tr): New.
1968 (_Hashtable_base<>::_M_equals_tr): Use latter.
1969 * include/bits/hashtable.h
1970 (_Hashtable<>::__small_size_threshold()): New, use _Hashtable_hash_traits.
1971 (_Hashtable<>::find): Loop through elements to look for key if size is lower
1972 than __small_size_threshold().
1973 (_Hashtable<>::_M_emplace(true_type, _Args&&...)): Likewise.
1974 (_Hashtable<>::_M_insert_unique(_Kt&&, _Args&&, const _NodeGenerator&)): Likewise.
1975 (_Hashtable<>::_M_compute_hash_code(const_iterator, const key_type&)): New.
1976 (_Hashtable<>::_M_emplace(const_iterator, false_type, _Args&&...)): Use latter.
1977 (_Hashtable<>::_M_find_before_node(const key_type&)): New.
1978 (_Hashtable<>::_M_erase(true_type, const key_type&)): Use latter.
1979 (_Hashtable<>::_M_erase(false_type, const key_type&)): Likewise.
1980 * src/c++11/hashtable_c++0x.cc: Include <bits/functional_hash.h>.
1981 * testsuite/util/testsuite_performance.h
1982 (report_performance): Use 9 width to display memory.
1983 * testsuite/performance/23_containers/insert_erase/unordered_small_size.cc:
1984 New performance test case.
1986 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
1989 * include/bits/basic_string.h (basic_string(const T&, size_t, size_t)):
1990 Relax constraints on string_view parameter.
1991 * include/bits/cow_string.h (basic_string(const T&, size_t, size_t)):
1993 * testsuite/21_strings/basic_string/cons/char/103919.cc: New test.
1995 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
1997 * config/abi/pre/gnu.ver (GLIBCXX_3.4.30): Export new symbol for
1999 * include/bits/c++config (_GLIBCXX23_CONSTEXPR): Define.
2000 * include/std/version (__cpp_lib_constexpr_typeinfo): Define.
2001 * libsupc++/tinfo.cc: Add #error to ensure non-inline definition
2003 (type_info::__equal): Define alias symbol.
2004 * libsupc++/typeinfo (type_info::before): Combine different
2005 implementations into one.
2006 (type_info::operator==): Likewise. Use address equality for
2007 constant evaluation. Call __equal for targets that require the
2008 definition to be non-inline.
2009 * testsuite/18_support/type_info/constexpr.cc: New test.
2011 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2013 * src/c++11/cxx11-ios_failure.cc (io_error_category): Define
2014 class and virtual functions as 'final'.
2015 (io_category_instance): Use constinit union to make the object
2017 * src/c++11/future.cc (future_error_category): Define class and
2018 virtual functions as 'final'.
2019 (future_category_instance): Use constinit union.
2021 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2023 * python/libstdcxx/v6/printers.py (StdErrorCodePrinter): Strip
2024 versioned namespace from the type name that is printed.
2026 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2028 * python/libstdcxx/v6/printers.py (StdRegexStatePrinter): New
2029 printer for std::regex NFA states.
2031 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2033 * testsuite/23_containers/forward_list/operations/1.cc: Fill in
2034 placeholders in comments.
2035 * testsuite/23_containers/forward_list/operations/2.cc:
2037 * testsuite/23_containers/forward_list/operations/3.cc:
2039 * testsuite/23_containers/forward_list/operations/4.cc:
2041 * testsuite/23_containers/forward_list/operations/5.cc:
2043 * testsuite/23_containers/forward_list/operations/6.cc:
2045 * testsuite/23_containers/forward_list/operations/7.cc:
2048 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2051 * include/bits/stl_deque.h (operator-): Do not use 0 as null
2054 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2056 * include/bits/alloc_traits.h (allocator_traits<allocator<void>>):
2057 Use std::_Construct for construct.
2059 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2062 * doc/xml/faq.xml: Add '-x c++' to preprocessor command.
2063 * doc/html/faq.html: Regenerate.
2065 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2067 * include/bits/regex.h (__regex_algo_impl): Change __policy and
2068 __match_mode template parameters to be function parameters.
2069 (regex_match, regex_search): Pass policy and match mode as
2071 * include/bits/regex.tcc (__regex_algo_impl): Change template
2072 parameters to function parameters.
2073 * include/bits/regex_compiler.h (_RegexTranslatorBase): Use
2074 'if constexpr' for conditions using template parameters.
2075 (_RegexTranslator): Likewise.
2076 * include/bits/regex_executor.tcc (_Executor::_M_handle_accept):
2078 * testsuite/util/testsuite_regex.h (regex_match_debug)
2079 (regex_search_debug): Move template arguments to function
2082 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2084 * testsuite/util/testsuite_regex.h (regex_match_debug): Compare
2085 results even if the match failed.
2087 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2089 * include/bits/regex_compiler.tcc: Adjust all calls to
2090 __throw_regex_error.
2091 * include/bits/regex_error.h (__throw_regex_error): Add noreturn
2093 * include/bits/regex_scanner.tcc: Likewise.
2094 * src/c++11/regex.cc (desc): New helper function.
2095 (regex_error::regex_error(error_type)): Use desc to get a string
2096 corresponding to the error code.
2099 Copyright (C) 2022 Free Software Foundation, Inc.
2101 Copying and distribution of this file, with or without modification,
2102 are permitted in any medium without royalty provided the copyright
2103 notice and this notice are preserved.