Partial implementation of C++20 of <ranges> header
[platform/upstream/gcc.git] / libstdc++-v3 / ChangeLog
1 2019-10-31  Jonathan Wakely  <jwakely@redhat.com>
2
3         * doc/doxygen/user.cfg.in: Add new header.
4         * include/Makefile.am: Add new header.
5         * include/Makefile.in: Regenerate.
6         * include/precompiled/stdc++.h: Include new header.
7         * include/std/ranges: New header.
8         (ranges::sentinel_t, ranges::range_value_t, ranges::range_reference_t)
9         (ranges::range_rvalue_reference_t, ranges::sized_range)
10         (ranges::output_range, ranges::input_ranges, ranges::forward_range)
11         (ranges::bidirectional_range, ranges::random_access_range)
12         (ranges::contiguous_range, ranges::common::range): Define.
13         * testsuite/24_iterators/headers/iterator/synopsis_c++20.cc: Check
14         that disabled_sized_sentinel can be specialized.
15         * testsuite/std/ranges/access/begin.cc: Include <ranges> instead of
16         <iterator>.
17         * testsuite/std/ranges/access/cbegin.cc: Likewise.
18         * testsuite/std/ranges/access/cdata.cc: Likewise.
19         * testsuite/std/ranges/access/cend.cc: Likewise.
20         * testsuite/std/ranges/access/crbegin.cc: Likewise.
21         * testsuite/std/ranges/access/crend.cc: Likewise.
22         * testsuite/std/ranges/access/data.cc: Likewise.
23         * testsuite/std/ranges/access/empty.cc: Likewise.
24         * testsuite/std/ranges/access/end.cc: Likewise.
25         * testsuite/std/ranges/access/end_neg.cc: Likewise.
26         * testsuite/std/ranges/access/rbegin.cc: Likewise.
27         * testsuite/std/ranges/access/rend.cc: Likewise.
28         * testsuite/std/ranges/access/size.cc: Likewise.
29         * testsuite/std/ranges/access/size_neg.cc: Likewise.
30         * testsuite/std/ranges/headers/ranges/synopsis.cc: New test.
31         * testsuite/std/ranges/range.cc: New test.
32         * testsuite/std/ranges/refinements.cc: New test.
33         * testsuite/std/ranges/sized.cc: New test.
34         * testsuite/util/testsuite_iterators.h: Add aliases for range types.
35         (output_iterator_wrapper::WritableObject::operator=): Add const
36         qualifier so that output_iterator_wrapper satisfies writable.
37
38         * testsuite/20_util/add_pointer/value.cc: Check void types.
39
40         * include/bits/range_access.h (__sizable): Rename to __sentinel_size.
41         Remove workaround for PR c++/92268 and remove redundant requirements
42         that are already checked by sized_sentinel_for.
43         * testsuite/std/ranges/access/cend.cc: Fix failures.
44         * testsuite/std/ranges/access/end.cc: Likewise.
45
46         * include/bits/range_access.h (ranges::begin): Combine array and
47         non-array overloads into one function template. Only use ADL for
48         classes and enums.
49         (ranges::end, ranges::size): Likewise. Make unbounded arrays
50         ill-formed.
51         (ranges::rbegin, ranges::rend): Only use ADL for classes and enums.
52         Reformat _S_noexcept() functions to mirror operator() structure.
53         * testsuite/std/ranges/access/begin.cc: Check incomplete array.
54         * testsuite/std/ranges/access/end_neg.cc: New test.
55         * testsuite/std/ranges/access/size.cc: Check array of incomplete type.
56         * testsuite/std/ranges/access/size_neg.cc: New test.
57
58         * testsuite/24_iterators/range_access*.cc: Move to ...
59         * testsuite/24_iterators/range_access/range_access*.cc: ... here.
60         * testsuite/24_iterators/range_access/range_access_cpp20_neg.cc: New
61         test.
62
63 2019-10-30  Jonathan Wakely  <jwakely@redhat.com>
64
65         * include/std/concepts (std::ranges::swap): Use a single overload for
66         the non-array cases, and switch using if-constexpr.
67
68         * include/bits/stl_iterator.h (__normal_iterator::iterator_concept):
69         Guard with __cpp_lib_concepts macro.
70
71         * include/std/bit (__cpp_lib_bitops): Define.
72         * include/std/version (__cpp_lib_constexpr): Remove.
73         (__cpp_lib_bitops, __cpp_lib_constexpr_dynamic_alloc): Define.
74         * testsuite/26_numerics/bit/header.cc: New test.
75         * testsuite/26_numerics/bit/header-2.cc: New test.
76         * testsuite/20_util/allocator_traits/header.cc: New test.
77         * testsuite/20_util/allocator_traits/header-2.cc: New test.
78
79         * include/bits/stl_iterator.h (namespace __gnu_cxx): Remove
80         using-declarations for std::iterator and std::iterator_traits.
81         (__gnu_cxx::__normal_iterator): Qualify iterator_traits.
82         * include/ext/algorithm (namespace __gnu_cxx): Remove
83         using-declarations for std names and qualify those names when used.
84         Also refer to std::min in parentheses to protect against function-like
85         macros.
86         * include/ext/rc_string_base.h: Qualify iterator_traits.
87         * include/ext/sso_string_base.h: Qualify iterator_traits.
88
89         PR libstdc++/92272
90         * include/bits/stl_bvector.h (_Bit_iterator::pointer)
91         (_Bit_const_iterator::pointer): Define as void for C++20.
92         * include/bits/stl_iterator.h (reverse_iterator::operator->()): Add
93         constraints for C++20.
94         (__normal_iterator::iterator_concept): Define for C++20.
95         * include/bits/streambuf_iterator.h (istreambuf_iterator::pointer):
96         Define as void for C++20.
97         (ostreambuf_iterator::difference_type): Define as ptrdiff_t for C++20.
98         (ostreambuf_iterator::ostreambuf_iterator()): Add default constructor
99         for C++20.
100         * testsuite/23_containers/vector/bool/iterator_c++20.cc: New test.
101         * testsuite/24_iterators/bidirectional/concept.cc: New test.
102         * testsuite/24_iterators/bidirectional/tag.cc: New test.
103         * testsuite/24_iterators/contiguous/concept.cc: New test.
104         * testsuite/24_iterators/contiguous/tag.cc: New test.
105         * testsuite/24_iterators/forward/concept.cc: New test.
106         * testsuite/24_iterators/forward/tag.cc: New test.
107         * testsuite/24_iterators/input/concept.cc: New test.
108         * testsuite/24_iterators/input/tag.cc: New test.
109         * testsuite/24_iterators/istreambuf_iterator/requirements/typedefs.cc:
110         New test.
111         * testsuite/24_iterators/ostreambuf_iterator/requirements/typedefs.cc:
112         New test.
113         * testsuite/24_iterators/output/concept.cc: New test.
114         * testsuite/24_iterators/output/tag.cc: New test.
115         * testsuite/24_iterators/random_access/concept.cc: New test.
116         * testsuite/24_iterators/random_access/tag.cc: New test.
117         * testsuite/24_iterators/range_operations/advance_debug_neg.cc: New
118         test.
119         * testsuite/24_iterators/random_access_iterator/26020.cc: Move to ...
120         * testsuite/24_iterators/operations/26020.cc: ... here.
121         * testsuite/24_iterators/random_access_iterator/
122         string_vector_iterators.cc: Move to ...
123         * testsuite/24_iterators/random_access/string_vector_iterators.cc: ...
124         here.
125
126         * testsuite/util/testsuite_iterators.h: Fix typo in __cplusplus check.
127
128 2019-10-29  Jonathan Wakely  <jwakely@redhat.com>
129
130         * include/bits/range_access.h (ranges::disable_sized_range)
131         (ranges::begin, ranges::end, ranges::cbegin, ranges::cend)
132         (ranges::rbegin, ranges::rend, ranges::crbegin, ranges::crend)
133         (ranges::size, ranges::empty, ranges::data, ranges::cdata)
134         (ranges::range, ranges::sized_range, ranges::advance, ranges::distance)
135         (ranges::next, ranges::prev): Guard with __cpp_lib_concepts.
136         * include/bits/stl_iterator.h (disable_sized_sentinel): Likewise.
137
138         * include/bits/alloc_traits.h (__cpp_lib_constexpr_dynamic_alloc):
139         Define.
140         (allocator_traits::_S_construct, allocator_traits::_S_destroy)
141         (__alloc_on_copy, __alloc_on_move, __alloc_on_swap): Use
142         _GLIBCXX14_CONSTEXPR instead of constexpr.
143         * include/bits/stl_construct.h (_Destroy): Likewise.
144
145         * include/Makefile.am: Add new header.
146         * include/Makefile.in: Regenerate.
147         * include/bits/iterator_concepts.h: New header.
148         (contiguous_iterator_tag, iter_reference_t, ranges::iter_move)
149         (iter_rvalue_reference_t, incrementable_traits, iter_difference_t)
150         (readable_traits, iter_value_t, readable, iter_common_reference_t)
151         (writable, waekly_incrementable, incrementable)
152         (input_or_output_iterator, sentinel_for, disable_sized_sentinel)
153         (sized_sentinel_for, input_iterator, output_iterator)
154         (forward_iterator, bidirectional_iterator, random_access_iterator)
155         (contiguous_iterator, indirectly_unary_invocable)
156         (indirectly_regular_unary_invocable, indirect_unary_predicate)
157         (indirect_relation, indirect_strict_weak_order, indirect_result_t)
158         (projected, indirectly_movable, indirectly_movable_storable)
159         (indirectly_copyable, indirectly_copyable_storable, ranges::iter_swap)
160         (indirectly_swappable, indirectly_comparable, permutable, mergeable)
161         (sortable, unreachable_sentinel_t, unreachable_sentinel)
162         (default_sentinel_t, default_sentinel): Define.
163         (__detail::__cpp17_iterator, __detail::__cpp17_input_iterator)
164         (__detail::__cpp17_fwd_iterator, __detail::__cpp17_bidi_iterator)
165         (__detail::__cpp17_randacc_iterator): Define.
166         (__iterator_traits): Define constrained specializations.
167         * include/bits/move.h (move): Only use old concept check for C++98.
168         * include/bits/range_access.h (ranges::disable_sized_range)
169         (ranges::begin, ranges::end, ranges::cbegin, ranges::cend)
170         (ranges::rbegin, ranges::rend, ranges::crbegin, ranges::crend)
171         (ranges::size, ranges::empty, ranges::data, ranges::cdata): Define
172         new customization points for C++20.
173         (ranges::range, ranges::sized_range): Define new concepts for C++20.
174         (ranges::advance, ranges::distance, ranges::next, ranges::prev):
175         Define new functions for C++20.
176         (__adl_end, __adl_cdata, __adl_cbegin, __adl_cend, __adl_rbegin)
177         (__adl_rend, __adl_crbegin, __adl_crend, __adl_cdata, __adl_size)
178         (__adl_empty): Remove.
179         * include/bits/stl_iterator.h (disable_sized_sentinel): Specialize
180         for reverse_iterator.
181         * include/bits/stl_iterator_base_types.h (contiguous_iterator_tag):
182         Define new struct for C++20.
183         (iterator_traits<_Tp*>): Constrain partial specialization in C++20.
184         * include/std/concepts (__is_class_or_enum): Move to __detail
185         namespace.
186         * testsuite/20_util/forward/c_neg.cc: Adjust dg-error line number.
187         * testsuite/20_util/forward/f_neg.cc: Likewise.
188         * testsuite/24_iterators/associated_types/incrementable.traits.cc: New
189         test.
190         * testsuite/24_iterators/associated_types/readable.traits.cc: New test.
191         * testsuite/24_iterators/contiguous/concept.cc: New test.
192         * testsuite/24_iterators/contiguous/tag.cc: New test.
193         * testsuite/24_iterators/customization_points/iter_move.cc: New test.
194         * testsuite/24_iterators/customization_points/iter_swap.cc: New test.
195         * testsuite/24_iterators/headers/iterator/synopsis_c++20.cc: New test.
196         * testsuite/24_iterators/range_operations/advance.cc: New test.
197         * testsuite/24_iterators/range_operations/distance.cc: New test.
198         * testsuite/24_iterators/range_operations/next.cc: New test.
199         * testsuite/24_iterators/range_operations/prev.cc: New test.
200         * testsuite/26_numerics/adjacent_difference/requirements/
201         explicit_instantiation/2.cc: Rename types that conflict with C++20
202         concepts.
203         * testsuite/26_numerics/adjacent_difference/requirements/
204         explicit_instantiation/pod.cc: Likewise.
205         * testsuite/26_numerics/partial_sum/requirements/
206         explicit_instantiation/2.cc: Likewise.
207         * testsuite/26_numerics/partial_sum/requirements/
208         explicit_instantiation/pod.cc: Likewise.
209         * testsuite/experimental/iterator/requirements.cc: Likewise.
210         * testsuite/std/ranges/access/begin.cc: New test.
211         * testsuite/std/ranges/access/cbegin.cc: New test.
212         * testsuite/std/ranges/access/cdata.cc: New test.
213         * testsuite/std/ranges/access/cend.cc: New test.
214         * testsuite/std/ranges/access/crbegin.cc: New test.
215         * testsuite/std/ranges/access/crend.cc: New test.
216         * testsuite/std/ranges/access/data.cc: New test.
217         * testsuite/std/ranges/access/empty.cc: New test.
218         * testsuite/std/ranges/access/end.cc: New test.
219         * testsuite/std/ranges/access/rbegin.cc: New test.
220         * testsuite/std/ranges/access/rend.cc: New test.
221         * testsuite/std/ranges/access/size.cc: New test.
222         * testsuite/util/testsuite_iterators.h (contiguous_iterator_wrapper)
223         (test_range, test_sized_range): New test utilities.
224
225         * testsuite/util/testsuite_iterators.h (BoundsContainer::size()): Add
226         new member function.
227         (WritableObject::operator=): Constrain with enable_if when available.
228         (remove_cv): Use std::remove_if when available.
229         (test_container::it(int)): Use size().
230         (test_container::size()): Use BoundsContainer::size().
231
232         PR libstdc++/92267
233         * include/bits/stl_deque.h (_Deque_iterator(const _Deque_iterator&)):
234         Do not define as defaulted.
235         * testsuite/23_containers/deque/types/92267.cc: New test.
236
237 2019-10-26  Gerald Pfeifer  <gerald@pfeifer.com>
238
239         * doc/xml/manual/codecvt.xml: Switch pubs.opengroup.org to https.
240         * doc/xml/manual/locale.xml (LC_ALL): Ditto.
241         * doc/xml/manual/messages.xml: Ditto.
242         
243 2019-10-26  John David Anglin  <danglin@gcc.gnu.org>
244
245         * config/abi/post/hppa-linux-gnu/baseline_symbols.txt: Update.
246
247 2019-10-25  Jonathan Wakely  <jwakely@redhat.com>
248
249         * testsuite/util/testsuite_iterators.h (output_iterator_wrapper)
250         (input_iterator_wrapper, forward_iterator_wrapper)
251         bidirectional_iterator_wrapper, random_access_iterator_wrapper): Remove
252         user-provided copy constructors and copy assignment operators so they
253         are defined implicitly.
254         (input_iterator_wrapper): Initialize members in default constructor.
255         (forward_iterator_wrapper): Remove assignments to members of base.
256
257         * include/bits/allocator.h: Check __cpp_constexpr_dynamic_alloc
258         before making the std::allocator destructor constexpr.
259         * testsuite/20_util/allocator/requirements/constexpr.cc: New test.
260
261         * include/bits/range_cmp.h: Check __cpp_lib_concepts before defining
262         concepts. Fix comment.
263         * include/bits/allocator.h 
264
265 2019-10-25  Gerald Pfeifer  <gerald@pfeifer.com>
266
267         * doc/xml/manual/policy_data_structures_biblio.xml: Switch
268         pubs.opengroup.org to https.
269
270 2019-10-25  Gerald Pfeifer  <gerald@pfeifer.com>
271         
272         * doc/xml/gnu/gpl-3.0.xml: Switch www.gnu.org to https.
273
274 2019-09-09  Edward Smith-Rowland  <3dw4rd@verizon.net>
275
276         * doc/xml/manual/status_cxx2020.xml: Add rows and update status.
277
278 2019-10-24  Jonathan Wakely  <jwakely@redhat.com>
279
280         * include/bits/allocator.h (allocator<void>): Restore the explicit
281         specialization for C++20, but make its API consistent with the primary
282         template.
283         (allocator::~allocator()): Restore the destructor for C++20, but make
284         it constexpr.
285         * testsuite/20_util/allocator/rebind_c++20.cc: Check allocator<void>.
286         * testsuite/20_util/allocator/requirements/typedefs_c++20.cc: Likewise.
287         * testsuite/20_util/allocator/void.cc: Check that constructors and
288         destructors are trivial. Check for converting constructor in C++20.
289         * testsuite/ext/malloc_allocator/variadic_construct.cc: Simplify
290         dejagnu target selector.
291         * testsuite/ext/new_allocator/variadic_construct.cc: Likewise.
292
293         * include/experimental/executor (__use_future_ct, use_future_t):
294         Define partial specializations for std::allocator.
295         (__use_future_ch): Overload constructor for completion tokens using
296         std::allocator.
297
298         PR libstdc++/88338 Implement P0898R3, C++20 concepts library
299         * doc/xml/manual/status_cxx2020.xml: Update status.
300         * doc/html/*: Regenerate.
301         * testsuite/std/concepts/1.cc: New test.
302         * testsuite/std/concepts/2.cc: New test.
303
304         * include/bits/random.h (uniform_random_bit_generator): Define for
305         C++20.
306         * testsuite/26_numerics/random/concept.cc: New test.
307         * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error line.
308
309 2019-10-23  Jonathan Wakely  <jwakely@redhat.com>
310
311         * include/std/functional (invoke): Add constexpr for C++20.
312         * include/std/version (__cpp_lib_constexpr_invoke): Define.
313         * testsuite/20_util/function_objects/invoke/constexpr.cc: New test.
314
315         PR c++/91369 Implement P0784R7 changes to allocation and construction
316         * include/bits/alloc_traits.h: Include <bits/stl_construct.h>.
317         (allocator_traits::_S_allocate, allocator_traits::_S_construct)
318         (allocator_traits::_S_destroy, allocator_traits::_S_max_size)
319         (allocator_traits::_S_select, allocator_traits::allocate)
320         (allocator_traits::deallocate, allocator_traits::construct)
321         (allocator_traits::destroy, allocator_traits::max_size)
322         (allocator_traits::select_on_container_copy_construction)
323         (allocator_traits<allocator<T>>): Add constexpr specifier for C++20.
324         (allocator_traits<allocator<T>>::construct): Use construct_at.
325         (allocator_traits<allocator<T>>::destroy): Use destroy_at.
326         (__alloc_on_copy, __alloc_on_move, __alloc_on_swap): Add constexpr
327         specifier.
328         (_Destroy(ForwardIterator, ForwardIterator, Alloc&))
329         (_Destroy(ForwardIterator, ForwardIterator, allocator<T>&)): Move here
330         from <bits/stl_construct.h>.
331         * include/bits/allocator.h (allocator::~allocator): Remove for C++20.
332         (allocator::allocate, allocate::deallocate): Define for C++20 and up.
333         (operator==, operator!=): Add constexpr specifier for C++20.
334         * include/bits/stl_construct.h: Don't include <ext/alloc_traits.h>.
335         (destroy_at): For C++20 add constexpr specifier and support for
336         destroying arrays.
337         (construct_at): Define new function for C++20.
338         (_Construct): Return result of placement new-expression. For C++11 and
339         up add constexpr. For C++20 dispatch to std::construct_at during
340         constant evaluation.
341         (_Destroy(pointer)): Add constexpr specifier. For C++20 dispatch to
342         std::destroy_at during constant evaluation.
343         (_Destroy_aux::__destroy, _Destroy_n_aux::__destroy_n): Add constexpr
344         specifier for C++20.
345         (_Destroy(ForwardIterator, ForwardIterator))
346         (_Destroy(ForwardIterator, Size)): Likewise. Do not elide trivial
347         destructors during constant evaluation.
348         (destroy, destroy_n): Add constexpr specifier for C++20.
349         (_Destroy(ForwardIterator, ForwardIterator, Alloc&))
350         (_Destroy(ForwardIterator, ForwardIterator, allocator<T>&)): Move to
351         <bits/alloc_traits.h>, to remove dependency on allocators.
352         * include/bits/stl_uninitialized.h: Include <ext/alloc_traits.h>.
353         Include <bits/stl_pair.h> instead of <utility>.
354         * include/ext/alloc_traits.h: Always include <bits/alloc_traits.h>.
355         (__alloc_traits::construct, __alloc_traits::destroy)
356         (__alloc_traits::_S_select_on_copy, __alloc_traits::_S_on_swap): Add
357         constexpr specifier.
358         * include/ext/malloc_allocator.h  (operator==, operator!=): Add
359         constexpr specifier for C++20.
360         * include/ext/new_allocator.h (operator==, operator!=): Likewise.
361         * testsuite/20_util/headers/memory/synopsis.cc: Add constexpr.
362         * testsuite/20_util/scoped_allocator/69293_neg.cc: Ignore additional
363         errors due to constexpr function called after failed static_assert.
364         * testsuite/20_util/specialized_algorithms/construct_at/1.cc: New test.
365         * testsuite/23_containers/vector/cons/destructible_debug_neg.cc:
366         Ignore additional errors due to constexpr function called after failed
367         static_assert.
368         * testsuite/23_containers/vector/cons/destructible_neg.cc: Likewise.
369
370         * testsuite/20_util/bind/91371.cc: Fix test to compile as C++11.
371
372         * include/debug/helper_functions.h (__valid_range): Change
373         _GLIBCXX_CONSTEXPR to _GLIBCXX14_CONSTEXPR.
374
375         * include/ext/throw_allocator.h (throw_allocator_base): Qualify
376         size_t and ptrdiff_t.
377
378         * include/ext/pb_ds/detail/bin_search_tree_/bin_search_tree_.hpp:
379         Use detail::rebind_traits.
380         * include/ext/pb_ds/detail/bin_search_tree_/node_iterators.hpp:
381         Likewise.
382         * include/ext/pb_ds/detail/bin_search_tree_/traits.hpp: Likewise.
383         * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Likewise.
384         * include/ext/pb_ds/detail/binary_heap_/entry_cmp.hpp: Likewise.
385         * include/ext/pb_ds/detail/binary_heap_/entry_pred.hpp: Likewise.
386         * include/ext/pb_ds/detail/binary_heap_/point_const_iterator.hpp:
387         Likewise.
388         * include/ext/pb_ds/detail/binomial_heap_base_/binomial_heap_base_.hpp:
389         Likewise.
390         * include/ext/pb_ds/detail/branch_policy/branch_policy.hpp: Likewise.
391         * include/ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp: Likewise.
392         * include/ext/pb_ds/detail/cond_dealtor.hpp: Likewise.
393         * include/ext/pb_ds/detail/eq_fn/hash_eq_fn.hpp (has_eq_fn): Likewise.
394         * include/ext/pb_ds/detail/gp_hash_table_map_/gp_ht_map_.hpp: Likewise.
395         * include/ext/pb_ds/detail/hash_fn/ranged_hash_fn.hpp: Likewise.
396         * include/ext/pb_ds/detail/hash_fn/ranged_probe_fn.hpp: Likewise.
397         * include/ext/pb_ds/detail/left_child_next_sibling_heap_/
398         left_child_next_sibling_heap_.hpp: Likewise.
399         * include/ext/pb_ds/detail/left_child_next_sibling_heap_/node.hpp:
400         Likewise.
401         * include/ext/pb_ds/detail/left_child_next_sibling_heap_/
402         point_const_iterator.hpp: Likewise.
403         * include/ext/pb_ds/detail/list_update_map_/lu_map_.hpp: Likewise.
404         * include/ext/pb_ds/detail/ov_tree_map_/
405         constructors_destructor_fn_imps.hpp: Likewise.
406         * include/ext/pb_ds/detail/ov_tree_map_/node_iterators.hpp: Likewise.
407         * include/ext/pb_ds/detail/ov_tree_map_/ov_tree_map_.hpp: Likewise.
408         * include/ext/pb_ds/detail/pairing_heap_/pairing_heap_.hpp: Likewise.
409         * include/ext/pb_ds/detail/pat_trie_/pat_trie_.hpp: Likewise.
410         * include/ext/pb_ds/detail/pat_trie_/pat_trie_base.hpp: Likewise.
411         * include/ext/pb_ds/detail/rb_tree_map_/node.hpp: Likewise.
412         * include/ext/pb_ds/detail/rc_binomial_heap_/rc.hpp: Likewise.
413         * include/ext/pb_ds/detail/splay_tree_/node.hpp: Likewise.
414         * include/ext/pb_ds/detail/thin_heap_/thin_heap_.hpp: Likewise.
415         * include/ext/pb_ds/detail/trie_policy/sample_trie_access_traits.hpp:
416         Likewise.
417         * include/ext/pb_ds/detail/type_utils.hpp: Fix typo in comment.
418         * include/ext/pb_ds/detail/types_traits.hpp (stored_value): Add
419         bool parameter to control whether the hash value is stored.
420         (select_base_type): New class template and partial specialization.
421         (maybe_null_type): Likewise.
422         (rebind_traits): New class template.
423         (type_base): Remove four nearly identical specializations.
424         (type_dispatch): Remove.
425         (type_traits): Use select_base_type and maybe_null_type instead of
426         type_base to control differences between specializations.
427         * include/ext/pb_ds/list_update_policy.hpp: Use detail::rebind_traits.
428         * include/ext/pb_ds/priority_queue.hpp: Likewise.
429         * include/ext/pb_ds/tree_policy.hpp: Likewise.
430         * include/ext/pb_ds/trie_policy.hpp: Likewise.
431
432         * include/backward/hash_set (hash_set): Use __alloc_traits.
433         * include/backward/hashtable.h (_Hashtable): Likewise.
434         * include/ext/alloc_traits.h (__alloc_traits::allocate): Add overload
435         taking a hint.
436         * include/ext/extptr_allocator.h (_ExtPtr_allocator::allocate): Ignore
437         hint.
438         * include/ext/slist (_Slist_base): Use __alloc_traits.
439         * include/tr1/hashtable.h (_Hashtable): Likewise.
440         * include/tr1/regex (match_results): Use vector::const_reference
441         instead of assuming the allocator defines it.
442         * testsuite/backward/hash_map/23528.cc: Use allocator_traits in C++11.
443         * testsuite/tr1/6_containers/unordered_map/capacity/29134-map.cc: Use
444         __gnu_test::max_size.
445         * testsuite/tr1/6_containers/unordered_multimap/capacity/
446         29134-multimap.cc: Likewise.
447         * testsuite/tr1/6_containers/unordered_multiset/capacity/
448         29134-multiset.cc: Likewise.
449         * testsuite/tr1/6_containers/unordered_set/capacity/29134-set.cc:
450         Likewise.
451
452 2019-10-22  Jonathan Wakely  <jwakely@redhat.com>
453
454         * testsuite/util/testsuite_abi.h: Restore use of tr1/unordered_map
455         when compiled as C++98.
456
457         * include/bits/memoryfwd.h (uses_allocator): Do not declare for C++98.
458         * testsuite/17_intro/names.cc: Check uses_allocator in C++98.
459
460         * include/bits/alloc_traits.h
461         (allocator_traits<allocator<T>>::allocate): Ignore hint for C++20.
462         (allocator_traits<allocator<T>>::construct): Perform placement new
463         directly for C++20, instead of calling allocator<T>::construct.
464         (allocator_traits<allocator<T>>::destroy): Call destructor directly
465         for C++20, instead of calling allocator<T>::destroy.
466         (allocator_traits<allocator<T>>::max_size): Return value directly
467         for C++20, instead of calling std::allocator<T>::max_size().
468         (__do_alloc_on_copy, __do_alloc_on_move, __do_alloc_on_swap): Do not
469         define for C++17 and up.
470         (__alloc_on_copy, __alloc_on_move, __alloc_on_swap): Use if-constexpr
471         for C++17 and up, instead of tag dispatching.
472         * include/bits/allocator.h (allocator<void>): Remove for C++20.
473         (allocator::pointer, allocator::const_pointer, allocator::reference)
474         (allocator::const_reference, allocator::rebind): Remove for C++20.
475         * include/bits/basic_string.h (basic_string): Use __alloc_traits to
476         rebind allocator.
477         * include/bits/memoryfwd.h (allocator<void>): Remove for C++20.
478         * include/ext/debug_allocator.h: Use __alloc_traits for rebinding.
479         * include/ext/malloc_allocator.h (malloc_allocator::~malloc_allocator)
480         (malloc_allocator::pointer, malloc_allocator::const_pointer)
481         (malloc_allocator::reference, malloc_allocator::const_reference)
482         (malloc_allocator::rebind, malloc_allocator::max_size)
483         (malloc_allocator::construct, malloc_allocator::destroy): Do not
484         define for C++20.
485         (malloc_allocator::_M_max_size): Define new function.
486         * include/ext/new_allocator.h (new_allocator::~new_allocator)
487         (new_allocator::pointer, new_allocator::const_pointer)
488         (new_allocator::reference, new_allocator::const_reference)
489         (new_allocator::rebind, new_allocator::max_size)
490         (new_allocator::construct, new_allocator::destroy): Do not
491         define for C++20.
492         (new_allocator::_M_max_size): Define new function.
493         * include/ext/rc_string_base.h (__rc_string_base::_Rep): Use
494         __alloc_traits to rebind allocator.
495         * include/ext/rope (_Rope_rep_base, _Rope_base): Likewise.
496         (rope::rope(CharT, const allocator_type&)): Use __alloc_traits
497         to construct character.
498         * include/ext/slist (_Slist_base): Use __alloc_traits to rebind
499         allocator.
500         * include/ext/sso_string_base.h (__sso_string_base::_M_max_size):
501         Use __alloc_traits.
502         * include/ext/throw_allocator.h (throw_allocator): Do not use optional
503         members of std::allocator, use __alloc_traits members instead.
504         * include/ext/vstring.h (__versa_string): Use __alloc_traits.
505         * include/ext/vstring_util.h (__vstring_utility): Likewise.
506         * include/std/memory: Include <bits/alloc_traits.h>.
507         * testsuite/20_util/allocator/8230.cc: Use __gnu_test::max_size.
508         * testsuite/20_util/allocator/rebind_c++20.cc: New test.
509         * testsuite/20_util/allocator/requirements/typedefs.cc: Do not check
510         for pointer, const_pointer, reference, const_reference or rebind in
511         C++20.
512         * testsuite/20_util/allocator/requirements/typedefs_c++20.cc: New test.
513         * testsuite/23_containers/deque/capacity/29134.cc: Use
514         __gnu_test::max_size.
515         * testsuite/23_containers/forward_list/capacity/1.cc: Likewise.
516         * testsuite/23_containers/list/capacity/29134.cc: Likewise.
517         * testsuite/23_containers/map/capacity/29134.cc: Likewise.
518         * testsuite/23_containers/multimap/capacity/29134.cc: Likewise.
519         * testsuite/23_containers/multiset/capacity/29134.cc: Likewise.
520         * testsuite/23_containers/set/capacity/29134.cc: Likewise.
521         * testsuite/23_containers/vector/capacity/29134.cc: Likewise.
522         * testsuite/ext/malloc_allocator/variadic_construct.cc: Do not run
523         test for C++20.
524         * testsuite/ext/new_allocator/variadic_construct.cc: Likewise.
525         * testsuite/ext/vstring/capacity/29134.cc: Use __gnu_test::max_size.
526         * testsuite/util/replacement_memory_operators.h: Do not assume
527         Alloc::pointer exists.
528         * testsuite/util/testsuite_allocator.h (__gnu_test::max_size): Define
529         helper to call max_size for any allocator.
530
531 2019-10-22  Andreas Schwab  <schwab@suse.de>
532
533         * config/abi/post/aarch64-linux-gnu/baseline_symbols.txt: Update.
534
535 2019-10-18  Jonathan Wakely  <jwakely@redhat.com>
536
537         PR libstdc++/92143
538         * libsupc++/new_opa.cc (operator new) [__APPLE__]: Increase alignment
539         to at least sizeof(void*).
540
541         * include/bits/range_cmp.h (ranges::less::operator()): Inline the
542         logic from std::less::operator() to remove the dependency on it.
543
544 2019-10-17  Jonathan Wakely  <jwakely@redhat.com>
545
546         * doc/doxygen/user.cfg.in (INPUT): Add new C++17 and C++20 headers.
547
548         * include/Makefile.am: Add new header.
549         * include/Makefile.in: Regenerate.
550         * include/bits/range_cmp.h: New header for C++20 function objects.
551         * include/std/functional: Include new header.
552         * testsuite/20_util/function_objects/identity/1.cc: New test.
553         * testsuite/20_util/function_objects/range.cmp/equal_to.cc: New test.
554         * testsuite/20_util/function_objects/range.cmp/greater.cc: New test.
555         * testsuite/20_util/function_objects/range.cmp/greater_equal.cc: New
556         test.
557         * testsuite/20_util/function_objects/range.cmp/less.cc: New test.
558         * testsuite/20_util/function_objects/range.cmp/less_equal.cc: New test.
559         * testsuite/20_util/function_objects/range.cmp/not_equal_to.cc: New
560         test.
561
562         PR libstdc++/92124
563         * include/bits/forward_list.h
564         (_M_move_assign(forward_list&&, false_type)): Do not use
565         __make_move_if_noexcept, instead move unconditionally.
566         * include/bits/stl_deque.h (_M_move_assign2(deque&&, false_type)):
567         Likewise.
568         * include/bits/stl_list.h (_M_move_assign(list&&, false_type)):
569         Likewise.
570         * include/bits/stl_vector.h (_M_move_assign(vector&&, false_type)):
571         Likewise.
572         * testsuite/23_containers/vector/92124.cc: New test.
573
574 2019-10-16  Jonathan Wakely  <jwakely@redhat.com>
575
576         * include/bits/c++config (_GLIBCXX_BUILTIN_IS_SAME_AS): Define to
577         one of __is_same_as or __is_same when available.
578         * include/std/concepts (__detail::__same_as): Use std::is_same_v.
579         * include/std/type_traits (is_same) [_GLIBCXX_BUILTIN_IS_SAME_AS]:
580         Use new macro instead of __is_same_as.
581         (is_same) [!_GLIBCXX_BUILTIN_IS_SAME_AS]: Restore partial
582         specialization.
583         (is_same_v) [_GLIBCXX_BUILTIN_IS_SAME_AS]: Use new macro.
584         (is_same_v) [!_GLIBCXX_BUILTIN_IS_SAME_AS]: Use std::is_same.
585
586 2019-10-16  François Dumont  <fdumont@gcc.gnu.org>
587
588         * src/c++11/debug.cc (print_field): Replace constness_names <unknown>
589         entry with <unknown constness>. Replace state_names <unknown> entry with
590         <unknown state>.
591
592 2019-10-11  Jonathan Wakely  <jwakely@redhat.com>
593
594         * include/Makefile.am: Add new header.
595         * include/Makefile.in: Regenerate.
596         * include/precompiled/stdc++.h: Include <concepts>.
597         * include/std/concepts: New header for C++20.
598         * include/std/version (__cpp_lib_concepts): Define.
599         * scripts/create_testsuite_files: Look for test files in new std
600         directory.
601         * testsuite/libstdc++-dg/conformance.exp: Likewise.
602         * testsuite/std/concepts/concepts.callable/invocable.cc: New test.
603         * testsuite/std/concepts/concepts.callable/regular_invocable.cc: New
604         test.
605         * testsuite/std/concepts/concepts.callable/relation.cc: New test.
606         * testsuite/std/concepts/concepts.callable/strictweakorder.cc: New
607         test.
608         * testsuite/std/concepts/concepts.lang/concept.arithmetic/
609         floating_point.cc: New test.
610         * testsuite/std/concepts/concepts.lang/concept.arithmetic/integral.cc:
611         New test.
612         * testsuite/std/concepts/concepts.lang/concept.arithmetic/
613         signed_integral.cc: New test.
614         * testsuite/std/concepts/concepts.lang/concept.arithmetic/
615         unsigned_integral.cc: New test.
616         * testsuite/std/concepts/concepts.lang/concept.assignable/1.cc: New
617         test.
618         * testsuite/std/concepts/concepts.lang/concept.common/1.cc: New test.
619         * testsuite/std/concepts/concepts.lang/concept.commonref/1.cc: New
620         test.
621         * testsuite/std/concepts/concepts.lang/concept.constructible/1.cc:
622         New test.
623         * testsuite/std/concepts/concepts.lang/concept.convertible/1.cc:
624         New test.
625         * testsuite/std/concepts/concepts.lang/concept.copyconstructible/1.cc:
626         New test.
627         * testsuite/std/concepts/concepts.lang/concept.defaultconstructible/
628         1.cc: New test.
629         * testsuite/std/concepts/concepts.lang/concept.derived/1.cc:
630         New test.
631         * testsuite/std/concepts/concepts.lang/concept.destructible/1.cc:
632         New test.
633         * testsuite/std/concepts/concepts.lang/concept.moveconstructible/1.cc:
634         New test.
635         * testsuite/std/concepts/concepts.lang/concept.same/1.cc:
636         New test.
637         * testsuite/std/concepts/concepts.lang/concept.swappable/swap.cc:
638         New test.
639         * testsuite/std/concepts/concepts.lang/concept.swappable/swappable.cc:
640         New test.
641         * testsuite/std/concepts/concepts.lang/concept.swappable/
642         swappable_with.cc: New test.
643         * testsuite/std/concepts/concepts.object/copyable.cc: New test.
644         * testsuite/std/concepts/concepts.object/movable.cc: New test.
645         * testsuite/std/concepts/concepts.object/regular.cc: New test.
646         * testsuite/std/concepts/concepts.object/semiregular.cc: New test.
647
648         * include/std/type_traits (is_same): Replace partial specialization
649         by using __is_same_as built-in in primary template.
650         (is_same_v): Use __is_same_as built-in instead of instantiating the
651         is_same trait.
652
653         PR libstdc++/92059
654         * include/tr2/dynamic_bitset (__dynamic_bitset_base): Define all
655         special member functions as defaulted. Add noexcept to most members.
656         (__dynamic_bitset_base(size_t, unsigned long long, const _Alloc&)):
657         Mask off unwanted bits in the __val parameter. Avoid undefined left
658         shifts.
659         (__dynamic_bitset_base::_M_assign): Remove.
660         (__dynamic_bitset_base::_M_do_reset): Use std::fill.
661         (__dynamic_bitset_base::_M_are_all_aux): Avoid integer promotion when
662         block_type has lower rank than int.
663         (dynamic_bitset): Add noexcept to most members. Use injected-class-name
664         in return types and parameter types.
665         (dynamic_bitset::_M_Nb): Add default member initializer.
666         (dynamic_bitset(), dynamic_bitset(const dynamic_bitset&)): Define as
667         defaulted.
668         (dynamic_bitset(dynamic_bitset&&)): Clear source object after move.
669         (dynamic_bitset::operator=(const dynamic_bitset&)): Define as
670         defaulted.
671         (dynamic_bitset::operator=(dynamic_bitset&&)): Add noexcept-specifier.
672         Define without using swap, to propagate allocator correctly.
673         (dynamic_bitset(const char*, const _Alloc&)): Use strlen.
674         (dynamic_bitset::_M_do_sanitize, dynamic_bitset::_M_do_fill): Use
675         casts to avoid unwanted integer promotions.
676         (dynamic_bitset::_M_copy_from_ptr): Rearrange template parameters and
677         add default template arguments and default argument to simplify usage.
678         (dynamic_bitset::_M_copy_from_string): Adjust call to _M_copy_from_ptr.
679         (operator==(const dynamic_bitset&, const dynamic_bitset&))
680         (operator<(const dynamic_bitset&, const dynamic_bitset&)): Use _M_Nb.
681         * include/tr2/dynamic_bitset.tcc (dynamic_bitset::_M_copy_from_ptr):
682         Adjust template parameters to match declaration.
683         * testsuite/tr2/dynamic_bitset/cmp.cc: New test.
684         * testsuite/tr2/dynamic_bitset/cons.cc: New test.
685         * testsuite/tr2/dynamic_bitset/copy.cc: New test.
686         * testsuite/tr2/dynamic_bitset/move.cc: New test.
687         * testsuite/tr2/dynamic_bitset/pr92059.cc: New test.
688
689         * include/bits/charconv.h (__to_chars_len): Avoid -Wsign-compare
690         warnings.
691
692 2019-10-10  Jonathan Wakely  <jwakely@redhat.com>
693
694         PR libstdc++/91057
695         * src/c++98/locale.cc [_GLIBCXX_LONG_DOUBLE_COMPAT]
696         (find_ldbl_sync_facet): Fix parameter type and missing return.
697
698 2019-10-09  Marek Polacek  <polacek@redhat.com>
699
700         PR c++/91364 - P0388R4: Permit conversions to arrays of unknown bound.
701         PR c++/69531 - DR 1307: Differently bounded array parameters.
702         PR c++/88128 - DR 330: Qual convs and pointers to arrays of pointers.
703         * testsuite/23_containers/span/lwg3255.cc: Adjust test to match the
704         post-P0388R4 behavior.
705
706 2019-10-09  Jonathan Wakely  <jwakely@redhat.com>
707
708         PR libstdc++/91057
709         * src/c++98/locale.cc (locale::id::_M_id()) [__GTHREADS]: Use atomic
710         compare-exchange or double-checked lock to ensure only one thread sets
711         the _M_index variable.
712         [_GLIBCXX_LONG_DOUBLE_COMPAT]: Call find_ldbl_sync_facet to detect
713         facets that share another facet's ID.
714         [_GLIBCXX_LONG_DOUBLE_COMPAT] (find_ldbl_sync_facet): New function.
715
716         PR libstdc++/78552
717         * src/c++98/locale_init.cc (locale::classic()): Do not construct a new
718         locale object for every call.
719         (locale::_S_initialize_once()): Construct C locale here.
720
721 2019-10-08  Jonathan Wakely  <jwakely@redhat.com>
722
723         * doc/Makefile.am (doc-html-docbook-regenerate): New target.
724         (${docbook_outdir}/html): Do not create unused 'html/ext' directory.
725         * doc/Makefile.in: Regenerate.
726         * doc/xml/manual/documentation_hacking.xml: Document new target.
727         * doc/html/*: Regenerate.
728
729         * doc/xml/manual/allocator.xml: Use archived copy of CUJ article.
730         * doc/html/*: Regenerate.
731
732 2019-10-06  François Dumont  <fdumont@gcc.gnu.org>
733
734         * include/bits/stl_algo.h
735         (__copy_n_a(_IIte, _Size, _OIte)): New.
736         (__copy_n_a(istreambuf_iterator<>, _Size, _CharT*)): New declaration.
737         (__copy_n(_IIte, _Size, _OIte, input_iterator_tag)): Adapt to use
738         latter.
739         * include/bits/streambuf_iterator.h (istreambuf_iterator<>): Declare
740         std::__copy_n_a friend.
741         (__copy_n_a(istreambuf_iterator<>, _Size, _CharT*)): New.
742         * testsuite/25_algorithms/copy_n/istreambuf_iterator/1.cc: New.
743         * testsuite/25_algorithms/copy_n/istreambuf_iterator/1_neg.cc: New.
744         * testsuite/25_algorithms/copy_n/istreambuf_iterator/2_neg.cc: New.
745
746         * include/bits/stl_iterator_base_types.h (__iterator_category_t): Define
747         for C++11.
748         (_RequireInputIte): Likewise and use __enable_if_t.
749         * include/std/numeric
750         (__is_random_access_iter): Use __iterator_category_t.
751
752         * include/bits/stl_algo.h (copy_n): Add __glibcxx_requires_can_increment
753         debug checks.
754         * testsuite/25_algorithms/copy_n/debug/1_neg.cc: New.
755         * testsuite/25_algorithms/copy_n/debug/2_neg.cc: New.
756
757 2019-10-04  François Dumont  <fdumont@gcc.gnu.org>
758
759         * include/debug/forward_list
760         (_Sequence_traits<__debug::forward_list<>>::_S_size): Returns __dp_sign
761         distance when not empty.
762         * include/debug/list (_Sequence_traits<__debug::list<>>::_S_size):
763         Likewise.
764         * include/debug/helper_functions.h (__dp_sign_max_size): New
765         _Distance_precision enum entry.
766         (__valid_range_aux(_IIte, _IIte, _Distance_traits<>::__type,
767         __false_type)): Adapt.
768         * include/debug/safe_iterator.tcc
769         (_Safe_iterator<>::_M_get_distance_to(const _Safe_iterator&)): Review
770         distance computation.
771
772 2019-10-04  Jonathan Wakely  <jwakely@redhat.com>
773
774         PR libstdc++/81091
775         PR libstdc++/91947
776         * configure.ac: Use AC_SYS_LARGEFILE to enable 64-bit file APIs.
777         * config.h.in: Regenerate:
778         * configure: Regenerate:
779         * include/Makefile.am (${host_builddir}/largefile-config.h): New
780         target to generate config header for filesystem library.
781         (${host_builddir}/c++config.h): Rename macros for large file support.
782         * include/Makefile.in: Regenerate.
783         * src/c++17/fs_dir.cc: Include new config header.
784         * src/c++17/fs_ops.cc: Likewise.
785         (filesystem::file_size): Use uintmax_t for size.
786         * src/filesystem/dir.cc: Include new config header.
787         * src/filesystem/ops.cc: Likewise.
788         (experimental::filesystem::file_size): Use uintmax_t for size.
789
790         * testsuite/util/testsuite_abi.h: Use std::unordered_map instead of
791         std::tr1::unordered_map.
792         * testsuite/util/testsuite_allocator.h: Likewise.
793
794         * include/tr1/hashtable.h: Add header for __gnu_cxx::__alloc_traits.
795
796         * include/tr1/hashtable.h (tr1::_Hashtable::_M_allocate_node): Use
797         __gnu_cxx::__alloc_traits for allocator construct function.
798         (tr1::_Hashtable::_M_deallocate_node): Likewise for destroy function.
799
800         * include/precompiled/stdc++.h: Include <span> for C++20.
801         * testsuite/17_intro/names.cc: Do not define 'e' for C++20.
802
803 2019-10-03  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
804
805         * include/parallel/multiway_merge.h (_RAIter3): Replace _C by _Cp.
806
807 2019-10-02  Jonathan Wakely  <jwakely@redhat.com>
808
809         * config/abi/pre/gnu.ver: Tighten up greedy wildcards.
810
811         * doc/xml/manual/parallel_mode.xml: Add caveat about support for
812         recent standards.
813         * doc/html/*: Regenerate.
814
815 2019-10-01  Jonathan Wakely  <jwakely@redhat.com>
816
817         * include/experimental/algorithm (experimental::sample): Qualify call
818         to __sample correctly.
819         * include/parallel/algo.h (sample, for_each_n): Add using-declarations
820         for algorithms that don't have parallel implementations.
821
822         * include/parallel/algobase.h (equal, lexicographical_compare): Add
823         _GLIBCXX20_CONSTEXPR and dispatch to sequential algorithm when being
824         constant evaluated.
825         * include/parallel/algorithmfwd.h (equal, lexicographical_compare):
826         Add _GLIBCXX20_CONSTEXPR.
827
828         * testsuite/17_intro/using_namespace_std_tr1_neg.cc: Skip test for
829         parallel mode.
830         * testsuite/20_util/hash/84998.cc: Likewise.
831         * testsuite/23_containers/deque/types/pmr_typedefs_debug.cc: Likewise.
832         * testsuite/23_containers/forward_list/pmr_typedefs_debug.cc: Likewise.
833         * testsuite/23_containers/list/pmr_typedefs_debug.cc: Likewise.
834         * testsuite/23_containers/map/pmr_typedefs_debug.cc: Likewise.
835         * testsuite/23_containers/multimap/pmr_typedefs_debug.cc: Likewise.
836         * testsuite/23_containers/multiset/pmr_typedefs_debug.cc: Likewise.
837         * testsuite/23_containers/set/pmr_typedefs_debug.cc: Likewise.
838         * testsuite/23_containers/unordered_map/pmr_typedefs_debug.cc:
839         Likewise.
840         * testsuite/23_containers/unordered_multimap/pmr_typedefs_debug.cc:
841         Likewise.
842         * testsuite/23_containers/unordered_multiset/pmr_typedefs_debug.cc:
843         Likewise.
844         * testsuite/23_containers/unordered_set/pmr_typedefs_debug.cc:
845         Likewise.
846         * testsuite/23_containers/vector/cons/destructible_debug_neg.cc:
847         Likewise.
848         * testsuite/23_containers/vector/types/pmr_typedefs_debug.cc: Likewise.
849         * testsuite/25_algorithms/binary_search/partitioned.cc: Likewise.
850         * testsuite/25_algorithms/copy/86658.cc: Likewise.
851         * testsuite/25_algorithms/equal_range/partitioned.cc: Likewise.
852         * testsuite/25_algorithms/lexicographical_compare/71545.cc: Likewise.
853         * testsuite/25_algorithms/lower_bound/partitioned.cc: Likewise.
854         * testsuite/25_algorithms/upper_bound/partitioned.cc: Likewise.
855
856         * include/parallel/algo.h: Replace non-reserved names.
857         * include/parallel/multiway_merge.h: Likewise.
858         * include/parallel/multiway_mergesort.h: Likewise.
859         * include/parallel/numericfwd.h: Likewise.
860         * testsuite/17_intro/names.cc: Add RAI to test macros.
861
862 2019-09-30  François Dumont  <fdumont@gcc.gnu.org>
863
864         * include/debug/array: Add C++20 constexpr to comparison operators.
865         * testsuite/23_containers/array/tuple_interface/get_debug_neg.cc: Adapt
866         dg-error line numbers.
867         * testsuite/23_containers/array/tuple_interface/
868         tuple_element_debug_neg.cc: Likewise.
869
870 2019-09-30  Andreas Tobler  <andreast@gcc.gnu.org>
871
872         * include/experimental/internet: Include netinet/in.h if we have
873         _GLIBCXX_HAVE_NETINET_IN_H defined.
874
875         * testsuite/ext/special_functions/airy_ai/check_nan.cc: Ignore the
876         FreeBSD warning about lower advertised precision of tgammal.
877         * testsuite/ext/special_functions/airy_bi/check_nan.cc: Likewise.
878         * testsuite/special_functions/07_cyl_bessel_i/check_nan.cc: Likewise.
879         * testsuite/special_functions/08_cyl_bessel_j/check_nan.cc: Likewise.
880         * testsuite/special_functions/09_cyl_bessel_k/check_nan.cc: Likewise.
881         * testsuite/special_functions/10_cyl_neumann/check_nan.cc: Likewise.
882         * testsuite/special_functions/19_sph_bessel/check_nan.cc: Likewise.
883         * testsuite/special_functions/21_sph_neumann/check_nan.cc: Likewise.
884         * testsuite/tr1/5_numerical_facilities/special_functions/
885         08_cyl_bessel_i/check_nan.cc: Likewise.
886         * testsuite/tr1/5_numerical_facilities/special_functions/
887         09_cyl_bessel_j/check_nan.cc: Likewise.
888         * testuite/tr1/5_numerical_facilities/special_functions/
889         10_cyl_bessel_k/check_nan.cc: Likewise.
890         * testsuite/tr1/5_numerical_facilities/special_functions/
891         11_cyl_neumann/check_nan.cc: Likewise.
892         * testsuite/tr1/5_numerical_facilities/special_functions/
893         21_sph_bessel/check_nan.cc: Likewise.
894         * testsuite/tr1/5_numerical_facilities/special_functions/
895         23_sph_neumann/check_nan.cc: Likewise.
896
897 2019-09-30  Jonathan Wakely  <jwakely@redhat.com>
898
899         * include/std/span (span(element_type(&)[N]))
900         (span(array<value_type, N>&), span(const array<value_type, N>&)):
901         Deduce array element type to allow safe const conversions (LWG 3255).
902         [!_GLIBCXX_P1394] (span(Container&), span(const Container&)): Use
903         remove_cv_t on arguments to __is_std_span and __is_std_array.
904         * testsuite/23_containers/span/lwg3255.cc: New test.
905
906         PR libstdc++/77936
907         * include/parallel/checkers.h (__is_sorted): Remove unused variable.
908
909 2019-09-28  François Dumont  <fdumont@gcc.gnu.org>
910
911         * include/bits/stl_algo.h (merge): Fix documentation.
912         * include/debug/functions.h (__check_sorted_aux): Add C++20 constexpr.
913         (__check_sorted): Likewise and remove nested irreflexive check.
914         (__check_sorted_set_aux, __check_sorted_set): Add C++20 constexpr.
915         (__check_partitioned_lower, __check_partitioned_upper): Likewise.
916         (_Irreflexive_checker::_S_is_valid): Likewise.
917         (__is_irreflexive, __is_irreflexive_pred): Likewise.
918         * include/debug/helper_functions.h (__get_distance): Add constexpr.
919         (__valid_range_aux): Add C++20 constexpr.
920         (__valid_range(_Iter, _Iter, _Distance_traits<_Iter>::__type&)):
921         Likewise and add std::is_constant_evaluated check.
922         (__valid_range_aux(_Iter, _Iter, std::input_iterator_tag)): New.
923         (__valid_range_aux(_Iter, _Iter, std::random_accss_iterator_tag)): New.
924         (__valid_range_aux(_Integral, _Integral, std::__true_type)): New,
925         use latter.
926         (__valid_range(_Iter, _Iter)): Adapt to use latter, add constexpr and
927         __builtin_is_contant_evaludated check..
928         (__can_advance, __base): Add constexpr.
929         * include/debug/macros.h [_GLIBCXX_HAVE_BUILTIN_IS_CONSTANT_EVALUATED]
930         (_GLIBCXX_DEBUG_VERIFY_COND_AT): New.
931         (__glibcxx_check_sorted): Use __glibcxx_check_irreflexive.
932         (__glibcxx_check_sorted_pred): Use __glibcxx_check_irreflexive_pred.
933         * testsuite/25_algorithms/binary_search/constexpr.cc: Use irreflexive
934         std::less.
935         * testsuite/25_algorithms/is_sorted/constexpr.cc: Likewise.
936         * testsuite/25_algorithms/merge/constexpr.cc: Fix order in camm. Fix
937         lambda to be irreflexive.
938
939 2019-09-27  Maciej W. Rozycki  <macro@wdc.com>
940
941         * configure: Regenerate.
942
943 2019-09-27  Jonathan Wakely  <jwakely@redhat.com>
944
945         PR libstdc++/91910
946         * src/c++11/debug.cc (_Safe_iterator_base::_M_detach()): Load pointer
947         atomically and lock the mutex before accessing the sequence.
948         (_Safe_local_iterator_base::_M_detach()): Likewise.
949         (_Safe_iterator_base::_M_reset()): Clear _M_sequence atomically.
950
951 2019-09-26  Jonathan Wakely  <jwakely@redhat.com>
952
953         * include/debug/array (to_array): Define for debug mode.
954
955         * include/bits/stl_pair.h (pair): Add _GLIBCXX20_CONSTEXPR to
956         piecewise construction constructor, assignment operators, and swap.
957         * include/std/tuple (pair::pair(piecewise_construct_t, tuple, tuple)):
958         Add _GLIBCXX20_CONSTEXPR.
959         (pair::pair(tuple, tuple, _Index_tuple, _Index_tuple)): Likewise.
960         * testsuite/20_util/pair/constexpr_assign.cc: New test.
961         * testsuite/20_util/pair/constexpr_swap.cc: New test.
962
963         * include/experimental/internet (operator==, operator<): Fix loop
964         condition to avoid reading past the end of the array.
965
966         * include/std/array: Remove references to profile mode.
967         * include/std/bitset: Likewise.
968         * include/std/deque: Likewise.
969         * include/std/forward_list: Likewise.
970         * include/std/list: Likewise.
971         * include/std/map: Likewise.
972         * include/std/set: Likewise.
973         * include/std/unordered_map: Likewise.
974         * include/std/unordered_set: Likewise.
975         * include/std/vector: Likewise.
976         * testsuite/17_intro/headers/c++1998/profile_mode.cc: New test.
977         * testsuite/17_intro/headers/c++2011/profile_mode.cc: New test.
978
979 2019-09-25  Jonathan Wakely  <jwakely@redhat.com>
980
981         * include/bits/regex.h
982         (basic_regex::assign(const C*, size_t, flag_type)): Add default
983         argument (LWG 3296).
984         * testsuite/28_regex/basic_regex/assign/char/lwg3296.cc: New test.
985         * testsuite/28_regex/basic_regex/assign/wchar_t/lwg3296.cc: New test.
986
987 2019-09-24  Jonathan Wakely  <jwakely@redhat.com>
988
989         * include/std/variant (variant::index()): Remove impossible case.
990
991         PR libstdc++/91871
992         * testsuite/util/testsuite_hooks.h
993         (conversion::iterator_to_const_iterator()): Do not return an invalid
994         iterator. Test direct-initialization and direct-list-initialization
995         as well as implicit conversion.
996
997 2019-09-23  Jonathan Wakely  <jwakely@redhat.com>
998
999         PR libstdc++/91788 (partial)
1000         * include/std/variant (variant::index()): Improve codegen for cases
1001         where conversion to size_t already works correctly.
1002
1003 2019-09-23  Andreas Schwab  <schwab@suse.de>
1004
1005         * config/abi/post/riscv64-linux-gnu/baseline_symbols.txt: Update.
1006
1007 2019-09-12  Jonathan Wakely  <jwakely@redhat.com>
1008
1009         PR libstdc++/91748
1010         * include/bits/stl_algo.h (for_each_n): Fix random access iterator
1011         case.
1012         * testsuite/25_algorithms/for_each/for_each_n.cc: Test with random
1013         access iterators.
1014
1015 2019-09-11  Jonathan Wakely  <jwakely@redhat.com>
1016
1017         * python/libstdcxx/v6/xmethods.py (SharedPtrUseCountWorker.__call__):
1018         Fix syntax error.
1019
1020         * testsuite/20_util/result_of/sfinae_friendly_1.cc: Add -Wno-volatile
1021         for C++2a and up. Define HAS_52748_FIXED and fix incorrect tests.
1022         * testsuite/tr1/3_function_objects/result_of.cc: Add -Wno-volatile
1023         for C++2a and up.
1024
1025 2019-09-10  Jonathan Wakely  <jwakely@redhat.com>
1026
1027         * include/std/type_traits (__do_common_type_impl): Implement
1028         additional COND-RES(CREF(D1), CRED(D2)) condition for C++20.
1029         (basic_common_reference, common_reference, common_reference_t): Define
1030         for C++20.
1031         * testsuite/20_util/common_reference/requirements/alias_decl.cc: New
1032         test.
1033         * testsuite/20_util/common_reference/requirements/
1034         explicit_instantiation.cc: New test.
1035         * testsuite/20_util/common_reference/requirements/typedefs.cc: New
1036         test.
1037
1038         * include/std/charconv (to_chars): Rename to __to_chars_i. Define
1039         non-template overloads for each signed and unsigned integer type and
1040         char. Define deleted overload for bool (LWG 3266).
1041         * testsuite/20_util/to_chars/1_neg.cc: Remove.
1042         * testsuite/20_util/to_chars/3.cc: New test.
1043         * testsuite/20_util/to_chars/lwg3266.cc: New test.
1044
1045 2019-09-10  Christophe Lyon  <christophe.lyon@st.com>
1046
1047         * acinclude.m4: Handle uclinux*.
1048         * configure: Regenerate.
1049         * configure.host: Handle uclinux*
1050
1051 2019-09-10  Christophe Lyon  <christophe.lyon@st.com>
1052         Mickaël Guêné <mickael.guene@st.com>
1053
1054         * libsupc++/eh_personality.cc (get_ttype_entry): Add FDPIC
1055         support.
1056
1057 2019-09-10  Jonathan Wakely  <jwakely@redhat.com>
1058
1059         PR libstdc++/91711
1060         * testsuite/23_containers/span/get_neg.cc: Avoid ambiguity due to
1061         0ul being a valid null pointer constant.
1062
1063         * include/std/type_traits (__remove_cv_t): New alias template.
1064         (is_void, is_integral, is_floating_point, is_pointer)
1065         (is_member_object_pointer, is_member_function_pointer, is_null_pointer)
1066         (is_member_point), __is_signed_integer, __is_unsigned_integer)
1067         (__make_unsigned_selector, __make_signed_selector, remove_pointer)
1068         (__decay_selector): Use __remove_cv_t.
1069         (remove_cv): Add partial specializations for cv-qualified types.
1070         (__decay_t): New alias template.
1071         (__decay_and_strip, __common_type_impl, __result_of_impl): Use
1072         __decay_t.
1073         (__enable_if_t): Move earlier in the file.
1074         (_Require): Use __enable_if_t.
1075         (swap(T&, T&)): Use _Require.
1076         (swap(T(&)[N])): Use __enable_if_t.
1077
1078 2019-09-09  Edward Smith-Rowland  <3dw4rd@verizon.net>
1079
1080         Implement C++20 p1424 - 'constexpr' feature macro concerns,
1081         Issue 3256 - Feature testing macro for constexpr algorithms,
1082         and Issue 3257 - Missing feature testing macro update from P0858.
1083         * include/std/version (__cpp_lib_constexpr_algorithms): Bump value.
1084         * include/bits/algorithmfwd.h: Ditto.
1085         * include/std/utility: Ditto.
1086         * testsuite/25_algorithms/constexpr_macro.cc: Ditto.
1087         * testsuite/25_algorithms/cpp_lib_constexpr.cc: New check for
1088         __cpp_lib_constexpr macro in <algorith>.
1089         * testsuite/20_util/exchange/constexpr.cc: Add check for
1090         __cpp_lib_constexpr macro in <utility>.
1091         * testsuite/25_algorithms/adjacent_find/constexpr.cc: Remove check for
1092         __cpp_lib_constexpr_algorithms.
1093         * testsuite/25_algorithms/all_of/constexpr.cc: Ditto.
1094         * testsuite/25_algorithms/any_of/constexpr.cc: Ditto.
1095         * testsuite/25_algorithms/binary_search/constexpr.cc: Ditto.
1096         * testsuite/25_algorithms/copy/constexpr.cc: Ditto.
1097         * testsuite/25_algorithms/copy_backward/constexpr.cc: Ditto.
1098         * testsuite/25_algorithms/copy_if/constexpr.cc: Ditto.
1099         * testsuite/25_algorithms/copy_n/constexpr.cc: Ditto.
1100         * testsuite/25_algorithms/count/constexpr.cc: Ditto.
1101         * testsuite/25_algorithms/count_if/constexpr.cc: Ditto.
1102         * testsuite/25_algorithms/equal/constexpr.cc: Ditto.
1103         * testsuite/25_algorithms/equal_range/constexpr.cc: Ditto.
1104         * testsuite/25_algorithms/fill/constexpr.cc: Ditto.
1105         * testsuite/25_algorithms/fill_n/constexpr.cc: Ditto.
1106         * testsuite/25_algorithms/find/constexpr.cc: Ditto.
1107         * testsuite/25_algorithms/find_end/constexpr.cc: Ditto.
1108         * testsuite/25_algorithms/find_first_of/constexpr.cc: Ditto.
1109         * testsuite/25_algorithms/find_if/constexpr.cc: Ditto.
1110         * testsuite/25_algorithms/find_if_not/constexpr.cc: Ditto.
1111         * testsuite/25_algorithms/for_each/constexpr.cc: Ditto.
1112         * testsuite/25_algorithms/generate/constexpr.cc: Ditto.
1113         * testsuite/25_algorithms/generate_n/constexpr.cc: Ditto.
1114         * testsuite/25_algorithms/is_heap/constexpr.cc: Ditto.
1115         * testsuite/25_algorithms/is_heap_until/constexpr.cc: Ditto.
1116         * testsuite/25_algorithms/is_partitioned/constexpr.cc: Ditto.
1117         * testsuite/25_algorithms/is_permutation/constexpr.cc: Ditto.
1118         * testsuite/25_algorithms/is_sorted/constexpr.cc: Ditto.
1119         * testsuite/25_algorithms/is_sorted_until/constexpr.cc: Ditto.
1120         * testsuite/25_algorithms/lexicographical_compare/constexpr.cc: Ditto.
1121         * testsuite/25_algorithms/lower_bound/constexpr.cc: Ditto.
1122         * testsuite/25_algorithms/merge/constexpr.cc: Ditto.
1123         * testsuite/25_algorithms/mismatch/constexpr.cc: Ditto.
1124         * testsuite/25_algorithms/none_of/constexpr.cc: Ditto.
1125         * testsuite/25_algorithms/partition_copy/constexpr.cc: Ditto.
1126         * testsuite/25_algorithms/partition_point/constexpr.cc: Ditto.
1127         * testsuite/25_algorithms/remove/constexpr.cc: Ditto.
1128         * testsuite/25_algorithms/remove_copy/constexpr.cc: Ditto.
1129         * testsuite/25_algorithms/remove_copy_if/constexpr.cc: Ditto.
1130         * testsuite/25_algorithms/remove_if/constexpr.cc: Ditto.
1131         * testsuite/25_algorithms/replace_copy/constexpr.cc: Ditto.
1132         * testsuite/25_algorithms/replace_copy_if/constexpr.cc: Ditto.
1133         * testsuite/25_algorithms/replace_if/constexpr.cc: Ditto.
1134         * testsuite/25_algorithms/reverse_copy/constexpr.cc: Ditto.
1135         * testsuite/25_algorithms/rotate_copy/constexpr.cc: Ditto.
1136         * testsuite/25_algorithms/search/constexpr.cc: Ditto.
1137         * testsuite/25_algorithms/search_n/constexpr.cc: Ditto.
1138         * testsuite/25_algorithms/set_difference/constexpr.cc: Ditto.
1139         * testsuite/25_algorithms/set_intersection/constexpr.cc: Ditto.
1140         * testsuite/25_algorithms/set_symmetric_difference/constexpr.cc: Ditto.
1141         * testsuite/25_algorithms/set_union/constexpr.cc: Ditto.
1142         * testsuite/25_algorithms/transform/constexpr.cc: Ditto.
1143         * testsuite/25_algorithms/unique/constexpr.cc: Ditto.
1144         * testsuite/25_algorithms/unique_copy/constexpr.cc: Ditto.
1145         * testsuite/25_algorithms/upper_bound/constexpr.cc: Ditto.
1146
1147 2019-09-09  Edward Smith-Rowland  <3dw4rd@verizon.net>
1148
1149         Update docs for recent <span> and constexpr lib changes.
1150         * doc/xml/manual/status_cxx2020.xml: Update p0202r3, p0858r0, p0879r0,
1151         p1023r0, p1085r2 status.
1152         * doc/html/manual/status.html: Regenerate.
1153
1154 2019-09-09  Antony Polukhin  <antoshkka@gmail.com>
1155
1156         * include/bits/charconv.h (__detail::__to_chars_10_impl): Replace
1157         final offsets with constants.
1158
1159 2019-09-09  Jonathan Wakely  <jwakely@redhat.com>
1160
1161         * include/bits/range_access.h (__adl_to_address): Remove.
1162         * include/std/span (__is_base_derived_safe_convertible_v): Replace
1163         with span::__is_compatible.
1164         (__is_std_array_v): Replace with __is_std_array class template and
1165         partial specializations.
1166         (__is_std_array, __is_std_span): New class templates and partial
1167         specializations.
1168         (span::__is_compatible): New alias template for SFINAE constraints.
1169         (span::span(element_type (&)[N])): Remove redundant constraints. Do
1170         not use __adl_data to obtain a pointer.
1171         (span::span(array<value_type, N>&)): Likewise.
1172         (span::span(const array<value_type, N>&)): Likewise.
1173         [_GLIBCXX_P1394] (span::iter_reference_t, span::iterator_t)
1174         (span::iter_value_t, span::derived_from): New alias templates for
1175         SFINAE constraints, until the equivalents are supported in <concepts>
1176         and <iterator>.
1177         [_GLIBCXX_P1394] (span::__is_compatible_iterator): New alias template
1178         for SFINAE constraints.
1179         [_GLIBCXX_P1394] (span::is_compatible_range): New class template for
1180         SFINAE constraints.
1181         [_GLIBCXX_P1394] (span::span(Range&&)): Improve constraints.
1182         [_GLIBCXX_P1394] (span::span(ContiguousIterator, Sentinel)): Likewise.
1183         Use std::to_address instead of __adl_to_address.
1184         [_GLIBCXX_P1394] (span::span(ContiguousIterator, size_type)): Likewise.
1185         [!_GLIBCXX_P1394] (span::__is_compatible_container): New alias
1186         template for SFINAE constraints.
1187         [!_GLIBCXX_P1394] (span::span(Container&))
1188         (span::span(const Container&)): Improve constraints.
1189         [!_GLIBCXX_P1394] (span::span(pointer, size_type))
1190         (span::span(pointer, pointer)): Remove redundant cast of pointer.
1191         (span(const span<OType, OExtent>&)): New constructor.
1192
1193 2019-09-06  Jonathan Wakely  <jwakely@redhat.com>
1194
1195         * include/bits/range_access.h (ssize): Define for C++20.
1196         * testsuite/24_iterators/range_access_cpp20.cc: New test.
1197         * doc/xml/manual/status_cxx2020.xml: Update P1227R2 status.
1198         * doc/html/*: Regenerate.
1199
1200 2019-09-06  Florian Weimer  <fweimer@redhat.com>
1201
1202         * configure: Regenerate.
1203
1204 2019-09-05  Jonathan Wakely  <jwakely@redhat.com>
1205
1206         * doc/xml/manual/status_cxx2020.xml: Update status for P0122R7 and
1207         P1024R3. Remove entry for P0920R2.
1208         * include/std/span  (__cpp_lib_span): Change value.
1209         (__extent_storage, __extent_storage<dynamic_extent>): Remove default
1210         constructor.
1211         (span): Replace __extent_storage base class with data member.
1212         (span::_S_subspan_extent): New function.
1213         (span::empty()): Add nodiscard attribute.
1214         (span::front, span::back, span::operator[]): Check preconditions.
1215         (span::first, span::last, span::subspan): Add noexcept. Improve
1216         precondition checks (LWG 3103).
1217         (get): Remove redundant condition from static_assert.
1218         (tuple_element<I, span<T, E>>): Fix static_assert message and simplify.
1219         (as_writable_bytes): Add inline specifier.
1220         * include/std/version (__cpp_lib_span): Change value.
1221         * testsuite/23_containers/span/back_neg.cc: Remove stray semi-colon.
1222         * testsuite/23_containers/span/front_neg.cc: Likewise.
1223         * testsuite/23_containers/span/index_op_neg.cc: Likewise.
1224         * testsuite/23_containers/span/last_neg.cc: Improve test.
1225         * testsuite/23_containers/span/subspan_neg.cc: Likewise.
1226         * testsuite/23_containers/span/1.cc: New test.
1227         * testsuite/23_containers/span/2.cc: New test.
1228         * testsuite/23_containers/span/back_assert_neg.cc: New test.
1229         * testsuite/23_containers/span/first_2_assert_neg.cc: New test.
1230         * testsuite/23_containers/span/first_assert_neg.cc: New test.
1231         * testsuite/23_containers/span/first_neg.cc: New test.
1232         * testsuite/23_containers/span/front_assert_neg.cc: New test.
1233         * testsuite/23_containers/span/index_op_assert_neg.cc: New test.
1234         * testsuite/23_containers/span/last_2_assert_neg.cc: New test.
1235         * testsuite/23_containers/span/last_assert_neg.cc: New test.
1236         * testsuite/23_containers/span/subspan_2_assert_neg.cc: New test.
1237         * testsuite/23_containers/span/subspan_3_assert_neg.cc: New test.
1238         * testsuite/23_containers/span/subspan_4_assert_neg.cc: New test.
1239         * testsuite/23_containers/span/subspan_5_assert_neg.cc: New test.
1240         * testsuite/23_containers/span/subspan_6_assert_neg.cc: New test.
1241         * testsuite/23_containers/span/subspan_assert_neg.cc: New test.
1242
1243 2019-09-05  JeanHeyd Meneide  <phdofthehouse@gmail.com>
1244
1245         * include/Makefile.am: Add <span> header.
1246         * include/Makefile.in: Regenerate.
1247         * include/bits/range_access.h (__adl_begin, __adl_end, __adl_cbegin)
1248         (__adl_cend, __adl_rbegin, __adl_rend, __adl_crbegin, __adl_crend)
1249         (__adl_data, __adl_cdata, __adl_size, __adl_empty, __adl_to_address):
1250         New functions for performing argument-dependent lookup of range
1251         customization points.
1252         * include/bits/stl_iterator.h (__normal_iterator): Add
1253         _GLIBCXX20_CONSTEXPR to all functions.
1254         * include/std/span: New header.
1255         * include/std/version (__cpp_lib_span): Define feature test macro.
1256         * testsuite/23_containers/span/contiguous_range_neg.cc: New test.
1257         * testsuite/23_containers/span/everything.cc: New test.
1258         * testsuite/23_containers/span/get_neg.cc: New test.
1259         * testsuite/23_containers/span/last_neg.cc: New test.
1260         * testsuite/23_containers/span/subspan_neg.cc: New test.
1261         * testsuite/23_containers/span/tuple_element_dynamic_neg.cc: New test.
1262         * testsuite/23_containers/span/tuple_element_oob_neg.cc: New test.
1263         * testsuite/23_containers/span/tuple_size_neg.cc: New test.
1264
1265 2019-09-05  Jonathan Wakely  <jwakely@redhat.com>
1266
1267         * doc/xml/manual/allocator.xml: Remove URL for bibliography entry.
1268         * doc/html/*: Regenerate.
1269
1270 2019-09-04  Mike Crowe  <mac@mcrowe.com>
1271
1272         PR libstdc++/41861
1273         * acinclude.m4 (GLIBCXX_CHECK_PTHREAD_COND_CLOCKWAIT): Check for new
1274         pthread_cond_clockwait function.
1275         * configure.ac: Use GLIBCXX_CHECK_PTHREAD_COND_CLOCKWAIT.
1276         * configure: Regenerate.
1277         * config.h.in: Regenerate.
1278         * include/std/condition_variable: (condition_variable): Rename
1279         __steady_clock_t typedef and add system_clock. Change __clock_t to be
1280         a typedef for the preferred clock to convert arbitrary other clocks to.
1281         [_GLIBCXX_USE_PTHREAD_COND_CLOCKWAIT] (wait_until): Add a steady_clock
1282         overload.
1283         (wait_until): Change __clock_t overload to use system_clock.
1284         [_GLIBCXX_USE_PTHREAD_COND_CLOCKWAIT] (__wait_until_impl): Add
1285         steady_clock overload that calls pthread_cond_clockwait.
1286         (__wait_until_impl): Change __clock_t overload to use system_clock.
1287         (condition_variable_any) [_GLIBCXX_USE_PTHREAD_COND_CLOCKWAIT]: Use
1288         steady_clock for __clock_t if pthread_cond_clockwait is available.
1289
1290 2019-09-04  Mike Crowe  <mac@mcrowe.com>
1291
1292         * testsuite/30_threads/condition_variable/members/2.cc (test01):
1293         Parameterise so that test can be run against an arbitrary clock.
1294         (main): Test using std::chrono::steady_clock and a user-defined
1295         clock in addition to the previous std::chrono::system_clock.
1296         * testsuite/30_threads/condition_variable_any/members/2.cc: Likewise.
1297
1298 2019-09-03  Ulrich Weigand  <uweigand@de.ibm.com>
1299
1300         * crossconfig.m4: Remove references to spu.
1301         * configure: Regenerate.
1302         * doc/xml/manual/appendix_contributing.xml: Remove references
1303         to __ea as "badword" for spu.
1304         * doc/html/manual/source_code_style.html: Regenerate.
1305         * include/tr1/ell_integral.tcc (__ellint_rd): Do not attempt
1306         to avoid __ea (as "badword" for spu).
1307         (__ellint_rj): Likewise.
1308
1309 2019-09-03  Chung-Lin Tang  <cltang@codesourcery.com>
1310
1311         PR other/79543
1312         * acinclude.m4 (GLIBCXX_CHECK_LINKER_FEATURES): Fix GNU ld --version
1313         scanning to conform to the GNU Coding Standards.
1314         * configure: Regenerate.
1315
1316 2019-09-02  Jonathan Wakely  <jwakely@redhat.com>
1317
1318         * src/c++17/memory_resource.cc: Use __constinit keyword.
1319
1320 2019-09-02  Jonathan Wakely  <jwakely@redhat.com>
1321
1322         * doc/xml/manual/abi.xml: Document 9.x library versions.
1323         * doc/html/*: Regenerate.
1324
1325 2019-09-02  Jonathan Wakely  <jwakely@redhat.com>
1326
1327         * include/std/charconv (__detail::__to_chars_2_len): Use std::log2p1.
1328         (__detail::__to_chars_8_len): Remove.
1329         (__detail::__to_chars_8): Inline length calculation here.
1330         (__detail::__from_chars_binary): Use numeric_limits instead of
1331         CHAR_BIT.
1332
1333 2019-09-02  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
1334
1335         * config/abi/post/i386-solaris/baseline_symbols.txt: Regenerate.
1336         * config/abi/post/i386-solaris/amd64/baseline_symbols.txt: Likewise.
1337         * config/abi/post/sparc-solaris/baseline_symbols.txt: Likewise.
1338         * config/abi/post/sparc-solaris/sparcv9/baseline_symbols.txt:
1339         Likewise.
1340
1341 2019-09-01  François Dumont  <fdumont@gcc.gnu.org>
1342
1343         * testsuite_files/util/testsuite_performance.h
1344         (resource_counter::start): Ignore unused malloc(0) result.
1345
1346 2019-09-01  Gerald Pfeifer  <gerald@pfeifer.com>
1347
1348         * doc/xml/manual/policy_data_structures_biblio.xml (COM: Component
1349         Model Object Technologies): Adjust name and link.
1350
1351 2019-08-30  Antony Polukhin  <antoshkka@gmail.com>
1352
1353         * include/std/charconv (__detail::__to_chars_8)
1354         __detail::__to_chars_16): Replace array of precomputed digits with
1355         arithmetic operations to avoid CPU cache misses. Remove zero
1356         termination from array of digits to allow symbol merge with generic
1357         implementation of __detail::__to_chars. Replace final offsets with
1358         constants. Use __detail::__to_chars_len_2 instead of a generic
1359         __detail::__to_chars_len.
1360         (__detail::__to_chars): Remove zero termination from array of digits.
1361         (__detail::__to_chars_2): Leading digit is always '1'.
1362
1363 2019-08-30  Jonathan Wakely  <jwakely@redhat.com>
1364
1365         * testsuite/23_containers/vector/cons/89164_c++17.cc: Fix errors.
1366
1367 2019-08-30  Uros Bizjak  <ubizjak@gmail.com>
1368
1369         * config/abi/post/alpha-linux-gnu/baseline_symbols.txt: Update.
1370
1371 2019-08-30  Jonathan Wakely  <jwakely@redhat.com>
1372
1373         PR libstdc++/89164
1374         * include/bits/stl_algobase.h (__copy_move): Give descriptive names
1375         to template parameters.
1376         * include/bits/stl_uninitialized.h (uninitialized_copy)
1377         (uninitialized_fill, uninitialized_fill_n): Add static assertions to
1378         diagnose invalid uses.
1379         * testsuite/20_util/specialized_algorithms/uninitialized_copy/1.cc:
1380         Adjust expected error.
1381         * testsuite/20_util/specialized_algorithms/uninitialized_copy/89164.cc:
1382         New test.
1383         * testsuite/20_util/specialized_algorithms/uninitialized_copy_n/
1384         89164.cc: New test.
1385         * testsuite/20_util/specialized_algorithms/uninitialized_fill/89164.cc:
1386         New test.
1387         * testsuite/20_util/specialized_algorithms/uninitialized_fill_n/
1388         89164.cc: New test.
1389         * testsuite/23_containers/vector/cons/89164.cc: New test.
1390         * testsuite/23_containers/vector/cons/89164_c++17.cc: New test.
1391
1392 2019-08-29  Jonathan Wakely  <jwakely@redhat.com>
1393
1394         PR libstdc++/91067
1395         * acinclude.m4 (libtool_VERSION): Bump to 6:28:0.
1396         * configure: Regenerate.
1397         * config/abi/pre/gnu.ver (GLIBCXX_3.4.28): Add new version. Export
1398         missing symbols.
1399         * testsuite/27_io/filesystem/iterators/91067.cc: Test move
1400         constructors.
1401         * testsuite/util/testsuite_abi.cc: Add new symbol version.
1402
1403 2019-08-29  Jakub Jelinek  <jakub@redhat.com>
1404
1405         * config/abi/post/aarch64-linux-gnu/baseline_symbols.txt: Update.
1406         * config/abi/post/s390x-linux-gnu/baseline_symbols.txt: Update.
1407
1408 2019-08-28  Jonathan Wakely  <jwakely@redhat.com>
1409
1410         * config/abi/post/i386-linux-gnu/baseline_symbols.txt: Update.
1411         * config/abi/post/i486-linux-gnu/baseline_symbols.txt: Update.
1412         * config/abi/post/powerpc-linux-gnu/baseline_symbols.txt: Update.
1413         * config/abi/post/powerpc64-linux-gnu/32/baseline_symbols.txt: Update.
1414         * config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt: Update.
1415         * config/abi/post/x86_64-linux-gnu/32/baseline_symbols.txt: Update.
1416         * config/abi/post/x86_64-linux-gnu/baseline_symbols.txt: Update.
1417
1418 2019-08-23  Joseph Myers  <joseph@codesourcery.com>
1419
1420         * src/filesystem/ops-common.h [_GLIBCXX_FILESYSTEM_IS_WINDOWS]
1421         (std::filesystem::__gnu_posix::lstat): Add return type.
1422
1423 2019-08-20  Jonathan Wakely  <jwakely@redhat.com>
1424
1425         * doc/doxygen/user.cfg.in (INPUT): Remove profile mode headers.
1426
1427         * include/std/numeric (reduce): Fix Doxygen markup.
1428
1429         PR libstdc++/91371
1430         * include/std/type_traits (is_function): Simplify definition. Remove
1431         partial specializations for function types.
1432         (__is_referenceable): Simplify definition.
1433         * testsuite/20_util/bind/91371.cc: New test.
1434         * testsuite/20_util/is_function/91371.cc: New test.
1435         * testsuite/20_util/is_function/value.cc: Check more pointer types.
1436         * testsuite/20_util/is_member_function_pointer/91371.cc: New test.
1437         * testsuite/20_util/is_object/91371.cc: New test.
1438
1439 2019-08-16  Uros Bizjak  <ubizjak@gmail.com>
1440
1441         * config/abi/post/alpha-linux-gnu/baseline_symbols.txt: Update.
1442
1443 2019-08-15  Jonathan Wakely  <jwakely@redhat.com>
1444
1445         PR libstdc++/91456
1446         * include/bits/std_function.h (__check_func_return_type): Remove.
1447         (function::_Callable): Use std::__is_invocable_impl instead of
1448         __check_func_return_type.
1449         * include/std/type_traits (__is_invocable_impl): Add another defaulted
1450         template parameter. Define a separate partial specialization for
1451         INVOKE and INVOKE<void>. For INVOKE<R> replace is_convertible check
1452         with a check that models delayed temporary materialization.
1453         * testsuite/20_util/function/91456.cc: New test.
1454         * testsuite/20_util/is_invocable/91456.cc: New test.
1455
1456 2019-08-14  Jonathan Wakely  <jwakely@redhat.com>
1457
1458         * include/std/type_traits (__is_nullptr_t): Add deprecated attribute.
1459
1460 2019-08-14  Edward Smith-Rowland  <3dw4rd@verizon.net>
1461
1462         Implement C++20 p0879 - Constexpr for swap and swap related functions.
1463         * include/std/version (__cpp_lib_constexpr_swap_algorithms): New macro.
1464         * include/bits/algorithmfwd.h (__cpp_lib_constexpr_swap_algorithms):
1465         New macro.
1466         (iter_swap, make_heap, next_permutation, partial_sort_copy, pop_heap)
1467         (prev_permutation, push_heap, reverse, rotate, sort_heap, swap)
1468         (swap_ranges, nth_element, partial_sort, sort): Add constexpr.
1469         * include/bits/move.h (swap): Add constexpr.
1470         * include/bits/stl_algo.h (__move_median_to_first, __reverse, reverse)
1471         (__gcd, __rotate, rotate, __partition, __heap_select)
1472         (__partial_sort_copy, partial_sort_copy, __unguarded_partition)
1473         (__unguarded_partition_pivot, __partial_sort, __introsort_loop, __sort)
1474         (__introselect, __chunk_insertion_sort, next_permutation)
1475         (prev_permutation, partition, partial_sort, nth_element, sort)
1476         (__iter_swap::iter_swap, iter_swap, swap_ranges): Add constexpr.
1477         * include/bits/stl_algobase.h (__iter_swap::iter_swap, iter_swap)
1478         (swap_ranges): Add constexpr.
1479         * include/bits/stl_heap.h (__push_heap, push_heap, __adjust_heap,
1480         __pop_heap, pop_heap, __make_heap, make_heap, __sort_heap, sort_heap):
1481         Add constexpr.
1482         * include/std/type_traits (swap): Add constexpr.
1483         * testsuite/25_algorithms/headers/algorithm/synopsis.cc: Add constexpr.
1484         * testsuite/25_algorithms/iter_swap/constexpr.cc: New test.
1485         * testsuite/25_algorithms/make_heap/constexpr.cc: New test.
1486         * testsuite/25_algorithms/next_permutation/constexpr.cc: New test.
1487         * testsuite/25_algorithms/nth_element/constexpr.cc: New test.
1488         * testsuite/25_algorithms/partial_sort/constexpr.cc: New test.
1489         * testsuite/25_algorithms/partial_sort_copy/constexpr.cc: New test.
1490         * testsuite/25_algorithms/partition/constexpr.cc: New test.
1491         * testsuite/25_algorithms/pop_heap/constexpr.cc: New test.
1492         * testsuite/25_algorithms/prev_permutation/constexpr.cc: New test.
1493         * testsuite/25_algorithms/push_heap/constexpr.cc: New test.
1494         * testsuite/25_algorithms/reverse/constexpr.cc: New test.
1495         * testsuite/25_algorithms/rotate/constexpr.cc: New test.
1496         * testsuite/25_algorithms/sort/constexpr.cc: New test.
1497         * testsuite/25_algorithms/sort_heap/constexpr.cc: New test.
1498         * testsuite/25_algorithms/swap/constexpr.cc: New test.
1499         * testsuite/25_algorithms/swap_ranges/constexpr.cc: New test.
1500
1501 2019-08-12  Jonathan Wakely  <jwakely@redhat.com>
1502
1503         PR libstdc++/90361
1504         * src/c++17/string-inst.cc: Use _GLIBCXX_USE_CXX11_ABI=1 by default.
1505
1506         * include/std/tuple (__unpack_std_tuple): New variable template and
1507         partial specializations.
1508         (apply, make_from_tuple): Add noexcept-specifier.
1509         * testsuite/20_util/tuple/apply/2.cc: New test.
1510         * testsuite/20_util/tuple/make_from_tuple/2.cc: New test.
1511
1512 2019-08-09  Corentin Gay  <gay@adacore.com>
1513
1514         * testsuite/ext/random/beta_distribution/operators/serialize.cc,
1515         testsuite/ext/random/hypergeometric_distribution/operators/serialize.cc,
1516         testsuite/ext/random/normal_mv_distribution/operators/serialize.cc,
1517         testsuite/ext/random/triangular_distribution/operators/serialize.cc,
1518         testsuite/ext/random/von_mises_distribution/operators/serialize.cc:
1519         Add call to `VERIFY`.
1520
1521 2019-08-09  Alexandre Oliva <oliva@adacore.com>
1522
1523         * include/ext/random
1524         (normal_mv_distribution::param_type::param_type): New private
1525         ctor taking a decomposed varcov matrix, for use by...
1526         (operator>>): ... this, befriended.
1527         * include/ext/random.tcc (operator>>): Use it.
1528         (normal_mv_distribution::param_type::_M_init_lower): Adjust
1529         member function name in exception message.
1530
1531 2019-08-08  Jonathan Wakely  <jwakely@redhat.com>
1532
1533         P0325R4 to_array from LFTS with updates
1534         * include/experimental/array (to_array): Qualify call to __to_array.
1535         * include/std/array (__cpp_lib_to_array, to_array): Define for C++20.
1536         * include/std/version (__cpp_lib_to_array): Likewise.
1537         * testsuite/23_containers/array/creation/1.cc: New test.
1538         * testsuite/23_containers/array/creation/2.cc: New test.
1539         * testsuite/23_containers/array/creation/3_neg.cc: New test.
1540         * testsuite/23_containers/array/tuple_interface/tuple_element_neg.cc:
1541         Use zero for dg-error line number.
1542
1543 2019-08-06  Jonathan Wakely  <jwakely@redhat.com>
1544
1545         P1651R0 bind_front should not unwrap reference_wrapper
1546         * include/std/functional (bind_front): Don't unwrap reference_wrapper.
1547         * include/std/version (__cpp_lib_bind_front): Update value.
1548         * testsuite/20_util/function_objects/bind_front/1.cc: Fix test for
1549         feature test macro.
1550         * testsuite/20_util/function_objects/bind_front/2.cc: New test.
1551
1552         * include/std/numbers [!__STRICT_ANSI__ && _GLIBCXX_USE_FLOAT128]
1553         (e_v, log2e_v, log10e_v, pi_v, inv_pi_v, inv_sqrtpi_v, ln2_v, ln10_v)
1554         (sqrt2_v, sqrt3_v, inv_sqrt3, egamma_v, phi_v): Add explicit
1555         specializations for __float128.
1556         * testsuite/26_numerics/numbers/float128.cc: New test.
1557
1558 2019-08-04  Gerald Pfeifer  <gerald@pfeifer.com>
1559
1560         * doc/xml/manual/documentation_hacking.xml: doxygen.org is now
1561         doxygen.nl.
1562
1563 2019-08-01  Edward Smith-Rowland  <3dw4rd@verizon.net>
1564
1565         Implement C++20 p0202 - Add Constexpr Modifiers to Functions
1566         in <algorithm> and <utility> Headers.
1567         Implement C++20 p1023 - constexpr comparison operators for std::array.
1568         * include/bits/algorithmfwd.h (all_of, any_of, binary_search, copy,
1569         copy_backward, copy_if, copy_n, equal_range, fill, find_end,
1570         find_if_not, includes, is_heap, is_heap_until, is_partitioned,
1571         is_permutation, is_sorted, is_sorted_until, iter_swap, lower_bound,
1572         none_of, partition_copy, partition_point, remove, remove_if,
1573         remove_copy, remove_copy_if, replace_copy, replace_copy_if,
1574         reverse_copy, rotate_copy, uunique, upper_bound, adjacent_find, count,
1575         count_if, equal, find, find_first_of, find_if, for_each, generate,
1576         generate_n, lexicographical_compare, merge, mismatch, replace,
1577         replace_if, search, search_n, set_difference, set_intersection,
1578         set_symmetric_difference, set_union, transform, unique_copy):
1579         Mark constexpr.
1580         * include/bits/cpp_type_traits.h (__miter_base): Mark constexpr.
1581         * include/bits/predefined_ops.h (_Iter_less_val::operator(),
1582         _Val_less_iter::operator(), _Iter_equal_to_iter::operator(),
1583         _Iter_equal_to_val::operator(), _Iter_equals_val::operator()):
1584          Use const ref instead of ref arg;
1585         (_Iter_less_val, __iter_less_val, _Val_less_iter, __val_less_iter,
1586         __iter_equal_to_iter, __iter_equal_to_val, __iter_comp_val,
1587         _Iter_comp_val, _Val_comp_iter, __val_comp_iter, __iter_equals_val,
1588         _Iter_equals_iter, __iter_comp_iter, _Iter_pred, __pred_iter,
1589         _Iter_comp_to_val, __iter_comp_val, _Iter_comp_to_iter,
1590         __iter_comp_iter): Mark constexpr.
1591         * include/bits/stl_algo.h (__find_if, __find_if_not, __find_if_not_n,
1592         __search, __search_n_aux, __search_n, __find_end, find_end, all_of,
1593         none_of, any_of, find_if_not, is_partitioned, partition_point,
1594         __remove_copy_if, remove_copy, remove_copy_if, copy_if, __copy_n,
1595         copy_n, partition_copy, __remove_if, remove, remove_if, __adjacent_find,
1596         __unique, unique, __unique_copy, reverse_copy, rotate_copy,
1597         __unguarded_linear_insert, __insertion_sort, __unguarded_insertion_sort,
1598         __final_insertion_sort, lower_bound, __upper_bound, upper_bound,
1599         __equal_range, equal_range, binary_search, __includes, includes,
1600         __next_permutation, __prev_permutation, __replace_copy_if, replace_copy,
1601         replace_copy_if, __count_if, is_sorted, __is_sorted_until,
1602         is_sorted_until, __is_permutation, is_permutation, for_each, find,
1603         find_if, find_first_of, adjacent_find, count, count_if, search,
1604         search_n, transform, replace, replace_if, generate, generate_n,
1605         unique_copy, __merge, merge, __set_union, set_union, __set_intersection,
1606         set_intersection, __set_difference, set_difference,
1607         __set_symmetric_difference, set_symmetric_difference):  Mark constexpr.
1608         * include/bits/stl_algobase.h (__memmove, __memcmp): New maybe constexpr
1609         wrappers around __builtin_memmove and __builtin_memcmp
1610         respectively;
1611         (__niter_base, __niter_wrap, __copy_m, __copy_move_a, __copy_move_a2,
1612         copy, move, __copy_move_b, __copy_move_backward_a,
1613         __copy_move_backward_a2, copy_backward, move_backward, __fill_a, fill,
1614         __fill_n_a, fill_n, equal, __lc_rai::__newlast1, __lc_rai::__cnd2,
1615         __lexicographical_compare_impl, __lexicographical_compare,
1616         __lexicographical_compare<true>::__lc, __lexicographical_compare_aux,
1617         __lower_bound, lower_bound, equal, __equal4, lexicographical_compare,
1618         __mismatch, mismatch, __is_heap_until, __is_heap, is_heap_until,
1619         is_heap): Mark constexpr.
1620         * include/bits/stl_heap.h (__is_heap_until, __is_heap, is_heap_until,
1621         is_heap): Mark constexpr.
1622         * include/bits/stl_iterator.h (__niter_base, __miter_base): Mark constexpr.
1623         * include/std/array: Make comparison ops constexpr.
1624         * include/std/utility: Make exchange constexpr.
1625         * include/std/version (__cpp_lib_constexpr_algorithms): New macro.
1626         * testsuite/23_containers/array/tuple_interface/get_neg.cc: Adjust.
1627         * testsuite/23_containers/array/tuple_interface/
1628         tuple_element_neg.cc: Adjust.
1629         * testsuite/20_util/exchange/constexpr.cc: New.
1630         * testsuite/23_containers/array/comparison_operators/constexpr.cc: New.
1631         * testsuite/25_algorithms/constexpr_macro.cc: New.
1632         * testsuite/25_algorithms/adjacent_find/constexpr.cc: New.
1633         * testsuite/25_algorithms/all_of/constexpr.cc: New.
1634         * testsuite/25_algorithms/any_of/constexpr.cc: New.
1635         * testsuite/25_algorithms/binary_search/constexpr.cc: New.
1636         * testsuite/25_algorithms/copy/constexpr.cc: New.
1637         * testsuite/25_algorithms/copy_backward/constexpr.cc: New.
1638         * testsuite/25_algorithms/copy_if/constexpr.cc: New.
1639         * testsuite/25_algorithms/copy_n/constexpr.cc: New.
1640         * testsuite/25_algorithms/count/constexpr.cc: New.
1641         * testsuite/25_algorithms/count_if/constexpr.cc: New.
1642         * testsuite/25_algorithms/equal/constexpr.cc: New.
1643         * testsuite/25_algorithms/equal_range/constexpr.cc: New.
1644         * testsuite/25_algorithms/fill/constexpr.cc: New.
1645         * testsuite/25_algorithms/fill_n/constexpr.cc: New.
1646         * testsuite/25_algorithms/find/constexpr.cc: New.
1647         * testsuite/25_algorithms/find_end/constexpr.cc: New.
1648         * testsuite/25_algorithms/find_first_of/constexpr.cc: New.
1649         * testsuite/25_algorithms/find_if/constexpr.cc: New.
1650         * testsuite/25_algorithms/find_if_not/constexpr.cc: New.
1651         * testsuite/25_algorithms/for_each/constexpr.cc: New.
1652         * testsuite/25_algorithms/generate/constexpr.cc: New.
1653         * testsuite/25_algorithms/generate_n/constexpr.cc: New.
1654         * testsuite/25_algorithms/is_heap/constexpr.cc: New.
1655         * testsuite/25_algorithms/is_heap_until/constexpr.cc: New.
1656         * testsuite/25_algorithms/is_partitioned/constexpr.cc: New.
1657         * testsuite/25_algorithms/is_permutation/constexpr.cc: New.
1658         * testsuite/25_algorithms/is_sorted/constexpr.cc: New.
1659         * testsuite/25_algorithms/is_sorted_until/constexpr.cc: New.
1660         * testsuite/25_algorithms/lexicographical_compare/constexpr.cc: New.
1661         * testsuite/25_algorithms/lower_bound/constexpr.cc: New.
1662         * testsuite/25_algorithms/merge/constexpr.cc: New.
1663         * testsuite/25_algorithms/mismatch/constexpr.cc: New.
1664         * testsuite/25_algorithms/none_of/constexpr.cc: New.
1665         * testsuite/25_algorithms/partition_copy/constexpr.cc: New.
1666         * testsuite/25_algorithms/partition_point/constexpr.cc: New.
1667         * testsuite/25_algorithms/remove/constexpr.cc: New.
1668         * testsuite/25_algorithms/remove_copy/constexpr.cc: New.
1669         * testsuite/25_algorithms/remove_copy_if/constexpr.cc: New.
1670         * testsuite/25_algorithms/remove_if/constexpr.cc: New.
1671         * testsuite/25_algorithms/replace_copy/constexpr.cc: New.
1672         * testsuite/25_algorithms/replace_copy_if/constexpr.cc: New.
1673         * testsuite/25_algorithms/replace_if/constexpr.cc: New.
1674         * testsuite/25_algorithms/reverse_copy/constexpr.cc: New.
1675         * testsuite/25_algorithms/rotate_copy/constexpr.cc: New.
1676         * testsuite/25_algorithms/search/constexpr.cc: New.
1677         * testsuite/25_algorithms/search_n/constexpr.cc: New.
1678         * testsuite/25_algorithms/set_difference/constexpr.cc: New.
1679         * testsuite/25_algorithms/set_intersection/constexpr.cc: New.
1680         * testsuite/25_algorithms/set_symmetric_difference/constexpr.cc: New.
1681         * testsuite/25_algorithms/set_union/constexpr.cc: New.
1682         * testsuite/25_algorithms/transform/constexpr.cc: New.
1683         * testsuite/25_algorithms/unique/constexpr.cc: New.
1684         * testsuite/25_algorithms/unique_copy/constexpr.cc: New.
1685         * testsuite/25_algorithms/upper_bound/constexpr.cc: New.
1686
1687 2019-07-31  Jonathan Wakely  <jwakely@redhat.com>
1688
1689         * include/std/memory (make_obj_using_allocator): Qualify call to
1690         uses_allocator_construction_args.
1691
1692         P0631R4 Math Constants
1693         * include/Makefile.am: Add new header.
1694         * include/Makefile.in: Regenerate.
1695         * include/precompiled/stdc++.h: Include new header.
1696         * include/std/numbers: New header.
1697         * include/std/version (__cpp_lib_math_constants): Define.
1698         * testsuite/26_numerics/numbers/1.cc: New test.
1699         * testsuite/26_numerics/numbers/2.cc: New test.
1700         * testsuite/26_numerics/numbers/3.cc: New test.
1701         * testsuite/26_numerics/numbers/nonfloat_neg.cc: New test.
1702
1703         * include/std/bit: Add Doxygen comments.
1704
1705         PR libstdc++/91308
1706         * include/bits/unique_ptr.h (unique_ptr::__safe_conversion_up): Remove
1707         constraints on deleter that should only apply to the constructor.
1708         (unique_ptr<T[], D>::__safe_conversion_up): Likewise.
1709         (unique_ptr<T[], D>::unique_ptr(unique_ptr<U, D>&&)): Restore
1710         constraints on deleter here.
1711         * testsuite/20_util/unique_ptr/assign/91308.cc: New test.
1712
1713 2019-07-29  Jonathan Wakely  <jwakely@redhat.com>
1714
1715         PR libstdc++/51333
1716         * libsupc++/cxxabi.h (__gnu_cxx::recursive_init_error): Do not define
1717         constructor inline.
1718         * libsupc++/guard_error.cc (__gnu_cxx::recursive_init_error): Define
1719         constructor.
1720         * testsuite/18_support/51333.cc: New test.
1721
1722 2019-07-28  Gerald Pfeifer  <gerald@pfeifer.com>
1723
1724         * doc/xml/manual/documentation_hacking.xml: Fix broken reference
1725         to the Doxygen manual. Avoid a "here" link on the way.
1726         Fix another broken link to Doxygen docblocks.
1727
1728 2019-07-26  Jonathan Wakely  <jwakely@redhat.com>
1729
1730         * include/std/bit (__cpp_lib_endian): Define.
1731         * include/std/version (__cpp_lib_endian): Define.
1732         * testsuite/26_numerics/endian/2.cc: New.
1733         * testsuite/26_numerics/endian/3.cc: New.
1734         * testsuite/26_numerics/endian/4.cc: New.
1735
1736 2019-07-26  François Dumont  <fdumont@gcc.gnu.org>
1737
1738         * testsuite/util/testsuite_iterators.h
1739         (bidirectional_iterator_wrapper): Fix type comment.
1740         (random_access_iterator_wrapper): Likewise.
1741
1742 2019-07-25  Jonathan Wakely  <jwakely@redhat.com>
1743
1744         * include/std/bit (endian): Move definition here as per P1612R1.
1745         * include/std/type_traits (endian): Remove definition from here.
1746         * testsuite/20_util/endian/1.cc: Rename to ...
1747         * testsuite/26_numerics/endian/1.cc: ... here. Adjust header.
1748
1749 2019-07-25  Martin Liska  <mliska@suse.cz>
1750             Dominik Infuhr  <dominik.infuehr@theobroma-systems.com>
1751
1752         PR c++/23383
1753         * testsuite/ext/bitmap_allocator/check_delete.cc: Add
1754         -fno-allocation-dce.
1755         * testsuite/ext/bitmap_allocator/check_new.cc: Likewise.
1756         * testsuite/ext/new_allocator/check_delete.cc: Likewise.
1757         * testsuite/ext/new_allocator/check_new.cc: Likewise.
1758
1759 2019-07-22  Jonathan Wakely  <jwakely@redhat.com>
1760
1761         * testsuite/26_numerics/bit/bitops.count/*: Rename to ...
1762         * testsuite/26_numerics/bit/bit.count/*: Here.
1763
1764         * include/std/bit (__rotl, __rotr): Change second parameter from
1765         unsigned int to int and handle negative values.
1766         (rotl, rotr): Remove check for __STRICT_ANSI__. Change second
1767         parameter from unsigned int to int. Add nodiscard attribute.
1768         * testsuite/26_numerics/bit/bitops.rot/rotl.cc: Rename to ...
1769         * testsuite/26_numerics/bit/bit.rotate/rotl.cc: Here. Test negative
1770         shifts.
1771         * testsuite/26_numerics/bit/bitops.rot/rotr.cc: Rename to ...
1772         * testsuite/26_numerics/bit/bit.rotate/rotr.cc: Here. Test negative
1773         shifts.
1774
1775         * include/std/bit (__ceil2): Make unrepresentable results undefined,
1776         as per P1355R2. Add debug assertion. Perform one left shift, not two,
1777         so that out of range values cause undefined behaviour. Ensure that
1778         shift will still be undefined if left operand is promoted.
1779         * testsuite/26_numerics/bit/bit.pow.two/ceil2.cc: Replace checks for
1780         unrepresentable values with checks that they are not core constant
1781         expressions.
1782         * testsuite/26_numerics/bit/bit.pow.two/ceil2_neg.cc: New test.
1783
1784 2019-07-19  François Dumont  <fdumont@gcc.gnu.org>
1785
1786         * include/bits/stl_tempbuf.h (__detail::__return_temporary_buffer): Fix
1787         sized deallocation size computation.
1788
1789 2019-07-19  Andreas Schwab  <schwab@linux-m68k.org>
1790
1791         * config/abi/post/m68k-linux-gnu/baseline_symbols.txt: Update.
1792
1793 2019-07-18  François Dumont  <fdumont@gcc.gnu.org>
1794
1795         * include/bits/stl_tempbuf.h (__detail::__return_temporary_buffer): New.
1796         (~_Temporary_buffer()): Use latter.
1797         (_Temporary_buffer(_FIterator, size_type)): Likewise.
1798
1799 2019-07-17  Andreas Schwab  <schwab@suse.de>
1800
1801         * config/abi/post/ia64-linux-gnu/baseline_symbols.txt: Update.
1802
1803 2019-07-16  Jason Merrill  <jason@redhat.com>
1804
1805         * include/std/memory (uses_allocator_construction_args): Add parens
1806         around constraint.
1807
1808 2019-07-12  Jonathan Wakely  <jwakely@redhat.com>
1809
1810         * testsuite/29_atomics/atomic_float/1.cc: Fix comment.
1811
1812         * include/experimental/string_view (__detail::__idt): Remove.
1813         (operator==, operator!=, operator<, operator>, operator<=, operator>=):
1814         Use __type_identity_t instead of __detail::__idt;
1815         * include/std/string_view (__detail::__idt): Remove.
1816         (operator==, operator!=, operator<, operator>, operator<=, operator>=):
1817         Use __type_identity_t instead of __detail::__idt;
1818         * include/std/type_traits (__type_identity_t): New alias template.
1819
1820         * doc/xml/manual/status_cxx2020.xml: Update status for atomic_ref
1821         and floating point atomics.
1822
1823 2019-07-11  Jonathan Wakely  <jwakely@redhat.com>
1824
1825         * doc/xml/manual/configure.xml: Improve documentation of
1826         --enable-libstdcxx-time option.
1827
1828         * include/bits/atomic_base.h (__atomic_impl): New namespace for
1829         wrappers around atomic built-ins.
1830         (__atomic_float, __atomic_ref): New class templates for use as base
1831         classes.
1832         * include/std/atomic (atomic<float>, atomic<double>)
1833         (atomic<long double>): New explicit specializations.
1834         (atomic_ref): New class template.
1835         (__cpp_lib_atomic_ref): Define.
1836         * include/std/version (__cpp_lib_atomic_ref): Define.
1837         * testsuite/29_atomics/atomic/60695.cc: Adjust dg-error.
1838         * testsuite/29_atomics/atomic_float/1.cc: New test.
1839         * testsuite/29_atomics/atomic_float/requirements.cc: New test.
1840         * testsuite/29_atomics/atomic_ref/deduction.cc: New test.
1841         * testsuite/29_atomics/atomic_ref/float.cc: New test.
1842         * testsuite/29_atomics/atomic_ref/generic.cc: New test.
1843         * testsuite/29_atomics/atomic_ref/integral.cc: New test.
1844         * testsuite/29_atomics/atomic_ref/pointer.cc: New test.
1845         * testsuite/29_atomics/atomic_ref/requirements.cc: New test.
1846
1847 2019-07-06  Jonathan Wakely  <jwakely@redhat.com>
1848
1849         * include/ext/atomicity.h (__exchange_and_add, __atomic_add): Replace
1850         throw() with _GLIBCXX_NOTHROW.
1851         (__atomic_add_dispatch): Return after performing atomic increment.
1852
1853 2019-07-05  Jonathan Wakely  <jwakely@redhat.com>
1854
1855         * include/ext/atomicity.h [_GLIBCXX_ATOMIC_BUILTINS] (__atomic_add)
1856         (__exchange_and_add): Replace static specifier with always_inline
1857         attribute.
1858         (__exchange_and_add_single, __atomic_add_single): Likewise.
1859         (__exchange_and_add_dispatch, __atomic_add_dispatch): Likewise. Also
1860         combine !__gthread_active_p() and !__GTHREADS branches.
1861
1862 2019-07-03  Jonathan Wakely  <jwakely@redhat.com>
1863
1864         PR libstdc++/91067
1865         * acinclude.m4 (libtool_VERSION): Bump to 6:27:0.
1866         * configure: Regenerate.
1867         * config/abi/pre/gnu.ver (GLIBCXX_3.4.27): Add new version. Export
1868         missing symbols.
1869         * testsuite/27_io/filesystem/iterators/91067.cc: New test.
1870         * testsuite/util/testsuite_abi.cc: Add new symbol version.
1871
1872 2019-07-02  Jonathan Wakely  <jwakely@redhat.com>
1873
1874         * include/bits/c++config (_GLIBCXX_HAVE_BUILTIN_LAUNDER)
1875         (_GLIBCXX_HAVE_BUILTIN_IS_CONSTANT_EVALUATED): Use __has_builtin
1876         instead of __is_identifier to detect Clang support.
1877
1878 2019-07-02  Jim Wilson  <jimw@sifive.com>
1879
1880         * configure.ac (BUILD_PDF): Also test for doxygen, dot, xsltproc,
1881         and xmllint.
1882         * configure: Regenerate.
1883
1884 2019-06-27  Jonathan Wakely  <jwakely@redhat.com>
1885
1886         PR libstdc++/91012
1887         * src/c++17/fs_path.cc (filesystem_error::_Impl): Use a string_view
1888         for the what_arg parameters.
1889         (filesystem_error::filesystem_error): Pass system_error::what() to
1890         the _Impl constructor.
1891         * testsuite/27_io/filesystem/filesystem_error/cons.cc: Ensure that
1892         filesystem_error::what() contains system_error::what().
1893
1894 2019-06-26  Jonathan Wakely  <jwakely@redhat.com>
1895
1896         * include/std/charconv (chars_format): Define bitmask type.
1897         * testsuite/20_util/to_chars/chars_format.cc: New test.
1898
1899         * include/bits/fs_path.h (path::__is_encoded_char): Use __is_one_of.
1900         * include/std/bit (_If_is_unsigned_integer_type): Remove.
1901         (_If_is_unsigned_integer): Use __is_unsigned_integer.
1902         (rotl(byte, unsigned), rotr(byte, unsigned), countl_zero(byte))
1903         (countl_one(byte), countr_zero(byte), countr_one(byte))
1904         (popcount(byte), ispow2(byte), ceil2(byte), floor2(byte))
1905         (log2p1(byte)): Remove.
1906         * include/std/charconv (__detail::__is_one_of): Move to <type_traits>.
1907         (__detail::__is_int_to_chars_type): Remove.
1908         (__detail::__integer_to_chars_result_type): Use __is_signed_integer
1909         and __is_unsigned_integer.
1910         * include/std/type_traits (__is_one_of): Move here from <charconv>.
1911         (__is_signed_integer, __is_unsigned_integer): New helpers.
1912         * testsuite/26_numerics/bit/bit.pow.two/ceil2.cc: Remove test for
1913         std::byte overload.
1914         * testsuite/26_numerics/bit/bit.pow.two/floor2.cc: Likewise.
1915         * testsuite/26_numerics/bit/bit.pow.two/ispow2.cc: Likewise.
1916         * testsuite/26_numerics/bit/bit.pow.two/log2p1.cc: Likewise.
1917         * testsuite/26_numerics/bit/bitops.count/countl_one.cc: Likewise.
1918         * testsuite/26_numerics/bit/bitops.count/countl_zero.cc: Likewise.
1919         * testsuite/26_numerics/bit/bitops.count/countr_one.cc: Likewise.
1920         * testsuite/26_numerics/bit/bitops.count/countr_zero.cc: Likewise.
1921         * testsuite/26_numerics/bit/bitops.count/popcount.cc: Likewise.
1922         * testsuite/26_numerics/bit/bitops.rot/rotl.cc: Likewise.
1923         * testsuite/26_numerics/bit/bitops.rot/rotr.cc: Likewise.
1924
1925 2019-06-25  Jonathan Wakely  <jwakely@redhat.com>
1926
1927         * include/std/numeric (midpoint(T, T)): Avoid std::abs in constexpr
1928         function.
1929
1930 2019-06-25  Jakub Jelinek  <jakub@redhat.com>
1931
1932         * include/pstl/pstl_config.h (_PSTL_PRAGMA_SIMD_SCAN,
1933         _PSTL_PRAGMA_SIMD_INCLUSIVE_SCAN, _PSTL_PRAGMA_SIMD_EXCLUSIVE_SCAN):
1934         Define to OpenMP 5.0 pragmas even for GCC 10.0+.
1935         (_PSTL_UDS_PRESENT): Define to 1 for GCC 10.0+.
1936
1937 2019-06-24  Jonathan Wakely  <jwakely@redhat.com>
1938
1939         * include/std/numeric (midpoint(T, T)): Change implementation for
1940         floating-point types to avoid incorrect rounding of denormals.
1941         * testsuite/26_numerics/midpoint/floating.cc: Add check for correct
1942         rounding with denormals.
1943         * testsuite/26_numerics/gcd/gcd_neg.cc: Adjust dg-error line numbers.
1944         * testsuite/26_numerics/lcm/lcm_neg.cc: Likewise.
1945
1946         * testsuite/18_support/headers/cfloat/values_c++17.cc: New test.
1947
1948 2019-06-20  Jonathan Wakely  <jwakely@redhat.com>
1949
1950         * acinclude.m4 (GLIBCXX_ENABLE_DEBUG): Only do debug build for final
1951         stage of bootstrap.
1952         * configure: Regenerate.
1953
1954         * include/std/variant (_Variant_storage, _Extra_visit_slot_needed):
1955         Qualify calls to __never_valueless.
1956
1957         * doc/xml/manual/status_cxx2017.xml: Fix outdated reference to
1958         C++17 working draft.
1959
1960         * testsuite/libstdc++-prettyprinters/simple.cc: Use non-palindromic
1961         vector<bool> for test.
1962         * testsuite/libstdc++-prettyprinters/simple11.cc: Likewise.
1963
1964 2019-06-19  Jonathan Wakely  <jwakely@redhat.com>
1965
1966         * include/bits/stream_iterator.h (istream_iterator::_M_equal()): Make
1967         private.
1968         (istream_iterator::_M_read()): Do not check stream state before
1969         attempting extraction. Set stream pointer to null when extraction
1970         fails (P0738R2).
1971         (operator==(const istream_iterator&, const istream_iterator&)): Change
1972         to be a hidden friend of istream_iterator.
1973         (operator!=(const istream_iterator&, const istream_iterator&)):
1974         Likewise.
1975         (ostream_iterator::ostream_iterator()): Add default constructor.
1976         (ostream_iterator::ostream_iterator(ostream_type*, const C*)): Use
1977         addressof.
1978         * testsuite/24_iterators/istream_iterator/1.cc: New test.
1979         * testsuite/24_iterators/ostream_iterator/1.cc: New test.
1980         * testsuite/24_iterators/ostream_iterator/70766.cc: Also check
1981         constructor taking a string.
1982         * testsuite/24_iterators/ostream_iterator/requirements/constexpr.cc:
1983         New test.
1984
1985 2019-06-19  Michael Weghorn  <m.weghorn@posteo.de>
1986             Jonathan Wakely  <jwakely@redhat.com>
1987
1988         PR libstdc++/90945
1989         * python/libstdcxx/v6/printers.py (StdVectorPrinter._iterator): Use
1990         values of type bool for vector<bool> elements.
1991         * testsuite/libstdc++-prettyprinters/simple.cc: Test vector<bool>.
1992         * testsuite/libstdc++-prettyprinters/simple11.cc: Likewise.
1993
1994 2019-06-19  Jonathan Wakely  <jwakely@redhat.com>
1995
1996         PR libstdc++/90920 partially revert r263433
1997         * include/bits/stl_algo.h (__rotate): Restore checks for empty ranges.
1998         (rotate): Remove checks.
1999         * testsuite/25_algorithms/rotate/90920.cc: New test.
2000
2001         * include/std/numeric (reduce(Iter, Iter, T, BinOp)): Fix value
2002         category used in invocable check.
2003         (reduce(Iter, Iter, T)): Pass initial value as rvalue.
2004         * testsuite/26_numerics/reduce/2.cc: New test.
2005
2006 2019-06-18  Jonathan Wakely  <jwakely@redhat.com>
2007
2008         * include/bits/algorithmfwd.h: Change title of doc group.
2009         * include/bits/stl_algo.h (for_each_n): Add new C++17 algorithm from
2010         P0024R2.
2011         * include/bits/stl_numeric.h: Define doc group and add algos to it.
2012         * include/std/numeric (__is_random_access_iter): New internal trait.
2013         (reduce, transform_reduce, exclusive_scan, inclusive_scan)
2014         (transform_exclusive_scan, transform_inclusive_scan): Likewise.
2015         * testsuite/25_algorithms/for_each/for_each_n.cc: New test.
2016         * testsuite/26_numerics/exclusive_scan/1.cc: New test.
2017         * testsuite/26_numerics/inclusive_scan/1.cc: New test.
2018         * testsuite/26_numerics/reduce/1.cc: New test.
2019         * testsuite/26_numerics/transform_exclusive_scan/1.cc: New test.
2020         * testsuite/26_numerics/transform_inclusive_scan/1.cc: New test.
2021         * testsuite/26_numerics/transform_reduce/1.cc: New test.
2022         * testsuite/util/testsuite_iterators.h (test_container::size()): New
2023         member function.
2024
2025         * include/c_global/cstddef (std::byte): Perform arithmetic operations
2026         in unsigned int to avoid promotion (LWG 2950).
2027
2028 2019-06-17  Jonathan Wakely  <jwakely@redhat.com>
2029
2030         * testsuite/20_util/allocator/1.cc: Add sized delete, which fixes a
2031         failure on AIX.
2032
2033         * include/c_global/cmath (__lerp, lerp): Add noexcept (LWG 3201).
2034
2035         PR libstdc++/90281 Fix string conversions for filesystem::path
2036         * include/bits/fs_path.h (u8path) [_GLIBCXX_FILESYSTEM_IS_WINDOWS]:
2037         Use codecvt_utf8_utf16 instead of codecvt_utf8. Use
2038         __str_codecvt_in_all to fail for partial conversions and throw on
2039         error.
2040         [!_GLIBCXX_FILESYSTEM_IS_WINDOWS && _GLIBCXX_USE_CHAR8_T]
2041         (path::_Cvt<char8_t>): Add explicit specialization.
2042         [_GLIBCXX_FILESYSTEM_IS_WINDOWS] (path::_Cvt::_S_wconvert): Remove
2043         overloads.
2044         [_GLIBCXX_FILESYSTEM_IS_WINDOWS] (path::_Cvt::_S_convert): Use
2045         if-constexpr instead of dispatching to _S_wconvert. Use codecvt
2046         instead of codecvt_utf8. Use __str_codecvt_in_all and
2047         __str_codecvt_out_all.
2048         [!_GLIBCXX_FILESYSTEM_IS_WINDOWS] (path::_Cvt::_S_convert): Use
2049         codecvt instead of codecvt_utf8. Use __str_codecvt_out_all.
2050         (path::_S_str_convert) [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Use
2051         codecvt_utf8_utf16 instead of codecvt_utf8. Construct return values
2052         with allocator. Use __str_codecvt_out_all. Fallthrough to POSIX code
2053         after converting to UTF-8.
2054         (path::_S_str_convert): Use codecvt instead of codecvt_utf8. Use
2055         __str_codecvt_in_all.
2056         (path::string): Fix initialization of string types with different
2057         allocators.
2058         (path::u8string) [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Use
2059         codecvt_utf8_utf16 instead of codecvt_utf8. Use __str_codecvt_out_all.
2060         * include/bits/locale_conv.h (__do_str_codecvt): Reorder static and
2061         runtime conditions.
2062         (__str_codecvt_out_all, __str_codecvt_in_all): New functions that
2063         return false for partial conversions.
2064         * include/experimental/bits/fs_path.h (u8path):
2065         [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Implement correctly for mingw.
2066         [_GLIBCXX_FILESYSTEM_IS_WINDOWS] (path::_Cvt::_S_wconvert): Add
2067         missing handling for char8_t. Use codecvt and codecvt_utf8_utf16
2068         instead of codecvt_utf8. Use __str_codecvt_in_all and
2069         __str_codecvt_out_all.
2070         [!_GLIBCXX_FILESYSTEM_IS_WINDOWS] (path::_Cvt::_S_convert): Use
2071         codecvt instead of codecvt_utf8. Use __str_codecvt_out_all.
2072         (path::string) [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Use
2073         codecvt_utf8_utf16 instead of codecvt_utf8. Construct return values
2074         with allocator. Use __str_codecvt_out_all and __str_codecvt_in_all.
2075         (path::string) [!_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Use
2076         __str_codecvt_in_all.
2077         (path::u8string) [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Use
2078         codecvt_utf8_utf16 instead of codecvt_utf8. Use __str_codecvt_out_all.
2079         * src/c++17/fs_path.cc (path::_S_convert_loc): Use
2080         __str_codecvt_in_all.
2081         * src/filesystem/path.cc (path::_S_convert_loc): Likewise.
2082         * testsuite/27_io/filesystem/path/construct/90281.cc: New test.
2083         * testsuite/27_io/filesystem/path/factory/u8path.cc: New test.
2084         * testsuite/27_io/filesystem/path/native/string.cc: Test with empty
2085         strings and with Unicode characters outside the basic multilingual
2086         plane.
2087         * testsuite/27_io/filesystem/path/native/alloc.cc: New test.
2088         * testsuite/experimental/filesystem/path/construct/90281.cc: New test.
2089         * testsuite/experimental/filesystem/path/factory/u8path.cc: New test.
2090         * testsuite/experimental/filesystem/path/native/alloc.cc: New test.
2091         * testsuite/experimental/filesystem/path/native/string.cc: Test with
2092         empty strings and with Unicode characters outside the basic
2093         multilingual plane.
2094
2095 2019-06-17  François Dumont  <fdumont@gcc.gnu.org>
2096             Jonathan Wakely  <jwakely@redhat.com>
2097
2098         * include/bits/hashtable.h (struct _Hashtable::_Scoped_node): New type.
2099         (_Hashtable::_M_insert_unique_node): Add key_type parameter. Don't
2100         deallocate node if insertion fails.
2101         (_Hashtable::_M_insert_multi_node): Likewise.
2102         (_Hashtable::_M_reinsert_node): Pass additional key argument.
2103         (_Hashtable::_M_reinsert_node_multi): Likewise. Remove FIXME.
2104         (_Hashtable::_M_extract_node(size_t, __node_base*)): New function.
2105         (_Hashtable::extract(const_iterator)): Use _M_extract_node.
2106         (_Hashtable::extract(const _Key&)): Likewise.
2107         (_Hashtable::_M_merge_unique): Pass additional key argument.
2108         (_Hashtable::_M_emplace<Args>(true_type, Args&&...)): Likewise. Use
2109         _Scoped_node.
2110         (_Hashtable::_M_insert): Likewise.
2111         * include/bits/hashtable_policy.h (_Map_base::operator[]): Likewise.
2112         (_Hashtable_alloc): Add comments to functions with misleading names.
2113
2114 2019-06-17  Jonathan Wakely  <jwakely@redhat.com>
2115
2116         * testsuite/20_util/bad_function_call/what.cc: Include <string> header
2117         for std::string.
2118         * testsuite/20_util/shared_ptr/cons/weak_ptr_expired.cc: Likewise.
2119         * testsuite/20_util/tuple/cons/allocator_with_any.cc: Include <memory>
2120         header for std::allocator.
2121         * testsuite/23_containers/array/tuple_interface/tuple_element.cc: Add
2122         using-declaration for std::size_t.
2123         * testsuite/23_containers/array/tuple_interface/tuple_size.cc:
2124         Likewise.
2125         * testsuite/23_containers/deque/cons/55977.cc: Include <istream> for
2126         std::istream.
2127         * testsuite/23_containers/vector/cons/55977.cc: Likewise.
2128         * testsuite/experimental/map/erasure.cc: Include <string> for
2129         std::string.
2130         * testsuite/experimental/unordered_map/erasure.cc: Likewise.
2131
2132 2019-06-14  Jonathan Wakely  <jwakely@redhat.com>
2133
2134         * include/experimental/type_traits (experimental::nonesuch): Use
2135         pragma to disable -Wctor-dtor-privacy warnings.
2136         * include/std/type_traits (__is_convertible_helper<From, To, false>)
2137         (__is_nt_convertible_helper<From, To, false>, __nonesuch): Likewise.
2138
2139         * include/std/version (__cpp_lib_bind_front): Add missing macro.
2140
2141 2019-06-12  Jonathan Wakely  <jwakely@redhat.com>
2142
2143         * include/std/algorithm (__cpp_lib_parallel_algorithm): Fix value.
2144         * include/std/memory (__cpp_lib_parallel_algorithm): Likewise.
2145         * include/std/numeric (__cpp_lib_parallel_algorithm): Likewise.
2146         * testsuite/25_algorithms/pstl/feature_test.cc: New test.
2147
2148         * include/std/variant (get<T>, get<N>, get_if<N>, get_if<T>)
2149         (variant::emplace): Change static_assert messages from "should be"
2150         to "must be".
2151         (hash<monostate>::operator()): Remove name of unused parameter.
2152
2153         * include/std/mutex (scoped_lock::~scoped_lock()): Use fold
2154         expression.
2155
2156         * include/Makefile.am: Add new <bits/charconv.h> header.
2157         * include/Makefile.in: Regenerate.
2158         * include/bits/basic_string.h (to_string(int), to_string(unsigned))
2159         (to_string(long), to_string(unsigned long), to_string(long long))
2160         (to_string(unsigned long long)): Rewrite to use __to_chars_10_impl.
2161         * include/bits/charconv.h: New header.
2162         (__detail::__to_chars_len): Move here from <charconv>.
2163         (__detail::__to_chars_10_impl): New function extracted from
2164         __detail::__to_chars_10.
2165         * include/std/charconv (__cpp_lib_to_chars): Add, but comment out.
2166         (__to_chars_unsigned_type): New class template that reuses
2167         __make_unsigned_selector_base::__select to pick a type.
2168         (__unsigned_least_t): Redefine as __to_chars_unsigned_type<T>::type.
2169         (__detail::__to_chars_len): Move to new header.
2170         (__detail::__to_chars_10): Add inline specifier. Move code doing the
2171         output to __detail::__to_chars_10_impl and call that.
2172         * include/std/version (__cpp_lib_to_chars): Add, but comment out.
2173         * testsuite/21_strings/basic_string/numeric_conversions/char/
2174         to_string.cc: Fix reference in comment. Remove unused variable.
2175         * testsuite/21_strings/basic_string/numeric_conversions/char/
2176         to_string_int.cc: New test.
2177
2178 2019-06-09  Edward Smith-Rowland  <3dw4rd@verizon.net>
2179
2180         Fix ConstexprIterator requirements tests - No constexpr algorithms!
2181         * testsuite/21_strings/basic_string_view/requirements/constexpr_iter.cc:
2182         Replace copy with hand-rolled loop.
2183         * testsuite/23_containers/array/requirements/constexpr_iter.cc:
2184         Ditto.
2185
2186 2019-06-08  Edward Smith-Rowland  <3dw4rd@verizon.net>
2187
2188         Test for C++20 p0858 - ConstexprIterator requirements.
2189         * testsuite/21_strings/basic_string_view/requirements/constexpr_iter.cc:
2190         New test.
2191         * testsuite/23_containers/array/requirements/constexpr_iter.cc:
2192         New test.
2193
2194 2019-06-07  Thomas Rodgers  <trodgers@redhat.com>
2195
2196         Rename PSTL macro's consistent with libstdc++ (and llvm upstream
2197         project) standards.
2198         * include/bits/c++config: Rename all macros of the form __PSTL* to
2199         _PSTL*.
2200         * include/std/algorithm: Likewise.
2201         * include/std/execution: Likewise.
2202         * include/std/numeric: Likewise.
2203         * include/std/memory: Likewise.
2204         * include/pstl/glue_memory_impl.h: Likewise.
2205         * include/pstl/numeric_impl.h: Likewise.
2206         * include/pstl/glue_memory_defs.h: Likewise.
2207         * include/pstl/execution_defs.h: Likewise.
2208         * include/pstl/utils.h: Likewise.
2209         * include/pstl/algorithm_fwd.h: Likewise.
2210         * include/pstl/unseq_backend_simd.h: Likewise.
2211         * include/pstl/glue_execution_defs.h: Likewise.
2212         * include/pstl/algorithm_impl.h: Likewise.
2213         * include/pstl/parallel_impl.h: Likewise.
2214         * include/pstl/memory_impl.h: Likewise.
2215         * include/pstl/glue_numeric_defs.h: Likewise.
2216         * include/pstl/parallel_backend_utils.h: Likewise.
2217         * include/pstl/glue_algorithm_defs.h: Likewise.
2218         * include/pstl/parallel_backend.h: Likewise.
2219         * include/pstl/glue_numeric_impl.h: Likewise.
2220         * include/pstl/parallel_backend_tbb.h: Likewise.
2221         * include/pstl/numeric_fwd.h: Likewise.
2222         * include/pstl/glue_algorithm_impl.h: Likewise.
2223         * include/pstl/execution_impl.h: Likewise.
2224         * include/pstl/pstl_config.h: Likewise.
2225         * testsuite/util/pstl/pstl_test_config.h: Likewise.
2226         * testsuite/util/pstl/test_utils.h: Likewise.
2227         * testsuite/20_util/specialized_algorithms/pstl/uninitialized_construct.cc:
2228         Likewise.
2229         * testsuite/20_util/specialized_algorithms/pstl/uninitialized_copy_move.cc:
2230         Likewise.
2231         * testsuite/26_numerics/pstl/numeric_ops/adjacent_difference.cc:
2232         Likewise.
2233         * testsuite/26_numerics/pstl/numeric_ops/scan.cc: Likewise.
2234         * testsuite/26_numerics/pstl/numeric_ops/transform_scan.cc: Likewise.
2235         * testsuite/26_numerics/pstl/numeric_ops/reduce.cc: Likewise.
2236         * testsuite/25_algorithms/pstl/alg_nonmodifying/reverse.cc: Likewise.
2237         * testsuite/25_algorithms/pstl/alg_nonmodifying/nth_element.cc:
2238         Likewise.
2239         * testsuite/25_algorithms/pstl/alg_nonmodifying/find_end.cc: Likewise.
2240         * testsuite/25_algorithms/pstl/alg_nonmodifying/find_if.cc: Likewise.
2241         * testsuite/25_algorithms/pstl/alg_nonmodifying/none_of.cc: Likewise.
2242         * testsuite/25_algorithms/pstl/alg_nonmodifying/count.cc: Likewise.
2243         * testsuite/25_algorithms/pstl/alg_nonmodifying/reverse_copy.cc:
2244         Likewise.
2245         * testsuite/25_algorithms/pstl/alg_nonmodifying/equal.cc: Likewise.
2246         * testsuite/25_algorithms/pstl/alg_nonmodifying/search_n.cc: Likewise.
2247         * testsuite/25_algorithms/pstl/alg_nonmodifying/find.cc: Likewise.
2248         * testsuite/25_algorithms/pstl/alg_nonmodifying/all_of.cc: Likewise.
2249         * testsuite/25_algorithms/pstl/alg_nonmodifying/find_first_of.cc:
2250         Likewise.
2251         * testsuite/25_algorithms/pstl/alg_sorting/is_heap.cc: Likewise.
2252         * testsuite/25_algorithms/pstl/alg_sorting/partial_sort.cc: Likewise.
2253         * testsuite/25_algorithms/pstl/alg_sorting/partial_sort_copy.cc:
2254         Likewise.
2255         * testsuite/25_algorithms/pstl/alg_sorting/lexicographical_compare.cc:
2256         Likewise.
2257         * testsuite/25_algorithms/pstl/alg_merge/inplace_merge.cc: Likewise.
2258         * testsuite/25_algorithms/pstl/alg_merge/merge.cc: Likewise.
2259         * testsuite/25_algorithms/pstl/alg_modifying_operations/unique_copy_equal.cc:
2260         Likewise.
2261         * testsuite/25_algorithms/pstl/alg_modifying_operations/replace_copy.cc:
2262         Likewise.
2263         * testsuite/25_algorithms/pstl/alg_modifying_operations/is_partitioned.cc:
2264         Likewise.
2265         * testsuite/25_algorithms/pstl/alg_modifying_operations/rotate_copy.cc:
2266         Likewise.
2267         * testsuite/25_algorithms/pstl/alg_modifying_operations/remove.cc:
2268         Likewise.
2269         * testsuite/25_algorithms/pstl/alg_modifying_operations/copy_if.cc:
2270         Likewise.
2271         * testsuite/25_algorithms/pstl/alg_modifying_operations/partition_copy.cc:
2272         Likewise.
2273         * testsuite/25_algorithms/pstl/alg_modifying_operations/partition.cc:
2274         Likewise.
2275         * testsuite/25_algorithms/pstl/alg_modifying_operations/copy_move.cc:
2276         Likewise.
2277         * testsuite/25_algorithms/pstl/alg_modifying_operations/unique.cc:
2278         Likewise.
2279         * testsuite/25_algorithms/pstl/alg_modifying_operations/rotate.cc:
2280         Likewise.
2281         * testsuite/25_algorithms/pstl/alg_nonmodifying/any_of.cc: Likewise.
2282
2283         Rename header guards to be consistent with upstream project's
2284         conventions.
2285         * include/pstl/glue_memory_impl.h: Rename all macros of the form
2286         _PSTL_(.*)_H to _PSTL_\U\1_H.
2287         * include/pstl/numeric_impl.h: Likewise.
2288         * include/pstl/glue_memory_defs.h: Likewise.
2289         * include/pstl/execution_defs.h: Likewise.
2290         * include/pstl/utils.h: Likewise.
2291         * include/pstl/algorithm_fwd.h: Likewise.
2292         * include/pstl/unseq_backend_simd.h: Likewise.
2293         * include/pstl/glue_execution_defs.h: Likewise.
2294         * include/pstl/algorithm_impl.h: Likewise.
2295         * include/pstl/parallel_impl.h: Likewise.
2296         * include/pstl/memory_impl.h: Likewise.
2297         * include/pstl/glue_numeric_defs.h: Likewise.
2298         * include/pstl/parallel_backend_utils.h: Likewise.
2299         * include/pstl/glue_algorithm_defs.h: Likewise.
2300         * include/pstl/parallel_backend.h: Likewise.
2301         * include/pstl/glue_numeric_impl.h: Likewise.
2302         * include/pstl/parallel_backend_tbb.h: Likewise.
2303         * include/pstl/numeric_fwd.h: Likewise.
2304         * include/pstl/glue_algorithm_impl.h: Likewise.
2305         * include/pstl/execution_impl.h: Likewise.
2306         * include/pstl/pstl_config.h: Likewise.
2307         * testsuite/util/pstl/pstl_test_config.h: Likewise.
2308
2309         Synchronize libstdc++ parallel algorithms with upstream
2310         project.
2311         * include/pstl/algorithm_fwd.h: Synchronize with
2312         upstream PSTL project.
2313         * include/pstl/algorithm_impl.h: Likewise.
2314         * include/pstl/execution_defs.h: Likewise.
2315         * include/pstl/execution_impl.h: Likewise.
2316         * include/pstl/glue_algorithm_impl.h: Likewise.
2317         * include/pstl/glue_execution_defs.h: Likewise.
2318         * include/pstl/numeric_fwd.h: Likewise.
2319         * include/pstl/numeric_impl.h: Likewise.
2320         * include/pstl/parallel_backend.h: Likewise.
2321         * include/pstl/pstl_config.h: Likewise.
2322         * include/pstl/unseq_backend_simd.h: Likewise.
2323         * include/pstl/parallel_backend_serial.h: New file.
2324         * include/Makefile.am (pstl_headers): Add
2325         parallel_backend_serial.h.
2326         * include/Makefile.in: Regenerate.
2327
2328         Clean up non-conforming names
2329         * include/pstl/algorithm_impl.h (__parallel_set_union_op):
2330         Uglfiy copy_range1 and copy_range2
2331         (__pattern_walk2_n): Rename local n to __n
2332         * include/pstl/parallel_backend_tbb.h (struct __binary_no_op):
2333         Rename parameter _T to _Tp.
2334
2335         Integrate non-TBB serial backend support
2336         * include/bits/c++config: Adjust TBB detection logic to select serial
2337         PSTL backend if no TBB present.
2338         * testsuite/utils/pstl/test_utils.h: Remove check for
2339         _PSTL_USE_PAR_POLICIES
2340         
2341 2019-06-07  Jonathan Wakely  <jwakely@redhat.com>
2342
2343         * testsuite/24_iterators/container_access.cc: Move dg-options before
2344         dg-do directive so the target check uses the -std option.
2345
2346         PR libstdc++/90770
2347         * configure: Regenerate.
2348         * src/Makefile.am (stamp-debug): Also test for missing makefile.
2349         * src/Makefile.in: Regenerate.
2350
2351 2019-06-06  Jonathan Wakely  <jwakely@redhat.com>
2352
2353         * include/std/array: Do not include <stdexcept>.
2354         * include/std/optional: Include <exception> and
2355         <bits/exception_defines.h> instead of <stdexcept>.
2356         * testsuite/20_util/function_objects/searchers.cc: Include <cctype>
2357         for std::isalnum.
2358         * testsuite/20_util/tuple/cons/deduction.cc: Include <memory> for
2359         std::allocator.
2360         * testsuite/23_containers/map/erasure.cc: Include <string>.
2361         * testsuite/23_containers/unordered_map/erasure.cc: Likewise.
2362
2363         * testsuite/23_containers/deque/requirements/dr438/assign_neg.cc: Add
2364         dg-prune-output for different C++98 diagnostic.
2365         * testsuite/23_containers/deque/requirements/dr438/constructor_1_neg.cc:
2366         Likewise.
2367         * testsuite/23_containers/deque/requirements/dr438/constructor_2_neg.cc:
2368         Likewise.
2369         * testsuite/23_containers/deque/requirements/dr438/insert_neg.cc:
2370         Likewise.
2371         * testsuite/23_containers/list/requirements/dr438/assign_neg.cc:
2372         Likewise.
2373         * testsuite/23_containers/list/requirements/dr438/constructor_1_neg.cc:
2374         Likewise.
2375         * testsuite/23_containers/list/requirements/dr438/constructor_2_neg.cc:
2376         Likewise.
2377         * testsuite/23_containers/list/requirements/dr438/insert_neg.cc:
2378         Likewise.
2379         * testsuite/23_containers/vector/requirements/dr438/assign_neg.cc:
2380         Likewise.
2381         * testsuite/23_containers/vector/requirements/dr438/
2382         constructor_1_neg.cc: Likewise.
2383         * testsuite/23_containers/vector/requirements/dr438/
2384         constructor_2_neg.cc: Likewise.
2385         * testsuite/23_containers/vector/requirements/dr438/insert_neg.cc:
2386         Likewise.
2387         * testsuite/libstdc++-prettyprinters/compat.cc: Do not run for C++98.
2388
2389         * testsuite/23_containers/unordered_map/requirements/debug_container.cc:
2390         Do not test allocator rebinding extension for C++2a.
2391         * testsuite/23_containers/unordered_set/allocator/ext_ptr.cc: Change
2392         dg-do directive for C++17 and C++2a.
2393
2394         * testsuite/23_containers/deque/requirements/explicit_instantiation/
2395         1_c++0x.cc: Remove redundant test.
2396         * testsuite/23_containers/deque/requirements/explicit_instantiation/
2397         2.cc: Use target selector instead of preprocessor condition.
2398         * testsuite/23_containers/deque/requirements/explicit_instantiation/
2399         3.cc: Do not run test for C++2a.
2400         * testsuite/23_containers/forward_list/requirements/
2401         explicit_instantiation/3.cc: Likewise.
2402         * testsuite/23_containers/forward_list/requirements/
2403         explicit_instantiation/5.cc: Do not test allocator rebinding extension
2404         for C++2a.
2405         * testsuite/23_containers/list/requirements/explicit_instantiation/
2406         1_c++0x.cc: Remove redundant test.
2407         * testsuite/23_containers/list/requirements/explicit_instantiation/
2408         2.cc: Use target selector instead of preprocessor condition.
2409         * testsuite/23_containers/list/requirements/explicit_instantiation/
2410         3.cc: Do not run test for C++2a.
2411         * testsuite/23_containers/list/requirements/explicit_instantiation/
2412         5.cc: Do not test allocator rebinding extension for C++2a.
2413         * testsuite/23_containers/map/requirements/explicit_instantiation/
2414         1_c++0x.cc: Remove redundant test.
2415         * testsuite/23_containers/map/requirements/explicit_instantiation/
2416         2.cc: Adjust comment.
2417         * testsuite/23_containers/map/requirements/explicit_instantiation/
2418         3.cc: Do not run test for C++2a.
2419         * testsuite/23_containers/map/requirements/explicit_instantiation/
2420         5.cc: Do not test allocator rebinding extension for C++2a.
2421         * testsuite/23_containers/multimap/requirements/explicit_instantiation/
2422         1_c++0x.cc: Remove redundant test.
2423         * testsuite/23_containers/multimap/requirements/explicit_instantiation/
2424         3.cc: Do not run test for C++2a.
2425         * testsuite/23_containers/multimap/requirements/explicit_instantiation/
2426         5.cc: Do not test allocator rebinding extension for C++2a.
2427         * testsuite/23_containers/multiset/requirements/explicit_instantiation/
2428         3.cc: Do not run test for C++2a.
2429         * testsuite/23_containers/multiset/requirements/explicit_instantiation/
2430         5.cc: Do not test allocator rebinding extension for C++2a.
2431         * testsuite/23_containers/set/requirements/explicit_instantiation/3.cc:
2432         Do not run test for C++2a.
2433         * testsuite/23_containers/set/requirements/explicit_instantiation/
2434         1_c++0x.cc: Remove redundant test.
2435         * testsuite/23_containers/set/requirements/explicit_instantiation/5.cc:
2436         Do not test allocator rebinding extension for C++2a.
2437         * testsuite/23_containers/unordered_map/requirements/
2438         explicit_instantiation/3.cc: Likewise.
2439         * testsuite/23_containers/unordered_map/requirements/
2440         explicit_instantiation/5.cc: Do not test allocator rebinding extension
2441         for C++2a.
2442         * testsuite/23_containers/unordered_multimap/requirements/
2443         explicit_instantiation/3.cc: Do not run test for C++2a.
2444         * testsuite/23_containers/unordered_multimap/requirements/
2445         explicit_instantiation/5.cc: Do not test allocator rebinding extension
2446         for C++2a.
2447         * testsuite/23_containers/unordered_multiset/requirements/
2448         explicit_instantiation/3.cc: Do not run test for C++2a.
2449         * testsuite/23_containers/unordered_multiset/requirements/
2450         explicit_instantiation/5.cc: Do not test allocator rebinding extension
2451         for C++2a.
2452         * testsuite/23_containers/unordered_set/requirements/
2453         explicit_instantiation/3.cc: Do not run test for C++2a.
2454         * testsuite/23_containers/unordered_set/requirements/
2455         explicit_instantiation/5.cc: Do not test allocator rebinding extension
2456         for C++2a.
2457         * testsuite/23_containers/vector/ext_pointer/explicit_instantiation/
2458         2.cc: Remove redundant test.
2459         * testsuite/23_containers/vector/ext_pointer/explicit_instantiation/
2460         3.cc: Do not run test for C++2a.
2461         * testsuite/23_containers/vector/requirements/explicit_instantiation/
2462         3.cc: Likewise.
2463
2464         * include/std/type_traits (is_empty, is_polymorphic, is_final)
2465         (is_abstract, is_aggregate): Remove static_assert.
2466         * testsuite/20_util/is_abstract/incomplete_neg.cc: Check for error
2467         from builtin only.
2468         * testsuite/20_util/is_aggregate/incomplete_neg.cc: Likewise. Add
2469         missing -std=gnu++17 option.
2470         * testsuite/20_util/is_empty/incomplete_neg.cc: New test.
2471         * testsuite/20_util/is_final/incomplete_neg.cc: New test.
2472         * testsuite/20_util/is_polymorphic/incomplete_neg.cc: Check for error
2473         from builtin only.
2474
2475         * testsuite/18_support/set_terminate.cc: Do not run for C++98 mode.
2476         * testsuite/18_support/set_unexpected.cc: Likewise.
2477         * testsuite/20_util/is_nothrow_invocable/value.cc: Test converting to
2478         void.
2479         * testsuite/20_util/is_nothrow_invocable/value_ext.cc: Fix constexpr
2480         function to be valid in C++11.
2481         * testsuite/26_numerics/complex/proj.cc: Do not run for C++98 mode.
2482         * testsuite/experimental/names.cc: Do not run for C++98 mode. Do not
2483         include Library Fundamentals or Networking headers in C++11 mode.
2484         * testsuite/ext/char8_t/atomic-1.cc: Do not run for C++98 mode.
2485
2486         * include/std/tuple (_TC): Replace with _TupleConstraints.
2487         (_TupleConstraints): New helper for SFINAE constraints, with more
2488         expressive member functions to reduce duplication when used.
2489         (tuple::_TC2, tuple::_TMC, tuple::_TNTC): Remove.
2490         (tuple::_TCC): Replace dummy type parameter with bool non-type
2491         parameter that can be used to check the pack size.
2492         (tuple::_ImplicitDefaultCtor, tuple::_ExplicitDefaultCtor)
2493         (tuple::_ImplicitCtor, tuple::_ExplicitCtor): New alias templates for
2494         checking constraints in constructors.
2495         (tuple::__valid_args, tuple::_UseOtherCtor, tuple::__use_other_ctor):
2496         New SFINAE helpers.
2497         (tuple::tuple): Use new helpers to reduce repitition in constraints.
2498         (tuple::tuple(allocator_arg_t, const Alloc&)): Constrain.
2499         (tuple<T1, T2>::_TCC, tuple<T1, T2>::_ImplicitDefaultCtor)
2500         (tuple<T1, T2>::_ExplicitDefaultCtor, tuple<T1, T2>::_ImplicitCtor)
2501         (tuple<T1, T2>::_ExplicitCtor): New alias templates for checking
2502         constraints in constructors.
2503         (tuple::__is_alloc_arg()): New SFINAE helpers.
2504         (tuple<T1, T2>::tuple): Use new helpers to reduce repitition in
2505         constraints.
2506         (tuple<T1, T2>::tuple(allocator_arg_t, const Alloc&)): Constrain.
2507         * testsuite/20_util/tuple/cons/90700.cc: New test.
2508         * testsuite/20_util/tuple/cons/allocators.cc: Add default constructor
2509         to meet new constraint on allocator-extended default constructor.
2510
2511 2019-06-03  Jonathan Wakely  <jwakely@redhat.com>
2512
2513         * include/bits/stl_map.h (map): Disable static assert for C++98 mode.
2514         * include/bits/stl_multimap.h (multimap): Likewise.
2515
2516 2019-06-03  François Dumont  <fdumont@gcc.gnu.org>
2517
2518         Rename variables and cleanup comments.
2519         * include/bits/hashtable_policy.h
2520         * include/bits/hashtable.h
2521
2522 2019-06-03  Jonathan Wakely  <jwakely@redhat.com>
2523
2524         * doc/xml/manual/status_cxx2020.xml: Add missing row for P0920R2.
2525         Fix bgcolor for P0340R3.
2526         * doc/html/*: Regenerate.
2527
2528         PR libstdc++/90686
2529         * doc/xml/manual/status_cxx2014.xml: Document what's missing from
2530         <experimental/memory_resource>.
2531         * doc/xml/manual/status_cxx2020.xml: Document status of P1285R0,
2532         P0339R6, P0340R3, P1164R1 and P1357R1.
2533         * doc/html/*: Regenerate.
2534
2535         * doc/xml/manual/status_cxx2020.xml: Document P1463R1 status.
2536         * include/bits/forward_list.h [__cplusplus > 201703]: Enable
2537         allocator::value_type assertion for C++2a.
2538         * include/bits/hashtable.h: Likewise.
2539         * include/bits/stl_deque.h: Likewise.
2540         * include/bits/stl_list.h: Likewise.
2541         * include/bits/stl_map.h: Likewise.
2542         * include/bits/stl_multimap.h: Likewise.
2543         * include/bits/stl_multiset.h: Likewise.
2544         * include/bits/stl_set.h: Likewise.
2545         * include/bits/stl_vector.h: Likewise.
2546         * testsuite/23_containers/deque/48101-3_neg.cc: New test.
2547         * testsuite/23_containers/forward_list/48101-3_neg.cc: New test.
2548         * testsuite/23_containers/list/48101-3_neg.cc: New test.
2549         * testsuite/23_containers/map/48101-3_neg.cc: New test.
2550         * testsuite/23_containers/multimap/48101-3_neg.cc: New test.
2551         * testsuite/23_containers/multiset/48101-3_neg.cc: New test.
2552         * testsuite/23_containers/set/48101-3_neg.cc: New test.
2553         * testsuite/23_containers/unordered_map/48101-3_neg.cc: New test.
2554         * testsuite/23_containers/unordered_multimap/48101-3_neg.cc: New test.
2555         * testsuite/23_containers/unordered_multiset/48101-3_neg.cc: New test.
2556         * testsuite/23_containers/unordered_set/48101-3_neg.cc: New test.
2557         * testsuite/23_containers/vector/48101-3_neg.cc: New test.
2558
2559 2019-05-31  Gerald Pfeifer  <gerald@pfeifer.com>
2560
2561         * doc/xml/manual/allocator.xml: Move hoard.org back to http.
2562
2563 2019-05-31  Jonathan Wakely  <jwakely@redhat.com>
2564
2565         * include/std/tuple (tuple<>): Add noexcept to allocator-extended
2566         constructors.
2567         (tuple<T1, T2>::__nothrow_default_constructible()): New helper
2568         function.
2569         (tuple<T1, T2>::tuple(), explicit tuple<T1, T2>::tuple()): Use helper.
2570
2571 2019-05-31  Jonathan Wakely  <jwakely@redhat.com>
2572
2573         * src/c++98/bitmap_allocator.cc: Add using-declaration for size_t.
2574
2575         PR libstdc++/90682
2576         * libsupc++/eh_term_handler.cc: Include eh_term_handler.h to get
2577         definition of _GLIBCXX_DEFAULT_TERM_HANDLER.
2578         * libsupc++/eh_term_handler.h: New header defining
2579         _GLIBCXX_DEFAULT_TERM_HANDLER.
2580         * libsupc++/eh_terminate.cc: Include eh_term_handler.h.
2581         (set_terminate): Restore default handler when argument is null.
2582         (set_unexpected): Likewise.
2583         * testsuite/18_support/set_terminate.cc: New test.
2584         * testsuite/18_support/set_unexpected.cc: New test.
2585
2586         * include/backward/hashtable.h (size_t, ptrdiff_t)
2587         (forward_iterator_tag, input_iterator_tag, _Construct, _Destroy)
2588         (distance, vector, pair, __iterator_category): Remove
2589         using-declarations that add these names to namespace __gnu_cxx.
2590         * include/ext/bitmap_allocator.h (size_t, ptrdiff_t): Likewise.
2591         * include/ext/debug_allocator.h (size_t): Likewise.
2592         * include/ext/functional (size_t, unary_function, binary_function)
2593         (mem_fun1_t, const_mem_fun1_t, mem_fun1_ref_t, const_mem_fun1_ref_t):
2594         Likewise.
2595         * include/ext/malloc_allocator.h (size_t, ptrdiff_t): Likewise.
2596         * include/ext/memory (ptrdiff_t, pair, __iterator_category): Likewise.
2597         * include/ext/mt_allocator.h (size_t, ptrdiff_t): Likewise.
2598         * include/ext/new_allocator.h (size_t, ptrdiff_t): Likewise.
2599         * include/ext/numeric (iota): Fix outdated comment.
2600         * include/ext/pool_allocator.h (size_t, ptrdiff_t): Likewise.
2601         * include/ext/rb_tree (_Rb_tree, allocator): Likewise.
2602         * include/ext/rope (size_t, ptrdiff_t, allocator, _Destroy): Likewise.
2603         * include/ext/ropeimpl.h (size_t, printf, basic_ostream)
2604         (__throw_length_error, _Destroy, std::__uninitialized_fill_n_a):
2605         Likewise.
2606         * include/ext/slist (size_t, ptrdiff_t, _Construct, _Destroy)
2607         (allocator, __true_type, __false_type): Likewise.
2608
2609 2019-05-31  Antony Polukhin  <antoshkka@gmail.com>
2610
2611         PR libstdc++/71579
2612         * include/std/type_traits __type_identity, __is_complete_or_unbounded):
2613         New helpers for checking preconditions in traits.
2614         (is_trivial, is_trivially_copyable, is_standard_layout, is_pod)
2615         (is_literal_type, is_empty, is_polymorphic, is_final, is_abstract)
2616         (is_destructible, is_nothrow_destructible, is_constructible)
2617         (is_default_constructible, is_copy_constructible)
2618         (is_move_constructible, is_nothrow_default_constructible)
2619         (is_nothrow_constructible, is_nothrow_copy_constructible)
2620         (is_nothrow_move_constructible, is_copy_assignable, is_move_assignable)
2621         (is_nothrow_assignable, is_nothrow_copy_assignable)
2622         (is_nothrow_move_assignable, is_trivially_constructible)
2623         (is_trivially_copy_constructible, is_trivially_move_constructible)
2624         is_trivially_assignable, is_trivially_copy_assignable)
2625         (is_trivially_move_assignable, is_trivially_destructible)
2626         (alignment_of, is_swappable, is_nothrow_swappable, is_invocable)
2627         (is_invocable_r, is_nothrow_invocable)
2628         (has_unique_object_representations, is_aggregate): Add static_asserts
2629         to make sure that type traits are not misused with incomplete types.
2630         (__is_constructible_impl, __is_nothrow_default_constructible_impl)
2631         (__is_nothrow_constructible_impl, __is_nothrow_assignable_impl): New
2632         base characteristics without assertions that can be reused in other
2633         traits.
2634         * testsuite/20_util/is_complete_or_unbounded/memoization.cc: New test.
2635         * testsuite/20_util/is_complete_or_unbounded/memoization_neg.cc: New
2636         test.
2637         * testsuite/20_util/is_complete_or_unbounded/value.cc: New test.
2638         * testsuite/20_util/is_abstract/incomplete_neg.cc: New test.
2639         * testsuite/20_util/is_aggregate/incomplete_neg.cc: New test.
2640         * testsuite/20_util/is_class/value.cc: Check incomplete type.
2641         * testsuite/20_util/is_function/value.cc: Likewise.
2642         * testsuite/20_util/is_move_constructible/incomplete_neg.cc: New test.
2643         * testsuite/20_util/is_nothrow_move_assignable/incomplete_neg.cc: New
2644         test.
2645         * testsuite/20_util/is_polymorphic/incomplete_neg.cc: New test.
2646         * testsuite/20_util/is_reference/value.cc: Check incomplete types.
2647         * testsuite/20_util/is_unbounded_array/value.cc: Likewise.
2648         * testsuite/20_util/is_union/value.cc: Likewise.
2649         * testsuite/20_util/is_void/value.cc: Likewise.
2650         * testsuite/util/testsuite_tr1.h: Add incomplete union type.
2651
2652 2019-05-31  Jonathan Wakely  <jwakely@redhat.com>
2653
2654         * include/bits/random.h (random_device::_M_init(const char*, size_t)):
2655         Add new private member function.
2656         * src/c++11/cow-string-inst.cc (random_device::_M_init(const string&))
2657         (random_device::_M_init_pretr1(const string&)): Call new private
2658         member with string data.
2659         * src/c++11/random.cc (random_device::_M_init(const char*, size_t)):
2660         Define.
2661         * testsuite/26_numerics/random/random_device/cons/default-cow.cc: New
2662         test using COW strings.
2663         * testsuite/26_numerics/random/random_device/cons/default.cc: Generate
2664         a value from the device.
2665         * testsuite/26_numerics/random/random_device/cons/token.cc: Likewise.
2666         Fix typo in token string.
2667
2668 2019-05-30  Nina Dinka Ranns  <dinka.ranns@gmail.com>
2669
2670         LWG2788 basic_string spurious use of a default constructible allocator
2671         * include/bits/basic_string.tcc [_GLIBCXX_USE_CXX11_ABI]
2672         (basic_string::_M_replace_dispatch): Construct temporary string with
2673         the current allocator.
2674         * testsuite/21_strings/basic_string/allocator/char/lwg2788.cc: New.
2675         * testsuite/21_strings/basic_string/allocator/wchar_t/lwg2788.cc: New.
2676
2677 2019-05-30  Jonathan Wakely  <jwakely@redhat.com>
2678
2679         * doc/xml/manual/diagnostics.xml: Update list of headers that define
2680         exception classes.
2681         * doc/xml/manual/support.xml: Rewrite advice around NULL. Rewrite
2682         section about new/delete overloads. Improve section on verbose
2683         terminate handler.
2684         * doc/html/*: Regenerate.
2685
2686         * doc/xml/manual/status_cxx2020.xml: Add feature-test macro for
2687         P0811R3. Change status of P1353R0.
2688         * doc/html/*: Regenerate.
2689
2690         * doc/xml/manual/status_cxx2011.xml: Use <variablelist> for
2691         documentation of implementation-defined types for [thread.req.native].
2692         * doc/xml/manual/status_cxx2017.xml: Update documentation of
2693         implementation-defined strings for [variant.bad.access]. Fix typo in
2694         documentation of implementation-defined support for [fs.conform.9945].
2695         * doc/html/*: Regenerate.
2696
2697 2019-05-29  Jonathan Wakely  <jwakely@redhat.com>
2698
2699         PR libstdc++/85494
2700         * testsuite/26_numerics/random/random_device/cons/token.cc: Fix test
2701         that fails on mingw-w64.
2702
2703         PR libstdc++/88881
2704         * src/c++17/fs_ops.cc [_GLIBCXX_FILESYSTEM_IS_WINDOWS]
2705         (status(const path&, error_code&)): Use parent_path() to remove
2706         trailing slash.
2707         (symlink_status(const path&, error_code&)): Duplicate workaround for
2708         bug in _wstat for paths with trailing slash.
2709         * testsuite/27_io/filesystem/operations/remove_all.cc: Check path
2710         with trailing slash.
2711         * testsuite/27_io/filesystem/operations/status.cc: Likewise.
2712         * testsuite/27_io/filesystem/operations/symlink_status.cc: Likewise.
2713
2714         * src/c++17/fs_path.cc (path::parent_path()): Create whole path at
2715         once instead of building it iteratively.
2716
2717         * testsuite/util/testsuite_api.h: Remove names of unused parameters.
2718
2719         PR libstdc++/85494 use rdseed and rand_s in std::random_device
2720         * acinclude.m4 (GLIBCXX_CHECK_X86_RDSEED): Define macro to check if
2721         the assembler supports rdseed.
2722         * config.h.in: Regenerate.
2723         * configure: Regenerate.
2724         * configure.ac: Use GLIBCXX_CHECK_X86_RDSEED.
2725         * config/os/mingw32-w64/os_defines.h (_GLIBCXX_USE_CRT_RAND_S): Define.
2726         * doc/html/*: Regenerate.
2727         * doc/xml/manual/status_cxx2011.xml: Document new tokens.
2728         * include/bits/random.h (random_device::random_device()): Always call
2729         _M_init rather than _M_init_pretr1.
2730         (random_device::random_device(const string&)): Likewise.
2731         (random_device::operator()()): Always call _M_getval().
2732         (random_device::_M_file): Replace first member of union with an
2733         anonymous struct, with _M_file as its first member.
2734         * src/c++11/random.cc [_GLIBCXX_X86_RDRAND] (USE_RDRAND): Define.
2735         [_GLIBCXX_X86_RDSEED] (USE_RDSEED): Define.
2736         (USE_MT19937): Define if none of the above are defined.
2737         (USE_POSIX_FILE_IO): Define.
2738         (_M_strtoul): Remove.
2739         [USE_RDSEED] (__x86_rdseed): Define new function.
2740         [_GLIBCXX_USE_CRT_RAND_S] (__winxp_rand_s): Define new function.
2741         (random_device::_M_init(const string&)): Initialize new union members.
2742         Add support for "rdseed" and "rand_s" tokens. Decide what the
2743         "default" token does according to which USE_* macros are defined.
2744         [USE_POSIX_FILE_IO]: Store a file descriptor.
2745         [USE_MT19937]: Forward to _M_init_pretr1 instead.
2746         (random_device::_M_init_pretr1(const string&)) [USE_MT19937]: Inline
2747         code from _M_strtoul.
2748         [!USE_MT19937]: Call _M_init, transforming the old default token or
2749         numeric tokens to "default".
2750         (random_device::_M_fini()) [USE_POSIX_FILE_IO]: Use close not fclose.
2751         (random_device::_M_getval()): Use new union members to obtain a
2752         random number from the stored function pointer or file descriptor.
2753         [USE_MT19937]: Obtain a value from the mt19937 engine.
2754         (random_device::_M_getval_pretr1()): Call _M_getval().
2755         (random_device::_M_getentropy()) [USE_POSIX_FILE_IO]: Use _M_fd
2756         instead of fileno.
2757         [!USE_MT19937] (mersenne_twister): Do not instantiate when not needed.
2758         * testsuite/26_numerics/random/random_device/85494.cc: New test.
2759
2760 2019-05-28  Jonathan Wakely  <jwakely@redhat.com>
2761
2762         PR libstdc++/90634
2763         * include/experimental/bits/fs_path.h (path::path(path&&)): Only call
2764         _M_split_cmpts() for a path with multiple components.
2765         (path::_S_is_dir_sep()): Add missing 'static' keyword to function.
2766         * src/filesystem/path.cc (path::_M_split_cmpts()): Count number of
2767         components and reserve space in vector. Return early when there is
2768         only one component.
2769         * testsuite/27_io/filesystem/path/construct/90634.cc: New test.
2770         * testsuite/experimental/filesystem/path/construct/90634.cc: New test.
2771
2772         * testsuite/util/testsuite_fs.h (compare_paths): Use three-argument
2773         form of std::equals for C++11 compatibility.
2774
2775 2019-05-26  Gerald Pfeifer  <gerald@pfeifer.com>
2776
2777         * doc/xml/manual/appendix_contributing.xml: Update pointer to
2778         C++ standard at ansi.org.
2779
2780 2019-05-24  Jonathan Wakely  <jwakely@redhat.com>
2781
2782         * include/std/numeric (midpoint(T*, T*)): Fix incorrect result.
2783         * testsuite/26_numerics/midpoint/pointer.cc: Change "compile" test
2784         to "run".
2785
2786         * testsuite/20_util/shared_ptr/cons/alias-rval.cc: Fix test.
2787         * testsuite/20_util/shared_ptr/cons/alias.cc: Remove unused function.
2788
2789 2019-05-23  Jonathan Wakely  <jwakely@redhat.com>
2790
2791         * testsuite/20_util/function_objects/invoke/1.cc: Move C++17-specific
2792         tests to ...
2793         * testsuite/20_util/function_objects/invoke/3.cc: New test.
2794         * testsuite/23_containers/unordered_set/allocator/ext_ptr.cc: Change
2795         "compile" test to "run".
2796
2797         * doc/xml/manual/intro.xml: Document LWG DR 2996 change.
2798         * doc/html/*: Regenerate.
2799         * include/bits/shared_ptr.h (shared_ptr(shared_ptr&&, T*)): Add
2800         rvalue aliasing constructor.
2801         (static_pointer_cast, const_pointer, dynamic_pointer_cast)
2802         (reinterpret_pointer_cast): Add overloads taking rvalues.
2803         * include/bits/shared_ptr_base.h (__shared_ptr(__shared_ptr&&, T*)):
2804         Add rvalue aliasing constructor.
2805         * testsuite/20_util/shared_ptr/casts/1.cc: Change "compile" test to
2806         "run" and check return values as well as types.
2807         * testsuite/20_util/shared_ptr/casts/reinterpret.cc: Likewise.
2808         * testsuite/20_util/shared_ptr/casts/rval.cc: New test.
2809         * testsuite/20_util/shared_ptr/cons/alias-rval.cc: New test.
2810         * testsuite/20_util/shared_ptr/cons/alias.cc: Remove unused return
2811         values.
2812
2813         * doc/xml/manual/evolution.xml: Document LWG DR 2921 change.
2814         * doc/xml/manual/intro.xml: Likewise.
2815         * include/std/future (__create_task_state): Add default arguments
2816         to make providing an allocator optional.
2817         (packaged_task::packaged_task(F&&)): Call __create_task_state directly
2818         instead of delegating to another constructor.
2819         (packaged_task::packaged_task(allocator_arg_t, const A&, ...)): Do not
2820         define allocator-extended constructors for C++17 and later.
2821         * testsuite/30_threads/packaged_task/cons/alloc.cc: Only run test for
2822         C++11 and C++14.
2823         * testsuite/30_threads/packaged_task/cons/alloc2.cc: Likewise.
2824         * testsuite/30_threads/packaged_task/cons/alloc_min.cc: Likewise.
2825         * testsuite/30_threads/packaged_task/uses_allocator.cc: Likewise.
2826
2827 2019-05-23  Hans-Peter Nilsson  <hp@axis.com>
2828
2829         * testsuite/26_numerics/random/poisson_distribution/operators/values.cc:
2830         Don't run the libstdc++/83237 part on simulator targets.
2831
2832 2019-05-23  Jonathan Wakely  <jwakely@redhat.com>
2833
2834         * doc/xml/manual/status_cxx2017.xml: Add feature test macro for
2835         P0040R3.
2836         * doc/html/*: Regenerate.
2837
2838         * include/experimental/any (__any_caster): Use RTTI if comparing
2839         addresses fails, to support non-unique addresses in shared libraries.
2840         * include/std/any (__any_caster): Likewise.
2841
2842         PR libstdc++/90220
2843         * include/experimental/any (__any_caster): Constrain to only be
2844         callable for object types. Use remove_cv_t instead of decay_t.
2845         If the type decays or isn't copy constructible, compare the manager
2846         function to a dummy specialization.
2847         (__any_caster): Add overload constrained for non-object types.
2848         (any::_Manager_internal<_Op>): Add dummy specialization.
2849         * testsuite/experimental/any/misc/any_cast.cc: Test function types
2850         and array types.
2851
2852 2019-05-22  Jonathan Wakely  <jwakely@redhat.com>
2853
2854         PR libstdc++/90557
2855         * src/c++17/fs_path.cc (path::_List::operator=(const _List&)): Fix
2856         reversed arguments to uninitialized_copy_n.
2857         * testsuite/27_io/filesystem/path/assign/copy.cc: Check that source
2858         is unchanged by copy assignment.
2859         * testsuite/util/testsuite_fs.h (compare_paths): Use std::equal to
2860         compare path components.
2861
2862         PR libstdc++/77691
2863         * include/experimental/memory_resource: Add system header pragma and
2864         do not define anything unless compiled as C++14 or later.
2865         (__resource_adaptor_common::__guaranteed_alignment): Remove.
2866         (__resource_adaptor_imp::do_allocate): If the requested alignment
2867         is a fundamental alignment then either allocate directly from _M_alloc
2868         or call the new _M_allocate function.
2869         (__resource_adaptor_imp::do_deallocate): Likewise for deallocation.
2870         (__resource_adaptor_imp::_M_allocate): New function that uses a copy
2871         of the allocator rebound to a POD type with the specified alignment.
2872         (__resource_adaptor_imp::_M_deallocate): Likewise for deallocation.
2873         * testsuite/experimental/memory_resource/new_delete_resource.cc:
2874         Adjust expected allocation sizes.
2875         * testsuite/experimental/memory_resource/resource_adaptor.cc: Remove
2876         xfail for Solaris x86.
2877
2878 2019-05-21  Thomas Rodgers  <trodgers@redhat.com>
2879
2880         LWG 3062 - Unnecessary decay_t in is_execution_policy_v
2881         * include/pstl/execution_defs.h (__enable_if_execution_policy):
2882         Use std::__remove_cvref_t when building with GCC.
2883
2884 2019-05-21  Jonathan Wakely  <jwakely@redhat.com>
2885
2886         PR libstdc++/90252
2887         * testsuite/lib/libstdc++.exp (check_effective_target_tbb-backend):
2888         Use "additional_flags" to pass -ltbb to v3_target_compile command.
2889         Use check_v3_target_prop_cached to cache the result of the test.
2890
2891         * doc/xml/manual/shared_ptr.xml: Fix names of lock policy constants.
2892
2893 2019-05-20  Thomas Rodgers  <trodgers@redhat.com>
2894
2895         PR libstdc++/90252
2896         * testsuite/lib/libstdc++.exp (check_effective_target_tbb-backend):
2897         Changed v3_target_compile check from preprocess to executable.
2898         Added "-ltbb" to v3_target_compile flags.
2899
2900 2019-05-20  Thomas Rodgers  <trodgers@redhat.com>
2901
2902         * testsuite/lib/libstdc++.exp (check_effective_target_tbb-backend):
2903         Add check for Thread Building Blocks 2018 or later.
2904
2905 2019-05-20  Jonathan Wakely  <jwakely@redhat.com>
2906
2907         * testsuite/experimental/names.cc: Only include Networking TS headers
2908         on targets with the necessary Gthreads support.
2909
2910 2019-05-20  Marek Polacek  <polacek@redhat.com>
2911
2912         CWG 2094 - volatile scalars are trivially copyable.
2913         PR c++/85679
2914         * testsuite/20_util/is_trivially_copyable/value.cc: Change the expected
2915         result for volatile int.
2916
2917 2019-05-20  Jonathan Wakely  <jwakely@redhat.com>
2918
2919         * testsuite/17_intro/names.cc: Do not check 'ptr' on Solaris.
2920         * testsuite/experimental/names.cc: Include <experimental/filesystem>
2921         conditionally.
2922
2923         PR c++/90532 Ensure __is_constructible(T[]) is false
2924         * include/std/type_traits (__do_is_default_constructible_impl)
2925         (__is_default_constructible_atom, __is_default_constructible_safe):
2926         Remove.
2927         (is_default_constructible): Use is_constructible.
2928         * testsuite/20_util/is_constructible/value.cc: Check int[] case.
2929         * testsuite/20_util/is_default_constructible/value.cc: Likewise.
2930         * testsuite/20_util/is_trivially_constructible/value.cc: Likewise.
2931         * testsuite/20_util/is_trivially_default_constructible/value.cc:
2932         Likewise.
2933
2934 2019-05-20  Pádraig Brady  <pbrady@fb.com>
2935
2936         * libstdc++-v3/include/ext/new_allocator.h (deallocate): Pass the size
2937         to the deallocator with -fsized-deallocation.
2938
2939 2019-05-20  Jonathan Wakely  <jwakely@redhat.com>
2940
2941         * testsuite/experimental/memory_resource/new_delete_resource.cc: Fix
2942         test by passing correct alignment to deallocate function.
2943
2944 2019-05-18  Jonathan Wakely  <jwakely@redhat.com>
2945
2946         PR libstdc++/90520
2947         * python/libstdcxx/v6/printers.py (UniquePointerPrinter.__init__):
2948         Raise exception if unique_ptr tuple member has unknown structure.
2949         * python/libstdcxx/v6/xmethods.py (UniquePtrGetWorker.__call__):
2950         Adjust worker to support new __uniq_ptr_data base class. Do not
2951         assume field called _M_head_impl is the first tuple element.
2952
2953 2019-05-17  François Dumont  <fdumont@gcc.gnu.org>
2954
2955         * include/bits/stl_deque.h
2956         (_Deque_iterator<>::__ptr_to): Remove, use std::__ptr_rebind.
2957         (_Deque_base(_Deque_base&&, const allocator_type&)): New.
2958         (_Deque_base::_Deque_impl_data): New.
2959         (_Deque_base::_Deque_impl): Inherit latter.
2960         (_Deque_base::_Deque_impl::_M_swap_data): Move...
2961         (_Deque_base::_Deque_impl_data::_M_swap_data): ... here.
2962         (_Deque_base::_Deque_impl()): Add noexcept qualification.
2963         (_Deque_base::_Deque_impl(_Deque_impl&&, _Tp_alloc_type&&)): New.
2964         (_Deque_base::_Deque_impl::_M_get_Tp_allocator()): Remove static_cast.
2965         (deque<>::deque()): Default.
2966         (deque<>::deque(deque&&)): Default.
2967         (deque<>::deque(deque&&, const allocator_type&, false_type)): New.
2968         (deque<>::deque(deque&&, const allocator_type&, true_type)): New.
2969         (deque<>::deque(deque&&, const allocator_type&)): Delegate to latters.
2970         (deque<>::deque<_It>(_It, _It, const allocator_type&)): Use
2971         _M_range_initialize.
2972         (deque<>::assign<_It>(_It, _It)): Use _M_assign_aux.
2973         (deque<>::resize(size_type, const value_type&)): Share a single
2974         implementation.
2975         (deque<>::insert<_It>(const_iterator, _It, _It)): Use
2976         _M_range_insert_aux.
2977         [__cplusplus >= 201103L](_M_initialize_dispatch): Remove.
2978         [__cplusplus >= 201103L](_M_assign_dispatch): Remove.
2979         [__cplusplus >= 201103L](_M_insert_dispatch): Remove.
2980         * testsuite/23_containers/deque/allocator/default_init.cc: New.
2981
2982 2019-05-17  Jonathan Wakely  <jwakely@redhat.com>
2983
2984         PR libstdc++/90246
2985         * include/std/variant (holds_alternative, get, get_if): Improve
2986         static assertion messages.
2987         (bad_variant_access::bad_variant_access()): Change default message.
2988         (__throw_bad_variant_access(bool)): New overload.
2989         (get): Use new overload.
2990         (visit, visit<R>): Improve exception message.
2991
2992         * testsuite/20_util/variant/compile.cc: Fix narrowing test for ILP32
2993         targets. Add more cases from P0608R3.
2994         * testsuite/20_util/variant/run.cc: Add more cases from P0608R3.
2995
2996         * include/bits/random.h (seed_seq::param): Fix non-reserved name.
2997         * include/experimental/type_traits (is_detected_exact)
2998         (is_detected_exact_v): Likewise.
2999         * include/pstl/execution_defs.h (is_execution_policy)
3000         (is_execution_policy_v, __enable_if_execution_policy): Likewise.
3001         * include/pstl/execution_impl.h (__policy_traits): Likewise.
3002         * testsuite/17_intro/names.cc: Check for more non-reserved names.
3003         * testsuite/experimental/names.cc: New test.
3004
3005         PR libstdc++/85965
3006         * include/bits/hashtable.h (_Hashtable::~_Hashtable()): Remove static
3007         assertions from the destructor.
3008         * include/bits/hashtable_policy.h (_Hash_code_base::_M_hash_code):
3009         Move static_assert for hash function to here.
3010         (_Hash_table_base::_M_equals): Move static_assert for equality
3011         predicate to here.
3012         * include/bits/stl_tree.h (_Rb_tree::_S_value(_Const_Link_type)):
3013         Remove.
3014         (_Rb_tree::_S_key(_Const_Link_type)): Move assertions here. Access
3015         the value directly instead of calling _S_value.
3016         (_Rb_tree::_S_value(_Const_Base_ptr)): Remove.
3017         (_Rb_tree::_S_key(_Const_Base_ptr)): Do downcast and forward to
3018         _S_key(_Const_Link_type).
3019         * testsuite/23_containers/set/85965.cc: Check construction,
3020         destruction, assignment and size() do not trigger the assertions.
3021         * testsuite/23_containers/unordered_set/85965.cc: Likewise.
3022         * testsuite/23_containers/map/48101_neg.cc: Call find and adjust
3023         expected errors.
3024         * testsuite/23_containers/multimap/48101_neg.cc: Likewise.
3025         * testsuite/23_containers/multiset/48101_neg.cc: Likewise.
3026         * testsuite/23_containers/set/48101_neg.cc: Likewise.
3027         * testsuite/23_containers/unordered_map/48101_neg.cc: Likewise.
3028         * testsuite/23_containers/unordered_multimap/48101_neg.cc: Likewise.
3029         * testsuite/23_containers/unordered_multiset/48101_neg.cc: Likewise.
3030         * testsuite/23_containers/unordered_set/48101_neg.cc: Likewise.
3031
3032         * include/bits/invoke.h [__cplusplus < 201703L] (__invoke_r<void>):
3033         Use _GLIBCXX14_CONSTEXPR because void functions cannot be constexpr
3034         in C++11.
3035
3036         * doc/xml/manual/status_cxx2020.xml: Update P0608R3, P0777R1, and
3037         P1165R1 entries.
3038         * doc/html/*: Regenerate.
3039         * include/std/tuple (make_from_tuple): Use remove_reference_t instead
3040         of decay_t (P0777R1).
3041
3042 2019-05-17  François Dumont  <fdumont@gcc.gnu.org>
3043
3044         Move from state of allocators (LWG2593)
3045         * include/bits/stl_deque.h
3046         (_Deque_base(_Deque_base&&, false_type)): Remove.
3047         (_Deque_base(_Deque_base&&, true_type)): Remove.
3048         (_Deque_base(_Deque_base&&)): Adapt.
3049         (_Deque_base::_M_move_impl()): Remove.
3050         * testsuite/util/testsuite_allocator.h
3051         (propagating_allocator(propagating_allocator&&)): Preserve move from
3052         state.
3053         * testsuite/23_containers/deque/allocator/move_assign.cc (test02):
3054         Adapt.
3055         * testsuite/23_containers/forward_list/allocator/move_assign.cc (test02):
3056         Adapt.
3057         * testsuite/23_containers/list/allocator/move_assign.cc (test02): Adapt.
3058         * testsuite/23_containers/map/allocator/move_assign.cc (test02): Adapt.
3059         * testsuite/23_containers/multimap/allocator/move_assign.cc (test02):
3060         Adapt.
3061         * testsuite/23_containers/multiset/allocator/move_assign.cc (test02):
3062         Adapt.
3063         * testsuite/23_containers/set/allocator/move_assign.cc (test02): Adapt.
3064         * testsuite/23_containers/unordered_map/allocator/move_assign.cc
3065         (test02): Adapt.
3066         * testsuite/23_containers/unordered_multimap/allocator/move_assign.cc
3067         (test02): Adapt.
3068         * testsuite/23_containers/unordered_multiset/allocator/move_assign.cc
3069         (test02): Adapt.
3070         * testsuite/23_containers/unordered_set/allocator/move_assign.cc
3071         (test02): Adapt.
3072         * testsuite/23_containers/vector/allocator/move_assign.cc (test02):
3073         Adapt.
3074         * testsuite/23_containers/vector/bool/allocator/move_assign.cc (test02):
3075         Adapt.
3076         * testsuite/21_strings/basic_string/allocator/char/move_assign.cc
3077         (test02): Adapt.
3078         * testsuite/21_strings/basic_string/allocator/wchar_t/move_assign.cc
3079         (test02): Adapt.
3080
3081 2019-05-16  Jonathan Wakely  <jwakely@redhat.com>
3082
3083         * src/c++17/fs_ops.cc (absolute(const path&, error_code&))
3084         [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Remove bogus assertion.
3085
3086         * include/std/variant (__overload_set): Remove.
3087         (_Arr): New helper.
3088         (_Build_FUN): New class template to define a single FUN overload,
3089         with specializations to prevent unwanted conversions, as per P0608R3.
3090         (_Build_FUNs): New class template to build an overload set of FUN.
3091         (_FUN_type): New alias template to perform overload resolution.
3092         (__accepted_type): Use integer_constant base for failure case. Use
3093         _FUN_type for successful case.
3094         (variant::__accepted_index): Use _Tp instead of _Tp&&.
3095         (variant::variant(_Tp&&)): Likewise.
3096         (variant::operator=(_Tp&&)): Likewise.
3097
3098         * include/std/variant (_Variant_storage<false, _Types...>::_M_reset):
3099         Replace raw visitation with a runtime check for the valueless state
3100         and a non-raw visitor.
3101         (_Variant_storage<false, _Types...>::_M_reset_impl): Remove.
3102         (variant::index()): Remove branch.
3103         (variant::swap(variant&)): Use valueless_by_exception() instead of
3104         comparing the index to variant_npos, and add likelihood attribute.
3105
3106         * include/bits/hashtable_policy.h (_Equal_helper): Remove.
3107         (_Hashtable_base::_Equal_hash_code): Define new class template.
3108         (_Hashtable_base::_M_equals): Use _Equal_hash_code instead of
3109         _Equal_helper.
3110
3111         * include/bits/hashtable_policy.h (_Hashtable_ebo_helper::_S_get):
3112         Replace with _M_get non-static member function.
3113         (_Hashtable_ebo_helper::_S_cget): Replace with _M_cget non-static
3114         member function.
3115         (_Hash_code_base, _Local_iterator_base, _Hashtable_base):
3116         (_Hashtable_alloc): Adjust to use non-static members of EBO helper.
3117
3118         * include/bits/hashtable_policy.h (_Hash_code_base::_M_swap): Use
3119         _S_get accessors for members in EBO helpers.
3120         (_Hash_code_base::_M_extract(), _Hash_code_base::_M_ranged_hash())
3121         (_Hash_code_base::_M_h1(), _Hash_code_base::_M_h2()): Remove non-const
3122         overloads.
3123         (_Hashtable_base::_M_swap): Use _S_get accessors for members in EBO
3124         helpers.
3125         (_Hashtable_base::_M_eq()): Remove non-const overload.
3126
3127 2019-05-15  Jonathan Wakely  <jwakely@redhat.com>
3128
3129         * include/std/variant (visit, visit<R>): Qualify calls to __do_visit.
3130
3131 2019-05-14  Jonathan Wakely  <jwakely@redhat.com>
3132
3133         * testsuite/util/testsuite_allocator.h (NullablePointer::operator bool):
3134         Fix return value.
3135
3136 2019-05-14  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
3137
3138         * config/os/solaris/solaris2.10: Move to ...
3139         * config/os/solaris: ... this.
3140         * configure.host (os_include_dir): Adapt.
3141         (abi_baseline_pair): Remove Solaris 10 handling.
3142         * config/abi/post/i386-solaris2.10: Remove.
3143         * config/abi/post/sparc-solaris2.10: Remove.
3144         * config/abi/post/i386-solaris2.11: Rename to ...
3145         * config/abi/post/i386-solaris: ... this.
3146         * config/abi/post/sparc-solaris2.11: Rename to ...
3147         * config/abi/post/sparc-solaris: ... this.
3148
3149         * libsupc++/new_opa.cc [_GLIBCXX_HAVE_MEMALIGN] [__sun]: Remove
3150         workaround.
3151
3152         * testsuite/ext/enc_filebuf/char/13598.cc: Remove *-*-solaris2.10
3153         xfail.
3154
3155 2019-05-14  Jonathan Wakely  <jwakely@redhat.com>
3156
3157         * include/std/variant (__visit_with_index): Remove typedef.
3158         (__deduce_visit_result): New tag type.
3159         (__raw_visit, __raw_idx_visit): New helper functions for "raw"
3160         visitation of possibly-valueless variants, forwarding to __do_visit
3161         with the relevant tag type.
3162         (_Variant_storage<false, _Types...>::_M_reset_impl): Use __raw_visit
3163         and make lambda return void.
3164         (__variant_construct): Likewise.
3165         (_Copy_assign_base::operator=, _Move_assign_base::operator=): Use
3166         __raw_idx_visit and make lambda return void.
3167         (_Multi_array::__untag_result): Add metafunction to check the function
3168         pointer type for a tag type that dictates the kind of visitation.
3169         (_Multi_array<_Ret(*)(_Visitor, _Variants...), __first, __rest...>):
3170         Use decltype(auto) instead of tagged function pointer type.
3171         (__gen_vtable_impl): Remove bool non-type parameter and unused
3172         _Variant_tuple parameter.
3173         (__gen_vtable_impl::__visit_invoke_impl): Remove.
3174         (__gen_vtable_impl::__do_visit_invoke): Remove.
3175         (__gen_vtable_impl::__do_visit_invoke_r): Remove.
3176         (__gen_vtable_impl::__visit_invoke): Use if-constexpr and __invoke_r
3177         for the visit<R> case, rather than dispatching to separate functions.
3178         (_VARIANT_RELATION_FUNCTION_TEMPLATE): Use __raw_idx_visit and make
3179         lambda return void.
3180         (variant::swap): Likewise.
3181         (__do_visit): Replace two non-type template parameters with a single
3182         type parameter, so that the caller must specify the visitor's return
3183         type (or one of the tag types).
3184         (visit): Deduce a return type from the visitor and use the
3185         __deduce_visit_result tag to enforce that all overloads return the
3186         same type.
3187         (visit<R>): Call __do_visit<R> with explicit result type.
3188         (__variant_hash_call_base_impl::operator()): Use __raw_visit and make
3189         lambda return void.
3190
3191 2019-05-14  Nina Dinka Ranns  <dinka.ranns@gmail.com>
3192
3193         nonesuch is insufficiently useless (lwg2996)
3194         * include/std/type_traits (struct __nonesuch): Added private base
3195         class to make __nonesuch not an aggregate and removed deleted default
3196         constructor.
3197         * include/bits/stl_pair.h (struct __nonesuch_no_braces): Removed.
3198         (operator=(const pair&)): Use __nonesuch instead of
3199         __nonesuch_no_braces.
3200         (operator=(pair&&)): Likewise
3201         * include/std/tuple (operator=(const tuple&)): Use __nonesuch instead
3202         of __nonesuch_no_braces.
3203         (operator=(tuple&&)): Likewise
3204         * include/experimental/type_traits (struct nonesuch): Added private
3205         base class to make nonesuch not an aggregate and removed deleted
3206         default constructor.
3207         * testsuite/20_util/nonesuch/nonesuch.cc: New.
3208         * testsuite/experimental/type_traits/nonesuch.cc: New.
3209
3210 2019-05-14  Jonathan Wakely  <jwakely@redhat.com>
3211
3212         * include/bits/std_function.h (_Simple_type_wrapper): Remove.
3213         (_Function_handler): Remove partial specializations for void return
3214         types and pointers to member.
3215         (_Function_handler::_M_manager): Adapt to removal of
3216         _Simple_type_wrapper.
3217         (_Function_handler::_M_invoke): Use __invoke_r instead of __invoke.
3218         * include/std/functional (_Bind_result::__enable_if_void)
3219         (_Bind_result::__disable_if_void): Remove sfinae helpers.
3220         (_Bind_result::__call): Use __invoke_r and remove overloads for void
3221         return types.
3222         * include/std/future (__future_base::_Task_state::_M_run)
3223         (__future_base::_Task_state::_M_run_delayed): Use __invoke_r and
3224         change return type of lambda expressions.
3225
3226         * include/bits/invoke.h (__invoke_r): Define new function implementing
3227         the INVOKE<R> pseudo-function.
3228         * testsuite/20_util/function_objects/invoke/1.cc: Add more tests.
3229         * testsuite/20_util/function_objects/invoke/2.cc: New test.
3230
3231         * include/std/type_traits (__is_nt_convertible_helper): Define it
3232         unconditionally, not only for C++20.
3233         (__is_nothrow_convertible): Define internal trait for use in C++11.
3234         (__is_nt_invocable_impl: Fix by using __is_nothrow_convertible.
3235         (is_invocable_r_v, is_nothrow_invocable_r_v): Add missing parameter.
3236         * testsuite/20_util/is_nothrow_convertible/value_ext.cc: New test.
3237         * testsuite/20_util/is_nothrow_convertible/value.cc: Check with type
3238         that has nothrow explicit conversion but potentially-throwing implicit
3239         conversion.
3240         * testsuite/20_util/is_nothrow_invocable/value.cc: Likewise.
3241         * testsuite/20_util/is_nothrow_invocable/value_ext.cc: Fix helper
3242         function to only consider implicit conversions.
3243         * testsuite/20_util/tuple/cons/noexcept_specs.cc: Add comment.
3244
3245         * include/std/iterator: Include <iosfwd> instead of <istream> and
3246         <ostream>.
3247
3248         * include/bits/stl_tree.h (_Rb_tree::erase(const Key*, const Key*)):
3249         Remove unused, non-standard function.
3250
3251         * include/bits/regex.h (match_results::max_size()): Adjust return
3252         value to account for prefix/suffix/unmatched subs.
3253         (match_results::_M_resize(unsigned int)): Use _Base_type::assign to
3254         reset the contained sub matches.
3255         (match_results::_M_establish_failed_match(_Bi_iter)): Add new member
3256         function to set result state following a failed match.
3257         * include/bits/regex.tcc (__regex_algo_impl): Remove loop to set
3258         sub_match states after _M_resize. Use _M_establish_failed_match.
3259
3260         PR libstdc++/69724
3261         * include/std/thread (thread::_State_impl, thread::_S_make_state):
3262         Replace single _Callable parameter with variadic _Args pack, to
3263         forward them directly to the tuple of decayed copies.
3264         * testsuite/30_threads/thread/cons/69724.cc: New test.
3265
3266 2019-05-14  Nina Dinka Ranns  <dinka.ranns@gmail.com>
3267
3268         Inconsistency wrt Allocators in basic_string assignment (LWG2579)
3269         * include/bits/basic_string.h: (operator=(const basic_string&):
3270         Move allocator decision to assign.
3271         (assign(const basic_string&)): Move allocator decision here.
3272         * testsuite/21_strings/basic_string/allocator/char/copy_assign.cc:
3273         Add tests.
3274         * testsuite/21_strings/basic_string/allocator/wchar_t/copy_assign.cc:
3275         Add tests.
3276
3277 2019-05-14  Jonathan Wakely  <jwakely@redhat.com>
3278
3279         * testsuite/util/testsuite_allocator.h (memory_resource)
3280         (default_resource_mgr): Fix indentation.
3281
3282         * testsuite/20_util/allocator_traits/members/allocate_hint_nonpod.cc:
3283         Use operator-> to access raw pointer member.
3284         * testsuite/23_containers/vector/59829.cc: Likewise.
3285         * testsuite/23_containers/vector/bool/80893.cc: Likewise.
3286         * testsuite/libstdc++-prettyprinters/cxx11.cc: Use NullablePointer.
3287         * testsuite/util/testsuite_allocator.h (NullablePointer): New utility
3288         for tests.
3289         (PointerBase, PointerBase_void): Derive from NullablePointer and use
3290         its constructors and equality operators. Change converting
3291         constructors to use operator-> to access private member of the other
3292         pointer type.
3293         (PointerBase_void::operator->()): Add, for access to private member.
3294         (operator-(PointerBase, PointerBase)): Change to hidden friend.
3295         (operator==(PointerBase, PointerBase)): Remove.
3296         (operator!=(PointerBase, PointerBase)): Remove.
3297
3298         * python/libstdcxx/v6/printers.py (UniquePointerPrinter.__init__): Do
3299         not assume field called _M_head_impl is the first tuple element.
3300         * testsuite/libstdc++-prettyprinters/compat.cc: Make tuple
3301         implementation more accurate.
3302         * testsuite/libstdc++-prettyprinters/cxx11.cc: Check unique_ptr with
3303         empty pointer type and non-empty deleter.
3304
3305         LWG 2899 - Make is_move_constructible correct for unique_ptr
3306         * include/bits/unique_ptr.h (__uniq_ptr_impl): Add move constructor,
3307         move assignment operator.
3308         (__uniq_ptr_impl::release(), __uniq_ptr_impl::reset(pointer)): Add.
3309         (__uniq_ptr_data): New class template with conditionally deleted
3310         special members.
3311         (unique_ptr, unique_ptr<T[], D>): Change type of data member from
3312         __uniq_ptr_impl<T, D> to __uniq_ptr_data<T, D>. Define move
3313         constructor and move assignment operator as defaulted.
3314         (unique_ptr::release(), unique_ptr<T[], D>::release()): Forward to
3315         __uniq_ptr_impl::release().
3316         (unique_ptr::reset(pointer), unique_ptr<T[], D>::reset<U>(U)): Forward
3317         to __uniq_ptr_impl::reset(pointer).
3318         * python/libstdcxx/v6/printers.py (UniquePointerPrinter.__init__):
3319         Check for new __uniq_ptr_data type.
3320         * testsuite/20_util/unique_ptr/dr2899.cc: New test.
3321
3322 2019-05-13  Jonathan Wakely  <jwakely@redhat.com>
3323
3324         PR libstdc++/90454.cc path construction from void*
3325         * include/bits/fs_path.h (path::_Path): Use remove_pointer so that
3326         pointers to void are rejected as well as void.
3327         * include/experimental/bits/fs_path.h (path::_Path): Likewise.
3328         * testsuite/27_io/filesystem/path/construct/80762.cc: Also check
3329         pointers to void.
3330         * testsuite/experimental/filesystem/path/construct/80762.cc: Likewise.
3331
3332         * doc/xml/manual/policy_data_structures.xml: Comment out stray
3333         <remark> elements. Fix formatting of bibliography references.
3334
3335 2019-05-13  Edward Smith-Rowland  <3dw4rd@verizon.net>
3336
3337         * doc/xml/manual/status_cxx2020.xml: Document P0811R3 status.
3338
3339 2019-05-13  Jonathan Wakely  <jwakely@redhat.com>
3340
3341         Remove Profile Mode, deprecated since 7.1.0
3342         * doc/Makefile.am: Remove XML file for profile mode docs.
3343         * doc/Makefile.in: Regenerate.
3344         * doc/xml/authors.xml: Remove authors of profile mode docs.
3345         * doc/xml/manual/appendix_contributing.xml: Remove mention of profile
3346         mode.
3347         * doc/xml/manual/debug.xml: Likewise.
3348         * doc/xml/manual/evolution.xml: Document removal of profile mode.
3349         * doc/xml/manual/profile_mode.xml: Remove profile mode docs.
3350         * doc/xml/manual/spine.xml: Remove profile mode author credit.
3351         * doc/xml/manual/test.xml: Remove docs for dg-require-profile-mode
3352         directive.
3353         * doc/xml/manual/using.xml: Remove docs for profile mode headers and
3354         macro.
3355         * doc/html/*: Regenerate.
3356         * include/Makefile.am: Remove profile mode headers.
3357         * include/Makefile.in: Regenerate.
3358         * include/bits/c++config (std::__profile): Remove namespace.
3359         [_GLIBCXX_PROFILE]: Remove checks for macro.
3360         * include/profile/array: Remove.
3361         * include/profile/base.h: Remove.
3362         * include/profile/bitset: Remove.
3363         * include/profile/deque: Remove.
3364         * include/profile/forward_list: Remove.
3365         * include/profile/impl/profiler.h: Remove.
3366         * include/profile/impl/profiler_algos.h: Remove.
3367         * include/profile/impl/profiler_container_size.h: Remove.
3368         * include/profile/impl/profiler_hash_func.h: Remove.
3369         * include/profile/impl/profiler_hashtable_size.h: Remove.
3370         * include/profile/impl/profiler_list_to_slist.h: Remove.
3371         * include/profile/impl/profiler_list_to_vector.h: Remove.
3372         * include/profile/impl/profiler_map_to_unordered_map.h: Remove.
3373         * include/profile/impl/profiler_node.h: Remove.
3374         * include/profile/impl/profiler_state.h: Remove.
3375         * include/profile/impl/profiler_trace.h: Remove.
3376         * include/profile/impl/profiler_vector_size.h: Remove.
3377         * include/profile/impl/profiler_vector_to_list.h: Remove.
3378         * include/profile/iterator_tracker.h: Remove.
3379         * include/profile/list: Remove.
3380         * include/profile/map: Remove.
3381         * include/profile/map.h: Remove.
3382         * include/profile/multimap.h: Remove.
3383         * include/profile/multiset.h: Remove.
3384         * include/profile/ordered_base.h: Remove.
3385         * include/profile/set: Remove.
3386         * include/profile/set.h: Remove.
3387         * include/profile/unordered_base.h: Remove.
3388         * include/profile/unordered_map: Remove.
3389         * include/profile/unordered_set: Remove.
3390         * include/profile/vector: Remove.
3391         * scripts/run_doxygen: Do not process profile mode headers.
3392         * testsuite/23_containers/array/element_access/60497.cc: Don't use
3393         profile mode type.
3394         * testsuite/23_containers/array/specialized_algorithms/swap_cxx17.cc:
3395         Remove dg-skip-if for profile mode.
3396         * testsuite/23_containers/forward_list/capacity/1.cc: Remove
3397         preprocessor check for profile mode.
3398         * testsuite/23_containers/list/capacity/29134.cc: Likewise.
3399         * testsuite/23_containers/map/modifiers/extract.cc: Remove dg-skip-if
3400         for profile mode.
3401         * testsuite/23_containers/map/modifiers/insert_or_assign/1.cc:
3402         Likewise.
3403         * testsuite/23_containers/map/modifiers/try_emplace/1.cc: Likewise.
3404         * testsuite/23_containers/multimap/modifiers/extract.cc: Likewise.
3405         * testsuite/23_containers/multiset/modifiers/extract.cc: Likewise.
3406         * testsuite/23_containers/set/modifiers/extract.cc: Likewise.
3407         * testsuite/23_containers/unordered_map/modifiers/extract.cc:
3408         Likewise.
3409         * testsuite/23_containers/unordered_multimap/modifiers/extract.cc:
3410         Likewise.
3411         * testsuite/23_containers/unordered_multiset/modifiers/extract.cc:
3412         Likewise.
3413         * testsuite/23_containers/unordered_set/modifiers/extract.cc:
3414         Likewise.
3415         * testsuite/23_containers/vector/bool/capacity/29134.cc: Remove
3416         preprocessor check for profile mode.
3417         * testsuite/23_containers/vector/bool/modifiers/insert/31370.cc:
3418         Likewise.
3419         * testsuite/23_containers/vector/modifiers/insert_vs_emplace.cc:
3420         Remove dg-skip-if for profile mode.
3421         * testsuite/25_algorithms/binary_search/partitioned.cc: Likewise.
3422         * testsuite/25_algorithms/equal_range/partitioned.cc: Likewise.
3423         * testsuite/25_algorithms/lexicographical_compare/71545.cc: Likewise.
3424         * testsuite/25_algorithms/lower_bound/partitioned.cc: Likewise.
3425         * testsuite/25_algorithms/upper_bound/partitioned.cc: Likewise.
3426         * testsuite/Makefile.am: Remove profile_flags variable and
3427         * testsuite/Makefile.am: Remove profile_flags variable and
3428         check-profile target.
3429         * testsuite/Makefile.in: Regenerate.
3430         * testsuite/ext/profile/all.cc: Remove.
3431         * testsuite/ext/profile/mutex_extensions_neg.cc: Remove.
3432         * testsuite/ext/profile/profiler_algos.cc: Remove.
3433         * testsuite/ext/profile/replace_new.cc: Remove.
3434         * testsuite/ext/throw_allocator/deallocate_global.cc: Remove
3435         preprocessor check for profile mode.
3436         * testsuite/ext/throw_allocator/deallocate_local.cc: Likewise.
3437         * testsuite/lib/libstdc++.exp (check_v3_target_profile_mode): Remove.
3438         (check_v3_target_normal_mode): Do not check for profile mode macro.
3439         * testsuite/libstdc++-prettyprinters/80276.cc: Remove dg-skip-if for
3440         profile mode.
3441         * testsuite/libstdc++-prettyprinters/compat.cc: Likewise.
3442         * testsuite/libstdc++-prettyprinters/cxx11.cc: Likewise.
3443         * testsuite/libstdc++-prettyprinters/cxx17.cc: Likewise.
3444         * testsuite/libstdc++-prettyprinters/debug.cc: Likewise.
3445         * testsuite/libstdc++-prettyprinters/debug_cxx11.cc: Likewise.
3446         * testsuite/libstdc++-prettyprinters/libfundts.cc: Likewise.
3447         * testsuite/libstdc++-prettyprinters/simple.cc: Likewise.
3448         * testsuite/libstdc++-prettyprinters/simple11.cc: Likewise.
3449         * testsuite/libstdc++-prettyprinters/whatis.cc: Likewise.
3450         * testsuite/libstdc++-prettyprinters/whatis2.cc: Likewise.
3451
3452         Remove array_allocator extension, deprecated since 4.9.0
3453         * doc/xml/manual/allocator.xml: Remove documentation for
3454         array_allocator.
3455         * doc/xml/manual/evolution.xml: Document array_allocator removal.
3456         * doc/xml/manual/using.xml: Remove header from documentation.
3457         * include/Makefile.am: Remove <ext/array_allocator.h> header.
3458         * include/Makefile.in: Regenerate.
3459         * include/ext/array_allocator.h: Remove.
3460         * include/precompiled/extc++.h: Do not include removed header.
3461         * testsuite/ext/array_allocator/1.cc: Remove.
3462         * testsuite/ext/array_allocator/2.cc: Remove.
3463         * testsuite/ext/array_allocator/26875.cc: Remove.
3464         * testsuite/ext/array_allocator/3.cc: Remove.
3465         * testsuite/ext/array_allocator/check_deallocate_null.cc: Remove.
3466         * testsuite/ext/array_allocator/check_delete.cc: Remove.
3467         * testsuite/ext/array_allocator/check_new.cc: Remove.
3468         * testsuite/ext/array_allocator/variadic_construct.cc: Remove.
3469         * testsuite/ext/headers.cc: Do not include removed header.
3470
3471 2019-05-11  François Dumont  <fdumont@gcc.gnu.org>
3472
3473         * include/bits/stl_bvector.h
3474         (operator==(const _Bit_iterator_base&, const _Bit_iterator_base&)):
3475         Make hidden friend.
3476         (operator<(const _Bit_iterator_base&, const _Bit_iterator_base&)):
3477         Likewise.
3478         (operator!=(const _Bit_iterator_base&, const _Bit_iterator_base&)):
3479         Likewise.
3480         (operator>(const _Bit_iterator_base&, const _Bit_iterator_base&)):
3481         Likewise.
3482         (operator<=(const _Bit_iterator_base&, const _Bit_iterator_base&)):
3483         Likewise.
3484         (operator>=(const _Bit_iterator_base&, const _Bit_iterator_base&)):
3485         Likewise.
3486         (operator-(const _Bit_iterator_base&, const _Bit_iterator_base&)):
3487         Likewise.
3488         (_Bit_iterator::operator+(difference_type)): Likewise and allow NRVO
3489         copy elision.
3490         (_Bit_iterator::operator-(difference_type)): Likewise.
3491         (operator+(ptrdiff_t, const _Bit_iterator&)): Make hidden friend.
3492         (_Bit_const_iterator::operator+(difference_type)): Likewise and allow
3493         NRVO copy elision.
3494         (_Bit_const_iterator::operator-(difference_type)): Likewise.
3495         (operator+(ptrdiff_t, const _Bit_const_iterator&)): Make hidden friend.
3496
3497 2019-05-10  Jonathan Wakely  <jwakely@redhat.com>
3498
3499         PR libstdc++/81266
3500         * testsuite/util/thread/all.h: Do not use remove_pointer for
3501         std::thread::native_handle_type.
3502
3503         PR libstdc++/90397
3504         * include/std/variant (_Variant_storage<false, Types...>::_M_storage())
3505         (_Variant_storage<true, Types...>::_M_reset()))
3506         (_Variant_storage<true, Types...>::_M_storage())): Add noexcept.
3507         (__get_storage): Likewise.
3508         (variant): Add noexcept to friend declarations for __get and
3509         __get_storage.
3510
3511         PR libstdc++/90388
3512         * include/bits/unique_ptr.h (default_delete, default_delete<T[]>):
3513         Use _Require for constraints.
3514         (operator>(nullptr_t, const unique_ptr<T,D>&)): Implement exactly as
3515         per the standard.
3516         (__uniq_ptr_hash): New base class with conditionally-disabled call
3517         operator.
3518         (hash<unique_ptr<T,D>>): Derive from __uniq_ptr_hash.
3519         * testsuite/20_util/default_delete/48631_neg.cc: Adjust dg-error line.
3520         * testsuite/20_util/unique_ptr/hash/90388.cc: New test.
3521
3522         * include/bits/shared_ptr.h: Improve docs.
3523         * include/bits/shared_ptr_base.h: Likewise.
3524         * include/bits/stl_uninitialized.h: Likewise.
3525         * include/bits/unique_ptr.h: Likewise.
3526         * libsupc++/new: Likewise.
3527
3528 2019-05-09  François Dumont  <fdumont@gcc.gnu.org>
3529
3530         * include/bits/stl_deque.h
3531         (operator==(const _Deque_iterator<>&, const _Deque_iterator<>&)):
3532         Make hidden friend.
3533         (operator!=(const _Deque_iterator<>&, const _Deque_iterator<>&)):
3534         Likewise.
3535         (operator<(const _Deque_iterator<>&, const _Deque_iterator<>&)):
3536         Likewise.
3537         (operator<=(const _Deque_iterator<>&, const _Deque_iterator<>&)):
3538         Likewise.
3539         (operator>(const _Deque_iterator<>&, const _Deque_iterator<>&)):
3540         Likewise.
3541         (operator>=(const _Deque_iterator<>&, const _Deque_iterator<>&)):
3542         Likewise.
3543         (_Deque_iterator<>::operator+(difference_type)): Likewise and allow NRVO
3544         copy elision.
3545         (_Deque_iterator<>::operator-(difference_type)): Likewise.
3546
3547 2019-05-08  François Dumont  <fdumont@gcc.gnu.org>
3548
3549         PR libstdc++/90277
3550         * testsuite/23_containers/unordered_multiset/insert/24061-multiset.cc
3551         (test01): Reserve for number of insertions to avoid rehash during test.
3552         * testsuite/23_containers/unordered_multimap/insert/24061-multimap.cc
3553         (test01): Likewise.
3554         * testsuite/23_containers/unordered_multimap/insert/24061-multimap.cc
3555         (test01): Likewise.
3556         (test02): Likewise.
3557         (test03): Likewise.
3558
3559 2019-05-08  Jonathan Wakely  <jwakely@redhat.com>
3560
3561         * include/experimental/bits/fs_path.h: Improve docs.
3562         * include/experimental/bits/net.h: Fix wrong header name in comment.
3563         Do not document implementation details.
3564         * include/experimental/netfwd: Fix doxygen grouping.
3565
3566 2019-05-07  Jonathan Wakely  <jwakely@redhat.com>
3567
3568         * include/bits/stl_pair.h: Improve docs.
3569         * include/std/tuple: Likewise.
3570
3571         * doc/doxygen/doxygroups.cc (std::literals): Add documentation for
3572         inline namespace.
3573         * include/std/chrono: Improve docs.
3574         * include/std/ratio: Do not document implementation details.
3575         * testsuite/20_util/ratio/cons/cons_overflow_neg.cc: Adjust dg-error
3576         line numbers.
3577         * testsuite/20_util/ratio/operations/ops_overflow_neg.cc: Likewise.
3578
3579         PR libstdc++/89102
3580         * doc/xml/manual/intro.xml: Document DR 2408 and 2465 changes.
3581         * include/std/chrono (__duration_common_type_wrapper): Replace with ...
3582         (__duration_common_type): New helper.
3583         (common_type<chrono::duration<R1, P2>, chrono::duration<R2, P2>>): Use
3584         __duration_common_type.
3585         (__timepoint_common_type_wrapper): Replace with ...
3586         (__timepoint_common_type): New helper.
3587         (common_type<chrono::time_point<C, D2>, chrono::time_point<C, D2>>):
3588         Use __time_point_common_type.
3589         * include/std/type_traits (common_type<>): Define, as per LWG 2408.
3590         (__common_type_impl): If either argument is transformed by decay,
3591         use the common_type of the decayed types.
3592         (__common_type_impl<_Tp, _Up, _Tp, _Up>): If the types are already
3593         decayed, use __do_common_type_impl to get the common_type.
3594         (common_type<_Tp>): Use common_type<_Tp, _Tp>.
3595         (__do_member_type_wrapper, __member_type_wrapper)
3596         (__expanded_common_type_wrapper): Remove.
3597         (__common_type_pack, __common_type_fold): New helpers.
3598         (common_type<_Tp, _Up, _Vp...>): Use new helpers instead of
3599         __member_type_wrapper and __expanded_common_type_wrapper.
3600         * testsuite/20_util/common_type/requirements/explicit_instantiation.cc:
3601         Test zero-length template argument list.
3602         * testsuite/20_util/common_type/requirements/sfinae_friendly_1.cc:
3603         Test single argument cases and argument types that should decay.
3604         * testsuite/20_util/common_type/requirements/sfinae_friendly_2.cc:
3605         Adjust expected error.
3606         * testsuite/20_util/duration/literals/range_neg.cc: Use zero for
3607         dg-error lineno.
3608         * testsuite/20_util/duration/requirements/typedefs_neg1.cc: Likewise.
3609         * testsuite/20_util/duration/requirements/typedefs_neg2.cc: Likewise.
3610         * testsuite/20_util/duration/requirements/typedefs_neg3.cc: Likewise.
3611
3612         * doc/xml/manual/intro.xml: Fix DR 2537 and DR 2566 confusion.
3613
3614 2019-05-01  Nina Dinka Ranns  <dinka.ranns@gmail.com>
3615
3616         Make allocator propagation more consistent for
3617         operator+(basic_string) (P1165R1)
3618         * include/bits/basic_string.h
3619         (operator+(basic_string&&, basic_string&&): Changed resulting
3620         allocator to always be the one from the first parameter.
3621         * include/bits/basic_string.tcc
3622         (operator+(const _CharT*, const basic_string&)): Changed
3623         resulting allocator to be SOCCC on the second parameter's allocator.
3624         (operator+(_CharT, const basic_string&)): Likewise.
3625         * testsuite/21_strings/basic_string/allocator/char/operator_plus.cc:
3626         New.
3627         * testsuite/21_strings/basic_string/allocator/wchar_t/operator_plus.cc:
3628         New.
3629
3630 2019-05-07  Jonathan Wakely  <jwakely@redhat.com>
3631
3632         * include/bits/regex.h: Improve docs.
3633         * include/bits/regex.tcc: Do not document implementation details.
3634
3635         * testsuite/19_diagnostics/error_code/hash.cc: New test.
3636
3637 2019-05-06  François Dumont  <fdumont@gcc.gnu.org>
3638
3639         * python/libstdcxx/v6/printers.py (add_one_template_type_printer):
3640         Add type printer for container types in std::__debug namespace.
3641         * testsuite/lib/gdb-test.exp (whatis-regexp-test): New.
3642         (gdb-tests): Use distinct parameters for the type of test and use of
3643         regex.
3644         (gdb-test): Check for regex test even if 'whatis' test.
3645         * testsuite/libstdc++-prettyprinters/80276.cc: Adapt for _GLIBCXX_DEBUG
3646         mode.
3647         * testsuite/libstdc++-prettyprinters/cxx11.cc: Likewise.
3648         * testsuite/libstdc++-prettyprinters/cxx17.cc: Likewise.
3649         * testsuite/libstdc++-prettyprinters/libfundts.cc: Likewise.
3650         * testsuite/libstdc++-prettyprinters/simple.cc: Likewise.
3651         * testsuite/libstdc++-prettyprinters/simple11.cc: Likewise.
3652         * testsuite/libstdc++-prettyprinters/whatis.cc: Likewise.
3653         * testsuite/libstdc++-prettyprinters/whatis2.cc: Likewise.
3654
3655 2019-05-04  Jonathan Wakely  <jwakely@redhat.com>
3656
3657         * include/std/system_error (error_category): Fix comment.
3658
3659         PR libstdc++/90299
3660         * src/c++17/fs_ops.cc (absolute(const path&)): Report an error if the
3661         argument is an empty path.
3662         (absolute(const path&, error_code&)): Use invalid_argument as error
3663         code instead of no_such_file_or_directory.
3664         * testsuite/27_io/filesystem/operations/absolute.cc: Check handling
3665         of non-existent paths and empty paths with both overloads of absolute.
3666
3667         * include/std/system_error (error_category, error_code)
3668         (error_condition): Improve docs.
3669         * libsupc++/exception: Add missing @addtogroup Doxygen command.
3670         * libsupc++/exception_ptr.h (exception_ptr): Link equality operators
3671         to class documentation. Suppress documentation for implementation
3672         details.
3673         * libsupc++/nested_exception.h (throw_with_nested, rethrow_if_nested):
3674         Suppress documentation for implementation details.
3675
3676         * include/std/system_error (error_code): Remove friend declaration
3677         for hash<error_code>.
3678         (hash<error_code>::operator()): Use public member functions to access
3679         value and category.
3680         (hash<error_condition>::operator()): Use address of category, not
3681         its object representation.
3682         * src/c++11/compatibility-c++0x.cc (hash<error_code>::operator()):
3683         Use public member functions to access value and category.
3684         * testsuite/19_diagnostics/error_condition/hash.cc: New test.
3685
3686 2019-05-04  François Dumont  <fdumont@gcc.gnu.org>
3687
3688         * include/bits/hashtable.h (_Hashtable<>::rehash): Review comment.
3689         * include/bits/hashtable_policy.h
3690         (_Prime_rehash_policy::_M_bkt_for_elements): Use __builtin_ceill.
3691         (_Power2_rehash_policy::_M_bkt_for_elements): Likewise.
3692         (_Power2_rehash_policy::_M_next_bkt): Enforce returning a result not
3693         smaller than input value rather than always greater. Preserve
3694         _M_next_resize if called with 0 input. Use __builtin_floorl.
3695         (_Power2_rehash_policy::_M_need_rehash): Rehash only if number of
3696         elements + number of insertions is greater than _M_next_resize. Start
3697         with 11 buckets if not told otherwise. Use __builtin_floorl.
3698         (_Rehash_base<>::reserve): Use rehash policy _M_bkt_for_elements.
3699         * src/c++11/hashtable_c++0x.cc (_Prime_rehash_policy::_M_next_bkt):
3700         Preserve _M_next_resize if called with 0 input. Use __builtin_floorl.
3701         (_Prime_rehash_policy::_M_need_rehash): Start with 11 buckets if not
3702         told otherwise. Use __builtin_floorl.
3703         * testsuite/23_containers/unordered_set/hash_policy/71181.cc: Adapt test
3704         to also validate _Power2_rehash_policy.
3705         * testsuite/23_containers/unordered_set/hash_policy/power2_rehash.cc:
3706         Adapt.
3707
3708 2019-05-03  Jonathan Wakely  <jwakely@redhat.com>
3709
3710         PR libstdc++/61761
3711         * testsuite/26_numerics/complex/proj.cc: Don't assume <cmath> defines
3712         std::copysign.
3713
3714         PR libstdc++/52119
3715         * include/ext/numeric_traits.h (__glibcxx_min): Avoid integer
3716         overflow warning with -Wpedantic -Wsystem-headers.
3717
3718 2019-05-02  Jonathan Wakely  <jwakely@redhat.com>
3719
3720         PR libstdc++/90314
3721         * include/bits/c++config (_GLIBCXX_NOEXCEPT_IF): Use variadic macro.
3722         * include/bits/move.h (swap): Remove extra parentheses.
3723
3724         * include/experimental/bits/lfts_config.h: Improve doc markup.
3725         * include/experimental/optional: Improve docs.
3726         (_Has_addressof_mem, _Has_addressof_free, _Has_addressof)
3727         (__constexpr_addressof): Remove.
3728         (optional::operator->()): Use std::__addressof().
3729         * include/std/optional (optional::operator->()): Adjust whitespace.
3730         * testsuite/experimental/optional/constexpr/observers/2.cc: Check
3731         that operator-> is still constexpr with overloaded operator&. Change
3732         to compile-only test.
3733         * testsuite/experimental/optional/constexpr/observers/3.cc: Change to
3734         compile-only test.
3735
3736         * include/bits/shared_ptr.h: Improve docs.
3737         * include/bits/shared_ptr_atomic.h: Likewise.
3738         * include/bits/unique_ptr.h: Likewise. Adjust whitespace.
3739
3740         * include/bits/basic_string.h: Fix iterator/index confusion in
3741         Doxygen comments.
3742         * include/bits/range_access.h: Fix Doxygen warnings.
3743         * include/bits/refwrap.h: Do not document implementation details.
3744         (ref, cref): Group docs with reference_wrapper.
3745         * include/std/fstream: Fix Doxygen markup.
3746         * libsupc++/initializer_list (begin, end): Group docs with
3747         initializer_list.
3748
3749         * doc/doxygen/user.cfg.in: Set MARKDOWN_SUPPORT=YES.
3750
3751         * include/bits/unique_lock.h: Fix/improve doxygen markup.
3752         * include/std/mutex: Likewise.
3753         * include/std/shared_mutex: Likewise.
3754
3755         * include/bits/fs_dir.h: Fix/improve doxygen markup.
3756         * include/bits/fs_fwd.h: Likewise.
3757         * include/bits/fs_ops.h: Likewise.
3758         * include/bits/fs_path.h: Likewise.
3759         * include/std/filesystem: Likewise.
3760
3761         * include/experimental/bits/net.h: Fix/improve doxygen markup.
3762         * include/experimental/buffer: Likewise.
3763         * include/experimental/executor: Likewise.
3764         * include/experimental/internet: Likewise.
3765         * include/experimental/io_context: Likewise.
3766         * include/experimental/net: Likewise.
3767         * include/experimental/netfwd: Likewise.
3768         * include/experimental/socket: Likewise.
3769         * include/experimental/timer: Likewise.
3770
3771         * doc/doxygen/doxygroups.cc: Move description of experimental group
3772         here.
3773         * include/experimental/algorithm: Add to libfund-ts doc group.
3774         * include/experimental/any: Likewise. Do not document implementation
3775         details.
3776         * include/experimental/array: Add to libfund-ts doc group.
3777         * include/experimental/bits/lfts_config.h: Define libfund-ts doc group
3778         for Library Fundamentals.
3779         * include/experimental/chrono: Add to libfund-ts doc group.
3780         * include/experimental/deque: Likewise.
3781         * include/experimental/forward_list: Likewise.
3782         * include/experimental/functional: Likewise.
3783         * include/experimental/iterator: Likewise.
3784         * include/experimental/list: Likewise.
3785         * include/experimental/map: Likewise.
3786         * include/experimental/memory: Likewise.
3787         * include/experimental/memory_resource: Likewise. Improve docs.
3788         details.
3789         * include/experimental/numeric: Add to libfund-ts doc group.
3790         * include/experimental/optional: Likewise.
3791         * include/experimental/propagate_const: Likewise.
3792         * include/experimental/random: Likewise.
3793         * include/experimental/ratio: Likewise.
3794         * include/experimental/regex: Likewise.
3795         * include/experimental/set: Likewise.
3796         * include/experimental/source_location: Likewise.
3797         * include/experimental/string: Likewise.
3798         * include/experimental/string_view: Likewise.
3799         * include/experimental/system_error: Likewise.
3800         * include/experimental/tuple: Likewise.
3801         * include/experimental/type_traits: Likewise.
3802         * include/experimental/unordered_map: Likewise.
3803         * include/experimental/unordered_set: Likewise.
3804         * include/experimental/utility: Likewise.
3805         * include/experimental/vector: Likewise.
3806         * testsuite/experimental/any/misc/any_cast_neg.cc: Adjust dg-error.
3807         * testsuite/experimental/array/neg.cc: Adjust dg-error.
3808         * testsuite/experimental/propagate_const/assignment/move_neg.cc:
3809         Likewise.
3810         * testsuite/experimental/propagate_const/cons/move_neg.cc: Likewise.
3811         * testsuite/experimental/propagate_const/requirements2.cc: Likewise.
3812         * testsuite/experimental/propagate_const/requirements3.cc: Likewise.
3813         * testsuite/experimental/propagate_const/requirements4.cc: Likewise.
3814         * testsuite/experimental/propagate_const/requirements5.cc: Likewise.
3815
3816         * include/experimental/bits/fs_dir.h: Fix Doxygen markup.
3817         * include/experimental/bits/fs_fwd.h: Improve docs.
3818         * include/experimental/bits/fs_ops.h: fix Doxygen markup.
3819         * include/experimental/bits/fs_path.h: Likewise.
3820         (path, filesystem_error, u8path): Improve docs.
3821         * include/experimental/filesystem: Link to docs for TS.
3822
3823         * config/allocator/new_allocator_base.h (__allocator_base): Add
3824         workaround for Doxygen bug #6945.
3825         * include/std/memory: Improve docs. Define group for pointer safety.
3826         * include/std/scoped_allocator: Improve docs. Use "undocumented"
3827         conditional to suppress documentation for implementation details.
3828
3829         * include/bits/specfun.h: Improve docs.
3830         * include/tr1/cmath: Likewise. Fix nesting of preprocessor conditions
3831         and namespaces.
3832
3833         * doc/doxygen/doxygroups.cc (std::tr2, std::__gnu_cxx): Improve docs.
3834         (std::experimental): Add docs.
3835         * doc/doxygen/user.cfg.in (PREDEFINED): Expand macros for __cxx11
3836         namespace to nothing when generating docs.
3837         * include/bits/regex_constants.h (std::regex_constants): Improve docs.
3838         * include/std/chrono (std::chrono): Likewise.
3839         * include/std/functional (std::placeholders): Likewise.
3840         * include/std/thread (std::this_thread): Likewise.
3841
3842         * include/parallel/settings.h: Fix Doxygen markup.
3843
3844         * include/ext/pb_ds/detail/bin_search_tree_/*_imps.hpp: Do not define
3845         anything unless PB_DS_CLASS_C_DEC is defined.
3846         * include/ext/pb_ds/detail/binary_heap_/*_imps.hpp: Likewise.
3847         * include/ext/pb_ds/detail/binomial_heap_/*_imps.hpp: Likewise.
3848         * include/ext/pb_ds/detail/binomial_heap_base_/*_imps.hpp: Likewise.
3849         * include/ext/pb_ds/detail/cc_hash_table_map_/*_imps.hpp: Likewise.
3850         * include/ext/pb_ds/detail/gp_hash_table_map_/*_imps.hpp: Likewise.
3851         * include/ext/pb_ds/detail/hash_fn/*_imp.hpp: Likewise.
3852         * include/ext/pb_ds/detail/left_child_next_sibling_heap_/*_imps.hpp:
3853         Likewise.
3854         * include/ext/pb_ds/detail/list_update_map_/*_imps.hpp: Likewise.
3855         * include/ext/pb_ds/detail/ov_tree_map_/*_imps.hpp: Likewise.
3856         * include/ext/pb_ds/detail/pairing_heap_/*_imps.hpp: Likewise.
3857         * include/ext/pb_ds/detail/pat_trie_/*_imps.hpp: Likewise.
3858         * include/ext/pb_ds/detail/rb_tree_map_/*_imps.hpp: Likewise.
3859         * include/ext/pb_ds/detail/rc_binomial_heap_/*_imps.hpp: Likewise.
3860         * include/ext/pb_ds/detail/resize_policy*_imp.hpp: Likewise.
3861         * include/ext/pb_ds/detail/splay_tree_/*_imps.hpp: Likewise.
3862         * include/ext/pb_ds/detail/thin_heap_/*_imps.hpp: Likewise.
3863         * include/ext/pb_ds/detail/trie_policy*_imp.hpp: Likewise.
3864         * include/ext/pb_ds/detail/unordered_iterator/const_iterator.hpp:
3865         Likewise.
3866         * include/ext/pb_ds/detail/unordered_iterator/iterator.hpp: Likewise.
3867         * include/ext/pb_ds/detail/unordered_iterator/point_const_iterator.hpp:
3868         Likewise.
3869         * include/ext/pb_ds/detail/unordered_iterator/point_iterator.hpp:
3870         Likewise.
3871
3872         * doc/doxygen/user.cfg.in: Regenerate with Doxygen 1.8.14 and set
3873         GROUP_NESTED_COMPOUNDS=YES and SORT_BY_SCOPE_NAME=NO. Add various
3874         _GLIBCXX_xxx macros and __attribute__(X) to PREDEFINED macros that
3875         Doxygen expands.
3876
3877 2019-05-01  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
3878
3879         * config/abi/post/i386-solaris2.10/baseline_symbols.txt: Regenerate.
3880         * config/abi/post/i386-solaris2.10/amd64/baseline_symbols.txt: Likewise.
3881         * config/abi/post/i386-solaris2.11/baseline_symbols.txt: Likewise.
3882         * config/abi/post/i386-solaris2.11/amd64/baseline_symbols.txt: Likewise.
3883         * config/abi/post/sparc-solaris2.10/baseline_symbols.txt: Likewise.
3884         * config/abi/post/sparc-solaris2.10/sparcv9/baseline_symbols.txt:
3885         Likewise.
3886         * config/abi/post/sparc-solaris2.11/baseline_symbols.txt: Likewise.
3887         * config/abi/post/sparc-solaris2.11/sparcv9/baseline_symbols.txt:
3888         Likewise.
3889
3890 2019-05-01  Jonathan Wakely  <jwakely@redhat.com>
3891
3892         PR libstdc++/61761
3893         * include/std/complex (__complex_proj): Return parameter unchanged.
3894         [_GLIBCXX_USE_C99_COMPLEX] (__complex_proj): Change overloads for
3895         floating-point types to take std::complex arguments.
3896         [_GLIBCXX_USE_C99_MATH_TR1] (__complex_proj): Add overloads for
3897         floating-point types.
3898         * testsuite/26_numerics/complex/proj.cc: New test.
3899
3900 2019-04-30  Jakub Jelinek  <jakub@redhat.com>
3901
3902         * config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Change _Lock_policyE2 exports
3903         to _Lock_policyE[012].
3904         * config/abi/post/riscv64-linux-gnu/baseline_symbols.txt: Update.
3905
3906 2019-04-30  Jonathan Wakely  <jwakely@redhat.com>
3907
3908         * testsuite/27_io/filesystem/path/decompose/root_path.cc: Remove
3909         macros accidentally left in.
3910         * testsuite/27_io/filesystem/path/native/string-char8_t.cc: Remove
3911         unnecessary -lstdc++fs option. Fix test for mingw.
3912         * testsuite/experimental/filesystem/path/native/string-char8_t.cc:
3913         Fix test for mingw.
3914
3915 2019-04-30  Jakub Jelinek  <jakub@redhat.com>
3916
3917         * config/abi/post/riscv64-linux-gnu/baseline_symbols.txt: Update.
3918
3919 2019-04-29  Jonathan Wakely  <jwakely@redhat.com>
3920
3921         * include/bits/stl_algo.h (generate_n): Adjust doxygen comment.
3922
3923         * include/bits/move.h (swap(T&, T&), swap(T (&)[N], T (&)[N])): Use
3924         _GLIBCXX_NOEXCEPT_IF to simplify declarations.
3925
3926         PR libstdc++/71312
3927         * src/c++11/shared_ptr.cc (get_mutex): Align pool mutexes to 64 bytes.
3928
3929         * include/bits/stl_bvector.h (vector<bool>::empty()): Add nodiscard
3930         attribute.
3931
3932         * include/bits/stl_iterator_base_types.h (_Iter_base): Remove unused
3933         class template and partial specialization.
3934
3935         PR libstdc++/87982
3936         * include/bits/stl_algo.h (generate_n): Convert _Size parameter to
3937         an integral type.
3938         * include/bits/stl_algobase.h (__size_to_integer): New overloaded
3939         functions to convert a value to an integral type.
3940         (__fill_n_a, __fill_n_a): Assert that __n is already an integral type.
3941         (fill_n): Convert _Size parameter to an integral type.
3942         * testsuite/25_algorithms/fill_n/87982.cc: New test.
3943         * testsuite/25_algorithms/fill_n/87982_neg.cc: New test.
3944         * testsuite/25_algorithms/fill_n/dr426.cc: New test.
3945         * testsuite/25_algorithms/generate_n/87982.cc: New test.
3946         * testsuite/25_algorithms/generate_n/87982_neg.cc: New test.
3947         * testsuite/25_algorithms/generate_n/dr426.cc: New test.
3948
3949 2019-04-28  Nina Dinka Ranns  <dinka.ranns@gmail.com>
3950
3951         Adding noexcept-specification on tuple constructors (LWG 2899)
3952         * libstdc++-v3/include/std/tuple:
3953         (tuple()): Add noexcept-specification.
3954         (tuple(const _Elements&...)): Likewise
3955         (tuple(_UElements&&...)): Likewise
3956         (tuple(const tuple<_UElements...>&)): Likewise
3957         (tuple(tuple<_UElements...>&&)): Likewise
3958         (tuple(const _T1&, const _T2&)): Likewise
3959         (tuple(_U1&&, _U2&&)): Likewise
3960         (tuple(const tuple<_U1, _U2>&): Likewise
3961         (tuple(tuple<_U1, _U2>&&): Likewise
3962         (tuple(const pair<_U1, _U2>&): Likewise
3963         (tuple(pair<_U1, _U2>&&): Likewise
3964         * libstdc++-v3/testsuite/20_util/tuple/cons/noexcept_specs.cc: New
3965
3966 2019-04-27  Marc Glisse  <marc.glisse@inria.fr>
3967
3968         PR libstdc++/87106
3969         * include/bits/stl_uninitialized.h (__relocate_object_a): Mark the
3970         arguments with __restrict.
3971
3972 2019-04-26  H.J. Lu  <hongjiu.lu@intel.com>
3973
3974         * config/abi/post/x86_64-linux-gnu/x32/baseline_symbols.txt: Updated.
3975
3976 2019-04-26  Jonathan Wakely  <jwakely@redhat.com>
3977
3978         * include/experimental/bits/fs_path.h
3979         (path::_S_convert_loc<_InputIterator>): Create const std::string to
3980         avoid redundant call to _S_convert_loc with non-const pointers.
3981
3982         * testsuite/20_util/variant/run.cc: Use a new Hashable type to test
3983         hashing, because pmr::string depends on _GLIBCXX_USE_CXX11_ABI==1.
3984         * testsuite/21_strings/basic_string/hash/hash.cc
3985         [!_GLIBCXX_USE_CXX11_ABI]: Don't test pmr strings.
3986         * testsuite/21_strings/basic_string/hash/hash_char8_t.cc
3987         [!_GLIBCXX_USE_CXX11_ABI]: Likewise.
3988
3989         * config/abi/pre/gnu.ver (GLIBCXX_3.4): Replace wildcard that matches
3990         wstring::_M_replace_dispatch with more specific patterns.
3991         * include/bits/fs_path.h (path::_S_convert_loc<_InputIterator>):
3992         Create const std::string to avoid redundant call to _S_convert_loc
3993         with non-const pointers.
3994         * include/bits/locale_conv.h (__do_str_codecvt): Use if-constexpr to
3995         avoid unnecessary basic_string::assign instantiations.
3996
3997         * include/std/memory (__uses_alloc_args): Add string-literal to
3998         static_assert, to match the one in __uses_alloc.
3999         [__cpp_concepts] (_Std_pair): Use C++2a syntax for concept.
4000         * testsuite/20_util/polymorphic_allocator/construct_c++2a.cc: Check
4001         for recursive uses-allocator construction of nested pairs.
4002         * testsuite/20_util/scoped_allocator/construct_pair_c++2a.cc:: Add
4003         comment.
4004
4005 2019-04-26  Jakub Jelinek  <jakub@redhat.com>
4006
4007         * config/abi/post/s390x-linux-gnu/32/baseline_symbols.txt: Update.
4008         * config/abi/post/s390-linux-gnu/baseline_symbols.txt: Update.
4009         * config/abi/post/powerpc-linux-gnu/baseline_symbols.txt: Update.
4010         * config/abi/post/powerpc64-linux-gnu/32/baseline_symbols.txt: Update.
4011
4012         * config/abi/post/x86_64-linux-gnu/baseline_symbols.txt: Update.
4013         * config/abi/post/x86_64-linux-gnu/32/baseline_symbols.txt: Update.
4014         * config/abi/post/i386-linux-gnu/baseline_symbols.txt: Update.
4015         * config/abi/post/i486-linux-gnu/baseline_symbols.txt: Update.
4016         * config/abi/post/aarch64-linux-gnu/baseline_symbols.txt: Update.
4017         * config/abi/post/s390x-linux-gnu/baseline_symbols.txt: Update.
4018         * config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt: Update.
4019
4020 2019-04-25  Jonathan Wakely  <jwakely@redhat.com>
4021
4022         PR libstdc++/90239
4023         * doc/xml/manual/status_cxx2020.xml: Amend P0591R4 status.
4024         * include/std/scoped_allocator [__cplusplus > 201703L]
4025         (scoped_allocator_adaptor::construct): Define in terms of
4026         uses_allocator_construction_args, as per P0591R4.
4027         * testsuite/20_util/scoped_allocator/construct_pair_c++2a.cc: New test.
4028         * testsuite/util/testsuite_allocator.h: Remove name of unused
4029         parameter.
4030
4031 2019-04-24  Jonathan Wakely  <jwakely@redhat.com>
4032
4033         * doc/xml/manual/status_cxx2017.xml: Document P0024R2 status.
4034         * doc/html/*: Regenerate.
4035
4036         * include/bits/fs_path.h (operator<, operator<=, operator>)
4037         (operator>=, operator==, operator!=): Make hidden friends, as per
4038         LWG 3065.
4039         * testsuite/27_io/filesystem/path/native/string-char8_t.cc: Fix
4040         string type in test.
4041         * testsuite/27_io/filesystem/path/native/string.cc: Likewise.
4042
4043         * include/std/any (any::any(ValueType&&)): Use __and_v.
4044         * include/std/numeric (midpoint(T, T, T), midpoint(T*, T*, T*)):
4045         Likewise.
4046
4047         * include/std/tuple (apply): Use remove_reference_t instead of decay_t
4048         as per P0777R1.
4049         * include/std/type_traits (__result_of_memfun): Use remove_reference
4050         instead of __remove_cvref_t and remove redundant is_same check.
4051         (__inv_unwrap): Use __remove_cvref_t instead of decay_t.
4052
4053         * include/experimental/string_view (basic_string_view::pointer)
4054         (basic_string_view::reference): Fix to refer to non-const value_type.
4055         * include/bits/basic_string.h (basic_string): Use __sv_check and
4056         __sv_limit instead of basic_string_view::_M_check and
4057         basic_string_view::_M_limit.
4058         * include/std/string_view (__sv_check, __sv_limit): New
4059         helper functions to replace basic_string_view::_M_check and
4060         basic_string_view::_M_limit.
4061         (basic_string_view): Add static assertions to enforce ill-formed
4062         requirement for traits_type::char_type from P1148R0, and to enforce
4063         required properties of char-like types.
4064         (basic_string_view::pointer, basic_string_view::reference): Fix to
4065         refer to non-const value_type.
4066         (basic_string_view::operator[], basic_string_view::at)
4067         (basic_string_view::front, basic_string_view::back)
4068         (basic_string_view::data): Use const_reference and const_pointer
4069         typedefs for return types.
4070         (basic_string_view::_M_check, basic_string_view::_M_limit): Remove.
4071         (hash<wstring_view>): Fix argument_type typedef.
4072         * testsuite/21_strings/basic_string_view/modifiers/remove_prefix/
4073         char/1.cc: Fix expected return type of basic_string_view::data().
4074         * testsuite/21_strings/basic_string_view/modifiers/remove_prefix/
4075         wchar_t/1.cc: Likewise.
4076         * testsuite/21_strings/basic_string_view/modifiers/remove_suffix/
4077         char/1.cc: Likewise.
4078         * testsuite/21_strings/basic_string_view/modifiers/remove_suffix/
4079         wchar_t/1.cc: Likewise.
4080         * testsuite/21_strings/basic_string_view/requirements/traits_neg.cc:
4081         New test.
4082         * testsuite/21_strings/basic_string_view/requirements/typedefs.cc:
4083         Check reference and pointer typedefs.
4084         * testsuite/experimental/string_view/requirements/typedefs.cc:
4085         Likewise.
4086         * testsuite/experimental/string_view/modifiers/remove_prefix/char/1.cc:
4087         Fix expected return type of basic_string_view::data().
4088         * testsuite/experimental/string_view/modifiers/remove_prefix/wchar_t/
4089         1.cc: Likewise.
4090         * testsuite/experimental/string_view/modifiers/remove_suffix/char/1.cc:
4091         Likewise.
4092         * testsuite/experimental/string_view/modifiers/remove_suffix/wchar_t/
4093         1.cc: Likewise.
4094
4095         PR libstdc++/90220
4096         * include/std/any (__any_caster): Use remove_cv_t instead of decay_t.
4097         Avoid a runtime check for types that can never be stored in std::any.
4098         * testsuite/20_util/any/misc/any_cast.cc: Test std::any_cast with
4099         array types.
4100
4101         PR libstdc++/90220 (partial)
4102         * include/std/any (any_cast<T>(any*), any_cast<T>(const any*)): Do
4103         not attempt ill-formed static_cast to pointers to non-object types.
4104         * testsuite/20_util/any/misc/any_cast.cc: Test std::any_cast with
4105         function types.
4106
4107         * testsuite/20_util/variant/run.cc: Catch exception by reference to
4108         prevent -Wcatch-value warning.
4109
4110         * include/std/variant (__variant_construct): Use template parameter
4111         type instead of equivalent decltype-specifier.
4112         (_Move_ctor_base<false, Types...>::_Move_ctor_base(_Move_ctor_base&&)):
4113         Replace forward with move.
4114         (_Move_ctor_base<false, Types...>::_M_destructive_move)
4115         (_Move_ctor_base<false, Types...>::_M_destructive_copy)
4116         (_Move_ctor_base<true, Types...>::_M_destructive_move)
4117         (_Move_ctor_base<true, Types...>::_M_destructive_copy): Only set the
4118         index after construction succeeds.
4119         (_Copy_assign_base<false, Types...>::operator=): Remove redundant
4120         if-constexpr checks that are always true. Use __remove_cvref_t instead
4121         of remove_reference so that is_nothrow_move_constructible check
4122         doesn't use a const rvalue parameter. In the potentially-throwing case
4123         construct a temporary and move assign it, as per LWG 2904.
4124         (_Move_assign_base<false, Types...>::operator=): Remove redundant
4125         if-constexpr checks that are always true. Use emplace as per LWG 2904.
4126         (variant::operator=(T&&)): Only use emplace conditionally, otherwise
4127         construct a temporary and move assign from it, as per LWG 2904.
4128         * testsuite/20_util/variant/exception_safety.cc: Check that
4129         assignment operators have strong exception safety guarantee.
4130
4131 2019-04-23  Thomas Rodgers <trodgers@redhat.com>
4132
4133         Document PSTL linker flags
4134
4135         * doc/xml/manual/using.xml: Add PSTL linker flags to table 3.1.
4136         
4137 2019-04-23  Jonathan Wakely  <jwakely@redhat.com>
4138
4139         * include/std/variant (__detail::__variant::_Traits): Make
4140         _S_trivial_copy_assign depend on _S_trivial_copy_ctor and make
4141         _S_trivial_move_assign depend on _S_trivial_move_ctor, as per
4142         P0602R4.
4143         (__detail::__variant::_Copy_assign_alias): Only depend on
4144         _S_trivial_copy_assign, which subsumes _S_trivial_copy_ctor now.
4145         * testsuite/20_util/variant/compile.cc: Correct checks for trivial
4146         move assignment operators.
4147
4148         PR libstdc++/90165
4149         * include/std/variant (variant::__not_self): New helper for the
4150         is_same_v<remove_cvref_t<T>, variant>==false constraints.
4151         (variant::__to_type_impl): Remove.
4152         (variant::__to_type): Add default argument to check pack size, instead
4153         of using __to_type_impl.
4154         (variant::__accepted_type): Add default argument using __not_self.
4155         (variant::__is_in_place_tag, variant::__not_in_place_tag): New helpers
4156         for variant(T&&) constructor constraint.
4157         (variant::variant(T&&)): Use __not_in_place_tag in constraints.
4158         Extract __accepted_type into a named template parameter for reuse in
4159         other constraints and in the exception specification.
4160         (variant::variant(in_place_type_t<T>, Args&&...))
4161         (variant::variant(in_place_type_t<T>, initializer_list<U>, Args&&...))
4162         (variant::variant(in_place_index_t<T>, Args&&...))
4163         (variant::variant(in_place_index_t<T>, initializer_list<U>, Args&&...))
4164         (variant::operator=T&&)): Remove redundant && from trait arguments.
4165         * testsuite/20_util/variant/compile.cc: Check variant(T&&) constructor
4166         isn't used for in_place_type or in_place_index arguments.
4167
4168         * include/std/type_traits (unwrap_reference_t): Define for C++2a.
4169         (unwrap_ref_decay): Remove inheritance from unwrap_reference.
4170         * testsuite/20_util/unwrap_reference/1.cc: Adjust test to use alias.
4171
4172 2019-04-23  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
4173             Bernd Edlinger  <bernd.edlinger@hotmail.de>
4174             Jakub Jelinek  <jakub@redhat.com>
4175
4176         PR target/89093
4177         * libsupc++/eh_personality.cc (PERSONALITY_FUNCTION): Add
4178         general-regs-only target attribute for ARM.
4179
4180 2019-04-23  Jonathan Wakely  <jwakely@redhat.com>
4181
4182         PR libstdc++/87431
4183         * include/bits/basic_string.h (_Never_valueless_alt): Make partial
4184         specialization also depend on is_nothrow_move_constructible.
4185         * include/std/variant (__detail::__variant::__never_valueless()):
4186         Only true if the variant would have a move assignment operator.
4187         (__detail::__variant::_Variant_storage<false, T...>::_M_valid()):
4188         Check __never_valueless<T...>().
4189         (variant::emplace): Only perform non-throwing move assignments
4190         for never-valueless alternatives if the variant has a move assignment
4191         operator.
4192         * testsuite/20_util/variant/compile.cc: Check that never-valueless
4193         types can be emplaced into non-assignable variants.
4194         * testsuite/20_util/variant/run.cc: Check that never-valueless types
4195         don't get copied when emplaced into non-assignable variants.
4196
4197         * include/std/variant (__detail::__variant::__ref_cast): Remove
4198         unused function.
4199         (__detail::__variant::_Uninitialized::_M_get)
4200         (__detail::__variant::__get)
4201         (__gen_vtable_impl::__element_by_index_or_cookie): Add noexcept.
4202
4203 2019-04-21  Iain Sandoe  <iain@sandoe.co.uk>
4204
4205         * testsuite/17_intro/headers/c++1998/charset.cc: Skip for Darwin8
4206         to Darwin10.
4207         * testsuite/17_intro/headers/c++2011/charset.cc: Likewise.
4208         * testsuite/17_intro/headers/c++2014/charset.cc: Likewise.
4209         * testsuite/17_intro/headers/c++2017/charset.cc: Likewise.
4210         * testsuite/17_intro/headers/c++2020/charset.cc: Likewise.
4211
4212 2019-04-20  Thomas Rodgers <trodgers@redhat.com>
4213
4214         Delegate PSTL configuration to pstl/pstl_config.h
4215
4216         * include/bits/c++config: Remove explicit PSTL configuration
4217         macros and use definitions from <pstl/pstl_config.h>.
4218         
4219 2019-04-20  Thomas Rodgers <trodgers@redhat.com>
4220
4221         Cleanup algorithm implementations
4222         * include/pstl/glue_algorithm_impl.h (stable_sort): Forward
4223         execution policy.
4224         (mismatch): Forward execution policy.
4225         (equal): Qualify call to std::equal().
4226         (partial_sort): Forward execution policy.
4227         (inplace_merge): Forward execution policy.
4228         
4229 2019-04-19  Thomas Rodgers <trodgers@redhat.com>
4230         
4231         Improve implementation of parallel equal()
4232         * include/pstl/algorithm_impl.h
4233         (__internal::__brick_equal): use "4 iterator" version of
4234         std::equal().
4235         (__internal::__brick_equal): use simd for random access
4236         iterators on unsequenced execution policies.
4237         (__internal::__pattern_equal): add "4 iterator" version
4238         (__internal::__pattern_equal): dispatch to simd __brick_equal
4239         for vector-only execution policies.
4240         (__internal::__pattern_equal): dispatch to __parallel_or for
4241         parallel execution policies.
4242         * include/pstl/glue_algorithm_impl.h
4243         (std::equal): dispatch to "4 iterator" version of
4244         __internal::__pattern_equal().
4245         
4246 2019-04-17  Jonathan Wakely  <jwakely@redhat.com>
4247
4248         PR libstdc++/90105
4249         * include/bits/forward_list.h (operator==): Do not use operator!= to
4250         compare elements.
4251         (forward_list<T, A>::sort(Comp)): When elements are equal take the one
4252         earlier in the list, so that sort is stable.
4253         * testsuite/23_containers/forward_list/operations/90105.cc: New test.
4254         * testsuite/23_containers/forward_list/comparable.cc: Test with
4255         types that meet the minimum EqualityComparable and LessThanComparable
4256         requirements. Remove irrelevant comment.
4257
4258         * include/std/variant (__detail::__variant::_Traits::_S_copy_assign):
4259         Do not depend on whether all alternative types are move constructible.
4260         (__detail::__variant::_Copy_assign_base::operator=): Remove cv-quals
4261         from the operand when deciding whether to perform the assignment.
4262         * testsuite/20_util/variant/compile.cc (DeletedMoves): Define type
4263         with deleted move constructor and deleted move assignment operator.
4264         (default_ctor, copy_ctor, move_ctor, copy_assign, move_assign): Check
4265         behaviour of variants with DeletedMoves as an alternative.
4266         * testsuite/20_util/variant/run.cc (DeletedMoves): Define same type.
4267         (move_ctor, move_assign): Check that moving a variant with a
4268         DeletedMoves alternative falls back to copying instead of moving.
4269
4270         * testsuite/20_util/variant/compile.cc: Remove empty string literals
4271         from static_assert declarations.
4272
4273         * testsuite/20_util/variant/compile.cc (MoveCtorOnly): Fix type to
4274         actually match its name.
4275         (MoveCtorAndSwapOnly): Define new type that adds swap to MoveCtorOnly.
4276         (test_swap()): Fix result for MoveCtorOnly and check
4277         MoveCtorAndSwapOnly.
4278
4279         * include/std/optional (optional::value_or(U&&) &&): Add missing
4280         constexpr specifier.
4281         * testsuite/20_util/optional/constexpr/observers/4.cc: Check value_or
4282         for disengaged optionals and rvalue optionals.
4283         * testsuite/20_util/optional/observers/4.cc: Likewise.
4284
4285 2019-04-12  Thomas Rodgers  <trodgers@redhat.com>
4286         
4287         * include/pstl/algorithm_impl.h: Uglify identfiers.
4288         * include/pstl/numeric_impl.h:  Uglify identfiers.
4289         * include/pstl/parallel_backend_tbb.h: Uglify identfiers.
4290
4291 2019-04-11  Thomas Rodgers  <trodgers@redhat.com>
4292
4293         * include/bits/c++config:
4294         Add definition for __PSTL_ASSERT.
4295         Add definition for __PSTL_ASSERT_MSG.
4296         * include/pstl/algorithm_impl.h: Replace use of assert().
4297         * include/pstl/numeric_impl.h: Replace use of assert().
4298         * include/pstl/parallel_backend_tbb.h:
4299         Replace use of assert().
4300         Replace use of __TBB_ASSERT().
4301         * include/pstl/parallel_backend_utils.h: Replace use of assert().
4302
4303 2019-04-11  Jonathan Wakely  <jwakely@redhat.com>
4304
4305         PR libstdc++/90046
4306         * src/c++17/memory_resource.cc
4307         (monotonic_buffer_resource::_Chunk::allocate): Increase alignment if
4308         needed to allow placing a _Chunk at the end of the buffer.
4309         (monotonic_buffer_resource::_M_new_buffer): Remove static_assert.
4310
4311 2019-04-10  Jonathan Wakely  <jwakely@redhat.com>
4312
4313         * doc/xml/faq.xml: Add information about emergency EH pool.
4314         * doc/xml/manual/debug.xml: Update list of memory debugging tools.
4315         Move outdated information on mt_allocator to a separate section.
4316         * doc/xml/manual/evolution.xml: Clarify that GLIBCXX_FORCE_NEW
4317         doesn't affect the default allocator.
4318
4319         * testsuite/lib/libstdc++.exp (check_v3_target_parallel_mode): Fix
4320         typo.
4321
4322         PR libstdc++/89851
4323         * testsuite/20_util/variant/89851.cc: New test.
4324
4325 2019-04-09  Jonathan Wakely  <jwakely@redhat.com>
4326
4327         * include/std/variant: Adjust whitespace. Add comments.
4328         (_Multi_array): Leave primary template undefined.
4329         (_Multi_array<_Tp>): Define partial specialization for base case of
4330         recursion.
4331         (__gen_vtable_impl, __gen_vtable): Remove redundant && from type
4332         which is always a reference.
4333         (__gen_vtable::_S_apply()): Remove function, inline body into
4334         default member initializer.
4335         * testsuite/20_util/variant/visit.cc: Test with noncopyable types.
4336
4337         * include/std/variant (__variant_idx_cookie): Add member type.
4338         (__visitor_result_type): Remove.
4339         (__do_visit): Use invoke_result instead of __visitor_result_type.
4340         * testsuite/20_util/variant/visit.cc: New test.
4341
4342         PR libstdc++/90008
4343         * include/std/variant (_VARIANT_RELATION_FUNCTION_TEMPLATE): Remove
4344         unused capture.
4345         * testsuite/20_util/variant/90008.cc: New test.
4346
4347 2019-04-09  Thomas Rodgers  <trodgers@redhat.com>
4348
4349         * include/pstl/algorithm_impl.h: Add namespace qualification.
4350         * include/pstl/execution_defs.h: Add namespace qualification.
4351         * include/pstl/execution_impl.h: Add namespace qualification.
4352         * include/pstl/numeric_impl.h: Add namespace qualification.
4353         * include/pstl/parallel_backend_tbb.h: Add namespace qualification.
4354         * include/pstl/unseq_backend_simd.h: Add namespace qualification.
4355         * include/pstl/parallel_backend_utils.h: Include <cassert>.
4356
4357 2019-04-08  Ville Voutilainen  <ville.voutilainen@gmail.com>
4358
4359         Fix visit<R> for variant.
4360         * include/std/variant (__do_visit): Add a template parameter
4361         for enforcing same return types for visit.
4362         (__gen_vtable_impl): Likewise.
4363         (_S_apply_single_alt): Adjust.
4364         (__visit_invoke_impl): New. Handle casting to void.
4365         (__do_visit_invoke): New. Enforces same return types.
4366         (__do_visit_invoke_r): New. Converts return types.
4367         (__visit_invoke): Adjust.
4368         (__gen_vtable):  Add a template parameter for enforcing
4369         same return types for visit.
4370         * testsuite/20_util/variant/visit_r.cc: Add a test for a visitor with
4371         different return types.
4372         * testsuite/20_util/variant/visit_neg.cc: New. Ensures that
4373         visitors with different return types don't accidentally
4374         compile with regular visitation.
4375
4376 2019-04-08  Christophe Lyon  <christophe.lyon@linaro.org>
4377
4378         * testsuite/27_io/filesystem/iterators/caching.cc: Add
4379         dg-require-filesystem-ts.
4380
4381 2019-04-05  Jonathan Wakely  <jwakely@redhat.com>
4382
4383         * doc/xml/manual/status_cxx2020.xml: Update status.
4384         * include/std/variant (visit<R>): Define for C++2a (P0655R1).
4385         * testsuite/20_util/variant/visit_r.cc: New test.
4386
4387         * include/bits/fs_dir.h (directory_iterator::operator*)
4388         (directory_iterator::operator->): Add noexcept.
4389         (operator==, operator!=): Replace namespace-scope equality operators
4390         for directory iterators with hidden friends.
4391
4392         PR libstdc++/89986
4393         * config/abi/pre/gnu.ver: Add missing exports.
4394         * testsuite/27_io/filesystem/iterators/directory_iterator.cc: Test
4395         increment member.
4396
4397         * config/abi/pre/gnu.ver: Export new symbols.
4398         * include/bits/fs_dir.h (recursive_directory_iterator::options())
4399         (recursive_directory_iterator::recursion_pending())
4400         (recursive_directory_iterator::disable_recursion_pending()): Remove
4401         inline definitions. Make noexcept.
4402         (recursive_directory_iterator::depth())
4403         (recursive_directory_iterator::operator*())
4404         (recursive_directory_iterator::operator->()): Make noexcept.
4405         (recursive_directory_iterator::_M_options)
4406         (recursive_directory_iterator::_M_pending): Remove data members.
4407         * src/c++17/fs_path.cc (_Dir_stack): Add constructor and data members.
4408         (recursive_directory_iterator::recursive_directory_iterator): Remove
4409         ctor-initializer. Use new constructor for _Dir_stack.
4410         (recursive_directory_iterator::options())
4411         (recursive_directory_iterator::recursion_pending())
4412         (recursive_directory_iterator::disable_recursion_pending()): Add
4413         non-inline definitions.
4414         (recursive_directory_iterator::depth()): Make noexcept.
4415         (recursive_directory_iterator::increment(error_code&))
4416         (recursive_directory_iterator::pop(error_code&)): Adjust to new
4417         location of options and recursion_pending members.
4418         * testsuite/27_io/filesystem/iterators/recursion_pending.cc: New test.
4419         * testsuite/util/testsuite_fs.h (__gnu_test::scoped_file): Add
4420         user-declared move constructor and assignment operator, to make the
4421         type move-only.
4422
4423         * src/c++17/fs_dir.cc (_Dir::advance(bool, error_code&)): Handle
4424         d_type == DT_UNKNOWN immediately.
4425         (_Dir::should_recurse(bool, error_code&)): Remove file_type::unknown
4426         handling here.
4427         * testsuite/27_io/filesystem/iterators/caching.cc: New test.
4428
4429         * include/bits/fs_path.h (path::operator=(path&&)): Check for self
4430         assignment.
4431         * src/c++17/fs_path.cc (path::operator=(const path&)): Likewise.
4432         * testsuite/27_io/filesystem/path/assign/copy.cc: Test self
4433         assignment.
4434
4435         PR libstdc++/87431 (again)
4436         * include/bits/basic_string.h (__variant::_Never_valueless_alt):
4437         Define partial specialization for basic_string.
4438         * include/bits/shared_ptr.h (_Never_valueless_alt): Likewise for
4439         shared_ptr and weak_ptr.
4440         * include/bits/std_function.h (_Never_valueless_alt): Likewise for
4441         function.
4442         * include/bits/stl_vector.h (_Never_valueless_alt): Likewise for
4443         vector.
4444         * include/bits/unique_ptr.h (_Never_valueless_alt): Likewise for
4445         unique_ptr.
4446         * include/debug/vector (_Never_valueless_alt): Likewise for debug
4447         vector.
4448         * include/std/any (_Never_valueless_alt): Define explicit
4449         specialization for any.
4450         * include/std/variant (_Never_valueless_alt): Define primary template.
4451         (__never_valueless): Use _Never_valueless_alt instead of
4452         is_trivially_copyable.
4453         (variant::emplace<N>(Args&&...)): Add special case for non-throwing
4454         initializations to avoid try-catch overhead. Add special case for
4455         scalars produced by potentially-throwing conversions. Use
4456         _Never_valueless_alt instead of is_trivially_copyable for the
4457         remaining strong exception-safety cases.
4458         (variant::emplace<N>(initializer_list<U>, Args&&...)): Likewise.
4459         * testsuite/20_util/variant/87431.cc: Run both test functions.
4460         * testsuite/20_util/variant/exception_safety.cc: New test.
4461         * testsuite/20_util/variant/run.cc: Use pmr::string instead of string,
4462         so the variant becomes valueless.
4463
4464 2019-04-03  Jonathan Wakely  <jwakely@redhat.com>
4465
4466         PR libstdc++/85184
4467         * include/std/variant (_Copy_assign_base, _Move_assign_base, variant):
4468         Remove assertions.
4469         (variant::emplace<_Tp>): Return result of emplace<N> directly.
4470
4471         * include/std/string (__hash_string_base): New class template defining
4472         operator() for hashing strings.
4473         (hash<pmr::string>, hash<pmr::u8string>, hash<pmr::u16string>)
4474         (hash<pmr::u32string>, hash<pmr::wstring>): Define for C++17.
4475         * testsuite/21_strings/basic_string/hash/hash.cc: New test.
4476         * testsuite/21_strings/basic_string/hash/hash_char8_t.cc: New test.
4477
4478 2019-04-01  Ville Voutilainen  <ville.voutilainen@gmail.com>
4479
4480         Use single-visitation in variant assignment and swap and relops.
4481         Also use indices instead of types when checking whether
4482         variants hold the same thing.
4483         * include/std/variant (__do_visit): Add a template parameter
4484         for index visitation, invoke with indices if index visitation
4485         is used.
4486         (__variant_idx_cookie): New.
4487         (__visit_with_index): Likewise.
4488         (_Copy_assign_base::operator=): Do single-visitation with
4489         an index visitor.
4490         (_Move_assign_base::operator=): Likewise.
4491         (_Extra_visit_slot_needed): Adjust.
4492         (__visit_invoke): Call with indices if it's an index visitor.
4493         (relops): Do single-visitation with an index visitor.
4494         (swap): Likewise.
4495         (__visitor_result_type): New.
4496
4497 2019-03-30  Eric Botcazou  <ebotcazou@adacore.com>
4498
4499         * src/c++17/fs_ops.cc (fs::permissions): Use std::errc::not_supported.
4500
4501 2019-03-28  Ville Voutilainen  <ville.voutilainen@gmail.com>
4502
4503         Don't revisit a variant we are already visiting.
4504         * include/std/variant (__variant_construct_single): New.
4505         (__variant_construct): Use it.
4506         (_M_destructive_move): Likewise.
4507         (_M_destructive_copy): Likewise.
4508         (_Copy_assign_base::operator=): Adjust.
4509         (_Move_assign_base::operator=): Likewise.
4510         (swap): Likewise.
4511
4512 2019-03-26  Jonathan Wakely  <jwakely@redhat.com>
4513
4514         PR libstdc++/85965
4515         * include/bits/hashtable.h (_Hashtable): Move static assertions to
4516         destructor so they are not evaluated until the _Key type is complete.
4517         * include/bits/stl_tree.h (_Rb_tree): Likewise.
4518         * testsuite/23_containers/set/85965.cc: New test.
4519         * testsuite/23_containers/unordered_set/85965.cc: New test.
4520         * testsuite/23_containers/map/48101_neg.cc: Replace "here" errors
4521         with regexp matching the corresponding _Rb_tree specialization.
4522         * testsuite/23_containers/multimap/48101_neg.cc: Likewise.
4523         * testsuite/23_containers/multiset/48101_neg.cc: Remove "here" error.
4524         * testsuite/23_containers/set/48101_neg.cc: Likewise.
4525         * testsuite/23_containers/unordered_map/48101_neg.cc: Likewise.
4526         * testsuite/23_containers/unordered_multimap/48101_neg.cc: Likewise.
4527         * testsuite/23_containers/unordered_multiset/48101_neg.cc: Likewise.
4528         * testsuite/23_containers/unordered_set/48101_neg.cc: Likewise.
4529
4530 2019-03-26  Ville Voutilainen  <ville.voutilainen@gmail.com>
4531
4532         PR libstdc++/89825
4533         Fix based on a suggestion by Antony Polukhin.
4534         * include/std/variant (__never_valueless): New.
4535         (_M_valid): Use it.
4536         (_Extra_visit_slot_needed): New.
4537         (_Multi_array): Use it.
4538         (_S_apply_all_alts): Likewise.
4539
4540 2019-03-26  Ville Voutilainen  <ville.voutilainen@gmail.com>
4541
4542         PR libstdc++/89824
4543         Fix based on a suggestion by Antony Polukhin.
4544         * include/std/variant (__gen_vtable): Don't reserve an
4545         additional table slot, _Multi_array already does that.
4546
4547 2019-03-26  Ville Voutilainen  <ville.voutilainen@gmail.com>
4548
4549         PR libstdc++/89816
4550         Fix based on a suggestion by Antony Polukhin.
4551         * include/std/variant (__variant_construct): Capture a pointer
4552         to the storage and visit just one variant.
4553
4554 2019-03-22  Jonathan Wakely  <jwakely@redhat.com>
4555
4556         * doc/xml/manual/backwards_compatibility.xml: Remove link to
4557         Doxygen-generated pages with unstable URL.
4558         * doc/xml/manual/concurrency_extensions.xml: Likewise.
4559         * doc/xml/manual/extensions.xml: Likewise.
4560         * doc/xml/manual/parallel_mode.xml: Likewise.
4561         * doc/xml/manual/support.xml: Likewise.
4562
4563         * include/bits/stl_algobase.h (__lg): Do arithmetic on type int to
4564         avoid -Wconversion warnings.
4565
4566 2019-03-21  Thomas Rodgers  <trodgers@redhat.com>
4567         
4568         * include/Makefile.am (std_header): Add ${std_srcdir}/execution.
4569         (pstl_srcdir, pstl_builddir, pstl_headers): New variables.
4570         (allstamped): Add stamp-pstl.
4571         (install-headers): Add ptsl_builddir.
4572         * include/Makefile.in: Regenerate.
4573         * include/bits/c++config: Add pstl configuration.
4574         * include/pstl/LICENSE.txt: New file.
4575         * include/pstl/algorithm_fwd.h: New file.
4576         * include/pstl/algorithm_impl.h: New file.
4577         * include/pstl/execution_defs.h: New file.
4578         * include/pstl/execution_impl.h: New file.
4579         * include/pstl/glue_algorithm_defs.h: New file.
4580         * include/pstl/glue_algorithm_impl.h: New file.
4581         * include/pstl/glue_execution_defs.h: New file.
4582         * include/pstl/glue_memory_defs.h: New file.
4583         * include/pstl/glue_memory_impl.h: New file.
4584         * include/pstl/glue_numeric_defs.h: New file.
4585         * include/pstl/glue_numeric_impl.h: New file.
4586         * include/pstl/memory_impl.h: New file.
4587         * include/pstl/numeric_fwd.h: New file.
4588         * include/pstl/numeric_impl.h: New file.
4589         * include/pstl/parallel_backend.h: New file.
4590         * include/pstl/parallel_backend_tbb.h: New file.
4591         * include/pstl/parallel_backend_utils.h: New file.
4592         * include/pstl/parallel_impl.h: New file.
4593         * include/pstl/pstl_config.h: New file.
4594         * include/pstl/unseq_backend_simd.h: New file.
4595         * include/pstl/utils.h: New file.
4596         * include/std/algorithm: Include parallel algorithm implementations.
4597         * include/std/execution: New file.
4598         * include/std/memory: Include parallel algorithm implementations.
4599         * include/std/numeric: Include parallel algorithm implementations.
4600         * include/std/version: Add parallel algorithms feature test macro.
4601         * testsuite/util/pstl/pstl_test_config.h: New file.
4602         * testsuite/util/pstl/test_utils.h: New file.
4603         * testsuite/20_util/specialized_algorithms/pstl/uninitialized_construct.cc: New file.
4604         * testsuite/20_util/specialized_algorithms/pstl/uninitialized_copy_move.cc: New file.
4605         * testsuite/20_util/specialized_algorithms/pstl/uninitialized_fill_destroy.cc: New file.
4606         * testsuite/25_algorithms/pstl/alg_merge/inplace_merge.cc: New file.
4607         * testsuite/25_algorithms/pstl/alg_merge/merge.cc: New file.
4608         * testsuite/25_algorithms/pstl/alg_modifying_operations/copy_if.cc: New file.
4609         * testsuite/25_algorithms/pstl/alg_modifying_operations/copy_move.cc: New file.
4610         * testsuite/25_algorithms/pstl/alg_modifying_operations/fill.cc: New file.
4611         * testsuite/25_algorithms/pstl/alg_modifying_operations/generate.cc: New file.
4612         * testsuite/25_algorithms/pstl/alg_modifying_operations/is_partitioned.cc: New file.
4613         * testsuite/25_algorithms/pstl/alg_modifying_operations/partition.cc: New file.
4614         * testsuite/25_algorithms/pstl/alg_modifying_operations/partition_copy.cc: New file.
4615         * testsuite/25_algorithms/pstl/alg_modifying_operations/remove.cc: New file.
4616         * testsuite/25_algorithms/pstl/alg_modifying_operations/remove_copy.cc: New file.
4617         * testsuite/25_algorithms/pstl/alg_modifying_operations/replace.cc: New file.
4618         * testsuite/25_algorithms/pstl/alg_modifying_operations/replace_copy.cc: New file.
4619         * testsuite/25_algorithms/pstl/alg_modifying_operations/rotate.cc: New file.
4620         * testsuite/25_algorithms/pstl/alg_modifying_operations/rotate_copy.cc: New file.
4621         * testsuite/25_algorithms/pstl/alg_modifying_operations/swap_ranges.cc: New file.
4622         * testsuite/25_algorithms/pstl/alg_modifying_operations/transform_binary.cc: New file.
4623         * testsuite/25_algorithms/pstl/alg_modifying_operations/transform_unary.cc: New file.
4624         * testsuite/25_algorithms/pstl/alg_modifying_operations/unique.cc: New file.
4625         * testsuite/25_algorithms/pstl/alg_modifying_operations/unique_copy_equal.cc: New file.
4626         * testsuite/25_algorithms/pstl/alg_nonmodifying/adjacent_find.cc: New file.
4627         * testsuite/25_algorithms/pstl/alg_nonmodifying/all_of.cc: New file.
4628         * testsuite/25_algorithms/pstl/alg_nonmodifying/any_of.cc: New file.
4629         * testsuite/25_algorithms/pstl/alg_nonmodifying/count.cc: New file.
4630         * testsuite/25_algorithms/pstl/alg_nonmodifying/equal.cc: New file.
4631         * testsuite/25_algorithms/pstl/alg_nonmodifying/find.cc: New file.
4632         * testsuite/25_algorithms/pstl/alg_nonmodifying/find_end.cc: New file.
4633         * testsuite/25_algorithms/pstl/alg_nonmodifying/find_first_of.cc: New file.
4634         * testsuite/25_algorithms/pstl/alg_nonmodifying/find_if.cc: New file.
4635         * testsuite/25_algorithms/pstl/alg_nonmodifying/for_each.cc: New file.
4636         * testsuite/25_algorithms/pstl/alg_nonmodifying/mismatch.cc: New file.
4637         * testsuite/25_algorithms/pstl/alg_nonmodifying/none_of.cc: New file.
4638         * testsuite/25_algorithms/pstl/alg_nonmodifying/nth_element.cc: New file.
4639         * testsuite/25_algorithms/pstl/alg_nonmodifying/reverse.cc: New file.
4640         * testsuite/25_algorithms/pstl/alg_nonmodifying/reverse_copy.cc: New file.
4641         * testsuite/25_algorithms/pstl/alg_nonmodifying/search_n.cc: New file.
4642         * testsuite/25_algorithms/pstl/alg_sorting/includes.cc: New file.
4643         * testsuite/25_algorithms/pstl/alg_sorting/is_heap.cc: New file.
4644         * testsuite/25_algorithms/pstl/alg_sorting/is_sorted.cc: New file.
4645         * testsuite/25_algorithms/pstl/alg_sorting/lexicographical_compare.cc: New file.
4646         * testsuite/25_algorithms/pstl/alg_sorting/minmax_element.cc: New file.
4647         * testsuite/25_algorithms/pstl/alg_sorting/partial_sort.cc: New file.
4648         * testsuite/25_algorithms/pstl/alg_sorting/partial_sort_copy.cc: New file.
4649         * testsuite/25_algorithms/pstl/alg_sorting/set.cc: New file.
4650         * testsuite/25_algorithms/pstl/alg_sorting/sort.cc: New file.
4651         * testsuite/26_numerics/pstl/numeric_ops/adjacent_difference.cc: New file.
4652         * testsuite/26_numerics/pstl/numeric_ops/reduce.cc: New file.
4653         * testsuite/26_numerics/pstl/numeric_ops/scan.cc: New file.
4654         * testsuite/26_numerics/pstl/numeric_ops/transform_reduce.cc: New file.
4655         * testsuite/26_numerics/pstl/numeric_ops/transform_scan.cc: New file.
4656         * testsuite/testsuite/20_util/specialized_algorithms/pstl/uninitialized_construct.cc: New file.
4657         * testsuite/testsuite/20_util/specialized_algorithms/pstl/uninitialized_copy_move.cc: New file.
4658         * testsuite/testsuite/20_util/specialized_algorithms/pstl/uninitialized_fill_destroy.cc: New file.
4659         * testsuite/testsuite/25_algorithms/pstl/alg_merge/inplace_merge.cc: New file.
4660         * testsuite/testsuite/25_algorithms/pstl/alg_merge/merge.cc: New file.
4661         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/copy_if.cc: New file.
4662         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/copy_move.cc: New file.
4663         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/fill.cc: New file.
4664         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/generate.cc: New file.
4665         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/is_partitioned.cc: New file.
4666         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/partition.cc: New file.
4667         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/partition_copy.cc: New file.
4668         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/remove.cc: New file.
4669         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/remove_copy.cc: New file.
4670         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/replace.cc: New file.
4671         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/replace_copy.cc: New file.
4672         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/rotate.cc: New file.
4673         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/rotate_copy.cc: New file.
4674         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/swap_ranges.cc: New file.
4675         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/transform_binary.cc: New file.
4676         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/transform_unary.cc: New file.
4677         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/unique.cc: New file.
4678         * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/unique_copy_equal.cc: New file.
4679         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/adjacent_find.cc: New file.
4680         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/all_of.cc: New file.
4681         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/any_of.cc: New file.
4682         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/count.cc: New file.
4683         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/equal.cc: New file.
4684         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/find.cc: New file.
4685         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/find_end.cc: New file.
4686         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/find_first_of.cc: New file.
4687         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/find_if.cc: New file.
4688         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/for_each.cc: New file.
4689         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/mismatch.cc: New file.
4690         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/none_of.cc: New file.
4691         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/nth_element.cc: New file.
4692         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/reverse.cc: New file.
4693         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/reverse_copy.cc: New file.
4694         * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/search_n.cc: New file.
4695         * testsuite/testsuite/25_algorithms/pstl/alg_sorting/includes.cc: New file.
4696         * testsuite/testsuite/25_algorithms/pstl/alg_sorting/is_heap.cc: New file.
4697         * testsuite/testsuite/25_algorithms/pstl/alg_sorting/is_sorted.cc: New file.
4698         * testsuite/testsuite/25_algorithms/pstl/alg_sorting/lexicographical_compare.cc: New file.
4699         * testsuite/testsuite/25_algorithms/pstl/alg_sorting/minmax_element.cc: New file.
4700         * testsuite/testsuite/25_algorithms/pstl/alg_sorting/partial_sort.cc: New file.
4701         * testsuite/testsuite/25_algorithms/pstl/alg_sorting/partial_sort_copy.cc: New file.
4702         * testsuite/testsuite/25_algorithms/pstl/alg_sorting/set.cc: New file.
4703         * testsuite/testsuite/25_algorithms/pstl/alg_sorting/sort.cc: New file.
4704         * testsuite/testsuite/26_numerics/pstl/numeric_ops/adjacent_difference.cc: New file.
4705         * testsuite/testsuite/26_numerics/pstl/numeric_ops/reduce.cc: New file.
4706         * testsuite/testsuite/26_numerics/pstl/numeric_ops/scan.cc: New file.
4707         * testsuite/testsuite/26_numerics/pstl/numeric_ops/transform_reduce.cc: New file.
4708         * testsuite/testsuite/26_numerics/pstl/numeric_ops/transform_scan.cc: New file.
4709
4710 2019-03-21  Jonathan Wakely  <jwakely@redhat.com>
4711
4712         * include/c_compatibility/math.h [!__STDCPP_WANT_MATH_SPEC_FUNCS__]
4713         (assoc_laguerre, assoc_laguerref, assoc_laguerrel, assoc_legendre)
4714         (assoc_legendref, assoc_legendrel, beta, betaf, betal, comp_ellint_1)
4715         (comp_ellint_1f, comp_ellint_1l, comp_ellint_2, comp_ellint_2f)
4716         (comp_ellint_2l, comp_ellint_3, comp_ellint_3f, comp_ellint_3l)
4717         (cyl_bessel_i, cyl_bessel_if, cyl_bessel_il, cyl_bessel_j)
4718         (cyl_bessel_jf, cyl_bessel_jl, cyl_bessel_k, cyl_bessel_kf)
4719         (cyl_bessel_kl, cyl_neumann, cyl_neumannf, cyl_neumannl, ellint_1)
4720         (ellint_1f, ellint_1l, ellint_2, ellint_2f, ellint_2l, ellint_3)
4721         (ellint_3f, ellint_3l, expint, expintf, expintl, hermite, hermitef)
4722         (hermitel, laguerre, laguerref, laguerrel, legendre, legendref)
4723         (legendrel, riemann_zeta, riemann_zetaf, riemann_zetal, sph_bessel)
4724         (sph_besself, sph_bessell, sph_legendre, sph_legendref, sph_legendrel)
4725         (sph_neumann, sph_neumannf, sph_neumannl): Only add using-declarations
4726         when the special functions IS is enabled, not for C++17.
4727         * testsuite/26_numerics/headers/cmath/functions_global_c++17.cc:
4728         Replace with ...
4729         * testsuite/26_numerics/headers/cmath/functions_global.cc: New test,
4730         without checks for special functions in C++17.
4731         * testsuite/26_numerics/headers/cmath/special_functions_global.cc:
4732         New test.
4733
4734         PR libstdc++/88066
4735         * include/backward/hash_map: Use <> for includes not "".
4736         * include/backward/hash_set: Likewise.
4737         * include/backward/strstream: Likewise.
4738         * include/tr1/bessel_function.tcc: Likewise.
4739         * include/tr1/exp_integral.tcc: Likewise.
4740         * include/tr1/legendre_function.tcc: Likewise.
4741         * include/tr1/modified_bessel_func.tcc: Likewise.
4742         * include/tr1/riemann_zeta.tcc: Likewise.
4743
4744 2019-03-19  Jonathan Wakely  <jwakely@redhat.com>
4745
4746         * doc/xml/manual/allocator.xml: Link to table documenting evolution
4747         of extension allocators.
4748         * doc/xml/manual/evolution.xml: Use angle brackets for header names.
4749         Document new headers in 7.2, 8.1 and 9.1 releases.
4750         * doc/xml/manual/using.xml: Adjust link target for new_allocator.
4751         * doc/html/*: Regenerate.
4752
4753 2019-03-12  John David Anglin  <dave.anglin@bell.net>
4754
4755         PR libstdc++/89461
4756         * testsuite/lib/libstdc++.exp: Locate libatomic.
4757         * testsuite/lib/dg-options.exp (add_options_for_libatomic): New.
4758         * testsuite/20_util/shared_ptr/thread/default_weaktoshared.cc: Add
4759         libatomic options.
4760         * testsuite/20_util/shared_ptr/thread/mutex_weaktoshared.cc: Likewise.
4761         * testsuite/experimental/net/timer/waitable/cons.cc: Likewise.
4762         * testsuite/experimental/net/timer/waitable/dest.cc: Likewise.
4763         * testsuite/experimental/net/timer/waitable/ops.cc: Likewise.
4764
4765 2019-03-11  Jonathan Wakely  <jwakely@redhat.com>
4766
4767         PR libstdc++/89460
4768         * configure.ac: Check for sockatmark.
4769         * crossconfig.m4: Check for sockatmark.
4770         * config.h.in: Regenerate.
4771         * configure: Regenerate.
4772         * include/experimental/internet (address_v4::_S_hton): Rename
4773         overloaded functions to _S_hton_16 and _S_ntoh_16.
4774         (address_v4::_S_ntoh): Rename to _S_ntoh_16 and _S_ntoh_32.
4775         (basic_endpoint): Adjust calls to _S_hton and _S_ntoh.
4776         * include/experimental/socket (basic_socket::at_mark): Check
4777         _GLIBCXX_HAVE_SOCKATMARK.
4778
4779         * testsuite/29_atomics/atomic_flag/test_and_set/explicit-hle.cc: Use
4780         const variables instead of macros.
4781
4782         PR libstdc++/89629
4783         * libsupc++/hash_bytes.cc [__SIZEOF_SIZE_T__ == 8] (_Hash_bytes):
4784         Use correct type for len_aligned.
4785         * testsuite/20_util/hash/89629.cc: New test.
4786
4787 2019-03-11  Jakub Jelinek  <jakub@redhat.com>
4788
4789         PR libstdc++/89641
4790         * include/std/atomic (atomic<T>::store, atomic<T>::load,
4791         atomic<T>::exchange, atomic<T>::compare_exchange_weak,
4792         atomic<T>::compare_exchange_strong): Cast __m or __s and __f to int.
4793         * include/bits/atomic_base.h (__atomic_base<T>::operator++,
4794         __atomic_base<T>::operator--, __atomic_base<T>::operator+=,
4795         __atomic_base<T>::operator-=, __atomic_base<T>::operator&=,
4796         __atomic_base<T>::operator|=, __atomic_base<T>::operator^=,
4797         __atomic_base<T*>::operator++, __atomic_base<T*>::operator--,
4798         __atomic_base<T*>::operator+=, __atomic_base<T*>::operator-=): Cast
4799         memory_order_seq_cst to int.
4800
4801 2019-03-08  Jonathan Wakely  <jwakely@redhat.com>
4802
4803         * doc/xml/manual/using.xml: Use link element instead of xref.
4804         * doc/html/*: Regenerate.
4805
4806         * include/bits/fs_path.h (path::format): Add fixed underlying type.
4807
4808 2019-03-08  François Dumont  <fdumont@gcc.gnu.org>
4809
4810         PR libstdc++/89477
4811         * include/debug/map.h (map): Use _RequireNotAllocator to constrain
4812         parameters in deduction guides.
4813         * include/debug/multimap.h (multimap): Likewise.
4814         * include/debug/set.h (multimap): Likewise.
4815         * include/debug/multiset.h (multimap): Likewise.
4816         * include/debug/unordered_map (unordered_map): Likewise.
4817         (unordered_multimap): Likewise.
4818         * include/debug/unordered_set (unordered_set): Likewise.
4819         (unordered_multiset): Likewise.
4820
4821         PR libstdc++/89608
4822         * include/debug/unordered_map (unordered_map<>::_M_check_rehashed):
4823         Invalidate all iterators in case of rehash.
4824         (unordered_multimap<>::_M_check_rehashed): Likewise.
4825         * include/debug/unordered_set
4826         (unordered_set<>::_M_check_rehashed): Likewise.
4827         (unordered_multiset<>::_M_check_rehashed): Likewise.
4828         * testsuite/23_containers/unordered_set/debug/89608_neg.cc: New.
4829
4830 2019-03-07  Andreas Schwab  <schwab@suse.de>
4831
4832         * config/abi/post/riscv64-linux-gnu: New directory.
4833         * config/abi/post/riscv64-linux-gnu/baseline_symbols.txt: New file.
4834
4835 2019-03-07  Jonathan Wakely  <jwakely@redhat.com>
4836
4837         * testsuite/20_util/function_objects/bind_front/1.cc: Change from
4838         compile test to run. Fix typo.
4839
4840         * doc/xml/manual/status_cxx2020.xml: Update C++20 status.
4841         * doc/html/*: Regenerate.
4842
4843         P0356R5 Simplified partial function application
4844         * include/std/functional [C++20] (_Bind_front, _Bind_front_t): Define
4845         helpers for bind_front.
4846         (bind_front, __cpp_lib_bind_front): Define.
4847         * testsuite/20_util/function_objects/bind_front/1.cc: New test.
4848
4849 2019-03-06  Jonathan Wakely  <jwakely@redhat.com>
4850
4851         * include/std/type_traits (__cpp_lib_bounded_array_traits): Define.
4852         * include/std/version (__cpp_lib_bounded_array_traits): Likewise.
4853         * testsuite/20_util/is_bounded_array/value.cc: Check for macro.
4854         * testsuite/20_util/is_unbounded_array/value.cc: Likewise.
4855
4856 2019-03-06  Edward Smith-Rowland  <3dw4rd@verizon.net>
4857
4858         PR libstdc++/86655 - std::assoc_legendre should not constrain
4859         the value of m (or x).
4860         * include/tr1/legendre_function.tcc (__assoc_legendre_p,
4861         __sph_legendre): If degree > order Don't throw, return 0.
4862         (__legendre_p, __assoc_legendre_p): Don't constrain x either.
4863         * testsuite/special_functions/02_assoc_legendre/pr86655.cc: New test.
4864         * testsuite/special_functions/20_sph_legendre/pr86655.cc: New test.
4865         * testsuite/tr1/5_numerical_facilities/special_functions/
4866         02_assoc_legendre/pr86655.cc: New test.
4867         * testsuite/tr1/5_numerical_facilities/special_functions/
4868         22_sph_legendre/pr86655.cc: New test.
4869
4870 2019-03-06  Ville Voutilainen  <ville.voutilainen@gmail.com>
4871
4872         Rewrite variant.
4873         Also PR libstdc++/85517
4874         * include/std/variant (__do_visit): New.
4875         (__variant_cast): Likewise.
4876         (__variant_cookie): Likewise.
4877         (__erased_*): Remove.
4878         (_Variant_storage::_S_vtable): Likewise.
4879         (_Variant_storage::__M_reset_impl): Adjust to use __do_visit.
4880         (_Variant_storage::__M_reset): Adjust.
4881         (__variant_construct): New.
4882         (_Copy_ctor_base(const _Copy_ctor_base&)): Adjust to use
4883         __variant_construct.
4884         (_Move_ctor_base(_Move_ctor_base&&)): Likewise.
4885         (_Move_ctor_base::__M_destructive_copy): New.
4886         (_Move_ctor_base::__M_destructive_move): Adjust to use
4887         __variant_construct.
4888         (_Copy_assign_base::operator=): Adjust to use __do_visit.
4889         (_Copy_assign_alias): Adjust to check both copy assignment
4890         and copy construction for triviality.
4891         (_Move_assign_base::operator=): Adjust to use __do_visit.
4892         (_Multi_array): Add support for visitors that accept and return
4893         a __variant_cookie.
4894         (__gen_vtable_impl::_S_apply_all_alts): Likewise.
4895         (__gen_vtable_impl::_S_apply_single_alt): Likewise.
4896         (__gen_vtable_impl::__element_by_index_or_cookie): New. Generate
4897         a __variant_cookie temporary for a variant that is valueless and..
4898         (__gen_vtable_impl::__visit_invoke): ..adjust here.
4899         (__gen_vtable::_Array_type): Conditionally make space for
4900         the __variant_cookie visitor case.
4901         (__variant_construct_by_index): New.
4902         (get_if): Adjust to use std::addressof.
4903         (relops): Adjust to use __do_visit.
4904         (variant): Add __variant_cast and __variant_construct_by_index
4905         as friends.
4906         (variant::emplace): Use _M_reset() and __variant_construct_by_index
4907         instead of self-destruction.
4908         (variant::swap): Adjust to use __do_visit.
4909         (visit): Reimplement in terms of __do_visit.
4910         (__variant_hash_call_base_impl::operator()): Adjust to use __do_visit.
4911         * testsuite/20_util/variant/compile.cc: Adjust.
4912         * testsuite/20_util/variant/run.cc: Likewise.
4913
4914 2019-03-06  Jonathan Wakely  <jwakely@redhat.com>
4915
4916         * include/bits/c++config.h (_cpp_lib_char8_t): Add L suffix to
4917         constant.
4918         * testsuite/experimental/feat-char8_t.cc: Likewise.
4919
4920          * include/std/type_traits [C++20] (is_bounded_array)
4921          (is_unbounded_array, is_bounded_array_v, is_unbounded_array_v):
4922          Define.
4923          * testsuite/20_util/is_bounded_array/requirements/
4924          explicit_instantiation.cc: New test.
4925          * testsuite/20_util/is_bounded_array/requirements/typedefs.cc: New
4926          test.
4927          * testsuite/20_util/is_bounded_array/value.cc: New test.
4928          * testsuite/20_util/is_unbounded_array/requirements/
4929          explicit_instantiation.cc: New test.
4930          * testsuite/20_util/is_unbounded_array/requirements/typedefs.cc: New
4931          * test.
4932          * testsuite/20_util/is_unbounded_array/value.cc: New test.
4933
4934         * include/bits/ptr_traits.h [C++20] (pointer_traits<T*>::pointer_to):
4935         Add constexpr.
4936         * testsuite/20_util/pointer_traits/pointer_to_constexpr.cc: New test.
4937
4938 2019-03-05  Jonathan Wakely  <jwakely@redhat.com>
4939
4940         * include/c_compatibility/math.h [C++20] (lerp): Add using
4941         declaration.
4942         * include/c_global/cmath [C++20] (__cpp_lib_interpolate): Define.
4943         (__lerp): Define function template to implement lerp.
4944         (lerp(float, float, float), lerp(double, double, double))
4945         (lerp(long double, long double, long double)): Define for C++20.
4946         * include/std/numeric [C++20] (__cpp_lib_interpolate): Define.
4947         (midpoint(T, T), midpoint(T*, T*)): Define.
4948         * include/std::version [C++20] (__cpp_lib_interpolate): Define.
4949         * testsuite/26_numerics/lerp.cc: New test.
4950         * testsuite/26_numerics/midpoint/floating.cc: New test.
4951         * testsuite/26_numerics/midpoint/integral.cc: New test.
4952         * testsuite/26_numerics/midpoint/pointer.cc: New test.
4953
4954 2019-03-04  Edward Smith-Rowland  <3dw4rd@verizon.net>
4955
4956         PR libstdc++/88996 Implement P0439R0
4957         Make std::memory_order a scoped enumeration.
4958         * include/bits/atomic_base.h: For C++20 make memory_order a scoped enum,
4959         add variables for the old enumerators.  Adjust calls.
4960         * testsuite/29_atomics/headers/atomic/types_std_c++2a.cc: New test.
4961         * testsuite/29_atomics/headers/atomic/types_std_c++2a_neg.cc: New test.
4962
4963 2019-03-04  Jonathan Wakely  <jwakely@redhat.com>
4964
4965         * testsuite/26_numerics/bit/bitops.rot/rotl.cc: Remove bogus dg-do
4966         directive.
4967
4968         * include/std/memory_resource (polymorphic_allocator): Add default
4969         template argument for C++20.
4970         (polymorphic_allocator::allocate_bytes)
4971         (polymorphic_allocator::deallocate_bytes)
4972         (polymorphic_allocator::allocate_object)
4973         (polymorphic_allocator::deallocate_object)
4974         (polymorphic_allocator::new_object)
4975         (polymorphic_allocator::delete_object): New member functions for
4976         C++20.
4977         * testsuite/20_util/polymorphic_allocator/allocate_object.cc: New
4978         test.
4979
4980 2019-03-03  Jonathan Wakely  <jwakely@redhat.com>
4981
4982         PR libstdc++/89562
4983         * src/filesystem/ops-common.h (do_copy_file): Open files in binary
4984         mode for mingw.
4985
4986 2019-03-01  Jonathan Wakely  <jwakely@redhat.com>
4987
4988         * testsuite/util/testsuite_allocator.h (__gnu_test::memory_resource)
4989         [!__cpp_sized_deallocation]: Do not pass size to operator delete.
4990
4991         * include/std/memory (uses_allocator_construction_args): New set of
4992         overloaded functions.
4993         (make_obj_using_allocator, uninitialized_construct_using_allocator):
4994         New functions.
4995         * include/std/memory_resource (polymorphic_allocator::construct)
4996         [__cplusplus > 201703l]: Replace all overloads with a single function
4997         using uses_allocator_construction_args.
4998         * testsuite/20_util/polymorphic_allocator/construct_c++2a.cc: New
4999         test.
5000         * testsuite/20_util/uses_allocator/make_obj.cc: New test.
5001
5002 2019-02-27  Jonathan Wakely  <jwakely@redhat.com>
5003
5004         PR libstdc++/89466
5005         * acinclude.m4 (GLIBCXX_CONFIGURE_DOCBOOK): Reorder check for local
5006         stylesheet directories before check for xsltproc. Try to use
5007         xmlcatalog to find local stylesheet directory before trying hardcoded
5008         paths. Add path used by suse to hardcoded paths. Adjust xsltproc
5009         check to look for the same stylesheet as doc/Makefile.am uses. Don't
5010         use xsltproc if xmlcatalog fails to find a local stylesheet.
5011         * configure.ac: Check for xmlcatalog.
5012         * Makefile.in: Regenerate.
5013         * configure: Likewise.
5014         * doc/Makefile.in: Likewise.
5015         * include/Makefile.in: Likewise.
5016         * libsupc++/Makefile.in: Likewise.
5017         * po/Makefile.in: Likewise.
5018         * python/Makefile.in: Likewise.
5019         * src/Makefile.in: Likewise.
5020         * src/c++11/Makefile.in: Likewise.
5021         * src/c++17/Makefile.in: Likewise.
5022         * src/c++98/Makefile.in: Likewise.
5023         * src/filesystem/Makefile.in: Likewise.
5024         * testsuite/Makefile.in: Likewise.
5025
5026 2019-02-26  Jonathan Wakely  <jwakely@redhat.com>
5027
5028         PR libstdc++/89477
5029         * include/bits/alloc_traits.h (_RequireNotAllocator): New helper for
5030         container deduction guides.
5031         * include/bits/hashtable.h (_RequireNotAllocatorOrIntegral): Likewise.
5032         * include/bits/stl_map.h (map): Use _RequireNotAllocator to constrain
5033         parameters in deduction guides.
5034         * include/bits/stl_multimap.h (multimap): Likewise.
5035         * include/bits/stl_multiset.h (multiset): Likewise.
5036         * include/bits/stl_queue.h (queue, priority_queue): Likewise.
5037         * include/bits/stl_set.h (set): Likewise.
5038         * include/bits/stl_stack.h (stack): Likewise.
5039         * include/bits/unordered_map.h (unordered_map, unordered_multimap):
5040         use _RequireNotAllocator and _RequireNotAllocatorOrIntegral to
5041         constrain parameters in deduction guides.
5042         * include/bits/unordered_set.h (unordered_set, unordered_multiset):
5043         Likewise.
5044         * testsuite/23_containers/map/cons/deduction.cc: Test additional
5045         deduction cases.
5046         * testsuite/23_containers/multiset/cons/deduction.cc: Likewise.
5047         * testsuite/23_containers/set/cons/deduction.cc: Likewise.
5048         * testsuite/23_containers/unordered_map/cons/deduction.cc: Likewise.
5049         * testsuite/23_containers/unordered_multimap/cons/deduction.cc:
5050         Likewise.
5051         * testsuite/23_containers/unordered_multiset/cons/deduction.cc:
5052         Likewise.
5053         * testsuite/23_containers/unordered_set/cons/deduction.cc: Likewise.
5054
5055         PR libstdc++/89416
5056         * include/bits/alloc_traits.h (__is_alloc_insertable_impl): Change
5057         to class template and partial specialization using void_t.
5058         (__is_copy_insertable, __is_move_insertable): Adjust base class.
5059
5060 2019-02-24  Jonathan Wakely  <jwakely@redhat.com>
5061
5062         PR libstdc++/89416
5063         * include/bits/alloc_traits.h (__is_alloc_insertable_impl): Make
5064         copy and move members public.
5065
5066 2019-02-23  Jonathan Wakely  <jwakely@redhat.com>
5067
5068         * include/std/type_traits (__underlying_type_impl): New helper to
5069         make underlying_type SFINAE-friendly.
5070         (underlying_type): Derive from __underlying_type_impl.
5071         * testsuite/20_util/underlying_type/requirements/typedefs-3.cc: New
5072         test.
5073
5074         PR libstdc++/89446
5075         * include/bits/char_traits.h (__constant_char_array): Check index is
5076         in range before dereferencing.
5077         (char_traits<char>::compare, char_traits<char>::find)
5078         (char_traits<char8_t>::compare, char_traits<char8_t>::find): Return
5079         immediately if n is zero.
5080         (char_traits<wchar_t>::compare, char_traits<wchar_t>::find): Likewise.
5081         Remove workarounds for PR 67026.
5082         * testsuite/21_strings/basic_string_view/operators/char/89446.cc:
5083         New test.
5084         * testsuite/21_strings/basic_string_view/operators/wchar_t/89446.cc:
5085         New test.
5086
5087 2019-02-22  Eric Botcazou  <ebotcazou@adacore.com>
5088
5089         * config/abi/post/sparc64-linux-gnu/baseline_symbols.txt: Adjust.
5090         * config/abi/post/sparc64-linux-gnu/32/baseline_symbols.txt: Likewise.
5091
5092 2019-02-22  Jakub Jelinek  <jakub@redhat.com>
5093
5094         PR libstdc++/89402
5095         * src/c++98/compatibility-ldbl.cc (_ZNKSt4hashIeEclEe): Change return
5096         type to std::size_t and argument to type to long double.
5097
5098 2019-02-22  Eric Botcazou  <ebotcazou@adacore.com>
5099
5100         * configure.host (abi_baseline_pair): Adjust for SPARC64/Linux.
5101         * config/abi/post/sparc64-linux-gnu: New directory.
5102         * config/abi/post/sparc64-linux-gnu/baseline_symbols.txt: New file.
5103         * config/abi/post/sparc64-linux-gnu/32: New directory.
5104         * config/abi/post/sparc64-linux-gnu/32/baseline_symbols.txt: New file.
5105
5106 2019-02-21  Jonathan Wakely  <jwakely@redhat.com>
5107
5108         * testsuite/29_atomics/headers/atomic/types_std_c++20.cc: New test.
5109         * testsuite/29_atomics/headers/atomic/types_std_c++20_neg.cc: New
5110         test.
5111
5112 2019-02-22  Tom Honermann  <tom@honermann.net>
5113
5114         * python/libstdcxx/v6/printers.py (register_type_printers): Add type
5115         printers for u8string and u8string_view.
5116
5117 2019-02-22  Tom Honermann  <tom@honermann.net>
5118
5119         * testsuite/18_support/byte/ops.cc: Validate
5120         std::to_integer<char8_t>, std::to_integer<char16_t>, and
5121         std::to_integer<char32_t>.
5122         * testsuite/18_support/numeric_limits/dr559.cc: Validate
5123         std::numeric_limits<char8_t>.
5124         * testsuite/18_support/numeric_limits/lowest.cc: Validate
5125         std::numeric_limits<char8_t>::lowest().
5126         * testsuite/18_support/numeric_limits/max_digits10.cc: Validate
5127         std::numeric_limits<char8_t>::max_digits10.
5128         * testsuite/18_support/type_info/fundamental.cc: Validate
5129         typeinfo for char8_t.
5130         * testsuite/20_util/from_chars/1_c++20_neg.cc: New test, validating
5131         std::from_chars with char8_t.
5132         * testsuite/20_util/hash/requirements/explicit_instantiation.cc:
5133         Validate explicit instantiation of std::hash<char8_t>.
5134         * testsuite/20_util/is_integral/value.cc: Validate
5135         std::is_integral<char8_t>.
5136         * testsuite/20_util/make_signed/requirements/typedefs-4.cc:
5137         Validate std::make_signed<char8_t>.
5138         * testsuite/21_strings/basic_string/cons/char/deduction.cc:
5139         Validate u8string construction from char8_t sources.
5140         * testsuite/21_strings/basic_string/types/pmr_typedefs.cc: Validate
5141         std::pmr::u8string.
5142         * testsuite/21_strings/basic_string_view/operations/compare/
5143         char/70483.cc: Validate substr operations on u8string_view.
5144         * testsuite/21_strings/basic_string_view/typedefs.cc: Validate that
5145         the u8string_view typedef is defined.
5146         * testsuite/21_strings/char_traits/requirements/
5147         constexpr_functions.cc: Validate char_traits<char8_t> constexpr
5148         member functions.
5149         * testsuite/21_strings/char_traits/requirements/
5150         constexpr_functions_c++17.cc: Validate char_traits<char8_t> C++17
5151         constexpr member functions.
5152         * testsuite/21_strings/headers/string/types_std_c++0x.cc: Validate
5153         that the u8string typedef is defined.
5154         * testsuite/22_locale/locale/cons/unicode.cc: Validate the presence
5155         of the std::codecvt<char16_t, char8_t, std::mbstate_t> and
5156         std::codecvt<char32_t, char8_t, std::mbstate_t> facets.
5157         * testsuite/29_atomics/atomic/cons/assign_neg.cc: Update line
5158         numbers.
5159         * testsuite/29_atomics/atomic/cons/copy_neg.cc: Likewise.
5160         * testsuite/29_atomics/atomic_integral/cons/assign_neg.cc:
5161         Likewise.
5162         * testsuite/29_atomics/atomic_integral/cons/copy_neg.cc: Likewise.
5163         * testsuite/29_atomics/atomic_integral/is_always_lock_free.cc:
5164         Validate std::atomic<char8_t>::is_always_lock_free
5165         * testsuite/29_atomics/atomic_integral/operators/bitwise_neg.cc:
5166         Update line numbers.
5167         * testsuite/29_atomics/atomic_integral/operators/decrement_neg.cc:
5168         Likewise.
5169         * testsuite/29_atomics/atomic_integral/operators/increment_neg.cc:
5170         Likewise.
5171         * testsuite/experimental/polymorphic_allocator/pmr_typedefs_string.cc:
5172         Validate std::experimental::pmr::u8string.
5173         * testsuite/experimental/string_view/typedefs.cc: Validate that the
5174         u8string_view typedef is defined.
5175         * testsuite/util/testsuite_common_types.h: Add char8_t, char16_t and
5176         char32_t to the typelists.
5177
5178 2019-02-22  Tom Honermann  <tom@honermann.net>
5179
5180         * include/ext/typelist.h: Constrain a partial specialization of
5181         typelist::detail::append_ to only match chain<T1,T2>.
5182
5183 2019-02-21  Jonathan Wakely  <jwakely@redhat.com>
5184
5185         PR libstdc++/89416
5186         * include/bits/alloc_traits.h (__is_alloc_insertable_impl): Replace
5187         class template with class. Replace move and copy member types with
5188         member alias templates, so they are only instantiated when needed.
5189         (__is_copy_insertable, __is_move_insertable): Adjust base class.
5190         * testsuite/23_containers/vector/modifiers/push_back/89130.cc: Enable
5191         test for C++11/14/17 as well.
5192         * testsuite/23_containers/vector/modifiers/push_back/89416.cc: New
5193         test.
5194
5195 2019-02-20  Jakub Jelinek  <jakub@redhat.com>
5196
5197         PR libstdc++/89402
5198         * src/c++98/compatibility-ldbl.cc (_ZNKSt4hashIeEclEe): Add
5199         _GLIBCXX_PURE to the alias declaration.
5200
5201 2019-02-19  Jonathan Wakely  <jwakely@redhat.com>
5202
5203         * testsuite/21_strings/basic_string/literals/types.cc
5204         [_GLIBCXX_USE_CHAR8_T]: Adjust expected string type for u8 literal.
5205         * testsuite/21_strings/basic_string/literals/values.cc
5206         [_GLIBCXX_USE_CHAR8_T]: Likewise.
5207         * testsuite/22_locale/codecvt/char16_t.cc: Adjust for u8 literals
5208         potentially having different type.
5209         * testsuite/22_locale/codecvt/char32_t.cc: Likewise.
5210         * testsuite/22_locale/codecvt/codecvt_utf8/79980.cc: Cast u8 literal
5211         to char.
5212         * testsuite/22_locale/codecvt/codecvt_utf8/wchar_t/1.cc: Likewise.
5213         * testsuite/22_locale/codecvt/utf8.cc: Likewise.
5214         * testsuite/22_locale/conversions/string/2.cc: Remove u8 prefix from
5215         string literals only using basic character set.
5216         * testsuite/22_locale/conversions/string/3.cc: Likewise. Cast other
5217         u8 literals to char.
5218         * testsuite/29_atomics/headers/atomic/macros.cc [_GLIBCXX_USE_CHAR8_T]:
5219         Test ATOMIC_CHAR8_T_LOCK_FREE.
5220         Add missing #error to ATOMIC_CHAR16_T_LOCK_FREE test.
5221         * testsuite/29_atomics/headers/atomic/types_std_c++0x.cc
5222         [_GLIBCXX_USE_CHAR8_T]: Check for std::atomic_char8_t.
5223         * testsuite/experimental/string_view/literals/types.cc
5224         [_GLIBCXX_USE_CHAR8_T]: Adjust expected string_view type for u8
5225         literal.
5226         * testsuite/experimental/string_view/literals/values.cc
5227         [_GLIBCXX_USE_CHAR8_T]: Likewise.
5228
5229 2019-02-19  Tom Honermann  <tom@honermann.net>
5230
5231         * testsuite/18_support/numeric_limits/char8_t.cc: New test cloned
5232         from char16_32_t.cc; validates numeric_limits<char8_t>.
5233         * testsuite/21_strings/basic_string/literals/types-char8_t.cc: New
5234         test cloned from types.cc; validates operator""s for char8_t
5235         returns u8string.
5236         * testsuite/21_strings/basic_string/literals/values-char8_t.cc: New
5237         test cloned from values.cc; validates construction and comparison
5238         of u8string values.
5239         * testsuite/21_strings/basic_string/requirements/
5240         /explicit_instantiation/char8_t/1.cc: New test cloned from
5241         char16_t/1.cc; validates explicit instantiation of
5242         basic_string<char8_t>.
5243         * testsuite/21_strings/basic_string_view/literals/types-char8_t.cc:
5244         New test cloned from types.cc; validates operator""sv for char8_t
5245         returns u8string_view.
5246         * testsuite/21_strings/basic_string_view/literals/
5247         values-char8_t.cc: New test cloned from values.cc; validates
5248         construction and comparison of u8string_view values.
5249         * testsuite/21_strings/basic_string_view/requirements/
5250         explicit_instantiation/char8_t/1.cc: New test cloned from
5251         char16_t/1.cc; validates explicit instantiation of
5252         basic_string_view<char8_t>.
5253         * testsuite/21_strings/char_traits/requirements/char8_t/65049.cc:
5254         New test cloned from char16_t/65049.cc; validates that
5255         char_traits<char8_t> is not vulnerable to the concerns in PR65049.
5256         * testsuite/21_strings/char_traits/requirements/char8_t/
5257         typedefs.cc: New test cloned from char16_t/typedefs.cc; validates
5258         that char_traits<char8_t> member typedefs are present and correct.
5259         * testsuite/21_strings/char_traits/requirements/
5260         explicit_instantiation/char8_t/1.cc: New test cloned from
5261         char16_t/1.cc; validates explicit instantiation of
5262         char_traits<char8_t>.
5263         * testsuite/22_locale/codecvt/char16_t-char8_t.cc: New test cloned
5264         from char16_t.cc: validates
5265         codecvt<char16_t, char8_t, mbstate_t>.
5266         * testsuite/22_locale/codecvt/char32_t-char8_t.cc: New test cloned
5267         from char32_t.cc: validates
5268         codecvt<char32_t, char8_t, mbstate_t>.
5269         * testsuite/22_locale/codecvt/utf8-char8_t.cc: New test cloned from
5270         utf8.cc; validates codecvt<char16_t, char8_t, std::mbstate_t> and
5271         codecvt<char32_t, char8_t, std::mbstate_t>.
5272         * testsuite/27_io/filesystem/path/native/string-char8_t.cc: New
5273         test cloned from string.cc; validates filesystem::path construction
5274         from char8_t input.
5275         * testsuite/experimental/feat-char8_t.cc: New test; validates that
5276         the __cpp_lib_char8_t feature test macro is defined with the
5277         correct value.
5278         * testsuite/experimental/filesystem/path/native/string-char8_t.cc:
5279         New test cloned from string.cc; validates filesystem::path
5280         construction from char8_t input.
5281         * testsuite/experimental/string_view/literals/types-char8_t.cc: New
5282         test cloned from types.cc; validates operator""sv for char8_t
5283         returns u8string_view.
5284         * testsuite/experimental/string_view/literals/values-char8_t.cc:
5285         New test cloned from values.cc; validates construction and
5286         comparison of u8string_view values.
5287         * testsuite/experimental/string_view/requirements/
5288         explicit_instantiation/char8_t/1.cc: New test cloned from
5289         char16_t/1.cc; validates explicit instantiation of
5290         basic_string_view<char8_t>.
5291         * testsuite/ext/char8_t/atomic-1.cc: New test; validates that
5292         ATOMIC_CHAR8_T_LOCK_FREE is not defined if char8_t support is not
5293         enabled.
5294
5295 2019-02-19  Tom Honermann  <tom@honermann.net>
5296
5297         P0482R5 char8_t: Standard library support
5298         * config/abi/pre/gnu-versioned-namespace.ver (CXXABI_2.0): Add
5299         typeinfo symbols for char8_t.
5300         * config/abi/pre/gnu.ver: Add CXXABI_1.3.12.
5301         (GLIBCXX_3.4.26): Add symbols for specializations of
5302         numeric_limits and codecvt that involve char8_t.
5303         (CXXABI_1.3.12): Add typeinfo symbols for char8_t.
5304         * include/bits/atomic_base.h: Add atomic_char8_t.
5305         * include/bits/basic_string.h: Add std::hash<u8string> and
5306         operator""s(const char8_t*, size_t).
5307         * include/bits/c++config: Define _GLIBCXX_USE_CHAR8_T and
5308         __cpp_lib_char8_t.
5309         * include/bits/char_traits.h: Add char_traits<char8_t>.
5310         * include/bits/codecvt.h: Add
5311         codecvt<char16_t, char8_t, mbstate_t>,
5312         codecvt<char32_t, char8_t, mbstate_t>,
5313         codecvt_byname<char16_t, char8_t, mbstate_t>, and
5314         codecvt_byname<char32_t, char8_t, mbstate_t>.
5315         * include/bits/cpp_type_traits.h: Add __is_integer<char8_t> to
5316         recognize char8_t as an integral type.
5317         * include/bits/fs_path.h: (path::__is_encoded_char): Recognize
5318         char8_t.
5319         (path::u8string): Return std::u8string when char8_t support is
5320         enabled.
5321         (path::generic_u8string): Likewise.
5322         (path::_S_convert): Handle conversion from char8_t input.
5323         (path::_S_str_convert): Likewise.
5324         * include/bits/functional_hash.h: Add hash<char8_t>.
5325         * include/bits/locale_conv.h (__str_codecvt_out): Add overloads for
5326         char8_t.
5327         * include/bits/locale_facets.h (_GLIBCXX_NUM_UNICODE_FACETS): Bump
5328         for new char8_t specializations.
5329         * include/bits/localefwd.h: Add missing declarations of
5330         codecvt<char16_t, char, mbstate_t> and
5331         codecvt<char32_t, char, mbstate_t>.  Add char8_t declarations
5332         codecvt<char16_t, char8_t, mbstate_t> and
5333         codecvt<char32_t, char8_t, mbstate_t>.
5334         * include/bits/postypes.h: Add u8streampos
5335         * include/bits/stringfwd.h: Add declarations of
5336         char_traits<char8_t> and u8string.
5337         * include/c_global/cstddef: Add __byte_operand<char8_t>.
5338         * include/experimental/bits/fs_path.h (path::__is_encoded_char):
5339         Recognize char8_t.
5340         (path::u8string): Return std::u8string when char8_t support is
5341         enabled.
5342         (path::generic_u8string): Likewise.
5343         (path::_S_convert): Handle conversion from char8_t input.
5344         (path::_S_str_convert): Likewise.
5345         * include/experimental/string: Add u8string.
5346         * include/experimental/string_view: Add u8string_view,
5347         hash<experimental::u8string_view>, and
5348         operator""sv(const char8_t*, size_t).
5349         * include/std/atomic: Add atomic<char8_t> and atomic_char8_t.
5350         * include/std/charconv (__is_int_to_chars_type): Recognize char8_t
5351         as a character type.
5352         * include/std/limits: Add numeric_limits<char8_t>.
5353         * include/std/string_view: Add u8string_view,
5354         hash<experimental::u8string_view>, and
5355         operator""sv(const char8_t*, size_t).
5356         * include/std/type_traits: Add __is_integral_helper<char8_t>,
5357         __make_unsigned<char8_t>, and __make_signed<char8_t>.
5358         * libsupc++/atomic_lockfree_defines.h: Define
5359         ATOMIC_CHAR8_T_LOCK_FREE.
5360         * src/c++11/Makefile.am: Compile with -fchar8_t when compiling
5361         codecvt.cc and limits.cc so that char8_t specializations of
5362         numeric_limits and codecvt and emitted.
5363         * src/c++11/Makefile.in: Likewise.
5364         * src/c++11/codecvt.cc: Define members of
5365         codecvt<char16_t, char8_t, mbstate_t>,
5366         codecvt<char32_t, char8_t, mbstate_t>,
5367         codecvt_byname<char16_t, char8_t, mbstate_t>, and
5368         codecvt_byname<char32_t, char8_t, mbstate_t>.
5369         * src/c++11/limits.cc: Define members of
5370         numeric_limits<char8_t>.
5371         * src/c++98/Makefile.am: Compile with -fchar8_t when compiling
5372         locale_init.cc and localename.cc.
5373         * src/c++98/Makefile.in: Likewise.
5374         * src/c++98/locale_init.cc: Add initialization for the
5375         codecvt<char16_t, char8_t, mbstate_t> and
5376         codecvt<char32_t, char8_t, mbstate_t> facets.
5377         * src/c++98/localename.cc: Likewise.
5378         * testsuite/util/testsuite_abi.cc: Validate ABI bump.
5379
5380 2019-02-18  Wilco Dijkstra  <wdijkstr@arm.com>
5381
5382         * 27_io/filesystem/operations/all.cc: Add dg-require-filesystem-ts.
5383         * 27_io/filesystem/operations/resize_file.cc: Likewise.
5384         * 27_io/filesystem/path/generation/normal2.cc: Likewise.
5385
5386 2019-02-14  Jonathan Wakely  <jwakely@redhat.com>
5387
5388         * doc/xml/manual/status_cxx2020.xml: Update P0887R1 status.
5389         * doc/html/*: Regenerate.
5390
5391         * doc/xml/manual/status_cxx2017.xml: Add P0063R3 to status table.
5392         * doc/html/*: Regenerate.
5393
5394         * doc/xml/manual/intro.xml: Document LWG 2586 status.
5395         * include/bits/uses_allocator.h (__uses_alloc): Use const lvalue
5396         allocator type in is_constructible checks.
5397         * testsuite/20_util/scoped_allocator/69293_neg.cc: Adjust dg-error.
5398         * testsuite/20_util/scoped_allocator/dr2586.cc: New test.
5399         * testsuite/20_util/tuple/cons/allocators.cc: Add test using
5400         problematic type from LWG 2586 discussion.
5401         * testsuite/20_util/uses_allocator/69293_neg.cc: Adjust dg-error.
5402         * testsuite/20_util/uses_allocator/cons_neg.cc: Likewise.
5403
5404         * configure.ac: Check for C11 timespec_get function.
5405         * crossconfig.m4 (freebsd, linux, gnu, cygwin, solaris, netbsd)
5406         (openbsd): Likewise
5407         * config.h.in: Regenerate.
5408         * configure: Regenerate.
5409         * include/c_global/ctime (timespec, timespec_get): Add to namespace
5410         std for C++17 and up.
5411
5412         * doc/xml/manual/intro.xml: Document LWG 2537 status.
5413         * include/bits/stl_queue.h
5414         (priority_queue(const Compare&, const Container&, const Alloc&))
5415         (priority_queue(const Compare&, Container&&, const Alloc&)): Call
5416         make_heap.
5417         * testsuite/23_containers/priority_queue/dr2537.cc: New test.
5418
5419         * doc/xml/manual/intro.xml: Document LWG 2566 status.
5420         * include/bits/stl_queue.h (queue, priority_queue): Add static
5421         assertions to enforce LWG 2566 requirement on value_type.
5422         * include/bits/stl_stack.h (stack): Likewise.
5423
5424         PR middle-end/89303
5425         * testsuite/20_util/enable_shared_from_this/89303.cc: New test.
5426
5427         * doc/xml/manual/intro.xml: Document LWG 2735 status.
5428         * include/bits/std_abs.h: Add comment about LWG 2735.
5429         * testsuite/26_numerics/headers/cstdlib/dr2735.cc: New test.
5430
5431 2019-02-13  Jonathan Wakely  <jwakely@redhat.com>
5432
5433         PR libstdc++/89345
5434         * include/std/version [__cpp_impl_destroying_delete]
5435         (__cpp_lib_destroying_delete): Only define for C++2a and later.
5436         * libsupc++/new [__cpp_impl_destroying_delete]
5437         (__cpp_lib_destroying_delete): Likewise.
5438         (destroying_delete_t, destroying_delete): Likewise, but define even
5439         when __cpp_impl_destroying_delete is not defined.
5440         * testsuite/18_support/destroying_delete.cc: New test.
5441
5442 2019-02-11  Jonathan Wakely  <jwakely@redhat.com>
5443
5444         PR libstdc++/89023
5445         * testsuite/17_intro/headers/c++2011/parallel_mode.cc: New test.
5446         * testsuite/17_intro/headers/c++2014/parallel_mode.cc: New test.
5447         * testsuite/17_intro/headers/c++2017/parallel_mode.cc: New test.
5448         * testsuite/28_regex/headers/regex/parallel_mode.cc: Remove.
5449
5450 2019-02-09  Jonathan Wakely  <jwakely@redhat.com>
5451
5452         PR libstdc++/71044
5453         * include/bits/fs_path.h (path::has_root_name)
5454         (path::has_root_directory, path::has_root_path)
5455         (path::has_relative_path, path::has_parent_path)
5456         (path::has_filename, path::has_stem, path::has_extension)
5457         (path::is_absolute, path::is_relative, path::_M_find_extension): Add
5458         noexcept.
5459         * src/c++17/fs_path.cc (path::has_root_name)
5460         (path::has_root_directory, path::has_root_path)
5461         (path::has_relative_path, path::has_parent_path)
5462         (path::has_filename, path::_M_find_extension): Add noexcept.
5463
5464 2019-02-06  Jonathan Wakely  <jwakely@redhat.com>
5465
5466         PR libstdc++/89102 (partial)
5467         * include/std/type_traits (common_type<>): Define.
5468         (common_type<T>): Derive from common_type<T, T>.
5469         * testsuite/20_util/common_type/requirements/explicit_instantiation.cc:
5470         Test zero-length template argument list.
5471         * testsuite/20_util/common_type/requirements/sfinae_friendly_1.cc:
5472         Test additional single argument cases.
5473         * testsuite/20_util/common_type/requirements/sfinae_friendly_2.cc:
5474         Adjust expected error.
5475
5476 2019-02-05  Jonathan Wakely  <jwakely@redhat.com>
5477
5478         PR libstdc++/89128
5479         * include/bits/stl_queue.h (queue, priority_queue): Add deduction
5480         guides.
5481         * include/bits/stl_stack.h (stack): Likewise.
5482         * testsuite/23_containers/priority_queue/deduction.cc: New test.
5483         * testsuite/23_containers/queue/deduction.cc: New test.
5484         * testsuite/23_containers/stack/deduction.cc: New test.
5485
5486         PR libstdc++/89194
5487         * include/std/type_traits (__is_convertible_helper)
5488         (__is_convertible_helper<_From, _To, false>): Revert changes to
5489         support is_nothrow_convertible.
5490         (__is_nt_convertible_helper): New helper.
5491         (is_nothrow_convertible): Use __is_nt_convertible_helper.
5492
5493         * testsuite/23_containers/vector/modifiers/push_back/49836.cc: Restore
5494         use of CopyConsOnlyType, but also test DelAnyAssign for completeness.
5495
5496         PR libstdc++/89130
5497         * include/bits/alloc_traits.h (__is_copy_insertable_impl): Rename to
5498         __is_alloc_insertable_impl. Replace single type member with two
5499         members, one for each of copy and move insertable.
5500         (__is_move_insertable): New trait for internal use.
5501         * include/bits/stl_vector.h (vector::_S_nothrow_relocate(true_type))
5502         (vector::_S_nothrow_relocate(true_type)): New functions to
5503         conditionally check if __relocate_a can throw.
5504         (vector::_S_use_relocate()): Dispatch to _S_nothrow_relocate based
5505         on __is_move_insertable.
5506         (vector::_S_do_relocate): New overloaded functions to conditionally
5507         call __relocate_a.
5508         (vector::_S_relocate): New function that dispatches to _S_do_relocate
5509         based on _S_use_relocate.
5510         * include/bits/vector.tcc (vector::reserve, vector::_M_realloc_insert)
5511         (vector::_M_default_append): Call _S_relocate instead of __relocate_a.
5512         * testsuite/23_containers/vector/modifiers/push_back/89130.cc: New.
5513
5514         PR libstdc++/89090
5515         * include/bits/stl_uninitialized.h (__relocate_a_1): Make unused
5516         parameter unnamed. Add message to static assertion.
5517         * include/bits/vector.tcc (vector::reserve, vector::_M_realloc_insert)
5518         (vector::_M_default_append): Use _GLIBCXX17_CONSTEXPR for if constexpr
5519         in C++11 code.
5520
5521 2019-02-05  Marc Glisse  <marc.glisse@inria.fr>
5522
5523         PR libstdc++/87106
5524         * include/bits/stl_uninitialized.h (__is_trivially_relocatable):
5525         Rename...
5526         (__is_bitwise_relocatable): ... to this.
5527         (__relocate_a_1): Adapt.
5528         * include/bits/stl_deque.h (__is_trivially_relocatable): Rename...
5529         (__is_bitwise_relocatable): ... to this.
5530
5531 2019-01-30  Jonathan Wakely  <jwakely@redhat.com>
5532
5533         PR libstdc++/89117
5534         * src/c++17/fs_path.cc (path::replace_extension): Erase extension from
5535         final component as well as from _M_pathname. Append the dot using
5536         operator+= instead of only to _M_pathname.
5537         (path::_M_find_extension): Reformat slightly.
5538         * testsuite/27_io/filesystem/path/modifiers/replace_extension.cc:
5539         Add more test cases.
5540
5541 2019-01-30  Ulrich Drepper  <drepper@redhat.com>
5542
5543         * doc/xml/manual/status_cxx2020.xml: Update P0600 entry.
5544
5545 2019-01-29  Jonathan Wakely  <jwakely@redhat.com>
5546
5547         * testsuite/26_numerics/headers/complex/synopsis.cc: Remove incorrect
5548         constexpr specifiers from arg and proj.
5549
5550         * config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Add missing exports for
5551         __shared_ptr instantiations used by gcc4-compatible ABI.
5552
5553         * include/experimental/forward_list (experimental::erase): Qualify
5554         call to erase_if.
5555         * include/experimental/list (experimental::erase): Likewise.
5556         * include/std/forward_list (std::erase): Likewise.
5557         * include/std/list (std::erase): Likewise.
5558
5559         * testsuite/20_util/reference_wrapper/result_type.cc: Disable for
5560         C++2a.
5561         * testsuite/20_util/reference_wrapper/typedefs-2.cc: Likewise.
5562         * testsuite/20_util/reference_wrapper/typedefs-3.cc: Likewise.
5563         * testsuite/20_util/reference_wrapper/typedefs.cc: Likewise.
5564         * testsuite/30_threads/async/54297.cc: Suppress nodiscard warning.
5565         * testsuite/ext/array_allocator/26875.cc: Likewise.
5566         * testsuite/ext/pool_allocator/allocate_chunk.cc: Likewise.
5567         * testsuite/util/replacement_memory_operators.h: Likewise.
5568         * testsuite/util/testsuite_allocator.h: Likewise.
5569
5570         * include/std/memory_resource (__pool_resource::_M_unpooled): Use
5571         normal mode vector, even for debug mode.
5572         * include/std/vector [_GLIBCXX_DEBUG] (_GLIBCXX_STD_C::pmr::vector):
5573         Define alias template for normal mode vector.
5574
5575 2019-01-28  Jonathan Wakely  <jwakely@redhat.com>
5576
5577         PR libstdc++/68737
5578         * config/locale/generic/c_locale.h (__convert_from_v)
5579         [_GLIBCXX_USE_C99_STDIO]: Also check _GLIBCXX_HAVE_BROKEN_VSNPRINTF.
5580         * config/os/hpux/os_defines.h: Define _GLIBCXX_HAVE_BROKEN_VSNPRINTF.
5581         * include/bits/locale_facets.tcc (num_put::_M_insert_float)
5582         [_GLIBCXX_USE_C99_STDIO]: Also check _GLIBCXX_HAVE_BROKEN_VSNPRINTF.
5583
5584 2019-01-24  Jonathan Wakely  <jwakely@redhat.com>
5585
5586         PR libstdc++/88840
5587         * include/bits/stl_vector.h (vector::__use_relocate): Replace static
5588         data member with static member function _S_use_relocate().
5589         * include/bits/vector.tcc (vector::reserve, vector::_M_realloc_insert)
5590         (vector::_M_default_append): Use _S_use_relocate() instead of
5591         __use_relocate.
5592
5593         * testsuite/27_io/filesystem/path/compare/strings.cc: Only compare
5594         sign of results.
5595
5596 2019-01-22  Jonathan Wakely  <jwakely@redhat.com>
5597
5598         PR libstdc++/88740
5599         * testsuite/util/testsuite_hooks.h [stderr] (VERIFY): Use fprintf to
5600         write to stderr instead of using printf.
5601
5602 2019-01-21  Jakub Jelinek  <jakub@redhat.com>
5603
5604         PR libstdc++/86590
5605         * include/bits/char_traits.h (__constant_string_p,
5606         __constant_char_array_p): Use __builtin_is_constant_evaluated if
5607         available.
5608
5609 2019-01-20  Ulrich Drepper  <drepper@redhat.com>
5610
5611         Implement C++20 P0600r1.
5612         * include/backward/hash_map: Add nodiscard attribute to empty.
5613         * include/backward/hash_set: Likewise.
5614         * backward/hashtable.h: Likewise.
5615         * include/bits/basic_string.h: Likewise.
5616         * include/bits/forward_list.h: Likewise.
5617         * include/bits/hashtable.h: Likewise.
5618         * include/bits/regex.h: Likewise.
5619         * include/bits/stl_deque.h: Likewise.
5620         * include/bits/stl_list.h: Likewise.
5621         * include/bits/stl_map.h: Likewise.
5622         * include/bits/stl_multimap.h: Likewise.
5623         * include/bits/stl_multiset.h: Likewise.
5624         * include/bits/stl_queue.h: Likewise.
5625         * include/bits/stl_set.h: Likewise.
5626         * include/bits/stl_stack.h: Likewise.
5627         * include/bits/stl_tree.h: Likewise.
5628         * include/bits/stl_vector.h: Likewise.
5629         * include/bits/unordered_map.h: Likewise.
5630         * include/bits/unordered_set.h: Likewise.
5631         * include/debug/array: Likewise.
5632         * include/experimental/any: Likewise.
5633         * include/experimental/bits/fs_path.h: Likewise.
5634         * include/experimental/internet: Likewise.
5635         * include/experimental/string_view: Likewise.
5636         * include/ext/pb_ds/detail/bin_search_tree_/info_fn_imps.hpp:
5637         Likewise.
5638         * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp:
5639         Likewise.
5640         * include/ext/pb_ds/detail/binary_heap_/info_fn_imps.hpp:
5641         Likewise.
5642         * include/ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp:
5643         Likewise.
5644         * include/ext/pb_ds/detail/cc_hash_table_map_/info_fn_imps.hpp:
5645         Likewise.
5646         * include/ext/pb_ds/detail/cc_hash_table_map_/size_fn_imps.hpp:
5647         Likewise.
5648         * include/ext/pb_ds/detail/gp_hash_table_map_/gp_ht_map_.hpp:
5649         Likewise.
5650         * include/ext/pb_ds/detail/gp_hash_table_map_/info_fn_imps.hpp:
5651         Likewise.
5652         * include/ext/pb_ds/detail/left_child_next_sibling_heap_/
5653         info_fn_imps.hpp: Likewise.
5654         * include/ext/pb_ds/detail/left_child_next_sibling_heap_/
5655         left_child_next_sibling_heap_.hpp: Likewise.
5656         * include/ext/pb_ds/detail/list_update_map_/info_fn_imps.hpp:
5657         Likewise.
5658         * include/ext/pb_ds/detail/list_update_map_/lu_map_.hpp:
5659         Likewise.
5660         * include/ext/pb_ds/detail/ov_tree_map_/info_fn_imps.hpp:
5661         Likewise.
5662         * include/ext/pb_ds/detail/ov_tree_map_/ov_tree_map_.hp:
5663         Likewise.
5664         * include/ext/pb_ds/detail/pat_trie_/info_fn_imps.hpp:
5665         Likewise.
5666         * include/ext/pb_ds/detail/pat_trie_/pat_trie_.hpp:
5667         Likewise.
5668         * include/ext/pb_ds/detail/rc_binomial_heap_/rc.hpp:
5669         Likewise.
5670         * include/ext/pb_ds/detail/tree_trace_base.hpp: Likewise.
5671         * include/ext/pb_ds/trie_policy.hpp: Likewise.
5672         * include/ext/rope: Likewise.
5673         * include/ext/slist: Likewise.
5674         * include/ext/vstring.h: Likewise.
5675         * include/profile/array: Likewise.
5676         * include/std/array: Likewise.
5677         * include/tr1/array: Likewise.
5678         * include/tr1/hashtable.h: Likewise.
5679         * include/tr1/regex: Likewise.
5680         * include/tr2/dynamic_bitset: Likewise.
5681         * include/bits/alloc_traits.h: Add nodiscard attribute to
5682         allocate.
5683         * include/experimental/memory_resource: Likewise.
5684         * include/ext/alloc_traits.h: Likewise.
5685         * include/ext/array_allocator.h: Likewise.
5686         * include/ext/bitmap_allocator.h: Likewise.
5687         * include/ext/debug_allocator.h: Likewise.
5688         * include/ext/extptr_allocator.h: Likewise.
5689         * include/ext/mt_allocator.h: Likewise.
5690         * include/ext/new_allocator.h: Likewise.
5691         * include/ext/pool_allocator.h: Likewise.
5692         * include/ext/throw_allocator.h: Likewise.
5693         * include/std/scoped_allocator: Likewise.
5694         * libsupc++/eh_alloc.cc: Likewise.
5695         * include/std/future: Add nodiscard attribute to async.
5696         * libsupc++/new: Add nodiscard attribute to new.
5697
5698 2019-01-18  Jonathan Wakely  <jwakely@redhat.com>
5699
5700         PR libstdc++/87514
5701         PR libstdc++/87520
5702         PR libstdc++/88782
5703         * config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Export new symbol.
5704         * include/bits/shared_ptr.h
5705         (shared_ptr(_Sp_make_shared_tag, const Alloc&, Args&&...))
5706         (allocate_shared): Change to use new tag type.
5707         * include/bits/shared_ptr_base.h (_Sp_make_shared_tag::_S_eq):
5708         Declare new member function.
5709         (_Sp_alloc_shared_tag): Define new type.
5710         (_Sp_counted_ptr_inplace): Declare __shared_count<_Lp> as a friend.
5711         (_Sp_counted_ptr_inplace::_M_get_deleter) [!__cpp_rtti]: Use
5712         _Sp_make_shared_tag::_S_eq to check type_info.
5713         (__shared_count(Ptr, Deleter),__shared_count(Ptr, Deleter, Alloc)):
5714         Constrain to prevent being called with _Sp_alloc_shared_tag.
5715         (__shared_count(_Sp_make_shared_tag, const _Alloc&, Args&&...)):
5716         Replace constructor with ...
5717         (__shared_count(Tp*&, _Sp_alloc_shared_tag<_Alloc>, Args&&...)): Use
5718         reference parameter so address of the new object can be returned to
5719         the caller. Obtain the allocator from the tag type.
5720         (__shared_ptr(_Sp_make_shared_tag, const Alloc&, Args&&...)): Replace
5721         constructor with ...
5722         (__shared_ptr(_Sp_alloc_shared_tag<Alloc>, Args&&...)): Pass _M_ptr
5723         to the __shared_count constructor.
5724         (__allocate_shared): Change to use new tag type.
5725         * src/c++11/shared_ptr.cc (_Sp_make_shared_tag::_S_eq): Define.
5726
5727 2019-01-17  Jonathan Wakely  <jwakely@redhat.com>
5728
5729         * src/c++17/fs_ops.cc
5730         (equivalent(const path&, const path&, error_code&))
5731         [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Use GetFileInformationByHandle to
5732         compare files instead of relying on incomplete info returned by stat.
5733
5734         PR libstdc++/88884
5735         * src/c++17/fs_ops.cc (absolute(const path&, error_code&)): Do nothing
5736         if the path is already absolute.
5737         [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Normalize root-directory.
5738         [!_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Pass error_code to current_path.
5739
5740         PR libstdc++/88881
5741         * src/c++17/fs_ops.cc (canonical(const path&, error_code&))
5742         [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Normalize path, to match behaviour
5743         of filesystem::exists.
5744         (create_directories(const path&, error_code&)): Add assertions.
5745         (status(const path&, error_code&)) [_GLIBCXX_FILESYSTEM_IS_WINDOWS]:
5746         Add workaround for bug in _wstat for paths with trailing slash.
5747         * testsuite/27_io/filesystem/operations/create_directories.cc: Adjust
5748         for expected behaviour on mingw.
5749         * testsuite/experimental/filesystem/operations/create_directories.cc:
5750         Likewise.
5751         * testsuite/27_io/filesystem/operations/temp_directory_path.cc: Use
5752         "TMP" instead of "TMPDIR" and clean environment before each test. Do
5753         not test permissions on mingw targets.
5754
5755 2019-01-16  Jonathan Wakely  <jwakely@redhat.com>
5756
5757         * config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Add exports for fstream
5758         constructors and open members taking wide strings. Fix patterns for
5759         filesystem::path members to match wstring_view parameters. Add
5760         exports for shared_ptr members used by directory iterators.
5761         * src/c++17/fs_ops.cc (remove(const path&, error_code&)): Clear the
5762         error code parameter if the file doesn't exist.
5763         * src/filesystem/ops.cc (remove(const path&, error_code&)):
5764         Likewise.
5765         * testsuite/27_io/filesystem/operations/canonical.cc: Fix expected
5766         values for mingw targets, where "/" is not an absolute path. Do not
5767         test symlinks on mingw targets.
5768         * testsuite/experimental/filesystem/operations/canonical.cc: Likewise.
5769         * testsuite/27_io/filesystem/operations/copy.cc: Do not test symlinks
5770         on mingw targets.
5771         * testsuite/experimental/filesystem/operations/copy.cc: Likewise.
5772         * testsuite/27_io/filesystem/operations/create_directories.cc: Check
5773         that each component of the path is created.
5774         * testsuite/experimental/filesystem/operations/create_directories.cc:
5775         Likewise.
5776         * testsuite/27_io/filesystem/operations/exists.cc: Do not test
5777         permissions on mingw targets.
5778         * testsuite/experimental/filesystem/operations/exists.cc: Likewise.
5779         * testsuite/27_io/filesystem/operations/is_empty.cc: Likewise.
5780         * testsuite/experimental/filesystem/operations/is_empty.cc: Likewise.
5781         * testsuite/27_io/filesystem/operations/permissions.cc: XFAIL for
5782         mingw targets.
5783         * testsuite/experimental/filesystem/operations/permissions.cc:
5784         Likewise.
5785         * testsuite/27_io/filesystem/operations/remove.cc: Do not test
5786         symlinks or permissions on mingw targets.
5787         * testsuite/experimental/filesystem/operations/remove.cc: Likewise.
5788         * testsuite/27_io/filesystem/operations/remove_all.cc: Do not test
5789         symlinks on mingw targets.
5790         * testsuite/experimental/filesystem/operations/remove_all.cc:
5791         Likewise.
5792         * testsuite/27_io/filesystem/operations/status.cc: Do not test
5793         permissions on mingw targets.
5794         * testsuite/27_io/filesystem/operations/weakly_canonical.cc: Do not
5795         test symlinks on mingw targets.
5796         * testsuite/experimental/filesystem/operations/space.cc: Fix test
5797         for mingw targets.
5798
5799 2019-02-14  Ulrich Drepper  <drepper@redhat.com>
5800
5801         PR libstdc++/88738
5802         Warn about unused comparisons of shared_ptr/unique_ptr
5803         * include/bits/c++config [_GLIBCXX_NODISCARD]: Define.
5804         * include/bits/shared_ptr.h: Use it for operator ==, !=,
5805         <, <=, >, >= for shared_ptr.
5806         * include/bits/unique_ptr.h: Likewise for unique_ptr.
5807
5808 2019-01-15  Jonathan Wakely  <jwakely@redhat.com>
5809
5810         * include/bits/shared_ptr_base.h (__cpp_lib_shared_ptr_arrays): Define
5811         as 201611L, because P0497R0 changes are supported.
5812         * include/std/version (__cpp_lib_shared_ptr_arrays): Likewise.
5813
5814         * include/bits/erase_if.h [__cplusplus > 201703L]
5815         (__cpp_lib_erase_if): Only define for C++2a.
5816         * include/std/iterator [__cplusplus >= 201402L && !_GLIBCXX_DEBUG]
5817         (__cpp_lib_null_iterators): Define.
5818         * include/std/version [__cplusplus >= 201402L && !_GLIBCXX_DEBUG]
5819         (__cpp_lib_null_iterators): Define.
5820         [__cpp_impl_destroying_delete] (__cpp_lib_destroying_delete): Define.
5821
5822         * doc/xml/manual/status_cxx2017.xml: Document P0032R3 and P0307R2
5823         status.
5824         * include/bits/stl_uninitialized.h (__cpp_lib_raw_memory_algorithms):
5825         Define.
5826         * include/std/any (__cpp_lib_any): Define as 201606L, because P0032R3
5827         changes are supported.
5828         * include/std/optional (__cpp_lib_optional): Likewise.
5829         * include/std/variant (__cpp_lib_variant): Likewise.
5830         * include/std/version [!__STRICT_ANSI__]
5831         (__cpp_lib_uncaught_exceptions): Define as long integer.
5832         [__cplusplus >= 201703L] (__cpp_lib_any)
5833         (__cpp_lib_raw_memory_algorithms, __cpp_lib_uncaught_exceptions)
5834         (__cpp_lib_variant): Define for C++17.
5835         [__cplusplus >= 201703L] (__cpp_lib_optional): Update value and define
5836         as long integer.
5837         * libsupc++/exception (__cpp_lib_uncaught_exceptions): Define as long
5838         integer.
5839
5840         * doc/xml/manual/status_cxx2020.xml: Update P1123R0 status.
5841
5842 2019-01-12  Jonathan Wakely  <jwakely@redhat.com>
5843
5844         PR libstdc++/88811
5845         PR libstdc++/83306
5846         * src/filesystem/path.cc: Fix typo. If first path is empty, show []
5847         before second path.
5848         * testsuite/experimental/filesystem/filesystem_error/cons.cc: New
5849         test.
5850
5851 2019-01-11  Jonathan Wakely  <jwakely@redhat.com>
5852
5853         * doc/xml/manual/intro.xml: Include new section.
5854         * doc/xml/manual/status_cxx2017.xml: Document more
5855         implementation-defined properties of the library.
5856         * doc/xml/manual/status_cxx2020.xml: Document C++2a status.
5857         * doc/html/*: Regenerate.
5858
5859         * include/bits/refwrap.h [__cplusplus > 201703L]
5860         (_Refwrap_base_arg1, _Refwrap_base_arg2, _Reference_wrapper_base)
5861         (_Reference_wrapper_base_memfun): Do not define for C++2a.
5862         (reference_wrapper): Do not derive from _Reference_wrapper_base_memfun
5863         for C++2a.
5864         (reference_wrapper::operator()): Add static assertion.
5865         * testsuite/20_util/reference_wrapper/incomplete.cc: New test.
5866
5867         * include/std/chrono (duration_values::zero(), duration_values::min())
5868         (duration_values::max()): Add noexcept.
5869         (duration::zero(), duration::min(), duration::max()): Likewise.
5870         (time_point::zero(), time_point::min(), time_point::max()): Likewise.
5871         * testsuite/20_util/duration/requirements/noexcept.cc: New test.
5872         * testsuite/20_util/time_point/requirements/noexcept.cc: New test.
5873
5874         * include/std/version (__cpp_lib_erase_if): Move to C++20 group.
5875
5876 2019-01-11  Jakub Jelinek  <jakub@redhat.com>
5877
5878         * include/std/type_traits (__cpp_lib_is_constant_evaluated): Define.
5879         * include/std/version (__cpp_lib_is_constant_evaluated): Define.
5880
5881 2019-01-11  Jonathan Wakely  <jwakely@redhat.com>
5882
5883         PR libstdc++/88802
5884         * include/bits/functional_hash.h (hash<nullptr_t>): Define
5885         specialization for C++17 (P0513R0, LWG 2817).
5886         * testsuite/20_util/hash/nullptr.cc: New test.
5887
5888         PR libstdc++/88125
5889         * config/abi/pre/gnu.ver (GLIBCXX_3.4.6): Remove unused duplicate
5890         pattern for std::basic_stringbuf::str().
5891
5892         * config/abi/pre/gnu.ver (GLIBCXX_3.4): Correct recent changes to
5893         basic_ostream::operator<< patterns.
5894
5895 2019-01-10  Jonathan Wakely  <jwakely@redhat.com>
5896
5897         * testsuite/27_io/filesystem/operations/last_write_time.cc: Fix
5898         test failures on targets with 32-bit time_t.
5899
5900         * include/bits/erase_if.h: Define __cpp_lib_erase_if.
5901         * include/std/deque: Likewise.
5902         * include/std/forward_list: Likewise.
5903         * include/std/list: Likewise.
5904         * include/std/string: Likewise.
5905         * include/std/vector: Likewise.
5906         * include/std/version: Likewise.
5907         * testsuite/21_strings/basic_string/erasure.cc: Test macro.
5908         * testsuite/23_containers/deque/erasure.cc: Likewise.
5909         * testsuite/23_containers/forward_list/erasure.cc: Likewise.
5910         * testsuite/23_containers/list/erasure.cc: Likewise.
5911         * testsuite/23_containers/map/erasure.cc: Likewise.
5912         * testsuite/23_containers/set/erasure.cc: Likewise.
5913         * testsuite/23_containers/unordered_map/erasure.cc: Likewise.
5914         * testsuite/23_containers/unordered_set/erasure.cc: Likewise.
5915         * testsuite/23_containers/vector/erasure.cc: Likewise.
5916
5917         * include/experimental/internet [AI_NUMERICSERV]
5918         (resolver_base::numeric_service): Define conditionally.
5919         * testsuite/experimental/net/internet/resolver/base.cc: Test it
5920         conditionally.
5921         * testsuite/experimental/net/internet/resolver/ops/lookup.cc:
5922         Likewise.
5923
5924 2019-01-10  Ville Voutilainen  <ville.voutilainen@gmail.com>
5925             Jonathan Wakely  <jwakely@redhat.com>
5926
5927         Implement LWG 2221
5928         * config/abi/pre/gnu.ver (GLIBCXX_3.4): Tighten patterns.
5929         (GLIBCXX_3.4.26): Add new exports.
5930         * include/Makefile.am: Add ostream-inst.cc. Move string-inst.cc to
5931         correct list of sources.
5932         * include/Makefile.in: Regenerate.
5933         * include/std/ostream (operator<<(nullptr_t)): New member function.
5934         * src/c++17/ostream-inst.cc: New file.
5935         * testsuite/27_io/basic_ostream/inserters_other/char/lwg2221.cc: New
5936         test.
5937
5938 2019-01-10  Jonathan Wakely  <jwakely@redhat.com>
5939
5940         * testsuite/util/testsuite_fs.h (nonexistent_path): Include name
5941         of the source file containing the caller.
5942         * testsuite/27_io/filesystem/iterators/directory_iterator.cc: Remove
5943         directories created by test.
5944         * testsuite/27_io/filesystem/iterators/recursive_directory_iterator.cc:
5945         Likewise.
5946         * testsuite/experimental/filesystem/iterators/directory_iterator.cc:
5947         Likewise.
5948         * testsuite/experimental/filesystem/iterators/
5949         recursive_directory_iterator.cc: Likewise.
5950
5951 2019-01-10  Jakub Jelinek  <jakub@redhat.com>
5952
5953         PR tree-optimization/88775
5954         * include/bits/stl_function.h (greater<_Tp*>::operator(),
5955         less<_Tp*>::operator(), greater_equal<_Tp*>::operator(),
5956         less_equal<_Tp*>::operator()): Use __builtin_is_constant_evaluated
5957         instead of __builtin_constant_p if available.  Don't bother with
5958         the pointer comparison in C++11 and earlier.
5959
5960 2019-01-09  Sandra Loosemore  <sandra@codesourcery.com>
5961
5962         PR other/16615
5963
5964         * include/ext/bitmap_allocator.h: Mechanically replace "can not"
5965         with "cannot".
5966
5967 2019-01-09  Jonathan Wakely  <jwakely@redhat.com>
5968
5969         * testsuite/libstdc++-prettyprinters/cxx17.cc: Fix expected output
5970         for filesystem::path. Give variables more distinctive names.
5971
5972         * include/std/optional (_Optional_payload_base::_M_copy_assign): New
5973         member function to perform non-trivial assignment.
5974         (_Optional_payload_base::_M_move_assign): Likewise.
5975         (_Optional_payload<T, true, false, true>::operator=)
5976         (_Optional_payload<T, true, true, false>::operator=)
5977         (_Optional_payload<T, true, false, false>::operator=): Call
5978         _M_copy_assign and/or _M_move_assign to do non-trivial assignments.
5979
5980         PR libstdc++/88204
5981         * testsuite/26_numerics/complex/operators/more_constexpr.cc: Do not
5982         test std::complex<long double> if long double format is IBM128.
5983         * testsuite/26_numerics/complex/requirements/more_constexpr.cc:
5984         Likewise.
5985
5986 2019-01-08  Jonathan Wakely  <jwakely@redhat.com>
5987
5988         * testsuite/libstdc++-prettyprinters/compat.cc: Test printer support
5989         for old std::unique_ptr layout.
5990         * testsuite/libstdc++-prettyprinters/cxx17.cc: Fix std::variant test
5991         to become valueless. Add filesystem::path tests.
5992
5993         PR libstdc++/87855
5994         * include/std/optional (_Optional_payload_base): New class template
5995         for common code hoisted from _Optional_payload specializations. Use
5996         a template for the union, to allow a partial specialization for
5997         types with non-trivial destructors. Add constructors for in-place
5998         initialization to the union.
5999         (_Optional_payload(bool, const _Optional_payload&)): Use _M_construct
6000         to perform non-trivial copy construction, instead of relying on
6001         non-standard copy elision in a delegating constructor.
6002         (_Optional_payload(bool, _Optional_payload&&)): Likewise for
6003         non-trivial move construction.
6004         (_Optional_payload): Derive from _Optional_payload_base and use it
6005         for everything except the non-trivial assignment operators, which are
6006         defined as needed.
6007         (_Optional_payload<false, C, M>): Derive from the specialization
6008         _Optional_payload<true, false, false> and add a destructor.
6009         (_Optional_base_impl::_M_destruct, _Optional_base_impl::_M_reset):
6010         Forward to corresponding members of _Optional_payload.
6011         (_Optional_base_impl::_M_is_engaged, _Optional_base_impl::_M_get):
6012         Hoist common members from _Optional_base.
6013         (_Optional_base): Make all members and base class public.
6014         (_Optional_base::_M_get, _Optional_base::_M_is_engaged): Move to
6015         _Optional_base_impl.
6016         * python/libstdcxx/v6/printers.py (StdExpOptionalPrinter): Add
6017         support for new std::optional layout.
6018         * testsuite/libstdc++-prettyprinters/compat.cc: New test.
6019
6020         PR libstdc++/88066
6021         * include/bits/locale_conv.h: Use <> for includes not "".
6022         * include/ext/random: Likewise.
6023         * include/ext/vstring.h: Likewise.
6024
6025 2019-01-08  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
6026
6027         * config/abi/pre/gnu.ver (GLIBCXX_3.4): Tighten existing patterns.
6028         (GLIBCXX_3.4.21): Likewise.
6029
6030 2019-01-08  Jonathan Wakely  <jwakely@redhat.com>
6031
6032         PR libstdc++/88749
6033         * src/filesystem/ops.cc (last_write_time): Fix preprocessor condition
6034         to match the one that controls whether utimbuf and utime are declared.
6035
6036 2019-01-07  Jonathan Wakely  <jwakely@redhat.com>
6037
6038         PR libstdc++/87787
6039         * include/bits/char_traits.h (char_traits::move): Do not pass null
6040         pointers to memmove.
6041         * include/bits/locale_facets.h
6042         (ctype<char>::widen(const char*, const char*, char*)): Do not
6043         pass null pointers to memcpy.
6044         (ctype<char>::narrow(const char*, const char*, char, char*)):
6045         Likewise.
6046         (ctype<char>::do_widen(const char*, const char*, char*)):
6047         Likewise.
6048         (ctype<char>::do_narrow(const char*, const char*, char, char*)):
6049         Likewise.
6050
6051         * doc/xml/manual/spine.xml: Update copyright years.
6052         * doc/xml/manual/status_cxx2017.xml: Adjust note about -lstdc++fs.
6053         * doc/xml/manual/using.xml: Remove requirement to link with -lstdc++fs
6054         for C++17 filesystem library.
6055         * doc/html/*: Regenerate.
6056
6057         * acinclude.m4 (GLIBCXX_CHECK_FILESYSTEM_DEPS): Check for truncate.
6058         * config.h.in: Regenerate.
6059         * config/abi/pre/gnu.ver: Order patterns for filesystem operations
6060         alphabetically and add missing entries for copy_symlink,
6061         hard_link_count, rename, and resize_file.
6062         * configure: Regenerate.
6063         * src/c++17/fs_ops.cc (resize_file): Remove #if so posix::truncate is
6064         used unconditionally.
6065         * src/filesystem/ops-common.h (__gnu_posix::truncate)
6066         [!_GLIBCXX_HAVE_TRUNCATE]: Provide fallback definition that only
6067         supports truncating to zero length.
6068         * testsuite/27_io/filesystem/operations/all.cc: New test.
6069         * testsuite/27_io/filesystem/operations/resize_file.cc: New test.
6070
6071 2019-01-06  Jonathan Wakely  <jwakely@redhat.com>
6072
6073         PR libstdc++/86756
6074         * acinclude.m4 (GLIBCXX_CHECK_FILESYSTEM_DEPS): Check for utime and
6075         lstat and define _GLIBCXX_USE_UTIME and _GLIBCXX_USE_LSTAT.
6076         * config.h.in: Regenerate.
6077         * config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Export symbols for
6078         remaining std::filesystem types and functions.
6079         * configure: Regenerate.
6080         * src/c++17/Makefile.am: Add C++17 filesystem sources.
6081         * src/c++17/Makefile.in: Regenerate.
6082         * src/c++17/cow-fs_dir.cc: Move src/filesystem/cow-std-dir.cc to
6083         here, and change name of included file.
6084         * src/c++17/cow-fs_ops.cc: Move src/filesystem/cow-std-ops.cc to
6085         here, and change name of included file.
6086         * src/c++17/fs_dir.cc: Move src/filesystem/std-dir.cc to here. Change
6087         path to dir-common.h.
6088         * src/c++17/fs_ops.cc: Move src/filesystem/std-ops.cc to here. Change
6089         path to ops-common.h. Disable -Wunused-parameter warnings.
6090         (internal_file_clock): Define unconditionally.
6091         [!_GLIBCXX_HAVE_SYS_STAT_H] (internal_file_clock::from_stat): Do not
6092         define.
6093         (do_copy_file, do_space): Move definitions to ops.common.h.
6094         (copy, file_size, hard_link_count, last_write_time, space): Only
6095         perform operation when _GLIBCXX_HAVE_SYS_STAT_H is defined, otherwise
6096         report an error.
6097         (last_write_time, read_symlink): Remove unused attributes from
6098         parameters.
6099         * src/filesystem/Makefile.am: Remove C++17 filesystem sources.
6100         * src/filesystem/Makefile.in: Regenerate.
6101         * src/filesystem/cow-std-dir.cc: Move to src/c++17/cow-fs_dir.cc.
6102         * src/filesystem/cow-std-ops.cc: Move to src/c++17/cow-fs_ops.cc.
6103         * src/filesystem/std-dir.cc: Move to src/c++17/fs_dir.cc.
6104         * src/filesystem/std-ops.cc: Move to src/c++17/fs_ops.cc.
6105         * src/filesystem/dir-common.h [!_GLIBCXX_HAVE_DIRENT_H]: Define
6106         dummy types and functions instead of using #error.
6107         * src/filesystem/dir.cc [!_GLIBCXX_HAVE_DIRENT_H]: Use #error.
6108         * src/filesystem/ops-common.h [!_GLIBCXX_USE_LSTAT] (lstat): Define
6109         in terms of stat.
6110         [!_GLIBCXX_HAVE_UNISTD_H]: Define dummy types and functions.
6111         (do_copy_file, do_space): Move definitions here from std-ops.cc.
6112         * src/filesystem/ops.cc: Adjust calls to do_copy_file and do_space
6113         to account for new namespace.
6114         * testsuite/27_io/filesystem/directory_entry/86597.cc: Remove
6115         -lstdc++fs from dg-options.
6116         * testsuite/27_io/filesystem/directory_entry/lwg3171.cc: Likewise.
6117         * testsuite/27_io/filesystem/file_status/1.cc: Likewise.
6118         * testsuite/27_io/filesystem/filesystem_error/cons.cc: Likewise.
6119         * testsuite/27_io/filesystem/filesystem_error/copy.cc: Likewise.
6120         * testsuite/27_io/filesystem/iterators/directory_iterator.cc:
6121         Likewise.
6122         * testsuite/27_io/filesystem/iterators/pop.cc: Likewise.
6123         * testsuite/27_io/filesystem/iterators/recursive_directory_iterator.cc:
6124         Likewise.
6125         * testsuite/27_io/filesystem/operations/absolute.cc: Likewise.
6126         * testsuite/27_io/filesystem/operations/canonical.cc: Likewise.
6127         * testsuite/27_io/filesystem/operations/copy.cc: Likewise.
6128         * testsuite/27_io/filesystem/operations/copy_file.cc: Likewise.
6129         * testsuite/27_io/filesystem/operations/create_directories.cc:
6130         Likewise.
6131         * testsuite/27_io/filesystem/operations/create_directory.cc: Likewise.
6132         * testsuite/27_io/filesystem/operations/create_symlink.cc: Likewise.
6133         * testsuite/27_io/filesystem/operations/current_path.cc: Likewise.
6134         * testsuite/27_io/filesystem/operations/equivalent.cc: Likewise.
6135         * testsuite/27_io/filesystem/operations/exists.cc: Likewise.
6136         * testsuite/27_io/filesystem/operations/file_size.cc: Likewise.
6137         * testsuite/27_io/filesystem/operations/is_empty.cc: Likewise.
6138         * testsuite/27_io/filesystem/operations/last_write_time.cc: Likewise.
6139         * testsuite/27_io/filesystem/operations/permissions.cc: Likewise.
6140         * testsuite/27_io/filesystem/operations/proximate.cc: Likewise.
6141         * testsuite/27_io/filesystem/operations/read_symlink.cc: Likewise.
6142         * testsuite/27_io/filesystem/operations/relative.cc: Likewise.
6143         * testsuite/27_io/filesystem/operations/remove.cc: Likewise.
6144         * testsuite/27_io/filesystem/operations/remove_all.cc: Likewise.
6145         * testsuite/27_io/filesystem/operations/space.cc: Likewise.
6146         * testsuite/27_io/filesystem/operations/status.cc: Likewise.
6147         * testsuite/27_io/filesystem/operations/symlink_status.cc: Likewise.
6148         * testsuite/27_io/filesystem/operations/temp_directory_path.cc:
6149         Likewise.
6150         * testsuite/27_io/filesystem/operations/weakly_canonical.cc: Likewise.
6151
6152
6153         PR libstdc++/86756
6154         * config/abi/pre/gnu.ver (GLIBCXX_3.4): Make various patterns for
6155         typeinfo and vtables less greedy.
6156         (GLIBCXX_3.4.26): Export symbols for std::filesystem::path.
6157         * src/c++17/Makefile.am: Add fs_path.cc and cow-fs_path.cc.
6158         * src/c++17/Makefile.in: Regenerate.
6159         * src/c++17/cow-fs_path.cc: Move src/filesystem/cow-std-path.cc to
6160         here, and change name of included file.
6161         * src/c++17/fs_path.cc: Move src/filesystem/std-path.cc to here.
6162         * src/filesystem/Makefile.am: Remove std-path.cc and cow-std-path.cc
6163         from sources.
6164         * src/filesystem/Makefile.in: Regenerate.
6165         * src/filesystem/cow-std-path.cc: Move to src/c++17/cow-fs_path.cc.
6166         * src/filesystem/std-path.cc: Move to src/c++17/fs_path.cc.
6167         * testsuite/27_io/filesystem/path/append/path.cc: Remove -lstdc++fs
6168         from dg-options and remove dg-require-filesystem-ts.
6169         * testsuite/27_io/filesystem/path/append/source.cc: Likewise.
6170         * testsuite/27_io/filesystem/path/assign/assign.cc: Likewise.
6171         * testsuite/27_io/filesystem/path/assign/copy.cc: Likewise.
6172         * testsuite/27_io/filesystem/path/compare/compare.cc: Likewise.
6173         * testsuite/27_io/filesystem/path/compare/lwg2936.cc: Likewise.
6174         * testsuite/27_io/filesystem/path/compare/path.cc: Likewise.
6175         * testsuite/27_io/filesystem/path/compare/strings.cc: Likewise.
6176         * testsuite/27_io/filesystem/path/concat/path.cc: Likewise.
6177         * testsuite/27_io/filesystem/path/concat/strings.cc: Likewise.
6178         * testsuite/27_io/filesystem/path/construct/80762.cc: Likewise.
6179         * testsuite/27_io/filesystem/path/construct/copy.cc: Likewise.
6180         * testsuite/27_io/filesystem/path/construct/default.cc: Likewise.
6181         * testsuite/27_io/filesystem/path/construct/format.cc: Likewise.
6182         * testsuite/27_io/filesystem/path/construct/locale.cc: Likewise.
6183         * testsuite/27_io/filesystem/path/construct/range.cc: Likewise.
6184         * testsuite/27_io/filesystem/path/construct/string_view.cc: Likewise.
6185         * testsuite/27_io/filesystem/path/decompose/extension.cc: Likewise.
6186         * testsuite/27_io/filesystem/path/decompose/filename.cc: Likewise.
6187         * testsuite/27_io/filesystem/path/decompose/parent_path.cc: Likewise.
6188         * testsuite/27_io/filesystem/path/decompose/relative_path.cc: Likewise.
6189         * testsuite/27_io/filesystem/path/decompose/root_directory.cc:
6190         Likewise.
6191         * testsuite/27_io/filesystem/path/decompose/root_name.cc: Likewise.
6192         * testsuite/27_io/filesystem/path/decompose/root_path.cc: Likewise.
6193         * testsuite/27_io/filesystem/path/decompose/stem.cc: Likewise.
6194         * testsuite/27_io/filesystem/path/generation/normal.cc: Likewise.
6195         * testsuite/27_io/filesystem/path/generation/normal2.cc: Likewise.
6196         * testsuite/27_io/filesystem/path/generation/proximate.cc: Likewise.
6197         * testsuite/27_io/filesystem/path/generation/relative.cc: Likewise.
6198         * testsuite/27_io/filesystem/path/generic/generic_string.cc: Likewise.
6199         * testsuite/27_io/filesystem/path/itr/components.cc: Likewise.
6200         * testsuite/27_io/filesystem/path/itr/traversal.cc: Likewise.
6201         * testsuite/27_io/filesystem/path/modifiers/clear.cc: Likewise.
6202         * testsuite/27_io/filesystem/path/modifiers/make_preferred.cc:
6203         Likewise.
6204         * testsuite/27_io/filesystem/path/modifiers/remove_filename.cc:
6205         Likewise.
6206         * testsuite/27_io/filesystem/path/modifiers/replace_extension.cc:
6207         Likewise.
6208         * testsuite/27_io/filesystem/path/modifiers/replace_filename.cc:
6209         Likewise.
6210         * testsuite/27_io/filesystem/path/modifiers/swap.cc: Likewise.
6211         * testsuite/27_io/filesystem/path/native/string.cc: Likewise.
6212         * testsuite/27_io/filesystem/path/nonmember/append.cc: Likewise.
6213         * testsuite/27_io/filesystem/path/nonmember/hash_value.cc: Likewise.
6214         * testsuite/27_io/filesystem/path/query/empty.cc: Likewise.
6215         * testsuite/27_io/filesystem/path/query/has_extension.cc: Likewise.
6216         * testsuite/27_io/filesystem/path/query/has_filename.cc: Likewise.
6217         * testsuite/27_io/filesystem/path/query/has_parent_path.cc: Likewise.
6218         * testsuite/27_io/filesystem/path/query/has_relative_path.cc: Likewise.
6219         * testsuite/27_io/filesystem/path/query/has_root_directory.cc:
6220         Likewise.
6221         * testsuite/27_io/filesystem/path/query/has_root_name.cc: Likewise.
6222         * testsuite/27_io/filesystem/path/query/has_root_path.cc: Likewise.
6223         * testsuite/27_io/filesystem/path/query/has_stem.cc: Likewise.
6224         * testsuite/27_io/filesystem/path/query/is_absolute.cc: Likewise.
6225         * testsuite/27_io/filesystem/path/query/is_relative.cc: Likewise.
6226
6227         PR libstdc++/87431
6228         * include/std/variant (_Variant_storage<true, _Types...>::_M_valid):
6229         Check is_trivially_copyable instead of is_scalar.
6230         (variant::emplace<N, Args>(Args&&...)): If construction of the new
6231         contained value can throw and its type is trivially copyable then
6232         construct into a temporary variant and move from it, to provide the
6233         strong exception safety guarantee.
6234         (variant::emplace<N, U, Args>(initializer_list<U>, Args&&...)):
6235         Likewise.
6236         * testsuite/20_util/variant/87431.cc: New test.
6237         * testsuite/20_util/variant/run.cc: Adjust test so that throwing
6238         conversion causes valueless state.
6239
6240         PR libstdc++/88607
6241         * testsuite/17_intro/headers/c++1998/charset.cc: New test.
6242         * testsuite/17_intro/headers/c++2011/charset.cc: New test.
6243         * testsuite/17_intro/headers/c++2014/charset.cc: New test.
6244         * testsuite/17_intro/headers/c++2017/charset.cc: New test.
6245         * testsuite/17_intro/headers/c++2020/charset.cc: New test.
6246
6247 2019-01-05  Jonathan Wakely  <jwakely@redhat.com>
6248
6249         * include/bits/fs_fwd.h (__file_clock): Define new clock.
6250         (file_time_type): Redefine in terms of __file_clock.
6251         * src/filesystem/ops-common.h (file_time): Add FIXME comment about
6252         overflow.
6253         * src/filesystem/std-ops.cc (is_set(perm_options, perm_options)): Give
6254         internal linkage.
6255         (internal_file_lock): New helper type for accessing __file_clock.
6256         (do_copy_file): Use internal_file_lock to convert system time to
6257         file_time_type.
6258         (last_write_time(const path&, error_code&)): Likewise.
6259         (last_write_time(const path&, file_time_type, error_code&)): Likewise.
6260
6261 2019-01-04  Jonathan Wakely  <jwakely@redhat.com>
6262
6263         * config/abi/pre/gnu.ver (GLIBCXX_3.4.21): Make patterns less greedy
6264         for const member functions of std::basic_string.
6265         (GLIBCXX_3.4.26): Export member functions of std::basic_string added
6266         in C++17.
6267         * include/bits/basic_string.h (basic_string(__sv_wrapper, const A&)):
6268         Make non-standard constructor private.
6269         [!_GLIBCXX_USE_CXX11_ABI] (basic_string(__sv_wrapper, const A&)):
6270         Likewise.
6271         * include/bits/basic_string.tcc (std::string, std::wstring): Declare
6272         explicit instantiations for C++17 as well as earlier dialects.
6273         * src/c++17/Makefile.am: Add new source files.
6274         * src/c++17/Makefile.in: Regenerate.
6275         * src/c++17/cow-string-inst.cc: New file defining explicit
6276         instantiations for basic_string member functions added in C++17.
6277         * src/c++17/string-inst.cc: Likewise.
6278
6279         * config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Export allocator-extended
6280         copy/move constructors for old std::basic_string.
6281         * include/bits/basic_string.h [!_GLIBCXX_USE_CXX11_ABI]
6282         (basic_string::reference, basic_string::const_reference): Define
6283         as plain references for C++11 and later.
6284         (basic_string::basic_string()): Put constructor body outside
6285         preprocessor conditional groups.
6286         (basic_string::basic_string(basic_string&&)): Move _Alloc_hider
6287         instead of copying it.
6288         (basic_string::basic_string(const basic_string&, const _Alloc&)):
6289         Define.
6290         (basic_string::basic_string(basic_string&&, const _Alloc&)):
6291         Define.
6292         * include/bits/fs_path.h [!_GLIBCXX_USE_CXX11_ABI]: Remove special
6293         cases for old basic_string.
6294         * testsuite/21_strings/basic_string/cons/char/8.cc: Test
6295         allocator-extended constructors unconditionally. Add extra members to
6296         allocator type when using old string ABI.
6297         * testsuite/21_strings/basic_string/allocator/71964.cc: Enable test
6298         for old string ABI.
6299         * testsuite/21_strings/basic_string/cons/wchar_t/8.cc: Likewise.
6300
6301         * testsuite/23_containers/list/61347.cc: Avoid spurious failure when
6302         -fno-inline added to test flags.
6303
6304         * testsuite/21_strings/basic_string/requirements/
6305         explicit_instantiation/debug.cc: Remove XFAIL for old ABI.
6306
6307         * testsuite/27_io/filesystem/filesystem_error/copy.cc: Fix static
6308         assertion failures with old std::string ABI.
6309
6310         * include/bits/fs_path.h (path::_List::erase): Replace both overloads
6311         with ...
6312         (path::pop_back(), path::_M_erase_from(const_iterator)): New member
6313         functions that will only erase elements at the end.
6314         * src/filesystem/std-path.cc (path::_List::_Impl::pop_back()): Define.
6315         (path::_List::_Impl::_M_erase_from(const_iterator)): Define.
6316         (path::_List::operator=(const _List&)): Use _M_erase_from(p) instead
6317         of erase(p, end()).
6318         (path::_List::pop_back()): Define.
6319         (path::_List::_M_erase_from(const_iterator)): Define.
6320         (path::operator/=(const path&)): Use pop_back to remove last component
6321         and _M_erase_from to remove multiple components.
6322         (path::_M_append(basic_string_view<value_type>)): Likewise.
6323         (path::operator+=(const path&)): Likewise.
6324         (path::_M_concat(basic_string_view<value_type>)): Likewise.
6325         (path::remove_filename()): Likewise.
6326         (path::lexically_normal()): Use _List::_Impl iterators instead of
6327         path::iterator. Use pop_back to remove components from the end. Clear
6328         trailing filename, instead of using erase(const_iterator) to remove
6329         a non-final component.
6330         * testsuite/27_io/filesystem/path/generation/normal.cc: Test
6331         additional cases.
6332         * testsuite/27_io/filesystem/path/generation/normal2.cc: New test.
6333
6334         * src/filesystem/std-path.cc (path::operator+=(const path&)): Fix
6335         incorrect treatment of empty filename after trailing slash.
6336         * testsuite/27_io/filesystem/path/concat/path.cc: Test problem case.
6337
6338         * testsuite/21_strings/basic_string/modifiers/assign/char/
6339         move_assign_optim.cc: Avoid spurious failure when -fno-inline added
6340         to test flags.
6341         * testsuite/21_strings/basic_string/modifiers/assign/wchar_t/
6342         move_assign_optim.cc: Likewise.
6343
6344 2019-01-03  Jonathan Wakely  <jwakely@redhat.com>
6345             Jakub Jelinek  <jakub@redhat.com>
6346
6347         PR libstdc++/88607
6348         * include/experimental/memory: Replace UTF-8 quote characters.
6349         * include/std/future: Replace UTF-8 "em dash" characters.
6350
6351 2019-01-03  Jonathan Wakely  <jwakely@redhat.com>
6352
6353         PR libstdc++/88607
6354         * include/bits/forward_list.h: Replace UTF-8 "ligature fi" character.
6355         * include/debug/forward_list: Likewise.
6356         * include/experimental/bits/shared_ptr.h: Remove UTF-8 "section sign"
6357         character.
6358         * include/experimental/chrono: Likewise.
6359         * include/experimental/functional: Likewise.
6360         * include/experimental/ratio: Likewise.
6361         * include/experimental/system_error: Likewise.
6362         * include/experimental/tuple: Likewise.
6363         * include/experimental/type_traits: Likewise.
6364         * include/parallel/workstealing.h: Replace UTF-8 "en dash" character.
6365         * include/parallel/multiseq_selection.h: Likewise.
6366
6367         PR libstdc++/88681
6368         * config/abi/pre/gnu.ver: Add missing exports.
6369         * testsuite/22_locale/collate_byname/88681.cc: New test.
6370         * testsuite/22_locale/time_get/get/char/88681.cc: New test.
6371         * testsuite/22_locale/time_get/get/wchar_t/88681.cc: New test.
6372
6373 2019-01-02  Jonathan Wakely  <jwakely@redhat.com>
6374
6375         * testsuite/23_containers/map/cons/deduction.cc: Test deduction from
6376         initializer_list<value_type> and from input iterator ranges.
6377         * testsuite/23_containers/multimap/cons/deduction.cc: Likewise.
6378
6379         * testsuite/experimental/string_view/element_access/char/empty.cc:
6380         Fix year range in copyright header.
6381
6382 2019-01-02  Joel Brobecker  <brobecker@adacore.com>
6383
6384         * testsuite/21_strings/basic_string_view/element_access/char/empty.cc:
6385         Fix year range in copyright header.
6386
6387 2019-01-01  Jakub Jelinek  <jakub@redhat.com>
6388
6389         Update copyright years.
6390 \f
6391 Copyright (C) 2019 Free Software Foundation, Inc.
6392
6393 Copying and distribution of this file, with or without modification,
6394 are permitted in any medium without royalty provided the copyright
6395 notice and this notice are preserved.