]> gcc.gnu.org Git - gcc.git/blame - libstdc++-v3/ChangeLog
Fix grammar in error message.
[gcc.git] / libstdc++-v3 / ChangeLog
CommitLineData
93b8cfce
PP
12020-02-16 Patrick Palka <ppalka@redhat.com>
2
3 * include/bits/ranges_algo.h (__lexicographical_compare_fn::operator()):
4 Move code after an early exit constexpr if to under an else branch.
5 * include/bits/ranges_algobase.h (__equal_fn::operator()): Likewise.
6
90b7eb65
PP
72020-02-15 Patrick Palka <ppalka@redhat.com>
8
55992626
PP
9 * include/bits/ranges_algo.h: Adjust whitespace and formatting.
10 * include/bits/ranges_algobase.h: Likewise.
11 * include/bits/ranges_uninitialized.h: Likewise.
12
b40c57bd
PP
13 * include/bits/ranges_algo.h: (adjacent_find, all_of, any_of,
14 binary_search, copy_if, count, count_if, equal_range, find, find_end,
15 find_first_of, find_if, find_if_not, for_each, generate, generate_n,
16 includes, inplace_merge, is_heap, is_heap_until, is_partitioned,
17 is_permutation, is_sorted, is_sorted_until, lexicographical_compare,
18 lower_bound, make_heap, max, max_element, merge, min, min_element,
19 minmax, minmax_element, mismatch, next_permutation, none_of,
20 nth_element, partial_sort, partial_sort_copy, partition, partition_copy,
21 partition_point, pop_heap, prev_permutation, push_heap, remove,
22 remove_copy, remove_copy_if, remove_if, replace, replace_copy,
23 replace_copy_if, replace_if, reverse, reverse_copy, rotate, rotate_copy,
24 search, search_n, set_difference, set_intersection,
25 set_symmetric_difference, set_union, shuffle, sort, sort_heap,
26 stable_partition, stable_sort, swap_ranges, transform, unique,
27 unique_copy, upper_bound): Convert into function objects.
28 * include/bits/ranges_algobase.h: (equal, copy, move, copy_n, fill_n,
29 fill, move_backward, copy_backward): Likewise.
30 * include/bits/ranges_uninitialized.h (uninitialized_default_construct,
31 uninitialized_default_construct_n, uninitialized_value_construct,
32 uninitialized_value_construct_n, uninitialized_copy,
33 uninitialized_copy_n, uninitialized_move, uninitialized_move_n,
34 uninitialized_fill, uninitialized_fill_n, construct_at, destroy_at,
35 destroy, destroy_n): Likewise.
36
90b7eb65
PP
37 * include/bits/ranges_algo.h (ranges::__find_end): Fold into ...
38 (ranges::find_end): ... here.
39 (ranges::__lexicographical_compare): Fold into ...
40 (ranges::lexicographical_compare): ... here.
41 * include/bits/ranges_algobase.h (ranges::__equal): Fold into ...
42 (ranges::equal): ... here.
43
55b00d14
JW
442020-02-15 Jonathan Wakely <jwakely@redhat.com>
45
46 * include/bits/erase_if.h (__cpp_lib_erase_if): Define to 202002L.
47 * include/std/deque: Likewise.
48 * include/std/forward_list: Likewise.
49 * include/std/list: Likewise.
50 * include/std/string: Likewise.
51 * include/std/vector: Likewise.
52 * include/std/version: Likewise.
53 * testsuite/23_containers/deque/erasure.cc: Test for new value.
54 * testsuite/23_containers/forward_list/erasure.cc: Likewise.
55 * testsuite/23_containers/list/erasure.cc: Likewise.
56 * testsuite/23_containers/map/erasure.cc: Likewise.
57 * testsuite/23_containers/set/erasure.cc: Likewise.
58 * testsuite/23_containers/unordered_map/erasure.cc: Likewise.
59 * testsuite/23_containers/unordered_set/erasure.cc: Likewise.
60 * testsuite/23_containers/vector/erasure.cc: Likewise.
61
5b1d5885
JW
622020-02-15 Jonathan Wakely <jwakely@redhat.com>
63
64 * include/bits/random.h (uniform_random_bit_generator): Require min()
65 and max() to be constant expressions and min() to be less than max().
66 * testsuite/26_numerics/random/concept.cc: Check additional cases.
67 * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error lineno.
68
90fc7b3c
PP
692020-02-13 Patrick Palka <ppalka@redhat.com>
70
613c932f
PP
71 * include/Makefile.am: Add <bits/ranges_uninitialized.h>.
72 * include/Makefile.in: Regenerate.
73 * include/bits/ranges_uninitialized.h: New header.
74 * include/std/memory: Include it.
75 * testsuite/20_util/specialized_algorithms/destroy/constrained.cc: New
76 test.
77 * .../uninitialized_copy/constrained.cc: New test.
78 * .../uninitialized_default_construct/constrained.cc: New test.
79 * .../uninitialized_fill/constrained.cc: New test.
80 * .../uninitialized_move/constrained.cc: New test.
81 * .../uninitialized_value_construct/constrained.cc: New test.
82
90fc7b3c
PP
83 * include/Makefile.am: Add bits/ranges_algobase.h
84 * include/Makefile.in: Regenerate.
85 * bits/ranges_algo.h: Include <bits/ranges_algobase.h> and refactor
86 existing #includes.
87 (__detail::__is_normal_iterator, __detail::is_reverse_iterator,
88 __detail::__is_move_iterator, copy_result, move_result,
89 __equal, equal, copy_result, move_result, move_backward_result,
90 copy_backward_result, __copy_or_move_backward, __copy_or_move, copy,
91 move, copy_backward, move_backward, copy_n_result, copy_n, fill_n,
92 fill): Split out into ...
93 * bits/range_algobase.h: ... this new header.
94
99bbab9f
PP
952020-02-12 Patrick Palka <ppalka@redhat.com>
96
97 LWG 3389 and LWG 3390
98 * include/bits/stl_iterator.h (move_move_iterator): Use std::move when
99 constructing the move_iterator with __i.
100 (counted_iterator::counted_iterator): Use std::move when initializing
101 M_current with __i.
102 * testsuite/24_iterators/counted_iterator/lwg3389.cc: New test.
103 * testsuite/24_iterators/move_iterator/lwg3390.cc: New test.
104
02ce382c
SL
1052020-02-12 Sandra Loosemore <sandra@codesourcery.com>
106
107 PR libstdc++/79193
108 PR libstdc++/88999
109
110 * configure: Regenerated.
111
b32a3f32
FD
1122020-02-12 François Dumont <fdumont@gcc.gnu.org>
113
114 * include/bits/hashtable.h
115 (_Hashtable<>(_Hashtable&&, std::allocator_type&)): Add
116 missing std namespace qualification to forward call.
117
dcda050e
JW
1182020-02-09 Jonathan Wakely <jwakely@redhat.com>
119
38660e87
JW
120 * testsuite/20_util/function_objects/range.cmp/equal_to.cc: Fix
121 comment.
122 * testsuite/20_util/function_objects/range.cmp/less.ccL Likewise.
123
97a7c229
JW
124 * include/std/ranges: Fix non-ASCII characters in comment.
125
dcda050e
JW
126 * include/bits/range_cmp.h (__detail::__eq_builtin_ptr_cmp): Require
127 equality comparison to be valid and return bool.
128 (__detail::__less_builtin_ptr_cmp): Likewise for less-than comparison.
129 * testsuite/20_util/function_objects/range.cmp/equal_to.cc: Check
130 type with ambiguous conversion to fundamental types.
131 * testsuite/20_util/function_objects/range.cmp/less.cc: Likewise.
132
d222d8ec
JW
1332020-02-07 Jonathan Wakely <jwakely@redhat.com>
134
c8dd2446
JW
135 * include/bits/iterator_concepts.h (iter_difference_t, iter_value_t):
136 Use remove_cvref_t.
137 (readable_traits): Rename to indirectly_readable_traits.
138 (readable): Rename to indirectly_readable.
139 (writable): Rename to indirectly_writable.
140 (__detail::__iter_exchange_move): Do not use remove_reference_t.
141 (indirectly_swappable): Adjust requires expression parameter types.
142 expression.
143 * include/bits/ranges_algo.h (ranges::transform, ranges::replace)
144 (ranges::replace_if, ranges::generate_n, ranges::generate)
145 (ranges::remove): Use new name for writable.
146 * include/bits/stl_iterator.h (__detail::__common_iter_has_arrow):
147 Use new name for readable.
148 * include/ext/pointer.h (readable_traits<_Pointer_adapter<P>>): Use
149 new name for readable_traits.
150 * testsuite/24_iterators/associated_types/readable.traits.cc: Likewise.
151 * testsuite/24_iterators/indirect_callable/projected.cc: Adjust for
152 new definition of indirectly_readable.
153
d222d8ec
JW
154 * include/bits/stl_iterator.h (__detail::__common_iter_ptr): Change
155 to take parameters of common_iterator, instead of the common_iterator
156 type itself. Fix argument for __common_iter_has_arrow constraint.
157 (iterator_traits<common_iterator<I, S>>::pointer): Adjust.
158
572992c8
JW
1592020-02-07 Jonathan Wakely <jwakely@redhat.com>
160
161 * include/std/ranges (iota_view): Add braces to prevent -Wempty-body
162 warning.
163 (basic_istream_view::_Iterator::operator++()): Add missing return.
164
cba9ef06
PP
1652020-02-07 Patrick Palka <ppalka@redhat.com>
166
a04f635d
PP
167 * include/bits/ranges_algo.h: Remove extraneous &&.
168
b7903d9f
PP
169 * include/std/ranges (ranges::__detail::__stream_extractable,
170 ranges::basic_istream_view, ranges::istream_view): Define.
171 * testsuite/std/ranges/istream_view: New test.
172
cba9ef06
PP
173 Implement C++20 range adaptors
174 * include/std/ranges: Include <bits/refwrap.h> and <tuple>.
175 (subrange::_S_store_size): Mark as const instead of constexpr to
176 avoid what seems to be a bug in GCC.
177 (__detail::__box): Give it defaulted copy and move constructors.
55d4cbcb
PP
178 (ranges::views::_Single::operator()): Mark constexpr.
179 (ranges::views::_Iota::operator()): Mark constexpr.
cba9ef06 180 (__detail::Empty): Define.
55d4cbcb
PP
181 (ranges::views::__closure::_RangeAdaptor,
182 ranges::views::__closure::_RangeAdaptorClosure, ref_view, all_view,
183 ranges::views::all, ranges::__detail::find_if,
184 ranges::__detail::find_if_not, ranges::__detail::mismatch,
185 ranges::detail::min, filter_view, ranges::views::filter, transform_view,
186 ranges::views::transform, take_view, ranges::views::take,
187 take_while_view, ranges::views::take_while, drop_view,
188 ranges::views::drop, join_view, ranges::views::join,
cba9ef06 189 __detail::require_constant, __detail::tiny_range, split_view,
55d4cbcb
PP
190 ranges::views::split, ranges::views::_Counted, ranges::views::counted,
191 common_view, ranges::views::common, reverse_view,
192 ranges::views::reverse,
193 ranges::views::__detail::__is_reversible_subrange,
194 ranges::views::__detail::__is_reverse_view, reverse_view,
195 ranges::views::reverse, __detail::__has_tuple_element, elements_view,
196 ranges::views::elements, ranges::views::keys, ranges::views::values):
197 Define.
198 (views): Alias for ranges::views.
199 (tuple_size<ranges::subrange<>>, tuple_element<0, ranges::subrange>,
200 tuple_element<1, ranges::subrange>): New partial specializations.
cba9ef06
PP
201 * testsuite/std/ranges/adaptors/all.cc: New test.
202 * testsuite/std/ranges/adaptors/common.cc: Likewise.
203 * testsuite/std/ranges/adaptors/counted.cc: Likewise.
204 * testsuite/std/ranges/adaptors/drop.cc: Likewise.
205 * testsuite/std/ranges/adaptors/drop_while.cc: Likewise.
206 * testsuite/std/ranges/adaptors/elements.cc: Likewise.
207 * testsuite/std/ranges/adaptors/filter.cc: Likewise.
208 * testsuite/std/ranges/adaptors/join.cc: Likewise.
209 * testsuite/std/ranges/adaptors/reverse.cc: Likewise.
210 * testsuite/std/ranges/adaptors/split.cc: Likewise.
211 * testsuite/std/ranges/adaptors/take.cc: Likewise.
212 * testsuite/std/ranges/adaptors/take_while.cc: Likewise.
213 * testsuite/std/ranges/adaptors/transform.cc: Likewise.
214
5713834e
JW
2152020-02-07 Jonathan Wakely <jwakely@redhat.com>
216
0d57370c
JW
217 * libsupc++/compare (__cmp_cat::type): Define typedef for underlying
218 type of enumerations and comparison category types.
219 (__cmp_cat::_Ord, __cmp_cat::_Ncmp): Add underlying type.
220 (__cmp_cat::_Ncmp::unordered): Change value to 2.
221 (partial_ordering::_M_value, weak_ordering::_M_value)
222 (strong_ordering::_M_value): Change type to __cmp_cat::type.
223 (partial_ordering::_M_is_ordered): Remove data member.
224 (partial_ordering): Use second bit of _M_value for unordered. Adjust
225 comparison operators.
226 (weak_ordering::operator partial_ordering): Simplify to remove
227 branches.
228 (operator<=>(unspecified, weak_ordering)): Likewise.
229 (strong_ordering::operator partial_ordering): Likewise.
230 (strong_ordering::operator weak_ordering): Likewise.
231 (operator<=>(unspecified, strong_ordering)): Likewise.
232 * testsuite/18_support/comparisons/categories/partialord.cc: New test.
233 * testsuite/18_support/comparisons/categories/strongord.cc: New test.
234 * testsuite/18_support/comparisons/categories/weakord.cc: New test.
235
5713834e
JW
236 * include/std/ranges (iota_view::_Iterator): Fix typo in name of
237 __cpp_lib_three_way_comparison macro and use deduced return type for
238 operator<=>.
239 * testsuite/std/ranges/iota/iterator.cc: New test.
240
bc464641
PP
2412020-02-07 Patrick Palka <ppalka@redhat.com>
242 Jonathan Wakely <jwakely@redhat.com>
243
244 Implement C++20 constrained algorithms
245 * include/Makefile.am: Add new header.
246 * include/Makefile.in: Regenerate.
247 * include/std/algorithm: Include <bits/ranges_algo.h>.
248 * include/bits/ranges_algo.h: New file.
249 * testsuite/25_algorithms/adjacent_find/constrained.cc: New test.
250 * testsuite/25_algorithms/all_of/constrained.cc: New test.
251 * testsuite/25_algorithms/any_of/constrained.cc: New test.
252 * testsuite/25_algorithms/binary_search/constrained.cc: New test.
253 * testsuite/25_algorithms/copy/constrained.cc: New test.
254 * testsuite/25_algorithms/copy_backward/constrained.cc: New test.
255 * testsuite/25_algorithms/copy_if/constrained.cc: New test.
256 * testsuite/25_algorithms/copy_n/constrained.cc: New test.
257 * testsuite/25_algorithms/count/constrained.cc: New test.
258 * testsuite/25_algorithms/count_if/constrained.cc: New test.
259 * testsuite/25_algorithms/equal/constrained.cc: New test.
260 * testsuite/25_algorithms/equal_range/constrained.cc: New test.
261 * testsuite/25_algorithms/fill/constrained.cc: New test.
262 * testsuite/25_algorithms/fill_n/constrained.cc: New test.
263 * testsuite/25_algorithms/find/constrained.cc: New test.
264 * testsuite/25_algorithms/find_end/constrained.cc: New test.
265 * testsuite/25_algorithms/find_first_of/constrained.cc: New test.
266 * testsuite/25_algorithms/find_if/constrained.cc: New test.
267 * testsuite/25_algorithms/find_if_not/constrained.cc: New test.
268 * testsuite/25_algorithms/for_each/constrained.cc: New test.
269 * testsuite/25_algorithms/generate/constrained.cc: New test.
270 * testsuite/25_algorithms/generate_n/constrained.cc: New test.
271 * testsuite/25_algorithms/heap/constrained.cc: New test.
272 * testsuite/25_algorithms/includes/constrained.cc: New test.
273 * testsuite/25_algorithms/inplace_merge/constrained.cc: New test.
274 * testsuite/25_algorithms/is_partitioned/constrained.cc: New test.
275 * testsuite/25_algorithms/is_permutation/constrained.cc: New test.
276 * testsuite/25_algorithms/is_sorted/constrained.cc: New test.
277 * testsuite/25_algorithms/is_sorted_until/constrained.cc: New test.
278 * testsuite/25_algorithms/lexicographical_compare/constrained.cc: New
279 test.
280 * testsuite/25_algorithms/lower_bound/constrained.cc: New test.
281 * testsuite/25_algorithms/max/constrained.cc: New test.
282 * testsuite/25_algorithms/max_element/constrained.cc: New test.
283 * testsuite/25_algorithms/merge/constrained.cc: New test.
284 * testsuite/25_algorithms/min/constrained.cc: New test.
285 * testsuite/25_algorithms/min_element/constrained.cc: New test.
286 * testsuite/25_algorithms/minmax/constrained.cc: New test.
287 * testsuite/25_algorithms/minmax_element/constrained.cc: New test.
288 * testsuite/25_algorithms/mismatch/constrained.cc: New test.
289 * testsuite/25_algorithms/move/constrained.cc: New test.
290 * testsuite/25_algorithms/move_backward/constrained.cc: New test.
291 * testsuite/25_algorithms/next_permutation/constrained.cc: New test.
292 * testsuite/25_algorithms/none_of/constrained.cc: New test.
293 * testsuite/25_algorithms/nth_element/constrained.cc: New test.
294 * testsuite/25_algorithms/partial_sort/constrained.cc: New test.
295 * testsuite/25_algorithms/partial_sort_copy/constrained.cc: New test.
296 * testsuite/25_algorithms/partition/constrained.cc: New test.
297 * testsuite/25_algorithms/partition_copy/constrained.cc: New test.
298 * testsuite/25_algorithms/partition_point/constrained.cc: New test.
299 * testsuite/25_algorithms/prev_permutation/constrained.cc: New test.
300 * testsuite/25_algorithms/remove/constrained.cc: New test.
301 * testsuite/25_algorithms/remove_copy/constrained.cc: New test.
302 * testsuite/25_algorithms/remove_copy_if/constrained.cc: New test.
303 * testsuite/25_algorithms/remove_if/constrained.cc: New test.
304 * testsuite/25_algorithms/replace/constrained.cc: New test.
305 * testsuite/25_algorithms/replace_copy/constrained.cc: New test.
306 * testsuite/25_algorithms/replace_copy_if/constrained.cc: New test.
307 * testsuite/25_algorithms/replace_if/constrained.cc: New test.
308 * testsuite/25_algorithms/reverse/constrained.cc: New test.
309 * testsuite/25_algorithms/reverse_copy/constrained.cc: New test.
310 * testsuite/25_algorithms/rotate/constrained.cc: New test.
311 * testsuite/25_algorithms/rotate_copy/constrained.cc: New test.
312 * testsuite/25_algorithms/search/constrained.cc: New test.
313 * testsuite/25_algorithms/search_n/constrained.cc: New test.
314 * testsuite/25_algorithms/set_difference/constrained.cc: New test.
315 * testsuite/25_algorithms/set_intersection/constrained.cc: New test.
316 * testsuite/25_algorithms/set_symmetric_difference/constrained.cc: New
317 test.
318 * testsuite/25_algorithms/set_union/constrained.cc: New test.
319 * testsuite/25_algorithms/shuffle/constrained.cc: New test.
320 * testsuite/25_algorithms/sort/constrained.cc: New test.
321 * testsuite/25_algorithms/stable_partition/constrained.cc: New test.
322 * testsuite/25_algorithms/stable_sort/constrained.cc: New test.
323 * testsuite/25_algorithms/swap_ranges/constrained.cc: New test.
324 * testsuite/25_algorithms/transform/constrained.cc: New test.
325 * testsuite/25_algorithms/unique/constrained.cc: New test.
326 * testsuite/25_algorithms/unique_copy/constrained.cc: New test.
327 * testsuite/25_algorithms/upper_bound/constrained.cc: New test.
328
d1aa7705
JW
3292020-02-06 Jonathan Wakely <jwakely@redhat.com>
330
bd630df0
JW
331 * include/bits/stl_iterator.h (__detail::__common_iter_ptr): Fix PR
332 number in comment. Fix indentation.
333
d1aa7705
JW
334 * include/bits/stl_algobase.h (__iter_swap, __iter_swap<true>): Remove
335 redundant _GLIBCXX20_CONSTEXPR.
336
26eae9ac
JW
337 * include/std/ranges (viewable_range): Replace decay_t with
338 remove_cvref_t (LWG 3375).
339
269e8130
JW
3402020-02-05 Jonathan Wakely <jwakely@redhat.com>
341
342 * include/bits/iterator_concepts.h (iter_reference_t)
343 (iter_rvalue_reference_t, iter_common_reference_t, indirect_result_t):
344 Remove workarounds for PR c++/67704.
345 * testsuite/24_iterators/aliases.cc: New test.
346
7db12d15
PP
3472020-02-05 Patrick Palka <ppalka@redhat.com>
348
349 * include/bits/stl_iterator.h (move_iterator::move_iterator): Move __i
350 when initializing _M_current.
351 (move_iterator::base): Split into two overloads differing in
352 ref-qualifiers as in P1207R4 for C++20.
353
9962493c
JW
3542020-02-04 Jonathan Wakely <jwakely@redhat.com>
355
9bc5bea1
JW
356 * include/std/functional (_GLIBCXX_NOT_FN_CALL_OP): Un-define after
357 use.
358
9962493c
JW
359 PR libstdc++/93562
360 * include/bits/unique_ptr.h (__uniq_ptr_impl::swap): Define.
361 (unique_ptr::swap, unique_ptr<T[], D>::swap): Call it.
362 * testsuite/20_util/unique_ptr/modifiers/93562.cc: New test.
363
20fa702b
AB
3642020-02-01 Andrew Burgess <andrew.burgess@embecosm.com>
365
366 * configure: Regenerate.
367
6e5a1963
PP
3682020-01-31 Patrick Palka <ppalka@redhat.com>
369
370 * testsuite/24_iterators/range_operations/distance.cc: Do not assume
371 test_range::end() returns the same type as test_range::begin().
372 * testsuite/24_iterators/range_operations/next.cc: Likewise.
373 * testsuite/24_iterators/range_operations/prev.cc: Likewise.
374 * testsuite/util/testsuite_iterators.h (__gnu_test::test_range::end):
375 Always return a sentinel<I>.
376
5cd2e126
JW
3772020-01-29 Jonathan Wakely <jwakely@redhat.com>
378
0a8f4feb
JW
379 PR libstdc++/92895
380 * include/std/stop_token (stop_token::stop_possible()): Call new
381 _M_stop_possible() function.
382 (stop_token::stop_requested()): Do not use stop_possible().
383 (stop_token::binary_semaphore): New class, as temporary stand-in for
384 std::binary_semaphore.
385 (stop_token::_Stop_cb::_M_callback): Add noexcept to type.
386 (stop_token::_Stop_cb::_M_destroyed, stop_token::_Stop_cb::_M_done):
387 New data members for symchronization with stop_callback destruction.
388 (stop_token::_Stop_cb::_Stop_cb): Make non-template.
389 (stop_token::_Stop_cb::_M_linked, stop_token::_Stop_cb::_S_execute):
390 Remove.
391 (stop_token::_Stop_cb::_M_run): New member function.
392 (stop_token::_Stop_state::_M_stopped, stop_token::_Stop_state::_M_mtx):
393 Remove.
394 (stop_token::_Stop_state::_M_owners): New data member to track
395 reference count for ownership.
396 (stop_token::_Stop_state::_M_value): New data member combining a
397 spinlock, the stop requested flag, and the reference count for
398 associated stop_source objects.
399 (stop_token::_Stop_state::_M_requester): New data member for
400 synchronization with stop_callback destruction.
401 (stop_token::_Stop_state::_M_stop_possible()): New member function.
402 (stop_token::_Stop_state::_M_stop_requested()): Inspect relevant bit
403 of _M_value.
404 (stop_token::_Stop_state::_M_add_owner)
405 (stop_token::_Stop_state::_M_release_ownership)
406 (stop_token::_Stop_state::_M_add_ssrc)
407 (stop_token::_Stop_state::_M_sub_ssrc): New member functions for
408 updating reference counts.
409 (stop_token::_Stop_state::_M_lock, stop_token::_Stop_state::_M_unlock)
410 (stop_token::_Stop_state::_M_lock, stop_token::_Stop_state::_M_unlock)
411 (stop_token::_Stop_state::_M_try_lock)
412 (stop_token::_Stop_state::_M_try_lock_and_stop)
413 (stop_token::_Stop_state::_M_do_try_lock): New member functions for
414 managing spinlock.
415 (stop_token::_Stop_state::_M_request_stop): Use atomic operations to
416 read and update state. Release lock while running callbacks. Use new
417 data members to synchronize with callback destruction.
418 (stop_token::_Stop_state::_M_remove_callback): Likewise.
419 (stop_token::_Stop_state::_M_register_callback): Use atomic operations
420 to read and update state.
421 (stop_token::_Stop_state_ref): Handle type to manage _Stop_state,
422 replacing shared_ptr.
423 (stop_source::stop_source(const stop_source&)): Update reference count.
424 (stop_source::operator=(const stop_source&)): Likewise.
425 (stop_source::~stop_source()): Likewise.
426 (stop_source::stop_source(stop_source&&)): Define as defaulted.
427 (stop_source::operator=(stop_source&&)): Establish postcondition on
428 parameter.
429 (stop_callback): Enforce preconditions on template parameter. Replace
430 base class with data member of new _Cb_impl type.
431 (stop_callback::stop_callback(const stop_token&, Cb&&))
432 (stop_callback::stop_callback(stop_token&&, Cb&&)): Fix TOCTTOU race.
433 (stop_callback::_Cb_impl): New type wrapping _Callback member and
434 defining the _S_execute member function.
435 * testsuite/30_threads/stop_token/stop_callback/deadlock-mt.cc: New
436 test.
437 * testsuite/30_threads/stop_token/stop_callback/deadlock.cc: New test.
438 * testsuite/30_threads/stop_token/stop_callback/destroy.cc: New test.
439 * testsuite/30_threads/stop_token/stop_callback/destructible_neg.cc:
440 New test.
441 * testsuite/30_threads/stop_token/stop_callback/invocable_neg.cc: New
442 test.
443 * testsuite/30_threads/stop_token/stop_callback/invoke.cc: New test.
444 * testsuite/30_threads/stop_token/stop_source/assign.cc: New test.
445 * testsuite/30_threads/stop_token/stop_token/stop_possible.cc: New
446 test.
447
f214ffb3
JW
448 * libsupc++/compare (__detail::__3way_builtin_ptr_cmp): Use
449 three_way_comparable_with.
450 (__detail::__3way_cmp_with): Remove workaround for fixed bug.
451 (compare_three_way::operator()): Remove redundant constraint from
452 requires-clause.
453 (__detail::_Synth3way::operator()): Use three_way_comparable_with
454 instead of workaround.
455 * testsuite/18_support/comparisons/object/93479.cc: Prune extra
456 output due to simplified constraints on compare_three_way::operator().
457
83b02010
JW
458 PR libstdc++/93479
459 * libsupc++/compare (__3way_builtin_ptr_cmp): Require <=> to be valid.
460 * testsuite/18_support/comparisons/object/93479.cc: New test.
461
5cd2e126
JW
462 * testsuite/std/ranges/access/end.cc: Do not assume test_range::end()
463 returns the same type as test_range::begin(). Add comments.
464 * testsuite/std/ranges/access/rbegin.cc: Likewise.
465 * testsuite/std/ranges/access/rend.cc: Likewise.
466 * testsuite/std/ranges/range.cc: Do not assume the sentinel for
467 test_range is the same as its iterator type.
468 * testsuite/util/testsuite_iterators.h (test_range::sentinel): Add
469 operator- overloads to satisfy sized_sentinel_for when the iterator
470 satisfies random_access_iterator.
471
759812fd
JW
4722020-01-28 Jonathan Wakely <jwakely@redhat.com>
473
72a9fd20
JW
474 PR libstdc++/93470
475 * include/bits/refwrap.h (reference_wrapper::operator()): Restrict
476 static assertion to object types.
477
759812fd
JW
478 PR libstdc++/93325
479 * acinclude.m4 (GLIBCXX_ENABLE_LIBSTDCXX_TIME): Use AC_SEARCH_LIBS for
480 clock_gettime instead of explicit glibc version check.
481 * configure: Regenerate.
482
a5d81aaa
JW
4832020-01-28 Martin Liska <mliska@suse.cz>
484
485 PR libstdc++/93478
486 * include/std/atomic: Fix typo.
487 * include/std/optional: Likewise.
488
4892020-01-27 Andrew Burgess <andrew.burgess@embecosm.com>
490
491 * configure: Regenerate.
492
389cd88c
JW
4932020-01-27 Jonathan Wakely <jwakely@redhat.com>
494
495 PR libstdc++/93426
496 * include/std/span (span): Fix deduction guide.
497 * testsuite/23_containers/span/deduction.cc: New test.
498
482eeff5
JW
4992020-01-24 Jonathan Wakely <jwakely@redhat.com>
500
501 * libsupc++/compare (__cmp_cat::_Eq): Remove enumeration type.
502 (__cmp_cat::_Ord::equivalent): Add enumerator.
503 (__cmp_cat::_Ord::_Less, __cmp_cat::_Ord::_Greater): Rename to less
504 and greater.
505 (partial_ordering, weak_ordering, strong_ordering): Remove
506 constructors taking __cmp_cat::_Eq parameters. Use renamed
507 enumerators.
508
e8e66971
MR
5092020-01-24 Maciej W. Rozycki <macro@wdc.com>
510
511 * acinclude.m4: Handle `--with-toolexeclibdir='.
512 * Makefile.in: Regenerate.
513 * aclocal.m4: Regenerate.
514 * configure: Regenerate.
515 * doc/Makefile.in: Regenerate.
516 * include/Makefile.in: Regenerate.
517 * libsupc++/Makefile.in: Regenerate.
518 * po/Makefile.in: Regenerate.
519 * python/Makefile.in: Regenerate.
520 * src/Makefile.in: Regenerate.
521 * src/c++11/Makefile.in: Regenerate.
522 * src/c++17/Makefile.in: Regenerate.
523 * src/c++98/Makefile.in: Regenerate.
524 * src/filesystem/Makefile.in: Regenerate.
525 * testsuite/Makefile.in: Regenerate.
526
7a900bce
AO
5272020-01-23 Alexandre Oliva <oliva@adacore.com>
528
f9e84b31
AO
529 * crossconfig.m4 (GLIBCXX_CHECK_MATH_DECL): Reject macros.
530 * configure: Rebuild.
531
7a900bce
AO
532 * testsuite/27_io/fpos/mbstate_t/1.cc: Zero-init mbstate_t.
533
04681fca
JW
5342020-01-23 Jonathan Wakely <jwakely@redhat.com>
535
536 PR libstdc++/91947
537 * include/Makefile.am (${host_builddir}/largefile-config.h): Simplify
538 rule.
539 * include/Makefile.in: Regenerate.
540
c784f162
JW
5412020-01-20 Jonathan Wakely <jwakely@redhat.com>
542
543 * doc/xml/faq.xml: Fix grammar.
544 * doc/xml/manual/appendix_contributing.xml: Improve instructions.
545 * doc/xml/manual/spine.xml: Update copyright years.
546 * doc/html/*: Regenerate.
547
f4d83eba
ER
5482020-01-19 Eric S. Raymond <esr@thyrsus.com>
549
550 * doc/xml/faq.xml: Update for SVN -> Git transition.
551 * doc/xml/manual/appendix_contributing.xml: Likewise.
552 * doc/xml/manual/status_cxx1998.xml: Likewise.
553 * doc/xml/manual/status_cxx2011.xml: Likewise.
554 * doc/xml/manual/status_cxx2014.xml: Likewise.
555 * doc/xml/manual/status_cxx2017.xml: Likewise.
556 * doc/xml/manual/status_cxx2020.xml: Likewise.
557 * doc/xml/manual/status_cxxtr1.xml: Likewise.
558 * doc/xml/manual/status_cxxtr24733.xml: Likewise.
559
49789fd0
IS
5602020-01-18 Iain Sandoe <iain@sandoe.co.uk>
561
562 * include/Makefile.am: Add coroutine to the std set.
563 * include/Makefile.in: Regenerated.
564 * include/std/coroutine: New file.
565
0ba6a850
JW
5662020-01-17 Jonathan Wakely <jwakely@redhat.com>
567
568 PR libstdc++/92376
569 * include/bits/c++config: Only do PSTL config when the header is
570 present, to fix freestanding.
571 * libsupc++/new_opa.cc [!_GLIBCXX_HOSTED]: Declare allocation
572 functions if they were detected by configure.
573
98d56ea8
JW
5742020-01-16 Kai-Uwe Eckhardt <kuehro@gmx.de>
575 Matthew Bauer <mjbauer95@gmail.com>
576 Jonathan Wakely <jwakely@redhat.com>
577
578 PR bootstrap/64271 (partial)
579 * config/os/bsd/netbsd/ctype_base.h (ctype_base::mask): Change type
580 to unsigned short.
581 (ctype_base::alpha, ctype_base::digit, ctype_base::xdigit)
582 (ctype_base::print, ctype_base::graph, ctype_base::alnum): Sync
583 definitions with NetBSD upstream.
584 (ctype_base::blank): Use _CTYPE_BL.
585 * config/os/bsd/netbsd/ctype_configure_char.cc (_C_ctype_): Remove
586 Declaration.
587 (ctype<char>::classic_table): Use _C_ctype_tab_ instead of _C_ctype_.
588 (ctype<char>::do_toupper, ctype<char>::do_tolower): Cast char
589 parameters to unsigned char.
590 * config/os/bsd/netbsd/ctype_inline.h (ctype<char>::is): Likewise.
591
d9165389
FD
5922020-01-16 François Dumont <fdumont@gcc.gnu.org>
593
594 PR libstdc++/91263
595 * include/bits/hashtable.h (_Hashtable<>): Make _Equality<> friend.
596 * include/bits/hashtable_policy.h: Include <bits/stl_algo.h>.
597 (_Equality_base): Remove.
598 (_Equality<>::_M_equal): Review implementation. Use
599 std::is_permutation.
600 * testsuite/23_containers/unordered_multiset/operators/1.cc
601 (Hash, Equal, test02, test03): New.
602 * testsuite/23_containers/unordered_set/operators/1.cc
603 (Hash, Equal, test02, test03): New.
604
2a0f6c61
JW
6052020-01-15 Jonathan Wakely <jwakely@redhat.com>
606
607 PR libstdc++/93267
608 * include/bits/iterator_concepts.h (__max_diff_type, __max_size_type):
609 Move here from <bits/range_access.h> and define using __int128 when
610 available.
611 (__is_integer_like, __is_signed_integer_like): Move here from
612 <bits/range_access.h>.
613 (weakly_incrementable): Use __is_signed_integer_like.
614 * include/bits/range_access.h (__max_diff_type, __max_size_type)
615 (__is_integer_like, __is_signed_integer_like): Move to
616 <bits/iterator_concepts.h>.
617 (__make_unsigned_like_t): Move here from <ranges>.
618 * include/std/ranges (__make_unsigned_like_t): Move to
619 <bits/range_access.h>.
620 (iota_view): Replace using-directive with using-declarations.
621 * testsuite/std/ranges/iota/93267.cc: New test.
622 * testsuite/std/ranges/iota_view.cc: Move to new 'iota' sub-directory.
623
e4379a93
JW
6242020-01-13 Jonathan Wakely <jwakely@redhat.com>
625
fe7cc34f
JW
626 PR libstdc++/93244
627 * include/bits/fs_path.h (path::generic_string<C,A>)
628 [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Convert root-dir to forward-slash.
629 * testsuite/27_io/filesystem/path/generic/generic_string.cc: Check
630 root-dir is converted to forward slash in generic pathname.
631 * testsuite/27_io/filesystem/path/generic/utf.cc: New test.
632 * testsuite/27_io/filesystem/path/generic/wchar_t.cc: New test.
633
e4379a93
JW
634 PR libstdc++/58605
635 * include/bits/atomic_base.h (__cpp_lib_atomic_value_initialization):
636 Define.
637 (__atomic_flag_base, __atomic_base, __atomic_base<_PTp*>)
638 (__atomic_float): Add default member initializer for C++20.
639 * include/std/atomic (atomic): Likewise.
640 (atomic::atomic()): Remove noexcept-specifier on default constructor.
641 * include/std/version (__cpp_lib_atomic_value_initialization): Define.
642 * testsuite/29_atomics/atomic/cons/assign_neg.cc: Adjust dg-error line
643 number.
644 * testsuite/29_atomics/atomic/cons/copy_neg.cc: Likewise.
645 * testsuite/29_atomics/atomic/cons/value_init.cc: New test.
646 * testsuite/29_atomics/atomic_flag/cons/value_init.cc: New test.
647 * testsuite/29_atomics/atomic_flag/requirements/trivial.cc: Adjust
648 expected result for is_trivially_default_constructible.
649 * testsuite/29_atomics/atomic_float/requirements.cc: Likewise.
650 * testsuite/29_atomics/atomic_float/value_init.cc: New test.
651 * testsuite/29_atomics/atomic_integral/cons/assign_neg.cc: Likewise.
652 * testsuite/29_atomics/atomic_integral/cons/copy_neg.cc: Likewise.
653 * testsuite/29_atomics/atomic_integral/cons/value_init.cc
654 * testsuite/29_atomics/atomic_integral/requirements/trivial.cc: Adjust
655 expected results for is_trivially_default_constructible.
656 * testsuite/util/testsuite_common_types.h (has_trivial_dtor): Add
657 new test generator.
658
7918cb93
JW
6592020-01-10 Jonathan Wakely <jwakely@redhat.com>
660
68be73fc
JW
661 * testsuite/util/testsuite_iterators.h: Improve comment.
662
78f02e80
JW
663 * testsuite/25_algorithms/equal/deque_iterators/1.cc: Don't use C++11
664 initialization syntax.
665
7918cb93
JW
666 PR libstdc++/92285
667 * include/bits/streambuf_iterator.h (istreambuf_iterator): Make type
668 of base class independent of __cplusplus value.
669 [__cplusplus < 201103L] (istreambuf_iterator::reference): Override the
670 type defined in the base class
671 * testsuite/24_iterators/istreambuf_iterator/92285.cc: New test.
672 * testsuite/24_iterators/istreambuf_iterator/requirements/
673 base_classes.cc: Adjust expected base class for C++98.
674
acd43917
OH
6752020-01-09 Olivier Hainque <hainque@adacore.com>
676
677 * doc/xml/manual/appendix_contributing.xml: Document _C2
678 as a reserved identifier, by VxWorks.
679 * include/bits/stl_map.h: Rename _C2 template typenames as _Cmp2.
680 * include/bits/stl_multimap.h: Likewise.
681
caa39b2e
JW
6822020-01-09 Jonathan Wakely <jwakely@redhat.com>
683
1a788638
JW
684 * include/ext/extptr_allocator.h (_ExtPtr_allocator::operator==)
685 (_ExtPtr_allocator::operator!=): Add missing const qualifiers.
686 * include/ext/pointer.h (readable_traits<_Pointer_adapter<S>>): Add
687 partial specialization to disambiguate the two constrained
688 specializations.
689
caa39b2e
JW
690 * include/experimental/type_traits (experimental::is_pod_v): Disable
691 -Wdeprecated-declarations warnings around reference to std::is_pod.
692 * include/std/type_traits (is_pod_v): Likewise.
693 * testsuite/18_support/max_align_t/requirements/2.cc: Also check
694 is_standard_layout and is_trivial. Do not check is_pod for C++20.
695 * testsuite/20_util/is_pod/requirements/explicit_instantiation.cc:
696 Add -Wno-deprecated for C++20.
697 * testsuite/20_util/is_pod/requirements/typedefs.cc: Likewise.
698 * testsuite/20_util/is_pod/value.cc: Likewise.
699 * testsuite/experimental/type_traits/value.cc: Likewise.
700
1a6c5064
JTM
7012020-01-09 JeanHeyd "ThePhD" Meneide <phdofthehouse@gmail.com>
702
703 * include/bits/c++config (_GLIBCXX20_DEPRECATED): Add new macro.
704 * include/std/type_traits (is_pod, is_pod_v): Deprecate for C++20.
705 * testuite/20_util/is_pod/deprecated-2a.cc: New test.
706
d574c8aa
JW
7072020-01-09 Jonathan Wakely <jwakely@redhat.com>
708
160e95dc
JW
709 PR libstdc++/93205
710 * include/bits/random.h (operator>>): Check stream operation succeeds.
711 * include/bits/random.tcc (operator<<): Remove redundant __ostream_type
712 typedefs.
713 (operator>>): Remove redundant __istream_type typedefs. Check stream
714 operations succeed.
715 (__extract_params): New function to fill a vector from a stream.
716 * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error line.
717
d574c8aa
JW
718 PR libstdc++/93208
719 * config/abi/pre/gnu.ver: Add new exports.
720 * include/std/memory_resource (memory_resource::~memory_resource()):
721 Do not define inline.
722 (monotonic_buffer_resource::~monotonic_buffer_resource()): Likewise.
723 * src/c++17/memory_resource.cc (memory_resource::~memory_resource()):
724 Define.
725 (monotonic_buffer_resource::~monotonic_buffer_resource()): Define.
726 * testsuite/20_util/monotonic_buffer_resource/93208.cc: New test.
727
b9c84e95
FD
7282020-01-09 François Dumont <fdumont@gcc.gnu.org>
729
730 PR libstdc++/92124
731 * include/bits/hashtable.h (_Hashtable<>::__alloc_node_gen_t): New
732 template alias.
733 (_Hashtable<>::__fwd_value_for): New.
734 (_Hashtable<>::_M_assign_elements<>): Remove _NodeGenerator template
735 parameter.
736 (_Hashtable<>::_M_assign<>): Add _Ht template parameter.
737 (_Hashtable<>::operator=(const _Hashtable<>&)): Adapt.
738 (_Hashtable<>::_M_move_assign): Adapt. Replace std::move_if_noexcept
739 with std::move.
740 (_Hashtable<>::_Hashtable(const _Hashtable&)): Adapt.
741 (_Hashtable<>::_Hashtable(const _Hashtable&, const allocator_type&)):
742 Adapt.
743 (_Hashtable<>::_Hashtable(_Hashtable&&, const allocator_type&)):
744 Adapt.
745 * testsuite/23_containers/unordered_set/92124.cc: New.
746
fff148b7
JW
7472020-01-08 Jonathan Wakely <jwakely@redhat.com>
748
749 PR libstdc++/93201
750 * src/c++17/fs_ops.cc (do_remove_all): New function implementing more
751 detailed error reporting for remove_all. Check result of recursive
752 call before incrementing iterator.
753 (remove_all(const path&), remove_all(const path&, error_code&)): Use
754 do_remove_all.
755 * src/filesystem/ops.cc (remove_all(const path&, error_code&)): Check
756 result of recursive call before incrementing iterator.
757 * testsuite/27_io/filesystem/operations/remove_all.cc: Check errors
758 are reported correctly.
759 * testsuite/experimental/filesystem/operations/remove_all.cc: Likewise.
760
9e3c1eb7
TR
7612020-01-07 Thomas Rodgers <trodgers@redhat.com>
762
763 * include/std/condition_variable
764 (condition_variable_any::wait_on): Rename to match current draft
765 standard.
766 (condition_variable_any::wait_on_until): Likewise.
767 (condition_variable_any::wait_on_for): Likewise.
768 * testsuite/30_threads/condition_variable_any/stop_token/wait_on.cc:
769 Adjust tests to account for renamed methods.
770
6af8819b
FD
7712020-01-07 François Dumont <fdumont@gcc.gnu.org>
772
773 PR libstdc++/92124
774 * include/bits/stl_tree.h
775 (_Rb_tree<>::_M_move_assign(_Rb_tree&, false_type)): Replace
776 std::move_if_noexcept by std::move.
777 * testsuite/23_containers/map/92124.cc: New.
778 * testsuite/23_containers/set/92124.cc: New.
779
f31a99f7
JW
7802020-01-06 Jonathan Wakely <jwakely@redhat.com>
781
a4a1f965
JW
782 * include/std/stop_token (stop_token): Remove operator!= (LWG 3254).
783 (stop_source): Likewise (LWG 3362).
784 * testsuite/30_threads/stop_token/stop_source.cc: Test equality
785 comparisons.
786
f31a99f7
JW
787 * include/bits/stl_algobase.h (__is_byte_iter, __min_cmp)
788 (lexicographical_compare_three_way): Do not depend on
789 __cpp_lib_concepts.
790 * include/std/version (__cpp_lib_three_way_comparison): Only define
791 when __cpp_lib_concepts is defined.
792 * libsupc++/compare (__cpp_lib_three_way_comparison): Likewise.
793
b4e70137
JW
7942020-01-03 Jonathan Wakely <jwakely@redhat.com>
795
796 * include/bits/stl_algobase.h (lexicographical_compare_three_way):
797 Only define four-argument overload when __cpp_lib_concepts is defined.
798
a8497ec6
JDA
7992020-01-01 John David Anglin <danglin@gcc.gnu.org>
800
801 * config/abi/post/hppa-linux-gnu/baseline_symbols.txt: Update.
802
8d9254fc 8032020-01-01 Jakub Jelinek <jakub@redhat.com>
5624e564
JJ
804
805 Update copyright years.
b4df5e92 806\f
8d9254fc 807Copyright (C) 2020 Free Software Foundation, Inc.
b4df5e92
JW
808
809Copying and distribution of this file, with or without modification,
810are permitted in any medium without royalty provided the copyright
811notice and this notice are preserved.
This page took 0.884938 seconds and 5 git commands to generate.