]> gcc.gnu.org Git - gcc.git/blob - libstdc++-v3/ChangeLog
Daily bump.
[gcc.git] / libstdc++-v3 / ChangeLog
1 2022-08-23 Jonathan Wakely <jwakely@redhat.com>
2
3 Backported from master:
4 2022-08-22 Jonathan Wakely <jwakely@redhat.com>
5
6 PR libstdc++/105678
7 * doc/xml/manual/using.xml: Document -lstdc++_libbacktrace
8 requirement for using std::stacktrace. Also adjust -frtti and
9 -fexceptions to document non-default (i.e. negative) forms.
10 * doc/html/*: Regenerate.
11
12 2022-08-19 Release Manager
13
14 * GCC 12.2.0 released.
15
16 2022-08-05 Jonathan Wakely <jwakely@redhat.com>
17
18 Backported from master:
19 2022-08-04 Jonathan Wakely <jwakely@redhat.com>
20
21 * include/std/string_view (basic_string_view(Range&&)): Add
22 explicit as per P2499R0.
23 * testsuite/21_strings/basic_string_view/cons/char/range_c++20.cc:
24 Adjust implicit conversions. Check implicit conversions fail.
25 * testsuite/21_strings/basic_string_view/cons/wchar_t/range_c++20.cc:
26 Likewise.
27
28 2022-08-05 Jonathan Wakely <jwakely@redhat.com>
29
30 Backported from master:
31 2022-08-04 Jonathan Wakely <jwakely@redhat.com>
32
33 * include/std/expected (unexpected::_M_val): Rename to _M_unex.
34 (bad_expected_access::_M_val): Likewise.
35
36 2022-08-05 Jonathan Wakely <jwakely@redhat.com>
37
38 Backported from master:
39 2022-08-04 Jonathan Wakely <jwakely@redhat.com>
40
41 * include/bits/ios_base.h (__cpp_lib_ios_noreplace): Update
42 value to 202207L.
43 * include/std/version (__cpp_lib_ios_noreplace): Likewise.
44 * testsuite/27_io/basic_ofstream/open/char/noreplace.cc: Check
45 for new value.
46 * testsuite/27_io/basic_ofstream/open/wchar_t/noreplace.cc:
47 Likewise.
48
49 2022-08-03 Jonathan Wakely <jwakely@redhat.com>
50
51 Backported from master:
52 2022-06-28 Jonathan Wakely <jwakely@redhat.com>
53
54 * src/c++17/fs_dir.cc (_Dir::dir_and_pathname):: Replace with
55 current() returning _At_path.
56 (_Dir::_Dir, _Dir::open_subdir, _Dir::do_unlink): Adjust.
57 * src/filesystem/dir-common.h (_Dir_base::_At_path): New class.
58 (_Dir_base::_Dir_Base, _Dir_base::openat): Use _At_path.
59 * src/filesystem/dir.cc (_Dir::dir_and_pathname): Replace with
60 current() returning _At_path.
61 (_Dir::_Dir, _Dir::open_subdir): Adjust.
62
63 2022-08-03 Jonathan Wakely <jwakely@redhat.com>
64
65 Backported from master:
66 2022-07-29 Jonathan Wakely <jwakely@redhat.com>
67
68 PR libstdc++/104443
69 * include/bits/stl_iterator.h (common_iterator::operator->):
70 Change return type to just auto.
71
72 2022-08-03 Jonathan Wakely <jwakely@redhat.com>
73
74 Backported from master:
75 2022-07-12 Jonathan Wakely <jwakely@redhat.com>
76
77 PR libstdc++/106248
78 * include/std/istream [C++17] (operator>>(istream&, char*)):
79 Set eofbit if we stopped extracting at EOF.
80 * testsuite/27_io/basic_istream/extractors_character/char/pr106248.cc:
81 New test.
82 * testsuite/27_io/basic_istream/extractors_character/wchar_t/pr106248.cc:
83 New test.
84
85 2022-08-03 Jonathan Wakely <jwakely@redhat.com>
86
87 Backported from master:
88 2022-07-01 Jonathan Wakely <jwakely@redhat.com>
89
90 * include/bits/fs_ops.h: Add nodiscard to all pure functions.
91 * include/experimental/bits/fs_ops.h: Likewise.
92 * testsuite/27_io/filesystem/operations/all.cc: Do not discard
93 results of absolute and canonical.
94 * testsuite/27_io/filesystem/operations/absolute.cc: Cast
95 discarded result to void.
96 * testsuite/27_io/filesystem/operations/canonical.cc: Likewise.
97 * testsuite/27_io/filesystem/operations/exists.cc: Likewise.
98 * testsuite/27_io/filesystem/operations/is_empty.cc: Likewise.
99 * testsuite/27_io/filesystem/operations/read_symlink.cc:
100 Likewise.
101 * testsuite/27_io/filesystem/operations/status.cc: Likewise.
102 * testsuite/27_io/filesystem/operations/symlink_status.cc:
103 Likewise.
104 * testsuite/27_io/filesystem/operations/temp_directory_path.cc:
105 Likewise.
106 * testsuite/experimental/filesystem/operations/canonical.cc:
107 Likewise.
108 * testsuite/experimental/filesystem/operations/exists.cc:
109 Likewise.
110 * testsuite/experimental/filesystem/operations/is_empty.cc:
111 Likewise.
112 * testsuite/experimental/filesystem/operations/read_symlink.cc:
113 Likewise.
114 * testsuite/experimental/filesystem/operations/temp_directory_path.cc:
115 Likewise.
116
117 2022-08-03 Jonathan Wakely <jwakely@redhat.com>
118
119 Backported from master:
120 2022-06-16 Jonathan Wakely <jwakely@redhat.com>
121
122 PR libstdc++/105995
123 * include/bits/basic_string.h (_M_use_local_data): Initialize
124 the entire SSO buffer.
125 * testsuite/21_strings/basic_string/cons/char/105995.cc: New test.
126
127 2022-08-03 Jonathan Wakely <jwakely@redhat.com>
128
129 Backported from master:
130 2022-06-14 Jonathan Wakely <jwakely@redhat.com>
131
132 * include/bits/new_allocator.h: Fix indentation.
133 * include/ext/malloc_allocator.h: Likewise.
134
135 2022-08-03 Jonathan Wakely <jwakely@redhat.com>
136
137 Backported from master:
138 2022-06-14 Jonathan Wakely <jwakely@redhat.com>
139
140 PR libstdc++/105957
141 * include/bits/allocator.h (allocator::allocate): Check for
142 overflow in constexpr allocation.
143 * testsuite/20_util/allocator/105975.cc: New test.
144
145 2022-08-03 Jonathan Wakely <jwakely@redhat.com>
146
147 Backported from master:
148 2022-06-10 Jonathan Wakely <jwakely@redhat.com>
149
150 PR libstdc++/105844
151 * include/experimental/numeric (experimental::gcd): Simplify
152 assertions. Use __abs_r instead of __absu.
153 (experimental::lcm): Likewise. Remove use of __detail::__lcm so
154 overflow can be detected.
155 * include/std/numeric (__detail::__absu): Rename to __abs_r and
156 change to allow signed result type, so overflow can be detected.
157 (__detail::__lcm): Remove.
158 (gcd): Simplify assertions. Use __abs_r instead of __absu.
159 (lcm): Likewise. Remove use of __detail::__lcm so overflow can
160 be detected.
161 * testsuite/26_numerics/gcd/gcd_neg.cc: Adjust dg-error lines.
162 * testsuite/26_numerics/lcm/lcm_neg.cc: Likewise.
163 * testsuite/26_numerics/gcd/105844.cc: New test.
164 * testsuite/26_numerics/lcm/105844.cc: New test.
165
166 2022-07-26 Thomas Rodgers <trodgers@redhat.com>
167
168 Backported from master:
169 2022-07-26 Thomas Rodgers <trodgers@redhat.com>
170
171 * include/bits/atomic_wait.h (__atomic_spin): Merge spin loops.
172
173 2022-07-22 Jonathan Wakely <jwakely@redhat.com>
174
175 Backported from master:
176 2022-06-28 Jonathan Wakely <jwakely@redhat.com>
177
178 * src/c++17/fs_dir.cc (_Dir::_Dir) [!_GLIBCXX_HAVE_OPENAT]:
179 Always store pathname if we don't have openat or unlinkat,
180 because the full path is needed to open sub-directories and
181 remove entries.
182
183 2022-07-22 Alexandre Oliva <oliva@adacore.com>
184
185 Backported from master:
186 2022-06-27 Alexandre Oliva <oliva@adacore.com>
187
188 * src/c++17/fs_dir.cc (dir_and_pathname): Use dirfd if
189 _GLIBCXX_HAVE_OPENAT.
190
191 2022-07-22 Alexandre Oliva <oliva@adacore.com>
192
193 Backported from master:
194 2022-06-24 Alexandre Oliva <oliva@adacore.com>
195
196 * acinclude.m4 (GLIBCXX_CHECK_FILESYSTEM_DEPS): Check for
197 openat.
198 * configure, config.h.in: Rebuilt.
199 * src/filesystem/dir-common.h (openat): Use ::openat if
200 _GLIBCXX_HAVE_OPENAT.
201 * src/filesystem/dir.cc (dir_and_pathname): Use dirfd if
202 _GLIBCXX_HAVE_OPENAT.
203
204 2022-07-22 Jonathan Wakely <jwakely@redhat.com>
205
206 Backported from master:
207 2022-05-06 Jonathan Wakely <jwakely@redhat.com>
208
209 * include/std/stacktrace: Do not include <cxxabi.h>.
210 (__cxa_demangle): Declare.
211
212 2022-07-21 Jonathan Wakely <jwakely@redhat.com>
213
214 Backported from master:
215 2022-07-20 Jonathan Wakely <jwakely@redhat.com>
216
217 PR libstdc++/100823
218 * include/bits/stl_iterator.h (common_iterator): Define move
219 constructor and move assignment operator.
220 (common_iterator::_M_assign): New function implementing
221 assignment.
222 (common_iterator::operator=): Use _M_assign.
223 (common_iterator::_S_valueless): New constant.
224 * testsuite/24_iterators/common_iterator/100823.cc: New test.
225
226 2022-07-21 Jonathan Wakely <jwakely@redhat.com>
227
228 Backported from master:
229 2022-07-20 Jonathan Wakely <jwakely@redhat.com>
230
231 * include/bits/stl_iterator.h (common_iterator): Fix incorrect
232 uses of is_nothrow_assignable_v. Fix inconsistent constraints on
233 friend declaration. Do not move argument in copy constructor.
234 * testsuite/24_iterators/common_iterator/1.cc: Check for
235 noexcept constructibnle/assignable.
236
237 2022-07-21 Nathan Sidwell <nathan@acm.org>
238
239 Backported from master:
240 2022-05-26 Nathan Sidwell <nathan@acm.org>
241
242 * include/bits/hashtable.h: Include required headers.
243 * include/bits/hashtable_policy.h: Likewise.
244 * include/bits/stl_heap.h: Likewise.
245 * include/bits/stl_iterator_base_funcs.h: Likewise.
246
247 2022-07-21 Jonathan Wakely <jwakely@redhat.com>
248
249 Backported from master:
250 2022-06-30 Jonathan Wakely <jwakely@redhat.com>
251
252 * include/bits/utility.h: Fix comment typos.
253
254 2022-07-21 Jonathan Wakely <jwakely@redhat.com>
255
256 Backported from master:
257 2022-06-28 Jonathan Wakely <jwakely@redhat.com>
258
259 * testsuite/20_util/from_chars/4.cc: Only use log2 if C99 math
260 functions are available.
261
262 2022-07-21 Jonathan Wakely <jwakely@redhat.com>
263
264 Backported from master:
265 2022-06-23 Jonathan Wakely <jwakely@redhat.com>
266
267 * testsuite/26_numerics/random/random_device/entropy.cc: Use
268 numeric_limits<unsigned>::digits.
269
270 2022-07-21 Marco Falke <falke.marco@gmail.com>
271
272 Backported from master:
273 2022-07-19 Marco Falke <falke.marco@gmail.com>
274
275 * include/std/charconv (__from_chars_alnum_to_val): Replace
276 implicit conversion from int to unsigned char with explicit
277 cast.
278
279 2022-07-21 Jonathan Wakely <jwakely@redhat.com>
280
281 Backported from master:
282 2022-06-30 Jonathan Wakely <jwakely@redhat.com>
283
284 PR libstdc++/88881
285 * src/filesystem/ops.cc (has_trailing_slash): New helper
286 function.
287 (fs::status): Strip trailing slashes.
288 (fs::symlink_status): Likewise.
289 * testsuite/experimental/filesystem/operations/temp_directory_path.cc:
290 Clean the environment before each test and use TMP instead of
291 TMPDIR so the test passes on Windows.
292
293 2022-07-21 Jonathan Wakely <jwakely@redhat.com>
294
295 Backported from master:
296 2022-06-10 Jonathan Wakely <jwakely@redhat.com>
297
298 PR libstdc++/105880
299 * libsupc++/eh_globals.cc (eh_globals): Ensure constant init and
300 prevent destruction during termination.
301 (__eh_globals_init::_M_init): Replace with static member _S_init.
302 (__cxxabiv1::__cxa_get_globals_fast): Update.
303 (__cxxabiv1::__cxa_get_globals): Likewise.
304
305 2022-07-07 Jonathan Wakely <jwakely@redhat.com>
306
307 Backported from master:
308 2022-07-01 Jonathan Wakely <jwakely@redhat.com>
309
310 PR libstdc++/106162
311 * include/Makefile.am (largefile-config.h): Add
312 stamp-${host_alias} prerequisite.
313 * include/Makefile.in: Regenerate.
314
315 2022-07-07 Jonathan Wakely <jwakely@redhat.com>
316
317 Backported from master:
318 2022-06-23 Jonathan Wakely <jwakely@redhat.com>
319
320 * testsuite/27_io/filesystem/iterators/error_reporting.cc: Use
321 rmdir to remove directories.
322 * testsuite/experimental/filesystem/iterators/error_reporting.cc:
323 Likewise.
324
325 2022-06-14 Jonathan Wakely <jwakely@redhat.com>
326
327 Backported from master:
328 2022-06-13 Jonathan Wakely <jwakely@redhat.com>
329
330 * include/std/atomic (__atomic_val_t): Use __type_identity_t
331 instead of atomic<T>::value_type, as per LWG 3220.
332 * testsuite/29_atomics/atomic/lwg3220.cc: New test.
333
334 2022-06-14 Mark Mentovai <mark@mentovai.com>
335
336 Backported from master:
337 2022-06-13 Mark Mentovai <mark@mentovai.com>
338
339 * include/experimental/bits/fs_path.h (__detail::__null_terminated):
340 Rename to __nul_terminated to avoid colliding with a macro in
341 Apple's SDK.
342
343 2022-06-08 Jonathan Wakely <jwakely@redhat.com>
344
345 Backported from master:
346 2022-05-27 Jonathan Wakely <jwakely@redhat.com>
347
348 PR libstdc++/105671
349 * include/std/sstream (basic_stringbuf::_M_high_mark): Add
350 always_inline attribute.
351
352 2022-06-08 Jonathan Wakely <jwakely@redhat.com>
353
354 Backported from master:
355 2022-05-26 Jonathan Wakely <jwakely@redhat.com>
356
357 PR libstdc++/105681
358 * include/ext/pb_ds/detail/resize_policy/hash_prime_size_policy_imp.hpp:
359 Limit ga_sizes array to values that fit in size_t.
360 * include/ext/random [__SIZE_WIDTH < 32] (sfmt86243)
361 (sfmt86243_64, sfmt132049, sfmt132049_64, sfmt216091)
362 (sfmt216091_64): Do not declare.
363
364 2022-06-08 Jonathan Wakely <jwakely@redhat.com>
365
366 Backported from master:
367 2022-05-19 Jonathan Wakely <jwakely@redhat.com>
368
369 * include/bits/basic_string.h: Do not include <ext/atomicity.h>
370 here.
371 * include/bits/cow_string.h: Include it here.
372
373 2022-05-27 Jonathan Wakely <jwakely@redhat.com>
374
375 Backported from master:
376 2022-05-26 Jonathan Wakely <jwakely@redhat.com>
377
378 * python/libstdcxx/v6/printers.py (StdErrorCodePrinter): Make
379 lookup for ios_errc and future_errc check versioned namespace.
380 (StdAtomicPrinter): Strip versioned namespace from typename.
381
382 2022-05-27 François Dumont <fdumont@gcc.gnu.org>
383
384 Backported from master:
385 2022-05-26 François Dumont <fdumont@gcc.gnu.org>
386
387 * python/libstdcxx/v6/printers.py (StdSpanPrinter.__init__):
388 Strip typename from version namespace.
389
390 2022-05-27 Jonathan Wakely <jwakely@redhat.com>
391
392 Backported from master:
393 2022-05-26 Jonathan Wakely <jwakely@redhat.com>
394
395 * python/libstdcxx/v6/printers.py (SharedPointerPrinter): Strip
396 versioned namespace from the template argument too.
397
398 2022-05-27 Jonathan Wakely <jwakely@redhat.com>
399
400 Backported from master:
401 2022-05-26 Jonathan Wakely <jwakely@redhat.com>
402
403 * include/bits/stl_iterator.h (counted_iterator::operator++(int)):
404 Add 'constexpr' as per LWG 3643.
405 * testsuite/24_iterators/counted_iterator/lwg3643.cc: New test.
406
407 2022-05-27 Jonathan Wakely <jwakely@redhat.com>
408
409 Backported from master:
410 2022-05-19 Jonathan Wakely <jwakely@redhat.com>
411
412 * include/std/memory_resource (polymorphic_allocator): Add
413 non-template equality operator, as proposed for LWG 3683.
414 * testsuite/20_util/polymorphic_allocator/lwg3683.cc: New test.
415
416 2022-05-27 Jonathan Wakely <jwakely@redhat.com>
417
418 Backported from master:
419 2022-05-20 Jonathan Wakely <jwakely@redhat.com>
420
421 * testsuite/26_numerics/random/bernoulli_distribution/operators/values.cc:
422 Run fewer iterations for simulator targets.
423 * testsuite/26_numerics/random/binomial_distribution/operators/values.cc:
424 Likewise.
425 * testsuite/26_numerics/random/discrete_distribution/operators/values.cc:
426 Likewise.
427 * testsuite/26_numerics/random/geometric_distribution/operators/values.cc:
428 Likewise.
429 * testsuite/26_numerics/random/negative_binomial_distribution/operators/values.cc:
430 Likewise.
431 * testsuite/26_numerics/random/poisson_distribution/operators/values.cc:
432 Likewise.
433 * testsuite/26_numerics/random/uniform_int_distribution/operators/values.cc:
434 Likewise.
435
436 2022-05-27 Jonathan Wakely <jwakely@redhat.com>
437
438 Backported from master:
439 2022-05-17 Jonathan Wakely <jwakely@redhat.com>
440
441 * testsuite/20_util/expected/synopsis.cc: Skip for versioned
442 namespace.
443 * testsuite/27_io/headers/iosfwd/synopsis.cc: Likewise.
444
445 2022-05-27 Jonathan Wakely <jwakely@redhat.com>
446
447 Backported from master:
448 2022-05-13 Jonathan Wakely <jwakely@redhat.com>
449
450 * include/bits/mofunc_impl.h: Fix doxygen command.
451
452 2022-05-27 Jonathan Wakely <jwakely@redhat.com>
453
454 Backported from master:
455 2022-05-13 Jonathan Wakely <jwakely@redhat.com>
456
457 * include/std/future (launch): Make operators noexcept.
458
459 2022-05-16 Jonathan Wakely <jwakely@redhat.com>
460
461 Backported from master:
462 2022-05-16 Jonathan Wakely <jwakely@redhat.com>
463
464 * doc/xml/manual/prerequisites.xml: Fix attributes for external
465 hyperlink.
466 * doc/html/manual/setup.html: Regenerate.
467
468 2022-05-16 Jonathan Wakely <jwakely@redhat.com>
469
470 Backported from master:
471 2022-05-16 Jonathan Wakely <jwakely@redhat.com>
472
473 * doc/xml/manual/status_cxx2023.xml: Update with gcc-12 support.
474 * doc/html/*: Regenerate.
475
476 2022-05-16 Jonathan Wakely <jwakely@redhat.com>
477
478 Backported from master:
479 2022-05-16 Jonathan Wakely <jwakely@redhat.com>
480
481 * doc/xml/manual/intro.xml: Include new chapter.
482 * doc/xml/manual/status_cxx2020.xml: Tweak release numbers.
483 * doc/xml/manual/status_cxx2023.xml: New file.
484 * doc/html/*: Regenerate.
485
486 2022-05-16 Jonathan Wakely <jwakely@redhat.com>
487
488 Backported from master:
489 2022-05-16 Jonathan Wakely <jwakely@redhat.com>
490
491 * doc/html/manual/status.html: Regenerate.
492 * doc/xml/manual/status_cxx2020.xml: Fix supported version for
493 C++20 bit operations.
494
495 2022-05-13 Alexandre Oliva <oliva@adacore.com>
496
497 Backported from master:
498 2022-05-06 Alexandre Oliva <oliva@adacore.com>
499
500 * include/experimental/bits/simd.h [__ALTIVEC__]: Require VSX
501 for double, long long, and 64-bit long intrinsic types.
502 [__ALTIVEC__] (__intrinsic_type): Mention 128-bit in
503 preexisting long double diagnostic, adjust no-VSX double
504 diagnostic to cover 64-bit long double as well.
505
506 2022-05-10 Jonathan Wakely <jwakely@redhat.com>
507
508 Backported from master:
509 2022-05-10 Jonathan Wakely <jwakely@redhat.com>
510
511 PR libstdc++/105284
512 * include/std/iosfwd: Add declarations for <spanstream> class
513 templates and typedefs.
514 * include/std/spanstream (basic_spanbuf, basic_ispanstream)
515 (basic_ospanstream, basic_spanstream): Remove default template
516 arguments.
517 * testsuite/27_io/headers/iosfwd/synopsis.cc: Add <spanstream>
518 declarations.
519 * testsuite/27_io/headers/iosfwd/types.cc: Check <spanstream>
520 default arguments.
521
522 2022-05-10 Jonathan Wakely <jwakely@redhat.com>
523
524 Backported from master:
525 2022-05-10 Jonathan Wakely <jwakely@redhat.com>
526
527 PR libstdc++/105284
528 * include/std/iosfwd: Add declarations for <synstream> class
529 templates and typedefs.
530 * include/std/syncstream (basic_syncbuf, basic_osyncstream):
531 Remove default template arguments.
532 * testsuite/27_io/headers/iosfwd/synopsis.cc: New test.
533 * testsuite/27_io/headers/iosfwd/types.cc: New test.
534
535 2022-05-09 Jonathan Wakely <jwakely@redhat.com>
536
537 Backported from master:
538 2022-05-06 Jonathan Wakely <jwakely@redhat.com>
539
540 PR libstdc++/104731
541 * testsuite/27_io/filesystem/iterators/error_reporting.cc:
542 Use a trailing char array as storage for dirent::d_name.
543
544 2022-05-06 Jonathan Wakely <jwakely@redhat.com>
545
546 Backported from master:
547 2022-05-06 Jonathan Wakely <jwakely@redhat.com>
548
549 PR libstdc++/105502
550 * include/bits/random.tcc
551 (operator>>(basic_istream<C,T>&, normal_distribution<R>&)):
552 Update state when __state_avail is false.
553 * testsuite/26_numerics/random/normal_distribution/operators/serialize.cc:
554 Check that deserialized object equals serialized one.
555
556 2022-05-06 Patrick Palka <ppalka@redhat.com>
557
558 Backported from master:
559 2022-05-02 Patrick Palka <ppalka@redhat.com>
560
561 PR libstdc++/103911
562 * src/c++17/floating_from_chars.cc (find_end_of_float): Accept
563 two delimeters for the exponent part in the form of a possibly
564 NULL string of length two. Don't use std::tolower.
565 (pattern): Adjust calls to find_end_of_float accordingly.
566
567 2022-05-06 Alexandre Oliva <oliva@adacore.com>
568
569 Backported from master:
570 2022-05-03 Alexandre Oliva <oliva@adacore.com>
571
572 PR c++/105324
573 * testsuite/20_util/from_chars/pr105324.cc: Guard test body
574 with conditional for floating-point overloads of from_char.
575
576 2022-05-06 Release Manager
577
578 * GCC 12.1.0 released.
579
580 2022-05-02 Patrick Palka <ppalka@redhat.com>
581
582 Backported from master:
583 2022-05-02 Patrick Palka <ppalka@redhat.com>
584
585 PR libstdc++/105441
586 * src/c++17/floating_from_chars.cc (__floating_from_chars_hex):
587 Also accept 'P' as the start of the exponent.
588 * testsuite/20_util/from_chars/7.cc: Add corresponding testcase.
589
590 2022-04-29 Jonathan Wakely <jwakely@redhat.com>
591
592 Backported from master:
593 2022-04-29 Jonathan Wakely <jwakely@redhat.com>
594
595 PR libstdc++/105417
596 * config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt:
597 Regenerate.
598 * src/c++11/compatibility-ldbl-alt128.cc [_GLIBCXX_USE_DUAL_ABI]:
599 Define __gnu_ieee128::num_get<C>::_M_extract_int[abi:cxx11]<I>
600 symbols as aliases for corresponding symbols without abi-tag.
601
602 2022-04-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
603
604 * config/abi/post/i386-solaris/baseline_symbols.txt: Regenerate.
605 * config/abi/post/i386-solaris/amd64/baseline_symbols.txt:
606 Likewise.
607 * config/abi/post/sparc-solaris/baseline_symbols.txt: Likewise.
608 * config/abi/post/sparc-solaris/sparcv9/baseline_symbols.txt:
609 Likewise.
610
611 2022-04-28 Jonathan Wakely <jwakely@redhat.com>
612
613 * doc/xml/manual/status_cxx1998.xml: Refer to GCC 12 not
614 mainline.
615 * doc/xml/manual/status_cxx2011.xml: Likewise.
616 * doc/xml/manual/status_cxx2014.xml: Likewise.
617 * doc/xml/manual/status_cxx2017.xml: Likewise.
618 * doc/xml/manual/status_cxx2020.xml: Likewise.
619 * doc/xml/manual/status_cxxtr1.xml: Likewise.
620 * doc/xml/manual/status_cxxtr24733.xml: Likewise.
621 * doc/html/manual/status.html: Regenerate.
622
623 2022-04-28 Jonathan Wakely <jwakely@redhat.com>
624
625 PR libstdc++/99290
626 * src/c++17/fs_ops.cc (fs::copy): Pass error_code to
627 directory_iterator constructor, and check on each iteration.
628 * src/filesystem/ops.cc (fs::copy): Likewise.
629 * testsuite/27_io/filesystem/operations/copy.cc: Check for
630 errors during recursion.
631 * testsuite/experimental/filesystem/operations/copy.cc:
632 Likewise.
633
634 2022-04-28 François Dumont <fdumont@gcc.gnu.org>
635
636 * config/abi/pre/gnu-versioned-namespace.ver: Remove
637 std::random_device::* pattern.
638
639 2022-04-27 Jakub Jelinek <jakub@redhat.com>
640
641 * config/abi/post/x86_64-linux-gnu/baseline_symbols.txt: Update.
642 * config/abi/post/x86_64-linux-gnu/32/baseline_symbols.txt: Update.
643 * config/abi/post/i486-linux-gnu/baseline_symbols.txt: Update.
644 * config/abi/post/aarch64-linux-gnu/baseline_symbols.txt: Update.
645 * config/abi/post/s390x-linux-gnu/baseline_symbols.txt: Update.
646 * config/abi/post/powerpc-linux-gnu/baseline_symbols.txt: Update.
647 * config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt: Update.
648 * config/abi/post/powerpc64-linux-gnu/32/baseline_symbols.txt: Update.
649
650 2022-04-27 Jonathan Wakely <jwakely@redhat.com>
651
652 * python/libstdcxx/v6/printers.py (SharedPointerPrinter): Add
653 support for atomic<shared_ptr<T>> and atomic<weak_ptr<T>>.
654 (StdAtomicPrinter): New printer.
655 (build_libstdcxx_dictionary): Register new printer.
656 * testsuite/libstdc++-prettyprinters/cxx11.cc: Test std::atomic.
657 * testsuite/libstdc++-prettyprinters/cxx20.cc: Test atomic smart
658 pointers.
659
660 2022-04-26 Jonathan Wakely <jwakely@redhat.com>
661
662 * include/bits/shared_ptr_atomic.h (atomic<shared_ptr>): Add
663 constructor for constant initialization from nullptr_t.
664 * testsuite/20_util/shared_ptr/atomic/atomic_shared_ptr.cc:
665 Check for new constructor.
666
667 2022-04-26 Jonathan Wakely <jwakely@redhat.com>
668
669 * include/bits/fs_path.h (hash<filesystem::path>): Define.
670 * testsuite/27_io/filesystem/path/nonmember/hash_value.cc:
671 Check std::hash specialization.
672
673 2022-04-25 Jonathan Wakely <jwakely@redhat.com>
674
675 * include/bits/ptr_traits.h (__cpp_lib_constexpr_memory): Define
676 conditionally.
677 * include/bits/unique_ptr.h (__cpp_lib_constexpr_memory):
678 Define for C++23.
679 (default_delete, default_delete<T[]>, __uniq_ptr_impl)
680 (unique_ptr, unique_ptr<T[], D>): Add constexpr to all member
681 functions.
682 * include/std/version (__cpp_lib_constexpr_memory): Define new
683 value for C++23.
684 * testsuite/20_util/unique_ptr/assign/constexpr.cc: New test.
685 * testsuite/20_util/unique_ptr/comparison/constexpr.cc: New test.
686 * testsuite/20_util/unique_ptr/cons/constexpr_c++20.cc: New test.
687 * testsuite/20_util/unique_ptr/creation/constexpr.cc: New test.
688 * testsuite/20_util/unique_ptr/modifiers/constexpr.cc: New test.
689 * testsuite/20_util/unique_ptr/specialized_algorithms/constexpr.cc:
690 New test.
691
692 2022-04-25 Jonathan Wakely <jwakely@redhat.com>
693
694 PR libstdc++/105375
695 * include/std/future (packaged_task): Add deduction guides.
696 * testsuite/30_threads/packaged_task/cons/deduction.cc: New test.
697
698 2022-04-25 Philipp Fent <fent@in.tum.de>
699
700 * python/libstdcxx/v6/printers.py (StdSpanPrinter._iterator):
701 Rename as iterator.
702 (StdInitializerListPrinter): Define new printer.
703 (build_libstdcxx_dictionary): Register new printer.
704 * testsuite/libstdc++-prettyprinters/cxx11.cc: Check printer for
705 initializer_list.
706
707 2022-04-22 Thomas W Rodgers <trodgers@redhat.com>
708
709 PR libstdc++/102994
710 * include/bits/atomic_base.h (atomic_flag::notify_one,
711 notify_all): Remove const qualification.
712 (__atomic_base::notify_one, notify_all): Likewise.
713 * include/std/atomic (atomic<bool>::notify_one, notify_all):
714 Likewise.
715 (atomic::notify_one, notify_all): Likewise.
716 (atomic<T*>::notify_one, notify_all): Likewise.
717 (atomic_notify_one, atomic_notify_all): Likewise.
718 * testsuite/29_atomics/atomic/wait_notify/102994.cc: Adjust test
719 to account for change in notify_one/notify_all signature.
720
721 2022-04-21 Patrick Palka <ppalka@redhat.com>
722
723 * include/std/charconv (__from_chars_alnum_to_val_table):
724 Simplify initialization of __lower/__upper_letters.
725 (__from_chars_alnum_to_val): Default the template parameter to
726 false.
727 * src/c++17/floating_from_chars.cc (starts_with_ci): Don't
728 assume the uppercase and lowercase letters are contiguous.
729 (__floating_from_chars_hex): Likewise.
730
731 2022-04-21 Patrick Palka <ppalka@redhat.com>
732
733 PR c++/105297
734 PR c++/105322
735 * include/std/charconv (__from_chars_alnum_to_val): Make
736 initializer for __table dependent in an artificial way.
737
738 2022-04-21 Jonathan Wakely <jwakely@redhat.com>
739
740 PR libstdc++/105324
741 * src/c++17/floating_from_chars.cc (buffer_resource::do_allocate):
742 Remove assertion.
743 * testsuite/20_util/from_chars/pr105324.cc: New test.
744
745 2022-04-20 Jonathan Wakely <jwakely@redhat.com>
746
747 * testsuite/21_strings/basic_string_view/operations/copy/char/constexpr.cc:
748 Check correct feature test macro.
749
750 2022-04-20 Jonathan Wakely <jwakely@redhat.com>
751
752 PR libstdc++/93602
753 * doc/xml/manual/prerequisites.xml: Document libiconv
754 workarounds.
755 * doc/html/manual/setup.html: Regenerate.
756 * src/Makefile.am (CXXLINK): Add $(LTLIBICONV).
757 * src/Makefile.in: Regenerate.
758
759 2022-04-19 Patrick Palka <ppalka@redhat.com>
760
761 * src/c++17/floating_to_chars.cc (_GLIBCXX_ASSERTIONS): Don't
762 define.
763 (__floating_to_chars_shortest): Add __builtin_unreachable calls to
764 squelch false-positive -Wmaybe-uninitialized and -Wreturn-type
765 warnings.
766 (__floating_to_chars_precision): Likewise.
767
768 2022-04-19 Philipp Fent <fent@in.tum.de>
769
770 * python/libstdcxx/v6/printers.py (StdSpanPrinter): Define.
771 * testsuite/libstdc++-prettyprinters/cxx20.cc: Test it.
772
773 2022-04-19 Jonathan Wakely <jwakely@redhat.com>
774
775 * acinclude.m4 (GLIBCXX_ENABLE_BACKTRACE): Fix shell operators.
776 * configure: Regenerate.
777
778 2022-04-18 Patrick Palka <ppalka@redhat.com>
779
780 * include/std/charconv (__from_chars_pow2_base): Manually
781 unroll the first iteration of the main loop and simplify
782 accordingly.
783
784 2022-04-15 Patrick Palka <ppalka@redhat.com>
785
786 PR libstdc++/104858
787 * include/bits/ranges_algo.h (__minmax_fn): Avoid dereferencing
788 __first twice at the start.
789 * testsuite/25_algorithms/minmax/constrained.cc (test06): New test.
790
791 2022-04-15 Patrick Palka <ppalka@redhat.com>
792
793 * include/std/charconv (__from_chars_alnum_to_val_table): Define.
794 (__from_chars_alnum_to_val): Define.
795 (__from_chars_binary): Rename to ...
796 (__from_chars_pow2_base): ... this. Generalize to handle any
797 power-of-two base using __from_chars_alnum_to_val.
798 (__from_chars_digit): Optimize digit recognition to a single
799 test instead of two tests. Use [[__unlikely___]] attribute.
800 (__from_chars_alpha_to_num): Remove.
801 (__from_chars_alnum): Use __from_chars_alnum_to_val. Use a
802 nested loop for the overflow case. Maintain a lower bound
803 on the number of available bits in the result and use it to
804 omit the overflow check.
805 (from_chars): Adjust appropriately.
806 * src/c++17/floating_from_chars.cc (ascii_to_hexit): Remove.
807 (__floating_from_chars_hex): Use __from_chars_alnum_to_val
808 to recognize a hex digit instead.
809
810 2022-04-14 Palmer Dabbelt <palmer@rivosinc.com>
811
812 * acinclude.m4 (GLIBCXX_ENABLE_LOCK_POLICY): Force auto to mutex
813 for RISC-V.
814 * configure: Regenerate.
815
816 2022-04-14 Jonathan Wakely <jwakely@redhat.com>
817
818 * doc/xml/manual/intro.xml: Fix comment.
819
820 2022-04-14 Jonathan Wakely <jwakely@redhat.com>
821
822 * include/precompiled/stdc++.h: Include <stacktrace> and
823 <stdatomic.h> for C++23.
824
825 2022-04-14 Jonathan Wakely <jwakely@redhat.com>
826
827 PR libstdc++/105269
828 * include/bits/stl_vector.h (__cpp_lib_constexpr_vector):
829 Define.
830 * include/c_compatibility/stdatomic.h (__cpp_lib_stdatomic_h):
831 Define.
832 * include/std/optional (__cpp_lib_optional): Define new value
833 for C++23.
834 (__cpp_lib_monadic_optional): Remove.
835 * include/std/version (__cpp_lib_constexpr_vector): Define.
836 (__cpp_lib_stdatomic_h): Define.
837 (__cpp_lib_optional): Define new value for C++23.
838 (__cpp_lib_monadic_optional): Remove.
839 * testsuite/20_util/optional/monadic/and_then.cc: Adjust.
840 * testsuite/20_util/optional/requirements.cc: Adjust for C++23.
841 * testsuite/20_util/optional/version.cc: Likewise.
842 * testsuite/23_containers/vector/cons/constexpr.cc: Check
843 feature test macro.
844 * testsuite/29_atomics/headers/stdatomic.h/c_compat.cc:
845 Likewise.
846 * testsuite/20_util/optional/monadic/version.cc: Removed.
847 * testsuite/23_containers/vector/requirements/version.cc: New test.
848 * testsuite/29_atomics/headers/stdatomic.h/version.cc: New test.
849
850 2022-04-12 Jonathan Wakely <jwakely@redhat.com>
851
852 * acinclude.m4 (GLIBCXX_ENABLE_BACKTRACE): Check for mmap.
853 * config.h.in: Regenerate.
854 * configure: Regenerate.
855
856 2022-04-12 Jonathan Wakely <jwakely@redhat.com>
857
858 * include/std/stacktrace (basic_stacktrace::current): Reallocate
859 a smaller container if the unused capacity is larger than the
860 used size.
861
862 2022-04-12 Jonathan Wakely <jwakely@redhat.com>
863
864 * include/std/stacktrace (basic_stacktrace): Use _Impl::_M_clone
865 or _Impl::_M_assign to initialize elements in allocated storage.
866 (basic_stacktrace::_M_clear()): Use _Impl::_M_resize instead of
867 _Impl::_M_destroy.
868 (basic_stacktrace::_Impl::_M_destroy()): Replace with ...
869 (basic_stacktrace::_Impl::_M_resize(size_type, allocator&)): New
870 function.
871 (basic_stacktrace::_Impl::_M_push_back): Use _M_xclone. Construct
872 new element using allocator.
873 (basic_stacktrace::_Impl::_M_clone): New function.
874 (basic_stacktrace::_Impl::_M_xclone): New function.
875 (basic_stacktrace::_Impl::_M_assign): New function.
876
877 2022-04-12 Jonathan Wakely <jwakely@redhat.com>
878
879 * include/std/stacktrace (basic_stacktrace::_Impl::_M_allocate):
880 Use nothrow new instead of try block for std::allocator.
881 (basic_stacktrace::_Impl::_M_deallocate): Use delete for
882 std::allocator.
883
884 2022-04-12 Jonathan Wakely <jwakely@redhat.com>
885
886 * include/std/stacktrace (basic_stacktrace::current): Replace
887 calls to _M_reserve and _S_curr_cb with call to _M_prepare.
888 Check return value of backtrace_simple when max depth given.
889 (basic_stacktrace::_M_reserve): Remove.
890 (basic_stacktrace::_S_curr_cb): Remove.
891 (basic_stacktrace::_M_prepare(size_type)): New function to
892 reserve initial capacity and return callback.
893 (basic_stacktrace::_Impl::_M_allocate): Remove check for 0 < n
894 and remove redundant zeroing of _M_frames and _M_capacity.
895 (basic_stacktrace::_Impl::_M_push_back): Add [[unlikely]]
896 attribute. Assign _Impl instead of swapping.
897 * testsuite/19_diagnostics/stacktrace/current.cc: New test.
898
899 2022-04-11 Jonathan Wakely <jwakely@redhat.com>
900
901 * include/std/stacktrace (basic_stacktrace::_Impl::_M_allocate):
902 Change [[unlikely]] attribute to [[likely]].
903
904 2022-04-11 Jonathan Wakely <jwakely@redhat.com>
905
906 PR libstdc++/105031
907 * include/std/stacktrace (basic_stacktrace::basic_stacktrace):
908 Fix allocator usage in constructors.
909 (basic_stacktrace::operator=(const basic_stacktrace&)): Do not
910 try to reallocate using const allocator.
911 (basic_stacktrace::operator=(basic_stacktrace&&)): Fix
912 if-constexpr with non-constant condition. Do not allocate new
913 storage if allocator propagates. Do not set _M_size if
914 allocation fails.
915 (basic_stacktrace::swap(basic_stacktrace&)): Fix typo. Add
916 assertion that non-propagating allocators are equal.
917 * testsuite/19_diagnostics/stacktrace/stacktrace.cc: New test.
918
919 2022-04-11 Jonathan Wakely <jwakely@redhat.com>
920
921 * include/std/stacktrace (basic_stacktrace::current): Duplicate
922 implementation into each overload. Add noinline attribute and
923 skip current frame.
924 (basic_stacktrace::max_size()): Call _Impl::_S_max_size.
925 (basic_stacktrace::_S_curr_cb()): New function defining lambda.
926 (basic_stacktrace::_Impl::_S_max_size): New function defining
927 maximum size in terms of allocator and size_type.
928 (basic_stacktrace::_Impl::_M_allocate): Check against
929 max_size().
930 * testsuite/19_diagnostics/stacktrace/entry.cc: Call function
931 for non-constexpr checks. Check line number is correct.
932
933 2022-04-11 Jonathan Wakely <jwakely@redhat.com>
934
935 * testsuite/20_util/stacktrace/entry.cc: Moved to...
936 * testsuite/19_diagnostics/stacktrace/entry.cc: ...here.
937 * testsuite/20_util/stacktrace/synopsis.cc: Moved to...
938 * testsuite/19_diagnostics/stacktrace/synopsis.cc: ...here.
939 * testsuite/20_util/stacktrace/version.cc: Moved to...
940 * testsuite/19_diagnostics/stacktrace/version.cc: ...here.
941
942 2022-04-11 Jonathan Wakely <jwakely@redhat.com>
943
944 * include/experimental/bits/fs_path.h (path): Define special
945 members after path::_Cmpt is complete.
946
947 2022-04-08 Jonathan Wakely <jwakely@redhat.com>
948
949 PR libstdc++/105153
950 * include/std/expected
951 (expected<void,E>::expected(expected<U,G>&&)): Fix constraints.
952 * testsuite/20_util/expected/cons.cc: Check constructor.
953
954 2022-04-08 Jonathan Wakely <jwakely@redhat.com>
955
956 PR libstdc++/105154
957 * include/std/expected (expected<void, E>::swap): Set
958 _M_has_value to false for objects that previously had a value.
959 * testsuite/20_util/expected/swap.cc: Fix test to check void
960 specialization.
961
962 2022-04-08 Jonathan Wakely <jwakely@redhat.com>
963
964 PR libstdc++/105146
965 * include/std/expected (bad_expected_access): Move constructor
966 parameter.
967 * testsuite/20_util/expected/bad.cc: New test.
968
969 2022-04-07 Hans-Peter Nilsson <hp@axis.com>
970
971 * testsuite/20_util/expected/requirements.cc: Correct minimal-size
972 test.
973
974 2022-04-02 Jakub Jelinek <jakub@redhat.com>
975
976 PR libstdc++/105128
977 * include/std/source_location (std::source_location::__impl): Move
978 definition before using __builtin_ret_type.
979
980 2022-04-01 Jonathan Wakely <jwakely@redhat.com>
981
982 * include/std/utility (unreachable): Define for C++23.
983 * include/std/version (__cpp_lib_unreachable): Define.
984 * src/c++11/debug.cc (__glibcxx_assert_fail): Check for valid
985 arguments. Handle only the function being given.
986 * testsuite/20_util/unreachable/1.cc: New test.
987 * testsuite/20_util/unreachable/version.cc: New test.
988
989 2022-04-01 Jonathan Wakely <jwakely@redhat.com>
990
991 * include/experimental/bits/fs_fwd.h (copy_file): Remove
992 incorrect noexcept from declaration.
993 * include/experimental/bits/fs_path.h (path::begin, path::end):
994 Add noexcept to declarations, to match definitions.
995
996 2022-04-01 Timm Bäder <tbaeder@redhat.com>
997
998 * include/bits/fs_ops.h: Fix filename in Doxygen comment.
999 * include/experimental/bits/fs_ops.h: Likewise.
1000
1001 2022-03-31 Jonathan Wakely <jwakely@redhat.com>
1002
1003 * libsupc++/new_opa.cc (aligned_alloc): Add comment.
1004
1005 2022-03-29 Jonathan Wakely <jwakely@redhat.com>
1006
1007 * testsuite/18_support/exception/38732.cc: Disable for C++23.
1008 * testsuite/18_support/headers/exception/synopsis.cc: Likewise.
1009 * testsuite/18_support/unexpected_handler.cc: Likewise.
1010
1011 2022-03-29 Jonathan Wakely <jwakely@redhat.com>
1012
1013 * libsupc++/compare (_Strong_order) [!__cpp_using_enum]: Add
1014 static data members for _Fp_fmt enumerators.
1015
1016 2022-03-29 Jonathan Wakely <jwakely@redhat.com>
1017
1018 * include/std/version (__cpp_lib_variant): Fix conditions to
1019 match <variant>.
1020 (__cpp_lib_expected): Fix condition to match <expected>.
1021
1022 2022-03-28 Jonathan Wakely <jwakely@redhat.com>
1023
1024 * testsuite/20_util/optional/monadic/and_then.cc: Fix typo.
1025 * testsuite/20_util/optional/monadic/transform.cc: Likewise.
1026 * testsuite/22_locale/codecvt/always_noconv/char/1.cc: Likewise.
1027 * testsuite/22_locale/codecvt/encoding/char/1.cc: Likewise.
1028 * testsuite/22_locale/codecvt/in/char/1.cc: Likewise.
1029 * testsuite/22_locale/codecvt/max_length/char/1.cc: Likewise.
1030 * testsuite/22_locale/codecvt/out/char/1.cc: Likewise.
1031 * testsuite/22_locale/codecvt/unshift/char/1.cc: Likewise.
1032
1033 2022-03-27 Jonathan Wakely <jwakely@redhat.com>
1034
1035 * doc/doxygen/user.cfg.in: Add new header.
1036 * include/Makefile.am: Likewise.
1037 * include/Makefile.in: Regenerate.
1038 * include/precompiled/stdc++.h: Add new header.
1039 * include/std/version (__cpp_lib_expected): Define.
1040 * libsupc++/exception [__cplusplus > 202002] (unexpected)
1041 (unexpected_handler, set_unexpected): Do not declare for C++23.
1042 * include/std/expected: New file.
1043 * testsuite/20_util/expected/assign.cc: New test.
1044 * testsuite/20_util/expected/cons.cc: New test.
1045 * testsuite/20_util/expected/illformed_neg.cc: New test.
1046 * testsuite/20_util/expected/observers.cc: New test.
1047 * testsuite/20_util/expected/requirements.cc: New test.
1048 * testsuite/20_util/expected/swap.cc: New test.
1049 * testsuite/20_util/expected/synopsis.cc: New test.
1050 * testsuite/20_util/expected/unexpected.cc: New test.
1051 * testsuite/20_util/expected/version.cc: New test.
1052
1053 2022-03-25 Jonathan Wakely <jwakely@redhat.com>
1054
1055 * include/std/bit (bit_cast, byteswap, endian): Add doxygen
1056 comments.
1057
1058 2022-03-23 Jonathan Wakely <jwakely@redhat.com>
1059
1060 PR libstdc++/105027
1061 * include/std/bit (bit_cast): Add constraints.
1062 * testsuite/26_numerics/bit/bit.cast/105027.cc: New test.
1063
1064 2022-03-23 Jonathan Wakely <jwakely@redhat.com>
1065
1066 * include/std/version [!_GLIBCXX_HOSTED]
1067 (__cpp_lib_hardware_interference_size): Define for freestanding.
1068 (__cpp_lib_bit_cast): Likewise.
1069 (__cpp_lib_is_layout_compatible): Likewise.
1070 (__cpp_lib_is_pointer_interconvertible): Likewise.
1071 (__cpp_lib_adaptor_iterator_pair_constructor): Do not define for
1072 freestanding.
1073 (__cpp_lib_invoke_r): Likewise.
1074 (__cpp_lib_ios_noreplace): Likewise.
1075 (__cpp_lib_monadic_optional): Likewise.
1076 (__cpp_lib_move_only_function): Likewise.
1077 (__cpp_lib_spanstream): Likewise.
1078 (__cpp_lib_stacktrace): Likewise.
1079 (__cpp_lib_string_contains): Likewise.
1080 (__cpp_lib_string_resize_and_overwrite): Likewise.
1081 (__cpp_lib_to_underlying): Likewise.
1082
1083 2022-03-23 Jonathan Wakely <jwakely@redhat.com>
1084
1085 PR libstdc++/105021
1086 * include/bits/atomic_base.h [!_GLIBCXX_HOSTED]: Do not include
1087 <bits/atomic_wait.h> for freestanding.
1088
1089 2022-03-22 Hans-Peter Nilsson <hp@axis.com>
1090
1091 * testsuite/20_util/from_chars/6.cc (test01) [FE_DOWNWARD]:
1092 Conditionalize call to fesetround.
1093
1094 2022-03-21 Jakub Jelinek <jakub@redhat.com>
1095
1096 PR libstdc++/104990
1097 * include/bits/locale_facets_nonio.tcc (get): Don't check if do_get
1098 isn't overloaded if __clang__ is defined.
1099
1100 2022-03-18 Jonathan Wakely <jwakely@redhat.com>
1101
1102 PR libstdc++/104242
1103 * include/std/any (any(T&&)): Revert change to constraints.
1104 * testsuite/20_util/any/cons/104242.cc: New test.
1105
1106 2022-03-18 Jonathan Wakely <jwakely@redhat.com>
1107
1108 PR libstdc++/92546
1109 * include/pstl/glue_algorithm_defs.h: Replace <functional> with
1110 <bits/stl_pair.h>.
1111 * include/pstl/utils.h: Replace <iterator> with <type_traits>.
1112 (__pstl::__internal::__except_handler): Use std::__terminate
1113 instead of std::terminate.
1114 * src/c++17/fs_path.cc: Include <array>.
1115 * testsuite/25_algorithms/adjacent_find/constexpr.cc: Include
1116 <functional>.
1117 * testsuite/25_algorithms/binary_search/constexpr.cc: Likewise.
1118 * testsuite/25_algorithms/clamp/constrained.cc: Likewise.
1119 * testsuite/25_algorithms/equal/constrained.cc: Likewise.
1120 * testsuite/25_algorithms/for_each/constrained.cc: Likewise.
1121 * testsuite/25_algorithms/includes/constrained.cc: Likewise.
1122 * testsuite/25_algorithms/is_heap/constexpr.cc: Likewise.
1123 * testsuite/25_algorithms/is_heap_until/constexpr.cc: Likewise.
1124 * testsuite/25_algorithms/is_permutation/constrained.cc: Include
1125 <iterator>.
1126 * testsuite/25_algorithms/is_sorted/constexpr.cc: Include
1127 <functional>.
1128 * testsuite/25_algorithms/is_sorted_until/constexpr.cc:
1129 Likewise.
1130 * testsuite/25_algorithms/lexicographical_compare/constexpr.cc:
1131 Likewise.
1132 * testsuite/25_algorithms/lexicographical_compare/constrained.cc:
1133 Likewise.
1134 * testsuite/25_algorithms/lexicographical_compare_three_way/1.cc:
1135 Include <array>.
1136 * testsuite/25_algorithms/lower_bound/constexpr.cc: Include
1137 <functional>.
1138 * testsuite/25_algorithms/max/constrained.cc: Likewise.
1139 * testsuite/25_algorithms/max_element/constrained.cc: Likewise.
1140 * testsuite/25_algorithms/min/constrained.cc: Likewise.
1141 * testsuite/25_algorithms/min_element/constrained.cc: Likewise.
1142 * testsuite/25_algorithms/minmax_element/constrained.cc:
1143 Likewise.
1144 * testsuite/25_algorithms/mismatch/constexpr.cc: Likewise.
1145 * testsuite/25_algorithms/move/93872.cc: Likewise.
1146 * testsuite/25_algorithms/move_backward/93872.cc: Include
1147 <iterator>.
1148 * testsuite/25_algorithms/nth_element/constexpr.cc: Include
1149 <functional>.
1150 * testsuite/25_algorithms/partial_sort/constexpr.cc: Likewise.
1151 * testsuite/25_algorithms/partial_sort_copy/constexpr.cc:
1152 Likewise.
1153 * testsuite/25_algorithms/search/constexpr.cc: Likewise.
1154 * testsuite/25_algorithms/search_n/constrained.cc: Likewise.
1155 * testsuite/25_algorithms/set_difference/constexpr.cc: Likewise.
1156 * testsuite/25_algorithms/set_difference/constrained.cc:
1157 Likewise.
1158 * testsuite/25_algorithms/set_intersection/constexpr.cc:
1159 Likewise.
1160 * testsuite/25_algorithms/set_intersection/constrained.cc:
1161 Likewise.
1162 * testsuite/25_algorithms/set_symmetric_difference/constexpr.cc:
1163 Likewise.
1164 * testsuite/25_algorithms/set_union/constexpr.cc: Likewise.
1165 * testsuite/25_algorithms/set_union/constrained.cc: Likewise.
1166 * testsuite/25_algorithms/sort/constexpr.cc: Likewise.
1167 * testsuite/25_algorithms/sort_heap/constexpr.cc: Likewise.
1168 * testsuite/25_algorithms/transform/constrained.cc: Likewise.
1169 * testsuite/25_algorithms/unique/constexpr.cc: Likewise.
1170 * testsuite/25_algorithms/unique/constrained.cc: Likewise.
1171 * testsuite/25_algorithms/unique_copy/constexpr.cc: Likewise.
1172 * testsuite/25_algorithms/upper_bound/constexpr.cc: Likewise.
1173 * testsuite/std/ranges/adaptors/elements.cc: Include <vector>.
1174 * testsuite/std/ranges/adaptors/lazy_split.cc: Likewise.
1175 * testsuite/std/ranges/adaptors/split.cc: Likewise.
1176
1177 2022-03-17 Jonathan Wakely <jwakely@redhat.com>
1178
1179 PR libstdc++/92546
1180 * include/bits/fs_path.h (path::make_preferred): Use
1181 handwritten loop instead of std::replace.
1182
1183 2022-03-17 Jonathan Wakely <jwakely@redhat.com>
1184
1185 PR middle-end/104966
1186 * include/bits/locale_facets_nonio.tcc
1187 (__moneypunct_cache::_M_cache): Replace try-catch with RAII and
1188 make all string copies before any stores to *this.
1189
1190 2022-03-17 Jonathan Wakely <jwakely@redhat.com>
1191
1192 * testsuite/util/testsuite_character.h: Fix comment.
1193
1194 2022-03-16 Jonathan Wakely <jwakely@redhat.com>
1195
1196 PR libstdc++/103407
1197 * config/abi/pre/gnu.ver: Make version for std::from_chars
1198 depend on HAVE_USELOCALE macro.
1199 * testsuite/util/testsuite_abi.cc (compare_symbols): Treat
1200 std::from_chars for floating-point types as undesignated if
1201 not found in the baseline symbols file.
1202
1203 2022-03-16 Jonathan Wakely <jwakely@redhat.com>
1204
1205 * include/std/charconv (__cpp_lib_to_chars): Only define when
1206 both from_chars and to_chars are supported for floating-point
1207 types.
1208 (from_chars, to_chars): Adjust preprocessor conditions guarding
1209 declarations.
1210 * include/std/version (__cpp_lib_to_chars): Adjust condition to
1211 match <charconv> definition.
1212 * src/c++17/floating_from_chars.cc (from_chars_strtod): New
1213 function template.
1214 (from_chars): Simplify preprocessor checks and use
1215 from_chars_strtod when appropriate.
1216
1217 2022-03-14 Jonathan Wakely <jwakely@redhat.com>
1218
1219 PR libstdc++/104875
1220 * src/c++11/codecvt.cc (read_utf8_code_point): Use char32_t to
1221 hold octets that will be left-shifted.
1222
1223 2022-03-10 Jonathan Wakely <jwakely@redhat.com>
1224
1225 PR libstdc++/104870
1226 * src/c++17/floating_from_chars.cc: Check __SIZE_WIDTH__ >= 32
1227 before using fast_float.
1228
1229 2022-03-10 Detlef Vollmann <dv@vollmann.ch>
1230
1231 PR libstdc++/104866
1232 * include/bits/this_thread_sleep.h: Fix order of #endif and
1233 closing brace of namespace.
1234
1235 2022-03-10 Jonathan Wakely <jwakely@redhat.com>
1236
1237 * libsupc++/compare (_Strong_order::_S_fp_cmp) [__vax__]:
1238 Handle NaN.
1239
1240 2022-03-10 Jonathan Wakely <jwakely@redhat.com>
1241
1242 * libsupc++/compare (_Strong_ordering::_S_fp_cmp) [__vax__]: Use
1243 <=> comparison.
1244
1245 2022-03-09 Patrick Palka <ppalka@redhat.com>
1246
1247 PR libstdc++/104859
1248 * src/c++17/floating_to_chars.cc (__floating_to_chars_hex):
1249 Be explicit when narrowing the shifted effective_mantissa,
1250 since it may have an integer-class type.
1251
1252 2022-03-08 Jonathan Wakely <jwakely@redhat.com>
1253
1254 * include/bits/uses_allocator_args.h: Remove incorrect copyright
1255 notice.
1256
1257 2022-03-07 Jonathan Wakely <jwakely@redhat.com>
1258
1259 PR libstdc++/104807
1260 * include/bits/c++config (__terminate, __glibcxx_assert_fail):
1261 Replace _GLIBCXX_VISIBILITY on function with visibility pragma.
1262 (__is_constant_evaluated): Add visibility pragma.
1263
1264 2022-03-07 Rasmus Villemoes <rasmus.villemoes@prevas.dk>
1265
1266 * config/locale/vxworks/ctype_members.cc: Remove <iostream>
1267 include.
1268
1269 2022-03-05 Jonathan Wakely <jwakely@redhat.com>
1270
1271 * include/bits/c++config (__glibcxx_assert_fail): Add visibility
1272 attribute.
1273 (__terminate): Likewise.
1274
1275 2022-03-04 Jonathan Wakely <jwakely@redhat.com>
1276
1277 * libsupc++/compare (strong_order::_S_fp_cmp): Move typedef
1278 inside #if condition.
1279
1280 2022-03-03 Jonathan Wakely <jwakely@redhat.com>
1281
1282 PR libstdc++/104748
1283 * testsuite/std/ranges/adaptors/all.cc: Use non-debug vector for
1284 constexpr test.
1285
1286 2022-03-03 Jonathan Wakely <jwakely@redhat.com>
1287
1288 * testsuite/17_intro/names.cc (func): Undef on AIX.
1289
1290 2022-03-03 Jonathan Wakely <jwakely@redhat.com>
1291
1292 PR libstdc++/96526
1293 * libsupc++/compare (strong_order): Add missing support for
1294 floating-point types.
1295 * testsuite/18_support/comparisons/algorithms/strong_order_floats.cc:
1296 New test.
1297
1298 2022-03-01 Jonathan Wakely <jwakely@redhat.com>
1299
1300 PR middle-end/103984
1301 * include/bits/regex_compiler.h (_BracketMatcher::_M_char): Use
1302 default member initializer.
1303
1304 2022-02-24 Jonathan Wakely <jwakely@redhat.com>
1305
1306 PR libstdc++/104602
1307 * include/std/source_location (source_location::current): Use
1308 deduced type of __builtin_source_location().
1309
1310 2022-02-22 Patrick Palka <ppalka@redhat.com>
1311
1312 * include/bits/ranges_base.h (__detail::__is_initializer_list):
1313 Define.
1314 (viewable_range): Adjust as per P2415R2.
1315 * include/bits/ranges_cmp.h (__cpp_lib_ranges): Adjust value.
1316 * include/std/ranges (owning_view): Define as per P2415R2.
1317 (enable_borrowed_range<owning_view>): Likewise.
1318 (views::__detail::__can_subrange): Replace with ...
1319 (views::__detail::__can_owning_view): ... this.
1320 (views::_All::_S_noexcept): Sync with operator().
1321 (views::_All::operator()): Use owning_view instead of subrange
1322 as per P2415R2.
1323 * include/std/version (__cpp_lib_ranges): Adjust value.
1324 * testsuite/std/ranges/adaptors/all.cc (test06): Adjust now that
1325 views::all uses owning_view instead of subrange.
1326 (test08): New test.
1327 * testsuite/std/ranges/adaptors/lazy_split.cc (test09): Adjust
1328 now that rvalue non-view non-borrowed ranges are viewable.
1329 * testsuite/std/ranges/adaptors/split.cc (test06): Likewise.
1330
1331 2022-02-17 Jonathan Wakely <jwakely@redhat.com>
1332
1333 PR libstdc++/104559
1334 * doc/xml/manual/evolution.xml: Document deprecation.
1335 * doc/html/manual/api.html: Regenerate.
1336 * include/bits/stl_bvector.h (insert(const_iterator, const bool&)):
1337 Remove default argument.
1338 (insert(const_iterator)): New overload with deprecated attribute.
1339 * testsuite/23_containers/vector/bool/modifiers/insert/104559.cc:
1340 New test.
1341
1342 2022-02-17 Jonathan Wakely <jwakely@redhat.com>
1343
1344 * python/libstdcxx/v6/printers.py (StdErrorCodePrinter): Replace
1345 code that call cat->name() on std::error_category objects.
1346 Identify known categories by symbol name and use a hardcoded
1347 name. Print error code values as enumerators where appopriate.
1348 * testsuite/libstdc++-prettyprinters/cxx11.cc: Adjust expected
1349 name of custom category. Check io_errc and future_errc errors.
1350
1351 2022-02-15 Jonathan Wakely <jwakely@redhat.com>
1352
1353 PR libstdc++/104542
1354 * include/bits/uses_allocator_args.h (make_obj_using_allocator)
1355 (uninitialized_construct_using_allocator): Add constexpr.
1356 * testsuite/20_util/uses_allocator/make_obj.cc: Check constexpr.
1357 * testsuite/20_util/uses_allocator/uninitialized_construct.cc: New test.
1358
1359 2022-02-14 Jonathan Wakely <jwakely@redhat.com>
1360
1361 PR libstdc++/100912
1362 * config/locale/gnu/c_locale.h (__convert_from_v): Use inline
1363 namespace for IEEE128 long double mode.
1364 * config/os/gnu-linux/ldbl-ieee128-extra.ver: Add new symbol
1365 version and export __gnu_cxx_ieee128::__convert_from_v.
1366 * include/bits/locale_facets_nonio.tcc (money_put::__do_put):
1367 Make __ibm128 overload use snprintf directly
1368 * testsuite/util/testsuite_abi.cc: Add new symbol version.
1369 Remove stable IEEE128/LDBL versions.
1370
1371 2022-02-14 Jonathan Wakely <jwakely@redhat.com>
1372
1373 PR libstdc++/103891
1374 * include/bits/c++config (_GLIBCXX_HAVE_COND_TRIVIAL_SPECIAL_MEMBERS):
1375 Remove.
1376 * include/std/variant: Check feature test macros instead.
1377 * include/std/version: Likewise.
1378
1379 2022-02-14 Jonathan Wakely <jwakely@redhat.com>
1380
1381 * testsuite/20_util/unsynchronized_pool_resource/allocate.cc:
1382 Fix typo.
1383
1384 2022-02-14 Jonathan Wakely <jwakely@redhat.com>
1385
1386 * src/c++17/floating_to_chars.cc (FLOAT128_TO_CHARS): Depend on
1387 LONG_DOUBLE_ALT128_COMPAT instead of USE_FLOAT128.
1388
1389 2022-02-11 Jonathan Wakely <jwakely@redhat.com>
1390
1391 * testsuite/20_util/temporary_buffer.cc: Fix dg-warning target
1392 selector.
1393
1394 2022-02-11 Jonathan Wakely <jwakely@redhat.com>
1395
1396 * testsuite/20_util/monotonic_buffer_resource/allocate.cc:
1397 Ignore -Walloc-larger-than warning.
1398 * testsuite/20_util/unsynchronized_pool_resource/allocate.cc:
1399 Likewise.
1400 * testsuite/29_atomics/atomic/cons/user_pod.cc: Compile with -O1
1401 to avoid linker error for __atomic_is_lock_free.
1402
1403 2022-02-10 Thomas Rodgers <rodgert@appliantology.com>
1404
1405 * include/bits/atomic_wait.h (__waiter_base::_S_do_spin,
1406 __waiter_base::_S_do_spin_v): Change memory order from relaxed
1407 to acquire.
1408
1409 2022-02-10 Jonathan Wakely <jwakely@redhat.com>
1410
1411 * include/c_compatibility/stdatomic.h (atomic_fetch_xor): Add
1412 using-declaration.
1413 (atomic_fetch_xor_explicit): Likewise.
1414 * testsuite/29_atomics/headers/stdatomic.h/c_compat.cc: Check
1415 arithmetic and logical operations for atomic_int.
1416
1417 2022-02-10 Jonathan Wakely <jwakely@redhat.com>
1418
1419 * src/filesystem/dir-common.h (_GLIBCXX_HAVE_DIRFD): Undefine
1420 when <dirent.h> is not available.
1421 (_GLIBCXX_HAVE_UNLINKAT): Likewise.
1422
1423 2022-02-09 Thomas Rodgers <rodgert@appliantology.com>
1424
1425 PR libstdc++/104442
1426 * include/bits/atomic_wait.h (__waiter::_M_do_wait_v): Move spin
1427 loop inside do loop so that threads failing the wait, reload
1428 _M_ver.
1429
1430 2022-02-08 Jonathan Wakely <jwakely@redhat.com>
1431
1432 * src/c++17/fs_dir.cc (_Dir(DIR*, const path&)): Change first
1433 parameter to _Dir_base&&.
1434 * src/filesystem/dir-common.h (_Dir_base(DIR*)): Remove.
1435 * src/filesystem/dir.cc (_Dir(DIR*, const path&)): Change first
1436 parameter to _Dir_base&&.
1437
1438 2022-02-08 Jonathan Wakely <jwakely@redhat.com>
1439
1440 * acinclude.m4 (GLIBCXX_ENABLE_LOCK_POLICY): Add comment about
1441 checking for CAS on correct word size.
1442
1443 2022-02-08 Jonathan Wakely <jwakely@redhat.com>
1444
1445 * testsuite/experimental/filesystem/operations/create_directories.cc:
1446 Adjust expected results for Windows.
1447
1448 2022-02-08 Jonathan Wakely <jwakely@redhat.com>
1449
1450 PR libstdc++/104161
1451 * src/c++17/fs_dir.cc (fs::recursive_directory_iterator::__erase):
1452 [i_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Refresh entry._M_type member,
1453 instead of checking for errno values indicating a directory.
1454 * src/c++17/fs_ops.cc (fs::remove_all(const path&)): Use similar
1455 logic to non-throwing overload.
1456 (fs::remove_all(const path&, error_code&)): Add comments.
1457 * src/filesystem/ops-common.h: Likewise.
1458
1459 2022-02-04 Jonathan Wakely <jwakely@redhat.com>
1460
1461 * src/filesystem/dir-common.h (_Dir_base::openat): Change return
1462 type to use portable posix::DIR alias.
1463
1464 2022-02-04 Jonathan Wakely <jwakely@redhat.com>
1465
1466 * include/c_compatibility/stdatomic.h [__clang__]: Use
1467 #include_next <stdatomic.h>.
1468
1469 2022-02-04 Jonathan Wakely <jwakely@redhat.com>
1470
1471 * include/experimental/bits/fs_ops.h (fs::copy_file): Remove
1472 noexcept.
1473 (fs::create_directories): Likewise.
1474 (fs::remove_all): Likewise.
1475 * src/filesystem/ops.cc (fs::copy_file): Remove noexcept.
1476 (fs::create_directories): Likewise.
1477 (fs::remove_all): Likewise.
1478
1479 2022-02-04 Jonathan Wakely <jwakely@redhat.com>
1480
1481 PR libstdc++/104161
1482 * acinclude.m4 (GLIBCXX_CHECK_FILESYSTEM_DEPS): Check for dirfd
1483 and unlinkat.
1484 * config.h.in: Regenerate.
1485 * configure: Regenerate.
1486 * include/bits/fs_dir.h (recursive_directory_iterator): Declare
1487 remove_all overloads as friends.
1488 (recursive_directory_iterator::__erase): Declare new member
1489 function.
1490 * include/bits/fs_fwd.h (remove, remove_all): Declare.
1491 * src/c++17/fs_dir.cc (_Dir): Add filename_only parameter to
1492 constructor. Pass file descriptor argument to base constructor.
1493 (_Dir::dir_and_pathname, _Dir::open_subdir, _Dir::do_unlink)
1494 (_Dir::unlink, _Dir::rmdir): Define new member functions.
1495 (directory_iterator): Pass filename_only argument to _Dir
1496 constructor.
1497 (recursive_directory_iterator::_Dir_stack): Adjust constructor
1498 parameters to take a _Dir rvalue instead of creating one.
1499 (_Dir_stack::orig): Add data member for storing original path.
1500 (_Dir_stack::report_error): Define new member function.
1501 (__directory_iterator_nofollow): Move here from dir-common.h and
1502 fix value to be a power of two.
1503 (__directory_iterator_filename_only): Define new constant.
1504 (recursive_directory_iterator): Construct _Dir object and move
1505 into _M_dirs stack. Pass skip_permission_denied argument to first
1506 advance call.
1507 (recursive_directory_iterator::increment): Use _Dir::open_subdir.
1508 (recursive_directory_iterator::__erase): Define new member
1509 function.
1510 * src/c++17/fs_ops.cc (ErrorReporter, do_remove_all): Remove.
1511 (fs::remove_all): Use new recursive_directory_iterator::__erase
1512 member function.
1513 * src/filesystem/dir-common.h (_Dir_base): Add int parameter to
1514 constructor and use openat to implement nofollow semantics.
1515 (_Dir_base::fdcwd, _Dir_base::set_close_on_exec, _Dir_base::openat):
1516 Define new member functions.
1517 (__directory_iterator_nofollow): Move to fs_dir.cc.
1518 * src/filesystem/dir.cc (_Dir): Pass file descriptor argument to
1519 base constructor.
1520 (_Dir::dir_and_pathname, _Dir::open_subdir): Define new member
1521 functions.
1522 (recursive_directory_iterator::_Dir_stack): Adjust constructor
1523 parameters to take a _Dir rvalue instead of creating one.
1524 (recursive_directory_iterator): Check for new nofollow option.
1525 Construct _Dir object and move into _M_dirs stack. Pass
1526 skip_permission_denied argument to first advance call.
1527 (recursive_directory_iterator::increment): Use _Dir::open_subdir.
1528 * src/filesystem/ops.cc (fs::remove_all): Use C++17 remove_all.
1529
1530 2022-02-04 Jonathan Wakely <jwakely@redhat.com>
1531
1532 * include/bits/allocator.h: Qualify std::allocator_traits in
1533 deprecated warnings.
1534 * libsupc++/exception (uncaught_exception): Add suggestion to
1535 deprecated warning.
1536
1537 2022-02-02 Jonathan Wakely <jwakely@redhat.com>
1538
1539 * src/c++17/fs_dir.cc (fs::recursive_directory_iterator::pop):
1540 Add [[maybe_unused]] attribute.
1541 * src/filesystem/dir.cc (fs::recursive_directory_iterator::pop):
1542 Likewise.
1543
1544 2022-02-02 Jonathan Wakely <jwakely@redhat.com>
1545
1546 * testsuite/23_containers/multiset/operators/cmp_c++20.cc: Use
1547 custom comparison function for multiset.
1548 * testsuite/23_containers/set/operators/cmp_c++20.cc: Use custom
1549 comparison function for set.
1550
1551 2022-02-02 Jonathan Wakely <jwakely@redhat.com>
1552
1553 * include/bits/boost_concept_check.h (_OutputIteratorConcept):
1554 Change member function to data member of function pointer type.
1555
1556 2022-02-02 Martin Sebor <msebor@redhat.com>
1557
1558 PR libstdc++/101831
1559 * include/std/array (begin): Declare const member function attribute
1560 const.
1561 (end, rbegin, rend, size, max_size, empty, data): Same.
1562 * testsuite/23_containers/array/capacity/empty.cc: Add test cases.
1563 * testsuite/23_containers/array/capacity/max_size.cc: Same.
1564 * testsuite/23_containers/array/capacity/size.cc: Same.
1565 * testsuite/23_containers/array/iterators/begin_end.cc: New test.
1566
1567 2022-02-02 Jonathan Wakely <jwakely@redhat.com>
1568
1569 * testsuite/27_io/filesystem/iterators/error_reporting.cc: Use
1570 autoconf macro to check whether d_type is present.
1571 * testsuite/experimental/filesystem/iterators/error_reporting.cc:
1572 Likewise.
1573
1574 2022-02-01 Jonathan Wakely <jwakely@redhat.com>
1575
1576 * testsuite/27_io/filesystem/iterators/97731.cc: New test.
1577 * testsuite/27_io/filesystem/iterators/recursive_directory_iterator.cc:
1578 Check follow_directory_symlink option.
1579 * testsuite/experimental/filesystem/iterators/recursive_directory_iterator.cc:
1580 Likewise.
1581
1582 2022-02-01 Jonathan Wakely <jwakely@redhat.com>
1583
1584 * src/c++17/fs_dir.cc (recursive_directory_iterator::increment):
1585 Reset state to past-the-end iterator on error.
1586 (fs::recursive_directory_iterator::pop(error_code&)): Likewise.
1587 (fs::recursive_directory_iterator::pop()): Check _M_dirs before
1588 it might get reset.
1589 * src/filesystem/dir.cc (recursive_directory_iterator): Likewise,
1590 for the TS implementation.
1591 * testsuite/27_io/filesystem/iterators/error_reporting.cc: New test.
1592 * testsuite/experimental/filesystem/iterators/error_reporting.cc: New test.
1593
1594 2022-02-01 Jonathan Wakely <jwakely@redhat.com>
1595
1596 * include/bits/fs_fwd.h (filesystem::perms): Fix comment.
1597
1598 2022-02-01 Jonathan Wakely <jwakely@redhat.com>
1599
1600 PR libstdc++/104301
1601 * acinclude.m4 (GLIBCXX_ENABLE_CSTDIO): Print different messages
1602 for stdio_pure and stdio_posix options.
1603 * configure: Regenerate.
1604
1605 2022-02-01 Thomas Rodgers <rodgert@appliantology.com>
1606
1607 * include/bits/atomic_wait.h: Change memory order from
1608 Acquire/Release with relaxed loads to SeqCst+Release for
1609 accesses to the waiter's count.
1610
1611 2022-01-31 Martin Liska <mliska@suse.cz>
1612
1613 * acinclude.m4: Detect *_ld_is_mold and use it.
1614 * configure: Regenerate.
1615
1616 2022-01-30 Hans-Peter Nilsson <hp@axis.com>
1617
1618 * testsuite/27_io/basic_istream/get/char/lwg3464.cc: Don't run on
1619 simulator targets.
1620 * testsuite/27_io/basic_istream/get/wchar_t/lwg3464.cc: Likewise.
1621
1622 2022-01-27 Jonathan Wakely <jwakely@redhat.com>
1623
1624 PR libstdc++/100516
1625 * include/bits/deque.tcc (_M_range_initialize<ForwardIterator>):
1626 Add __builtin_unreachable to loop.
1627 * testsuite/23_containers/deque/100516.cc: New test.
1628
1629 2022-01-27 Jonathan Wakely <jwakely@redhat.com>
1630
1631 * include/bits/ranges_base.h (ranges::advance): Avoid signed
1632 overflow. Do nothing if already equal to desired result.
1633 * testsuite/24_iterators/range_operations/advance_overflow.cc:
1634 New test.
1635
1636 2022-01-27 Martin Liska <mliska@suse.cz>
1637
1638 PR libstdc++/104259
1639 * acinclude.m4: Fix typo.
1640 * configure: Regenerate.
1641
1642 2022-01-25 Jonathan Wakely <jwakely@redhat.com>
1643
1644 PR libstdc++/104019
1645 * include/bits/istream.tcc (basic_istream::sentry): Add braces
1646 around try-block.
1647 * include/bits/shared_ptr_base.h (_Sp_counted_array_base::_M_init):
1648 Add pragmas to disable bogus warnings from PR 61596.
1649
1650 2022-01-25 Jonathan Wakely <jwakely@redhat.com>
1651
1652 PR libstdc++/104217
1653 * src/c++17/fs_ops.cc (_GNU_SOURCE): Define.
1654 * src/filesystem/dir.cc (_GNU_SOURCE): Define.
1655 * src/filesystem/ops.cc (_GNU_SOURCE): Define.
1656
1657 2022-01-25 Jonathan Wakely <jwakely@redhat.com>
1658
1659 PR libstdc++/104161
1660 * acinclude.m4 (GLIBCXX_CHECK_FILESYSTEM_DEPS): Check for
1661 fdopendir.
1662 * config.h.in: Regenerate.
1663 * configure: Regenerate.
1664 * src/c++17/fs_dir.cc (_Dir): Add nofollow flag to constructor
1665 and pass it to base class constructor.
1666 (directory_iterator): Pass nofollow flag to _Dir constructor.
1667 (fs::recursive_directory_iterator::increment): Likewise.
1668 * src/c++17/fs_ops.cc (do_remove_all): Use nofollow option for
1669 directory_iterator constructor. Move error check outside loop.
1670 * src/filesystem/dir-common.h (_Dir_base): Add nofollow flag to
1671 constructor and when it's set use ::open with O_NOFOLLOW and
1672 O_DIRECTORY.
1673 * src/filesystem/dir.cc (_Dir): Add nofollow flag to constructor
1674 and pass it to base class constructor.
1675 (directory_iterator): Pass nofollow flag to _Dir constructor.
1676 (fs::recursive_directory_iterator::increment): Likewise.
1677 * src/filesystem/ops.cc (remove_all): Use nofollow option for
1678 directory_iterator constructor. Move error check outside loop.
1679
1680 2022-01-23 Jonathan Wakely <jwakely@redhat.com>
1681
1682 PR libstdc++/104032
1683 * include/std/spanstream (basic_spanbuf(basic_spanbuf&&)): Use
1684 mem-initializer for _M_buf.
1685 (basic_spanbuf::Operator=(basic_spanbuf&&)): Fix ill-formed
1686 member access.
1687 * testsuite/27_io/spanstream/2.cc: New test.
1688
1689 2022-01-23 Jonathan Wakely <jwakely@redhat.com>
1690
1691 * src/c++17/floating_from_chars.cc (USE_STRTOD_FOR_FROM_CHARS):
1692 Define macro for case where std::from_chars is implemented in
1693 terms of strtod, strtof or strtold.
1694 (buffer_resource, valid_fmt, find_end_of_float, pattern)
1695 (from_chars_impl, make_result, reserve_string): Do not define
1696 unless USE_STRTOD_FOR_FROM_CHARS is defined.
1697 (from_chars): Define when at least one of USE_LIB_FAST_FLOAT and
1698 USE_STRTOD_FOR_FROM_CHARS is defined, instead of
1699 _GLIBCXX_HAVE_USELOCALE. Use fast_float for long double when it
1700 is binary64.
1701
1702 2022-01-23 Jonathan Wakely <jwakely@redhat.com>
1703
1704 PR libstdc++/104174
1705 * include/bits/hashtable_policy.h (_Map_base): Add partial
1706 specialization for maps with const key types.
1707 * testsuite/23_containers/unordered_map/104174.cc: New test.
1708
1709 2022-01-23 Jonathan Wakely <jwakely@redhat.com>
1710
1711 PR libstdc++/104019
1712 * include/bits/shared_ptr_base.h (_Sp_counted_base<>::_M_release):
1713 Set members to zero without type punning.
1714
1715 2022-01-21 Jonathan Wakely <jwakely@redhat.com>
1716
1717 * testsuite/20_util/shared_ptr/cons/array.cc: Fix comment.
1718
1719 2022-01-21 Jonathan Wakely <jwakely@redhat.com>
1720
1721 PR libstdc++/87193
1722 PR libstdc++/104019
1723 * include/bits/alloc_traits.h (__cpp_lib_allocator_traits_is_always_equal):
1724 Define as type long.
1725 * include/bits/allocator.h (__cpp_lib_incomplete_container_elements):
1726 Likewise.
1727 * include/bits/basic_string.h (__cpp_lib_string_udls): Likewise.
1728 * include/bits/chrono.h (__cpp_lib_chrono): Likewise.
1729 (__cpp_lib_chrono_udls): Likewise.
1730 * include/bits/move.h (__cpp_lib_addressof_constexpr): Likewise.
1731 * include/bits/node_handle.h (__cpp_lib_node_extract): Likewise.
1732 * include/bits/range_access.h (__cpp_lib_nonmember_container_access):
1733 Likewise.
1734 * include/bits/shared_ptr.h (__cpp_lib_enable_shared_from_this):
1735 Likewise.
1736 * include/bits/stl_algo.h (__cpp_lib_clamp): Likewise.
1737 (__cpp_lib_sample): Likewise.
1738 * include/bits/stl_algobase.h (__cpp_lib_robust_nonmodifying_seq_ops):
1739 Likewise.
1740 * include/bits/stl_function.h (__cpp_lib_transparent_operators):
1741 Likewise.
1742 * include/bits/stl_iterator.h (__cpp_lib_make_reverse_iterator):
1743 Likewise.
1744 * include/bits/stl_map.h (__cpp_lib_map_try_emplace):
1745 Likewise.
1746 * include/bits/stl_tree.h (__cpp_lib_generic_associative_lookup):
1747 Likewise.
1748 * include/bits/unique_ptr.h (__cpp_lib_make_unique):
1749 Likewise.
1750 * include/bits/unordered_map.h (__cpp_lib_unordered_map_try_emplace):
1751 Likewise.
1752 * include/c_global/cmath (__cpp_lib_hypot): Likewise.
1753 * include/c_global/cstddef (__cpp_lib_byte): Likewise.
1754 * include/std/atomic (__cpp_lib_atomic_is_always_lock_free):
1755 Likewise.
1756 * include/std/complex (__cpp_lib_complex_udls): Likewise.
1757 * include/std/filesystem (__cpp_lib_filesystem): Likewise.
1758 * include/std/functional (__cpp_lib_not_fn): Likewise.
1759 (__cpp_lib_boyer_moore_searcher): Likewise.
1760 * include/std/iomanip (__cpp_lib_quoted_string_io): Likewise.
1761 * include/std/mutex (__cpp_lib_scoped_lock): Likewise.
1762 * include/std/numeric (__cpp_lib_gcd_lcm): Likewise.
1763 (__cpp_lib_gcd, __cpp_lib_lcm): Likewise.
1764 * include/std/tuple (__cpp_lib_apply): Likewise.
1765 (__cpp_lib_make_from_tuple): Likewise.
1766 * include/std/type_traits (__cpp_lib_integral_constant_callable)
1767 (__cpp_lib_bool_constant, __cpp_lib_logical_traits)
1768 (__cpp_lib_is_null_pointer, __cpp_lib_transformation_trait_aliases)
1769 (__cpp_lib_result_of_sfinae, __cpp_lib_void_t)
1770 (__cpp_lib_is_swappable, __cpp_lib_is_invocable)
1771 (__cpp_lib_has_unique_object_representations)
1772 (__cpp_lib_is_aggregate): Likewise.
1773 * include/std/version: Likewise.
1774 * libsupc++/new (__cpp_lib_launder): Likewise.
1775
1776 2022-01-21 Jonathan Wakely <jwakely@redhat.com>
1777
1778 * include/std/version (__cpp_lib_shared_ptr_arrays): Fix
1779 condition for C++17 definition.
1780
1781 2022-01-21 Jonathan Wakely <jwakely@redhat.com>
1782
1783 * include/bits/shared_ptr_atomic.h (_Sp_atomic::_Atomic_count):
1784 Add constexpr.
1785 (_Sp_atomic::_M_ptr): Add default member-initializer.
1786 * testsuite/20_util/shared_ptr/atomic/atomic_shared_ptr.cc:
1787 Check constant initialization.
1788 * testsuite/20_util/weak_ptr/atomic_weak_ptr.cc: Likewise.
1789
1790 2022-01-20 Jonathan Wakely <jwakely@redhat.com>
1791
1792 * src/c++11/cxx11-ios_failure.cc (__constinit): Define as
1793 equivalent attribute for Clang.
1794 * src/c++11/future.cc (__constinit): Likewise.
1795 * src/c++11/system_error.cc (__constinit): Likewise.
1796 * src/c++17/memory_resource.cc (__constinit): Likewise.
1797
1798 2022-01-20 Jonathan Wakely <jwakely@redhat.com>
1799
1800 * scripts/testsuite_flags.in: Only add src/filesystem/.libs and
1801 src/libbacktrace/.libs to LDFLAGS if those directories exist.
1802
1803 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1804
1805 * configure.ac (GLIBCXX_ENABLE_DEBUG_FLAGS): Remove -gdwarf-4
1806 from default flags.
1807 * configure: Regenerate.
1808
1809 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1810
1811 PR libstdc++/104123
1812 * testsuite/29_atomics/headers/stdatomic.h/c_compat.cc: Include
1813 <stddef.h>.
1814
1815 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1816
1817 * scripts/testsuite_flags.in: Add src/libbacktrace/.libs to
1818 linker search paths.
1819 * src/Makefile.am: Fix src/debug/libbacktrace build.
1820 * src/Makefile.in: Regenerate.
1821 * src/libbacktrace/Makefile.am: Use per-library CPPFLAGS
1822 variable. Use symlinks for the source files.
1823 * src/libbacktrace/Makefile.in: Regenerate.
1824
1825 2022-01-19 Matthias Kretz <m.kretz@gsi.de>
1826
1827 * include/experimental/bits/simd.h (__floating_point_flags): Do
1828 not rely on math_errhandling to expand to a constant expression.
1829
1830 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1831
1832 * doc/xml/manual/evolution.xml: Document deprecations.
1833 * doc/xml/manual/status_cxx2017.xml: Update status.
1834 * doc/html/*: Regenerate.
1835
1836 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1837
1838 * include/bits/stl_tempbuf.h (get_temporary_buffer): Change
1839 _GLIBCXX14_DEPRECATED to _GLIBCXX17_DEPRECATED.
1840
1841 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1842
1843 * include/bits/stl_pair.h (_PCC::_DeprConsPair): Remove unused
1844 function.
1845
1846 2022-01-19 Jonathan Wakely <jwakely@redhat.com>
1847
1848 PR libstdc++/104101
1849 * include/bits/shared_ptr_atomic.h (_Sp_atomic::_Atomic_count::lock):
1850 Only use __thread_relax if __cpp_lib_atomic_wait is defined.
1851
1852 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1853
1854 PR libstdc++/104099
1855 * include/bits/basic_string.h (basic_string(nullptr_t)): Only
1856 define for C++23.
1857 (operator=(nullptr_t)): Likewise.
1858 * include/bits/cow_string.h: Likewise.
1859 * include/std/string_view (basic_string_view(nullptr_t)):
1860 Likewise.
1861 * testsuite/21_strings/basic_string/cons/char/nullptr.cc: Adjust
1862 expected error. Add examples that become ill-formed in C++23.
1863 * testsuite/21_strings/basic_string_view/cons/char/nonnull.cc:
1864 Adjust expected errors.
1865 * testsuite/21_strings/basic_string_view/cons/wchar_t/nonnull.cc:
1866 Likewise.
1867
1868 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1869
1870 PR libstdc++/104098
1871 * include/bits/stl_iterator.h (reverse_iterator): Check
1872 __cpp_lib_concepts instead of __cplusplus.
1873
1874 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1875
1876 PR libstdc++/101124
1877 * include/bits/stl_pair.h (pair): Adjust constraints on
1878 deprecated constructors accepting literal zero as null pointer
1879 constant. Improve wording of deprecated attribute.
1880 * testsuite/20_util/pair/cons/99957.cc: Check that deprecated
1881 constructors do not cause ambiguities for copyable types.
1882
1883 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1884
1885 * include/bits/stl_function.h (ptr_fun): Fix suggestion for
1886 non-deprecated alternative.
1887
1888 2022-01-18 Tom Honermann <tom@honermann.net>
1889
1890 * acinclude.m4: Define config macros if uchar.h provides
1891 c8rtomb() and mbrtoc8().
1892 * config.h.in: Regenerate.
1893 * configure: Regenerate.
1894 * include/c_compatibility/uchar.h (c8rtomb, mbrtoc8): Define.
1895 * include/c_global/cuchar (c8rtomb, mbrtoc8): Likewise.
1896 * include/c_std/cuchar (c8rtomb, mbrtoc8): Likewise.
1897 * testsuite/21_strings/headers/cuchar/functions_std_cxx20.cc:
1898 New test.
1899 * testsuite/21_strings/headers/cuchar/functions_std_fchar8_t.cc:
1900 New test.
1901
1902 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1903
1904 * include/Makefile.am: Install new header.
1905 * include/Makefile.in: Regenerate.
1906 * include/c_compatibility/stdatomic.h: New file.
1907 * testsuite/29_atomics/headers/stdatomic.h/c_compat.cc: New test.
1908
1909 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1910
1911 PR libstdc++/104080
1912 * src/c++17/fast_float/LOCAL_PATCHES: Update.
1913 * src/c++17/fast_float/fast_float.h (FASTFLOAT_IS_BIG_ENDIAN):
1914 Define in terms of __BYTE_ORDER__.
1915
1916 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1917
1918 PR libstdc++/104080
1919 * src/c++17/fast_float/LOCAL_PATCHES: UPDATE.
1920 * src/c++17/fast_float/fast_float.h (round): Use explicit
1921 template argument list for std::min.
1922
1923 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1924
1925 * doc/xml/manual/status_cxx2017.xml: Update C++17 status.
1926 * doc/xml/manual/status_cxx2020.xml: Use 12.1 instead of 12 for
1927 upcoming release.
1928 * doc/html/manual/status.html: Regenerate.
1929
1930 2022-01-18 Jonathan Wakely <jwakely@redhat.com>
1931
1932 * acinclude.m4 (GLIBCXX_ENABLE_FULLY_DYNAMIC_STRING): Improve
1933 comments.
1934 * configure: Regenerate.
1935
1936 2022-01-17 Patrick Palka <ppalka@redhat.com>
1937
1938 * src/c++17/floating_from_chars.cc: (USE_LIB_FAST_FLOAT):
1939 Conditionally define, and use it to conditionally include
1940 fast_float.
1941 (from_chars): Use fast_float for float and double when
1942 USE_LIB_FAST_FLOAT.
1943
1944 2022-01-17 Patrick Palka <ppalka@redhat.com>
1945
1946 * src/c++17/fast_float/LOCAL_PATCHES: Update.
1947 * src/c++17/fast_float/fast_float.h (from_chars_advanced): In
1948 case of over/underflow, return errc::result_out_of_range and don't
1949 modify 'value'.
1950
1951 2022-01-17 Patrick Palka <ppalka@redhat.com>
1952
1953 * src/c++17/fast_float/LOCAL_PATCHES: Update.
1954 * src/c++17/fast_float/fast_float.h: Apply local modifications.
1955
1956 2022-01-17 Patrick Palka <ppalka@redhat.com>
1957
1958 * src/c++17/fast_float/LOCAL_PATCHES: New file.
1959 * src/c++17/fast_float/MERGE: New file.
1960 * src/c++17/fast_float/README.md: New file, copied from the
1961 fast_float repository.
1962 * src/c++17/fast_float/fast_float.h: New file, an amalgamation
1963 of the fast_float library.
1964
1965 2022-01-17 Patrick Palka <ppalka@redhat.com>
1966
1967 * src/c++17/floating_from_chars.cc: Include <bit>.
1968 (ascii_to_hexit, starts_with_ci): Conditionally define.
1969 (__floating_from_chars_hex): Conditionally define.
1970 (from_chars): Use __floating_from_chars_hex for
1971 chars_format::hex parsing of binary32/64 float/double.
1972 (testsuite/20_util/from_chars/7.cc): New test.
1973 * testsuite/20_util/from_chars/7.cc: New file.
1974
1975 2022-01-17 Jonathan Wakely <jwakely@redhat.com>
1976
1977 * acinclude.m4 (GLIBCXX_ENABLE_BACKTRACE): New macro.
1978 * configure.ac: Use GLIBCXX_ENABLE_BACKTRACE.
1979 * include/Makefile.am: Add new header.
1980 * include/Makefile.in: Regenerate.
1981 * include/std/stacktrace: New header.
1982 * include/std/version (__cpp_lib_stacktrace): Define.
1983 * Makefile.in: Regenerate.
1984 * config.h.in: Regenerate.
1985 * configure: Regenerate.
1986 * doc/Makefile.in: Regenerate.
1987 * libsupc++/Makefile.in: Regenerate.
1988 * po/Makefile.in: Regenerate.
1989 * python/Makefile.in: Regenerate.
1990 * src/Makefile.am: Regenerate.
1991 * src/Makefile.in: Regenerate.
1992 * src/c++11/Makefile.in: Regenerate.
1993 * src/c++17/Makefile.in: Regenerate.
1994 * src/c++20/Makefile.in: Regenerate.
1995 * src/c++98/Makefile.in: Regenerate.
1996 * src/filesystem/Makefile.in: Regenerate.
1997 * testsuite/Makefile.in: Regenerate.
1998 * src/libbacktrace/Makefile.am: New file.
1999 * src/libbacktrace/Makefile.in: New file.
2000 * src/libbacktrace/backtrace-rename.h: New file.
2001 * src/libbacktrace/backtrace-supported.h.in: New file.
2002 * src/libbacktrace/config.h.in: New file.
2003 * testsuite/lib/libstdc++.exp (check_effective_target_stacktrace):
2004 New proc.
2005 * testsuite/20_util/stacktrace/entry.cc: New test.
2006 * testsuite/20_util/stacktrace/synopsis.cc: New test.
2007 * testsuite/20_util/stacktrace/version.cc: New test.
2008
2009 2022-01-17 Jonathan Wakely <jwakely@redhat.com>
2010
2011 * doc/xml/manual/status_cxx2020.xml: Use final C++20 option
2012 names.
2013 * doc/html/manual/status.html: Regenerate.
2014
2015 2022-01-17 Jonathan Wakely <jwakely@redhat.com>
2016
2017 PR libstdc++/103650
2018 * include/Makefile.am: Rename LT_OBJDIR and STDC_HEADERS.
2019 * include/Makefile.in: Regenerate.
2020 * testsuite/17_intro/headers/c++1998/103650.cc: New test.
2021
2022 2022-01-17 Matthias Kretz <m.kretz@gsi.de>
2023
2024 * include/experimental/bits/simd.h (__floating_point_flags): Do
2025 not rely on the presence of the math_errhandling macro.
2026
2027 2022-01-17 Jonathan Wakely <jwakely@redhat.com>
2028
2029 * include/bits/shared_ptr_atomic.h (_Sp_atomic): Add typename
2030 to qualified-id for dependent type.
2031
2032 2022-01-17 Jonathan Wakely <jwakely@redhat.com>
2033
2034 * doc/xml/manual/status_cxx2020.xml: Update.
2035 * doc/html/manual/status.html: Regenerate.
2036
2037 2022-01-17 Jonathan Wakely <jwakely@redhat.com>
2038 Thomas Rodgers <trodgers@redhat.com>
2039
2040 * include/bits/shared_ptr_atomic.h (__cpp_lib_atomic_shared_ptr):
2041 New macro.
2042 (_Sp_atomic): New class template.
2043 (atomic<shared_ptr<T>>, atomic<weak_ptr<T>>): New partial
2044 specializations.
2045 * include/bits/shared_ptr_base.h (__shared_count, __weak_count)
2046 (__shared_ptr, __weak_ptr): Declare _Sp_atomic as a friend.
2047 * include/std/version (__cpp_lib_atomic_shared_ptr): New macro.
2048 * testsuite/20_util/shared_ptr/atomic/atomic_shared_ptr.cc: New
2049 test.
2050 * testsuite/20_util/weak_ptr/atomic_weak_ptr.cc: New test.
2051
2052 2022-01-15 Matthias Kretz <m.kretz@gsi.de>
2053
2054 * include/experimental/bits/simd.h: Move feature detection bools
2055 and add __have_avx512bitalg, __have_avx512vbmi2,
2056 __have_avx512vbmi, __have_avx512ifma, __have_avx512cd,
2057 __have_avx512vnni, __have_avx512vpopcntdq.
2058 (__detail::__machine_flags): New function which returns a unique
2059 uint64 depending on relevant -m and -f flags.
2060 (__detail::__odr_helper): New type alias for either an anonymous
2061 type or a type specialized with the __machine_flags number.
2062 (_SimdIntOperators): Change template parameters from _Impl to
2063 _Tp, _Abi because _Impl now has an __odr_helper parameter which
2064 may be _OdrEnforcer from the anonymous namespace, which makes
2065 for a bad base class.
2066 (many): Either add __odr_helper template parameter or mark as
2067 always_inline.
2068 * include/experimental/bits/simd_detail.h: Add defines for
2069 AVX512BITALG, AVX512VBMI2, AVX512VBMI, AVX512IFMA, AVX512CD,
2070 AVX512VNNI, AVX512VPOPCNTDQ, and AVX512VP2INTERSECT.
2071 * include/experimental/bits/simd_builtin.h: Add __odr_helper
2072 template parameter or mark as always_inline.
2073 * include/experimental/bits/simd_fixed_size.h: Ditto.
2074 * include/experimental/bits/simd_math.h: Ditto.
2075 * include/experimental/bits/simd_scalar.h: Ditto.
2076 * include/experimental/bits/simd_neon.h: Add __odr_helper
2077 template parameter.
2078 * include/experimental/bits/simd_ppc.h: Ditto.
2079 * include/experimental/bits/simd_x86.h: Ditto.
2080
2081 2022-01-14 Uroš Bizjak <ubizjak@gmail.com>
2082
2083 * testsuite/22_locale/numpunct/members/char/3.cc:
2084 Require pt_PT locale instead of nl_NL.
2085 (test02): Use pt_PT locale instead of nl_NL.
2086
2087 2022-01-14 Jonathan Wakely <jwakely@redhat.com>
2088
2089 PR libstdc++/91260
2090 PR libstdc++/91383
2091 PR libstdc++/95065
2092 * include/backward/binders.h (bind1st, bind2nd): Add deprecated
2093 attribute.
2094 * include/bits/refwrap.h (_Maybe_unary_or_binary_function):
2095 Disable deprecated warnings for base classes.
2096 (_Reference_wrapper_base): Likewise.
2097 * include/bits/shared_ptr_base.h (_Sp_owner_less): Likewise.
2098 * include/bits/stl_bvector.h (_Bit_iterator_base): Likewise.
2099 * include/bits/stl_function.h (unary_function, binary_function):
2100 Add deprecated attribute.
2101 (unary_negate, not1, binary_negate, not2, ptr_fun)
2102 (pointer_to_unary_function, pointer_to_binary_function)
2103 (mem_fun_t, const_mem_fun_t, mem_fun_ref_t, const_mem_fun_ref_t)
2104 (mem_fun1_t, const_mem_fun1_t, mem_fun_ref1_t)
2105 (const_mem_fun1_ref_t, mem_fun, mem_fun_ref): Add deprecated
2106 attributes.
2107 * include/bits/stl_iterator.h: Disable deprecated warnings for
2108 std::iterator base classes.
2109 * include/bits/stl_iterator_base_types.h (iterator): Add
2110 deprecated attribute.
2111 * include/bits/stl_map.h (map::value_compare): Disable
2112 deprecated warnings for base class.
2113 * include/bits/stl_multimap.h (multimap::value_compare):
2114 Likewise.
2115 * include/bits/stl_raw_storage_iter.h (raw_storage_iterator):
2116 Add deprecated attribute.
2117 * include/bits/stl_tempbuf.h (get_temporary_buffer): Likewise.
2118 * include/bits/stream_iterator.h: Disable deprecated warnings.
2119 * include/bits/streambuf_iterator.h: Likewise.
2120 * include/ext/bitmap_allocator.h: Remove unary_function base
2121 classes.
2122 * include/ext/functional: Disable deprecated warnings.
2123 * include/ext/rope: Likewise.
2124 * include/ext/throw_allocator.h: Likewise.
2125 * include/std/type_traits (result_of): Add deprecated attribute.
2126 * include/tr1/functional: Disable deprecated warnings.
2127 * include/tr1/functional_hash.h: Likewise.
2128 * testsuite/20_util/function_objects/binders/1.cc: Add
2129 -Wno-disable-deprecations.
2130 * testsuite/20_util/function_objects/binders/3113.cc: Likewise.
2131 * testsuite/20_util/function_objects/constexpr.cc: Add
2132 dg-warning.
2133 * testsuite/20_util/raw_storage_iterator/base.cc: Likewise.
2134 * testsuite/20_util/raw_storage_iterator/dr2127.cc: Likewise.
2135 * testsuite/20_util/raw_storage_iterator/requirements/base_classes.cc:
2136 Likewise.
2137 * testsuite/20_util/raw_storage_iterator/requirements/explicit_instantiation/1.cc:
2138 Likewise.
2139 * testsuite/20_util/raw_storage_iterator/requirements/typedefs.cc:
2140 Likewise.
2141 * testsuite/20_util/reference_wrapper/24803.cc:
2142 Likewise.
2143 * testsuite/20_util/reference_wrapper/typedefs.cc: Enable for
2144 C++20 and check for absence of nested types.
2145 * testsuite/20_util/shared_ptr/comparison/less.cc: Remove
2146 std::binary_function base class.
2147 * testsuite/20_util/temporary_buffer.cc: Add dg-warning.
2148 * testsuite/21_strings/basic_string/cons/char/69092.cc: Remove
2149 std::iterator base class.
2150 * testsuite/24_iterators/back_insert_iterator/requirements/base_classes.cc:
2151 Likewise.
2152 * testsuite/24_iterators/front_insert_iterator/requirements/base_classes.cc:
2153 Likewise.
2154 * testsuite/24_iterators/insert_iterator/requirements/base_classes.cc:
2155 Likewise.
2156 * testsuite/24_iterators/istream_iterator/requirements/base_classes.cc:
2157 Likewise.
2158 * testsuite/24_iterators/istreambuf_iterator/92285.cc:
2159 Likewise.
2160 * testsuite/24_iterators/istreambuf_iterator/requirements/base_classes.cc:
2161 Likewise.
2162 * testsuite/24_iterators/ostream_iterator/requirements/base_classes.cc:
2163 Likewise.
2164 * testsuite/24_iterators/ostreambuf_iterator/requirements/base_classes.cc:
2165 Likewise.
2166 * testsuite/24_iterators/reverse_iterator/requirements/base_classes.cc:
2167 Likewise.
2168 * testsuite/25_algorithms/copy/34595.cc:
2169 Likewise.
2170 * testsuite/25_algorithms/minmax/3.cc: Remove std::binary_function
2171 base class.
2172 * testsuite/25_algorithms/all_of/requirements/explicit_instantiation/2.cc:
2173 Disable deprecated warnings.
2174 * testsuite/25_algorithms/all_of/requirements/explicit_instantiation/pod.cc:
2175 Likewise.
2176 * testsuite/25_algorithms/any_of/requirements/explicit_instantiation/2.cc:
2177 Likewise.
2178 * testsuite/25_algorithms/any_of/requirements/explicit_instantiation/pod.cc:
2179 Likewise.
2180 * testsuite/25_algorithms/copy_if/requirements/explicit_instantiation/2.cc:
2181 Likewise.
2182 * testsuite/25_algorithms/copy_if/requirements/explicit_instantiation/pod.cc:
2183 Likewise.
2184 * testsuite/25_algorithms/count_if/requirements/explicit_instantiation/2.cc:
2185 Likewise.
2186 * testsuite/25_algorithms/count_if/requirements/explicit_instantiation/pod.cc:
2187 Likewise.
2188 * testsuite/25_algorithms/find_end/requirements/explicit_instantiation/2.cc:
2189 Likewise.
2190 * testsuite/25_algorithms/find_end/requirements/explicit_instantiation/pod.cc:
2191 Likewise.
2192 * testsuite/25_algorithms/find_first_of/requirements/explicit_instantiation/2.cc:
2193 Likewise.
2194 * testsuite/25_algorithms/find_first_of/requirements/explicit_instantiation/pod.cc:
2195 Likewise.
2196 * testsuite/25_algorithms/find_if/requirements/explicit_instantiation/2.cc:
2197 Likewise.
2198 * testsuite/25_algorithms/find_if/requirements/explicit_instantiation/pod.cc:
2199 Likewise.
2200 * testsuite/25_algorithms/find_if_not/requirements/explicit_instantiation/2.cc:
2201 Likewise.
2202 * testsuite/25_algorithms/find_if_not/requirements/explicit_instantiation/pod.cc:
2203 Likewise.
2204 * testsuite/25_algorithms/for_each/requirements/explicit_instantiation/2.cc:
2205 Likewise.
2206 * testsuite/25_algorithms/for_each/requirements/explicit_instantiation/pod.cc:
2207 Likewise.
2208 * testsuite/25_algorithms/is_partitioned/requirements/explicit_instantiation/2.cc:
2209 Likewise.
2210 * testsuite/25_algorithms/is_partitioned/requirements/explicit_instantiation/pod.cc:
2211 Likewise.
2212 * testsuite/25_algorithms/is_permutation/requirements/explicit_instantiation/2.cc:
2213 Likewise.
2214 * testsuite/25_algorithms/is_permutation/requirements/explicit_instantiation/pod.cc:
2215 Likewise.
2216 * testsuite/25_algorithms/none_of/requirements/explicit_instantiation/2.cc:
2217 Likewise.
2218 * testsuite/25_algorithms/none_of/requirements/explicit_instantiation/pod.cc:
2219 Likewise.
2220 * testsuite/25_algorithms/partition/requirements/explicit_instantiation/2.cc:
2221 Likewise.
2222 * testsuite/25_algorithms/partition/requirements/explicit_instantiation/pod.cc:
2223 Likewise.
2224 * testsuite/25_algorithms/partition_copy/requirements/explicit_instantiation/2.cc:
2225 Likewise.
2226 * testsuite/25_algorithms/partition_copy/requirements/explicit_instantiation/pod.cc:
2227 Likewise.
2228 * testsuite/25_algorithms/partition_point/requirements/explicit_instantiation/2.cc:
2229 Likewise.
2230 * testsuite/25_algorithms/partition_point/requirements/explicit_instantiation/pod.cc:
2231 Likewise.
2232 * testsuite/25_algorithms/random_shuffle/requirements/explicit_instantiation/2.cc:
2233 Likewise.
2234 * testsuite/25_algorithms/random_shuffle/requirements/explicit_instantiation/pod.cc:
2235 Likewise.
2236 * testsuite/25_algorithms/remove_copy_if/requirements/explicit_instantiation/2.cc:
2237 Likewise.
2238 * testsuite/25_algorithms/remove_copy_if/requirements/explicit_instantiation/pod.cc:
2239 Likewise.
2240 * testsuite/25_algorithms/remove_if/requirements/explicit_instantiation/2.cc:
2241 Likewise.
2242 * testsuite/25_algorithms/remove_if/requirements/explicit_instantiation/pod.cc:
2243 Likewise.
2244 * testsuite/25_algorithms/replace_copy_if/requirements/explicit_instantiation/2.cc:
2245 Likewise.
2246 * testsuite/25_algorithms/replace_copy_if/requirements/explicit_instantiation/pod.cc:
2247 Likewise.
2248 * testsuite/25_algorithms/replace_if/requirements/explicit_instantiation/2.cc:
2249 Likewise.
2250 * testsuite/25_algorithms/replace_if/requirements/explicit_instantiation/pod.cc:
2251 Likewise.
2252 * testsuite/25_algorithms/search/requirements/explicit_instantiation/2.cc:
2253 Likewise.
2254 * testsuite/25_algorithms/search/requirements/explicit_instantiation/pod.cc:
2255 Likewise.
2256 * testsuite/25_algorithms/search_n/requirements/explicit_instantiation/2.cc:
2257 Likewise.
2258 * testsuite/25_algorithms/search_n/requirements/explicit_instantiation/pod.cc:
2259 Likewise.
2260 * testsuite/25_algorithms/stable_partition/requirements/explicit_instantiation/2.cc:
2261 Likewise.
2262 * testsuite/25_algorithms/stable_partition/requirements/explicit_instantiation/pod.cc:
2263 Likewise.
2264 * testsuite/25_algorithms/transform/requirements/explicit_instantiation/2.cc:
2265 Likewise.
2266 * testsuite/25_algorithms/transform/requirements/explicit_instantiation/pod.cc:
2267 Likewise.
2268 * testsuite/27_io/basic_filebuf/underflow/wchar_t/9178.cc: Add
2269 dg-warning.
2270 * testsuite/ext/pb_ds/example/priority_queue_erase_if.cc:
2271 Likewise.
2272 * testsuite/ext/pb_ds/example/priority_queue_split_join.cc:
2273 Likewise.
2274 * testsuite/tr1/3_function_objects/reference_wrapper/typedefs.cc:
2275 Disable deprecated warnings.
2276 * testsuite/tr1/6_containers/hash/requirements/base_classes.cc:
2277 Likewise.
2278 * testsuite/util/regression/trait/erase_if_fn.hpp: Remove
2279 std::unary_function base classes.
2280 * testsuite/util/testsuite_iterators.h (output_iterator_wrapper):
2281 Remove std::iterator base classes.
2282
2283 2022-01-14 Jonathan Wakely <jwakely@redhat.com>
2284
2285 * include/bits/shared_ptr.h (__cpp_lib_shared_ptr_weak_type):
2286 Correct type of macro value.
2287 (shared_ptr): Add additional friend declarations.
2288 (make_shared, allocate_shared): Constrain existing overloads and
2289 remove static_assert.
2290 * include/bits/shared_ptr_base.h (__cpp_lib_smart_ptr_for_overwrite):
2291 New macro.
2292 (_Sp_counted_ptr_inplace<T, Alloc, Lp>): New partial
2293 specialization for use with make_shared_for_overwrite.
2294 (__cpp_lib_shared_ptr_arrays): Update value for C++20.
2295 (_Sp_counted_array_base): New class template.
2296 (_Sp_counted_array): New class template.
2297 (__shared_count(_Tp*&, const _Sp_counted_array_base&, _Init)):
2298 New constructor for allocating shared arrays.
2299 (__shared_ptr(const _Sp_counted_array_base&, _Init)): Likewise.
2300 * include/std/version (__cpp_lib_shared_ptr_weak_type): Correct
2301 type.
2302 (__cpp_lib_shared_ptr_arrays): Update value for C++20.
2303 (__cpp_lib_smart_ptr_for_overwrite): New macro.
2304 * testsuite/20_util/shared_ptr/creation/99006.cc: Adjust
2305 expected errors.
2306 * testsuite/20_util/shared_ptr/creation/array.cc: New test.
2307 * testsuite/20_util/shared_ptr/creation/overwrite.cc: New test.
2308 * testsuite/20_util/shared_ptr/creation/version.cc: New test.
2309 * testsuite/20_util/unique_ptr/creation/for_overwrite.cc: Check
2310 feature test macro. Test non-trivial default-initialization.
2311
2312 2022-01-14 Jonathan Wakely <jwakely@redhat.com>
2313
2314 * include/bits/stl_construct.h (_Construct, _Construct_novalue):
2315 Also cast away cv-qualifiers when converting pointer to void.
2316 * testsuite/20_util/allocator/void.cc: Test construct function
2317 with cv-qualified types.
2318
2319 2022-01-14 Jonathan Wakely <jwakely@redhat.com>
2320
2321 PR libstdc++/103992
2322 * include/bits/stl_iterator.h (common_iterator): Use
2323 std::construct_at instead of placement new.
2324 * testsuite/24_iterators/common_iterator/1.cc: Check copy
2325 construction is usable in constant expressions.
2326
2327 2022-01-14 Jonathan Wakely <jwakely@redhat.com>
2328
2329 * doc/xml/manual/status_cxx2011.xml: Document new tokens
2330 accepted by std::random_device constructor.
2331 * doc/html/manual/status.html: Regenerate.
2332
2333 2022-01-12 Patrick Palka <ppalka@redhat.com>
2334
2335 * testsuite/20_util/to_chars/103955.cc: Add explicit dg-do
2336 directive.
2337
2338 2022-01-12 Patrick Palka <ppalka@redhat.com>
2339
2340 PR libstdc++/103955
2341 * src/c++17/floating_to_chars.cc (__floating_to_chars_hex):
2342 Track the excess precision separately from the effective
2343 precision. Avoid overflow in bounds check by splitting it into
2344 two checks.
2345 (__floating_to_chars_precision): Avoid overflow in bounds checks
2346 similarly.
2347 * testsuite/20_util/to_chars/103955.cc: New test.
2348
2349 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
2350
2351 PR libstdc++/103726
2352 * include/Makefile.am: Install <source_location> for
2353 freestanding.
2354 * include/Makefile.in: Regenerate.
2355 * include/std/version (__cpp_lib_source_location): Define for
2356 freestanding.
2357
2358 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
2359
2360 * include/std/ranges (ranges::lazy_split_view::_InnerIter::end()):
2361 Add neoxcept (LWG 3593).
2362
2363 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
2364
2365 * include/std/ranges (ranges::__detail::__box): Add constexpr to
2366 assignment operators (LWG 3572).
2367 * testsuite/std/ranges/adaptors/filter.cc: Check assignment of a
2368 view that uses copyable-box.
2369
2370 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
2371
2372 PR libstdc++/103726
2373 * include/Makefile.am: Install <coroutine> for freestanding.
2374 * include/Makefile.in: Regenerate.
2375 * include/std/coroutine: Adjust headers and preprocessor
2376 conditions.
2377 (__coroutine_traits_impl): Use concepts when available.
2378 [_GLIBCXX_HOSTED] (hash<coroutine_handle>): Define.
2379
2380 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
2381
2382 * include/std/ostream (operator<<(basic_ostream&, charT)):
2383 Use unformatted input if no padding is needed.
2384 (operator<<(basic_ostream<char>&, char)): Likewise.
2385
2386 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
2387
2388 PR libstdc++/103891
2389 * include/bits/c++config (_GLIBCXX_HAVE_COND_TRIVIAL_SPECIAL_MEMBERS):
2390 Define.
2391 * include/std/variant (__cpp_lib_variant): Only define C++20
2392 value when the compiler is known to support conditionally
2393 trivial destructors.
2394 * include/std/version (__cpp_lib_variant): Likewise.
2395
2396 2022-01-11 Jonathan Wakely <jwakely@redhat.com>
2397
2398 * include/bits/stl_iterator.h (common_iterator): Add constexpr
2399 to all member functions (LWG 3574).
2400 * testsuite/24_iterators/common_iterator/1.cc: Evaluate some
2401 tests as constant expressions.
2402 * testsuite/24_iterators/common_iterator/2.cc: Likewise.
2403
2404 2022-01-10 Jakub Jelinek <jakub@redhat.com>
2405
2406 PR libstdc++/77760
2407 * include/bits/locale_facets_nonio.h (__time_get_state): New struct.
2408 (time_get::_M_extract_via_format): Declare new method with
2409 __time_get_state& as an extra argument.
2410 * include/bits/locale_facets_nonio.tcc (_M_extract_via_format): Add
2411 __state argument, set various fields in it while parsing. Handle %j,
2412 %U, %w and %W, fix up handling of %y, %Y and %C, don't adjust tm_hour
2413 for %p immediately. Add a wrapper around the method without the
2414 __state argument for backwards compatibility.
2415 (_M_extract_num): Remove all __len == 4 special cases.
2416 (time_get::do_get_time, time_get::do_get_date, time_get::do_get): Zero
2417 initialize __state, pass it to _M_extract_via_format and finalize it
2418 at the end.
2419 (do_get_year): For 1-2 digit parsed years, map 0-68 to 2000-2068,
2420 69-99 to 1969-1999. For 3-4 digit parsed years use that as year.
2421 (get): If do_get isn't overloaded from the locale_facets_nonio.tcc
2422 version, don't call do_get but call _M_extract_via_format instead to
2423 pass around state.
2424 * config/abi/pre/gnu.ver (GLIBCXX_3.4.30): Export _M_extract_via_format
2425 with extra __time_get_state and __time_get_state::_M_finalize_state.
2426 * src/c++98/locale_facets.cc (is_leap, day_of_the_week,
2427 day_of_the_year): New functions in anon namespace.
2428 (mon_yday): New var in anon namespace.
2429 (__time_get_state::_M_finalize_state): Define.
2430 * testsuite/22_locale/time_get/get/char/4.cc: New test.
2431 * testsuite/22_locale/time_get/get/wchar_t/4.cc: New test.
2432 * testsuite/22_locale/time_get/get_year/char/1.cc (test01): Parse 197
2433 as year 197AD instead of error.
2434 * testsuite/22_locale/time_get/get_year/char/5.cc (test01): Parse 1 as
2435 year 2001 instead of error.
2436 * testsuite/22_locale/time_get/get_year/char/6.cc: New test.
2437 * testsuite/22_locale/time_get/get_year/wchar_t/1.cc (test01): Parse
2438 197 as year 197AD instead of error.
2439 * testsuite/22_locale/time_get/get_year/wchar_t/5.cc (test01): Parse
2440 1 as year 2001 instead of error.
2441 * testsuite/22_locale/time_get/get_year/wchar_t/6.cc: New test.
2442
2443 2022-01-10 Jonathan Wakely <jwakely@redhat.com>
2444
2445 PR libstdc++/103866
2446 * acinclude.m4 (GLIBCXX_COMPUTE_STDIO_INTEGER_CONSTANTS): Do
2447 nothing for freestanding builds.
2448 (GLIBCXX_ENABLE_HOSTED): Define FREESTANDING_FLAGS.
2449 * configure.ac: Do not use AC_LIBTOOL_DLOPEN when configured
2450 with --without-headers. Do not use GCC_HEADER_STDINT for
2451 freestanding builds.
2452 * libsupc++/Makefile.am (HOSTED_CXXFLAGS): Use -ffreestanding
2453 for freestanding builds.
2454 * configure: Regenerate.
2455 * Makefile.in: Regenerate.
2456 * doc/Makefile.in: Regenerate.
2457 * include/Makefile.in: Regenerate.
2458 * libsupc++/Makefile.in: Regenerate.
2459 * po/Makefile.in: Regenerate.
2460 * python/Makefile.in: Regenerate.
2461 * src/Makefile.in: Regenerate.
2462 * src/c++11/Makefile.in: Regenerate.
2463 * src/c++17/Makefile.in: Regenerate.
2464 * src/c++20/Makefile.in: Regenerate.
2465 * src/c++98/Makefile.in: Regenerate.
2466 * src/filesystem/Makefile.in: Regenerate.
2467 * testsuite/Makefile.in: Regenerate.
2468
2469 2022-01-10 Jonathan Wakely <jwakely@redhat.com>
2470
2471 * testsuite/28_regex/algorithms/regex_replace/char/103664.cc:
2472 Add dg-timeout-factor directive.
2473 * testsuite/28_regex/basic_regex/84110.cc: Likewise.
2474 * testsuite/28_regex/basic_regex/ctors/char/other.cc: Likewise.
2475 * testsuite/28_regex/match_results/102667.cc: Likewise.
2476
2477 2022-01-10 Jonathan Wakely <jwakely@redhat.com>
2478
2479 * doc/xml/manual/using.xml: Update documentation around default
2480 -std option.
2481 * doc/html/*: Regenerate.
2482
2483 2022-01-10 Jonathan Wakely <jwakely@redhat.com>
2484
2485 PR libstdc++/100017
2486 * src/c++17/Makefile.am (AM_CXXFLAGS): Add -nostdinc++.
2487 * src/c++17/Makefile.in: Regenerate.
2488
2489 2022-01-09 Sandra Loosemore <sandra@codesourcery.com>
2490
2491 * testsuite/18_support/type_info/constexpr.cc: Add explicit
2492 -fdelete-null-pointer-checks option.
2493
2494 2022-01-06 Pavel I. Kryukov <pavel.kryukov@phystech.edu>
2495 Jonathan Wakely <jwakely@redhat.com>
2496
2497 PR libstdc++/103853
2498 * include/bits/forward_list.tcc (forward_list::merge): Check for
2499 self-merge.
2500 * testsuite/23_containers/forward_list/operations/merge.cc: New test.
2501
2502 2022-01-06 Jonathan Wakely <jwakely@redhat.com>
2503
2504 * include/bits/regex.h (basic_regex, match_results): Qualify
2505 name in friend declaration, to work around Clang bug.
2506
2507 2022-01-06 Jonathan Wakely <jwakely@redhat.com>
2508
2509 * testsuite/ext/rope/pthread7-rope.cc: Add dg-timeout-factor.
2510
2511 2022-01-06 Jonathan Wakely <jwakely@redhat.com>
2512
2513 PR libstdc++/103911
2514 * include/std/charconv (__from_chars_alpha_to_num): Return
2515 char instead of unsigned char. Change invalid return value to
2516 127 instead of using numeric trait.
2517 (__from_chars_alnum): Fix comment. Do not use std::isdigit.
2518 Change type of variable to char.
2519
2520 2022-01-05 François Dumont <fdumont@gcc.gnu.org>
2521
2522 PR libstdc++/68303
2523 * include/bits/hashtable_policy.h
2524 (_Hashtable_hash_traits<_Hash>): New.
2525 (_Hash_code_base<>::_M_hash_code(const _Hash_node_value<>&)): New.
2526 (_Hashtable_base<>::_M_key_equals): New.
2527 (_Hashtable_base<>::_M_equals): Use latter.
2528 (_Hashtable_base<>::_M_key_equals_tr): New.
2529 (_Hashtable_base<>::_M_equals_tr): Use latter.
2530 * include/bits/hashtable.h
2531 (_Hashtable<>::__small_size_threshold()): New, use _Hashtable_hash_traits.
2532 (_Hashtable<>::find): Loop through elements to look for key if size is lower
2533 than __small_size_threshold().
2534 (_Hashtable<>::_M_emplace(true_type, _Args&&...)): Likewise.
2535 (_Hashtable<>::_M_insert_unique(_Kt&&, _Args&&, const _NodeGenerator&)): Likewise.
2536 (_Hashtable<>::_M_compute_hash_code(const_iterator, const key_type&)): New.
2537 (_Hashtable<>::_M_emplace(const_iterator, false_type, _Args&&...)): Use latter.
2538 (_Hashtable<>::_M_find_before_node(const key_type&)): New.
2539 (_Hashtable<>::_M_erase(true_type, const key_type&)): Use latter.
2540 (_Hashtable<>::_M_erase(false_type, const key_type&)): Likewise.
2541 * src/c++11/hashtable_c++0x.cc: Include <bits/functional_hash.h>.
2542 * testsuite/util/testsuite_performance.h
2543 (report_performance): Use 9 width to display memory.
2544 * testsuite/performance/23_containers/insert_erase/unordered_small_size.cc:
2545 New performance test case.
2546
2547 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2548
2549 PR libstdc++/103919
2550 * include/bits/basic_string.h (basic_string(const T&, size_t, size_t)):
2551 Relax constraints on string_view parameter.
2552 * include/bits/cow_string.h (basic_string(const T&, size_t, size_t)):
2553 Likewise.
2554 * testsuite/21_strings/basic_string/cons/char/103919.cc: New test.
2555
2556 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2557
2558 * config/abi/pre/gnu.ver (GLIBCXX_3.4.30): Export new symbol for
2559 ARM EABI.
2560 * include/bits/c++config (_GLIBCXX23_CONSTEXPR): Define.
2561 * include/std/version (__cpp_lib_constexpr_typeinfo): Define.
2562 * libsupc++/tinfo.cc: Add #error to ensure non-inline definition
2563 is emitted.
2564 (type_info::__equal): Define alias symbol.
2565 * libsupc++/typeinfo (type_info::before): Combine different
2566 implementations into one.
2567 (type_info::operator==): Likewise. Use address equality for
2568 constant evaluation. Call __equal for targets that require the
2569 definition to be non-inline.
2570 * testsuite/18_support/type_info/constexpr.cc: New test.
2571
2572 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2573
2574 * src/c++11/cxx11-ios_failure.cc (io_error_category): Define
2575 class and virtual functions as 'final'.
2576 (io_category_instance): Use constinit union to make the object
2577 immortal.
2578 * src/c++11/future.cc (future_error_category): Define class and
2579 virtual functions as 'final'.
2580 (future_category_instance): Use constinit union.
2581
2582 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2583
2584 * python/libstdcxx/v6/printers.py (StdErrorCodePrinter): Strip
2585 versioned namespace from the type name that is printed.
2586
2587 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2588
2589 * python/libstdcxx/v6/printers.py (StdRegexStatePrinter): New
2590 printer for std::regex NFA states.
2591
2592 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2593
2594 * testsuite/23_containers/forward_list/operations/1.cc: Fill in
2595 placeholders in comments.
2596 * testsuite/23_containers/forward_list/operations/2.cc:
2597 Likewise.
2598 * testsuite/23_containers/forward_list/operations/3.cc:
2599 Likewise.
2600 * testsuite/23_containers/forward_list/operations/4.cc:
2601 Likewise.
2602 * testsuite/23_containers/forward_list/operations/5.cc:
2603 Likewise.
2604 * testsuite/23_containers/forward_list/operations/6.cc:
2605 Likewise.
2606 * testsuite/23_containers/forward_list/operations/7.cc:
2607 Likewise.
2608
2609 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2610
2611 PR libstdc++/103848
2612 * include/bits/stl_deque.h (operator-): Do not use 0 as null
2613 pointer constant.
2614
2615 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2616
2617 * include/bits/alloc_traits.h (allocator_traits<allocator<void>>):
2618 Use std::_Construct for construct.
2619
2620 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2621
2622 PR libstdc++/103877
2623 * doc/xml/faq.xml: Add '-x c++' to preprocessor command.
2624 * doc/html/faq.html: Regenerate.
2625
2626 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2627
2628 * include/bits/regex.h (__regex_algo_impl): Change __policy and
2629 __match_mode template parameters to be function parameters.
2630 (regex_match, regex_search): Pass policy and match mode as
2631 function arguments.
2632 * include/bits/regex.tcc (__regex_algo_impl): Change template
2633 parameters to function parameters.
2634 * include/bits/regex_compiler.h (_RegexTranslatorBase): Use
2635 'if constexpr' for conditions using template parameters.
2636 (_RegexTranslator): Likewise.
2637 * include/bits/regex_executor.tcc (_Executor::_M_handle_accept):
2638 Likewise.
2639 * testsuite/util/testsuite_regex.h (regex_match_debug)
2640 (regex_search_debug): Move template arguments to function
2641 arguments.
2642
2643 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2644
2645 * testsuite/util/testsuite_regex.h (regex_match_debug): Compare
2646 results even if the match failed.
2647
2648 2022-01-05 Jonathan Wakely <jwakely@redhat.com>
2649
2650 * include/bits/regex_compiler.tcc: Adjust all calls to
2651 __throw_regex_error.
2652 * include/bits/regex_error.h (__throw_regex_error): Add noreturn
2653 attribute.
2654 * include/bits/regex_scanner.tcc: Likewise.
2655 * src/c++11/regex.cc (desc): New helper function.
2656 (regex_error::regex_error(error_type)): Use desc to get a string
2657 corresponding to the error code.
2658
2659 \f
2660 Copyright (C) 2022 Free Software Foundation, Inc.
2661
2662 Copying and distribution of this file, with or without modification,
2663 are permitted in any medium without royalty provided the copyright
2664 notice and this notice are preserved.
This page took 0.17323 seconds and 5 git commands to generate.