Update C++17 library status tables
[gcc.git] / libstdc++-v3 / ChangeLog
1 2019-04-24 Jonathan Wakely <jwakely@redhat.com>
2
3 * doc/xml/manual/status_cxx2017.xml: Document P0024R2 status.
4 * doc/html/*: Regenerate.
5
6 * include/bits/fs_path.h (operator<, operator<=, operator>)
7 (operator>=, operator==, operator!=): Make hidden friends, as per
8 LWG 3065.
9 * testsuite/27_io/filesystem/path/native/string-char8_t.cc: Fix
10 string type in test.
11 * testsuite/27_io/filesystem/path/native/string.cc: Likewise.
12
13 * include/std/any (any::any(ValueType&&)): Use __and_v.
14 * include/std/numeric (midpoint(T, T, T), midpoint(T*, T*, T*)):
15 Likewise.
16
17 * include/std/tuple (apply): Use remove_reference_t instead of decay_t
18 as per P0777R1.
19 * include/std/type_traits (__result_of_memfun): Use remove_reference
20 instead of __remove_cvref_t and remove redundant is_same check.
21 (__inv_unwrap): Use __remove_cvref_t instead of decay_t.
22
23 * include/experimental/string_view (basic_string_view::pointer)
24 (basic_string_view::reference): Fix to refer to non-const value_type.
25 * include/bits/basic_string.h (basic_string): Use __sv_check and
26 __sv_limit instead of basic_string_view::_M_check and
27 basic_string_view::_M_limit.
28 * include/std/string_view (__sv_check, __sv_limit): New
29 helper functions to replace basic_string_view::_M_check and
30 basic_string_view::_M_limit.
31 (basic_string_view): Add static assertions to enforce ill-formed
32 requirement for traits_type::char_type from P1148R0, and to enforce
33 required properties of char-like types.
34 (basic_string_view::pointer, basic_string_view::reference): Fix to
35 refer to non-const value_type.
36 (basic_string_view::operator[], basic_string_view::at)
37 (basic_string_view::front, basic_string_view::back)
38 (basic_string_view::data): Use const_reference and const_pointer
39 typedefs for return types.
40 (basic_string_view::_M_check, basic_string_view::_M_limit): Remove.
41 (hash<wstring_view>): Fix argument_type typedef.
42 * testsuite/21_strings/basic_string_view/modifiers/remove_prefix/
43 char/1.cc: Fix expected return type of basic_string_view::data().
44 * testsuite/21_strings/basic_string_view/modifiers/remove_prefix/
45 wchar_t/1.cc: Likewise.
46 * testsuite/21_strings/basic_string_view/modifiers/remove_suffix/
47 char/1.cc: Likewise.
48 * testsuite/21_strings/basic_string_view/modifiers/remove_suffix/
49 wchar_t/1.cc: Likewise.
50 * testsuite/21_strings/basic_string_view/requirements/traits_neg.cc:
51 New test.
52 * testsuite/21_strings/basic_string_view/requirements/typedefs.cc:
53 Check reference and pointer typedefs.
54 * testsuite/experimental/string_view/requirements/typedefs.cc:
55 Likewise.
56 * testsuite/experimental/string_view/modifiers/remove_prefix/char/1.cc:
57 Fix expected return type of basic_string_view::data().
58 * testsuite/experimental/string_view/modifiers/remove_prefix/wchar_t/
59 1.cc: Likewise.
60 * testsuite/experimental/string_view/modifiers/remove_suffix/char/1.cc:
61 Likewise.
62 * testsuite/experimental/string_view/modifiers/remove_suffix/wchar_t/
63 1.cc: Likewise.
64
65 PR libstdc++/90220
66 * include/std/any (__any_caster): Use remove_cv_t instead of decay_t.
67 Avoid a runtime check for types that can never be stored in std::any.
68 * testsuite/20_util/any/misc/any_cast.cc: Test std::any_cast with
69 array types.
70
71 PR libstdc++/90220 (partial)
72 * include/std/any (any_cast<T>(any*), any_cast<T>(const any*)): Do
73 not attempt ill-formed static_cast to pointers to non-object types.
74 * testsuite/20_util/any/misc/any_cast.cc: Test std::any_cast with
75 function types.
76
77 * testsuite/20_util/variant/run.cc: Catch exception by reference to
78 prevent -Wcatch-value warning.
79
80 * include/std/variant (__variant_construct): Use template parameter
81 type instead of equivalent decltype-specifier.
82 (_Move_ctor_base<false, Types...>::_Move_ctor_base(_Move_ctor_base&&)):
83 Replace forward with move.
84 (_Move_ctor_base<false, Types...>::_M_destructive_move)
85 (_Move_ctor_base<false, Types...>::_M_destructive_copy)
86 (_Move_ctor_base<true, Types...>::_M_destructive_move)
87 (_Move_ctor_base<true, Types...>::_M_destructive_copy): Only set the
88 index after construction succeeds.
89 (_Copy_assign_base<false, Types...>::operator=): Remove redundant
90 if-constexpr checks that are always true. Use __remove_cvref_t instead
91 of remove_reference so that is_nothrow_move_constructible check
92 doesn't use a const rvalue parameter. In the potentially-throwing case
93 construct a temporary and move assign it, as per LWG 2904.
94 (_Move_assign_base<false, Types...>::operator=): Remove redundant
95 if-constexpr checks that are always true. Use emplace as per LWG 2904.
96 (variant::operator=(T&&)): Only use emplace conditionally, otherwise
97 construct a temporary and move assign from it, as per LWG 2904.
98 * testsuite/20_util/variant/exception_safety.cc: Check that
99 assignment operators have strong exception safety guarantee.
100
101 2019-04-23 Thomas Rodgers <trodgers@redhat.com>
102
103 Document PSTL linker flags
104
105 * doc/xml/manual/using.xml: Add PSTL linker flags to table 3.1.
106
107 2019-04-23 Jonathan Wakely <jwakely@redhat.com>
108
109 * include/std/variant (__detail::__variant::_Traits): Make
110 _S_trivial_copy_assign depend on _S_trivial_copy_ctor and make
111 _S_trivial_move_assign depend on _S_trivial_move_ctor, as per
112 P0602R4.
113 (__detail::__variant::_Copy_assign_alias): Only depend on
114 _S_trivial_copy_assign, which subsumes _S_trivial_copy_ctor now.
115 * testsuite/20_util/variant/compile.cc: Correct checks for trivial
116 move assignment operators.
117
118 PR libstdc++/90165
119 * include/std/variant (variant::__not_self): New helper for the
120 is_same_v<remove_cvref_t<T>, variant>==false constraints.
121 (variant::__to_type_impl): Remove.
122 (variant::__to_type): Add default argument to check pack size, instead
123 of using __to_type_impl.
124 (variant::__accepted_type): Add default argument using __not_self.
125 (variant::__is_in_place_tag, variant::__not_in_place_tag): New helpers
126 for variant(T&&) constructor constraint.
127 (variant::variant(T&&)): Use __not_in_place_tag in constraints.
128 Extract __accepted_type into a named template parameter for reuse in
129 other constraints and in the exception specification.
130 (variant::variant(in_place_type_t<T>, Args&&...))
131 (variant::variant(in_place_type_t<T>, initializer_list<U>, Args&&...))
132 (variant::variant(in_place_index_t<T>, Args&&...))
133 (variant::variant(in_place_index_t<T>, initializer_list<U>, Args&&...))
134 (variant::operator=T&&)): Remove redundant && from trait arguments.
135 * testsuite/20_util/variant/compile.cc: Check variant(T&&) constructor
136 isn't used for in_place_type or in_place_index arguments.
137
138 * include/std/type_traits (unwrap_reference_t): Define for C++2a.
139 (unwrap_ref_decay): Remove inheritance from unwrap_reference.
140 * testsuite/20_util/unwrap_reference/1.cc: Adjust test to use alias.
141
142 2019-04-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
143 Bernd Edlinger <bernd.edlinger@hotmail.de>
144 Jakub Jelinek <jakub@redhat.com>
145
146 PR target/89093
147 * libsupc++/eh_personality.cc (PERSONALITY_FUNCTION): Add
148 general-regs-only target attribute for ARM.
149
150 2019-04-23 Jonathan Wakely <jwakely@redhat.com>
151
152 PR libstdc++/87431
153 * include/bits/basic_string.h (_Never_valueless_alt): Make partial
154 specialization also depend on is_nothrow_move_constructible.
155 * include/std/variant (__detail::__variant::__never_valueless()):
156 Only true if the variant would have a move assignment operator.
157 (__detail::__variant::_Variant_storage<false, T...>::_M_valid()):
158 Check __never_valueless<T...>().
159 (variant::emplace): Only perform non-throwing move assignments
160 for never-valueless alternatives if the variant has a move assignment
161 operator.
162 * testsuite/20_util/variant/compile.cc: Check that never-valueless
163 types can be emplaced into non-assignable variants.
164 * testsuite/20_util/variant/run.cc: Check that never-valueless types
165 don't get copied when emplaced into non-assignable variants.
166
167 * include/std/variant (__detail::__variant::__ref_cast): Remove
168 unused function.
169 (__detail::__variant::_Uninitialized::_M_get)
170 (__detail::__variant::__get)
171 (__gen_vtable_impl::__element_by_index_or_cookie): Add noexcept.
172
173 2019-04-21 Iain Sandoe <iain@sandoe.co.uk>
174
175 * testsuite/17_intro/headers/c++1998/charset.cc: Skip for Darwin8
176 to Darwin10.
177 * testsuite/17_intro/headers/c++2011/charset.cc: Likewise.
178 * testsuite/17_intro/headers/c++2014/charset.cc: Likewise.
179 * testsuite/17_intro/headers/c++2017/charset.cc: Likewise.
180 * testsuite/17_intro/headers/c++2020/charset.cc: Likewise.
181
182 2019-04-20 Thomas Rodgers <trodgers@redhat.com>
183
184 Delegate PSTL configuration to pstl/pstl_config.h
185
186 * include/bits/c++config: Remove explicit PSTL configuration
187 macros and use definitions from <pstl/pstl_config.h>.
188
189 2019-04-20 Thomas Rodgers <trodgers@redhat.com>
190
191 Cleanup algorithm implementations
192 * include/pstl/glue_algorithm_impl.h (stable_sort): Forward
193 execution policy.
194 (mismatch): Forward execution policy.
195 (equal): Qualify call to std::equal().
196 (partial_sort): Forward execution policy.
197 (inplace_merge): Forward execution policy.
198
199 2019-04-19 Thomas Rodgers <trodgers@redhat.com>
200
201 Improve implementation of parallel equal()
202 * include/pstl/algorithm_impl.h
203 (__internal::__brick_equal): use "4 iterator" version of
204 std::equal().
205 (__internal::__brick_equal): use simd for random access
206 iterators on unsequenced execution policies.
207 (__internal::__pattern_equal): add "4 iterator" version
208 (__internal::__pattern_equal): dispatch to simd __brick_equal
209 for vector-only execution policies.
210 (__internal::__pattern_equal): dispatch to __parallel_or for
211 parallel execution policies.
212 * include/pstl/glue_algorithm_impl.h
213 (std::equal): dispatch to "4 iterator" version of
214 __internal::__pattern_equal().
215
216 2019-04-17 Jonathan Wakely <jwakely@redhat.com>
217
218 PR libstdc++/90105
219 * include/bits/forward_list.h (operator==): Do not use operator!= to
220 compare elements.
221 (forward_list<T, A>::sort(Comp)): When elements are equal take the one
222 earlier in the list, so that sort is stable.
223 * testsuite/23_containers/forward_list/operations/90105.cc: New test.
224 * testsuite/23_containers/forward_list/comparable.cc: Test with
225 types that meet the minimum EqualityComparable and LessThanComparable
226 requirements. Remove irrelevant comment.
227
228 * include/std/variant (__detail::__variant::_Traits::_S_copy_assign):
229 Do not depend on whether all alternative types are move constructible.
230 (__detail::__variant::_Copy_assign_base::operator=): Remove cv-quals
231 from the operand when deciding whether to perform the assignment.
232 * testsuite/20_util/variant/compile.cc (DeletedMoves): Define type
233 with deleted move constructor and deleted move assignment operator.
234 (default_ctor, copy_ctor, move_ctor, copy_assign, move_assign): Check
235 behaviour of variants with DeletedMoves as an alternative.
236 * testsuite/20_util/variant/run.cc (DeletedMoves): Define same type.
237 (move_ctor, move_assign): Check that moving a variant with a
238 DeletedMoves alternative falls back to copying instead of moving.
239
240 * testsuite/20_util/variant/compile.cc: Remove empty string literals
241 from static_assert declarations.
242
243 * testsuite/20_util/variant/compile.cc (MoveCtorOnly): Fix type to
244 actually match its name.
245 (MoveCtorAndSwapOnly): Define new type that adds swap to MoveCtorOnly.
246 (test_swap()): Fix result for MoveCtorOnly and check
247 MoveCtorAndSwapOnly.
248
249 * include/std/optional (optional::value_or(U&&) &&): Add missing
250 constexpr specifier.
251 * testsuite/20_util/optional/constexpr/observers/4.cc: Check value_or
252 for disengaged optionals and rvalue optionals.
253 * testsuite/20_util/optional/observers/4.cc: Likewise.
254
255 2019-04-12 Thomas Rodgers <trodgers@redhat.com>
256
257 * include/pstl/algorithm_impl.h: Uglify identfiers.
258 * include/pstl/numeric_impl.h: Uglify identfiers.
259 * include/pstl/parallel_backend_tbb.h: Uglify identfiers.
260
261 2019-04-11 Thomas Rodgers <trodgers@redhat.com>
262
263 * include/bits/c++config:
264 Add definition for __PSTL_ASSERT.
265 Add definition for __PSTL_ASSERT_MSG.
266 * include/pstl/algorithm_impl.h: Replace use of assert().
267 * include/pstl/numeric_impl.h: Replace use of assert().
268 * include/pstl/parallel_backend_tbb.h:
269 Replace use of assert().
270 Replace use of __TBB_ASSERT().
271 * include/pstl/parallel_backend_utils.h: Replace use of assert().
272
273 2019-04-11 Jonathan Wakely <jwakely@redhat.com>
274
275 PR libstdc++/90046
276 * src/c++17/memory_resource.cc
277 (monotonic_buffer_resource::_Chunk::allocate): Increase alignment if
278 needed to allow placing a _Chunk at the end of the buffer.
279 (monotonic_buffer_resource::_M_new_buffer): Remove static_assert.
280
281 2019-04-10 Jonathan Wakely <jwakely@redhat.com>
282
283 * doc/xml/faq.xml: Add information about emergency EH pool.
284 * doc/xml/manual/debug.xml: Update list of memory debugging tools.
285 Move outdated information on mt_allocator to a separate section.
286 * doc/xml/manual/evolution.xml: Clarify that GLIBCXX_FORCE_NEW
287 doesn't affect the default allocator.
288
289 * testsuite/lib/libstdc++.exp (check_v3_target_parallel_mode): Fix
290 typo.
291
292 PR libstdc++/89851
293 * testsuite/20_util/variant/89851.cc: New test.
294
295 2019-04-09 Jonathan Wakely <jwakely@redhat.com>
296
297 * include/std/variant: Adjust whitespace. Add comments.
298 (_Multi_array): Leave primary template undefined.
299 (_Multi_array<_Tp>): Define partial specialization for base case of
300 recursion.
301 (__gen_vtable_impl, __gen_vtable): Remove redundant && from type
302 which is always a reference.
303 (__gen_vtable::_S_apply()): Remove function, inline body into
304 default member initializer.
305 * testsuite/20_util/variant/visit.cc: Test with noncopyable types.
306
307 * include/std/variant (__variant_idx_cookie): Add member type.
308 (__visitor_result_type): Remove.
309 (__do_visit): Use invoke_result instead of __visitor_result_type.
310 * testsuite/20_util/variant/visit.cc: New test.
311
312 PR libstdc++/90008
313 * include/std/variant (_VARIANT_RELATION_FUNCTION_TEMPLATE): Remove
314 unused capture.
315 * testsuite/20_util/variant/90008.cc: New test.
316
317 2019-04-09 Thomas Rodgers <trodgers@redhat.com>
318
319 * include/pstl/algorithm_impl.h: Add namespace qualification.
320 * include/pstl/execution_defs.h: Add namespace qualification.
321 * include/pstl/execution_impl.h: Add namespace qualification.
322 * include/pstl/numeric_impl.h: Add namespace qualification.
323 * include/pstl/parallel_backend_tbb.h: Add namespace qualification.
324 * include/pstl/unseq_backend_simd.h: Add namespace qualification.
325 * include/pstl/parallel_backend_utils.h: Include <cassert>.
326
327 2019-04-08 Ville Voutilainen <ville.voutilainen@gmail.com>
328
329 Fix visit<R> for variant.
330 * include/std/variant (__do_visit): Add a template parameter
331 for enforcing same return types for visit.
332 (__gen_vtable_impl): Likewise.
333 (_S_apply_single_alt): Adjust.
334 (__visit_invoke_impl): New. Handle casting to void.
335 (__do_visit_invoke): New. Enforces same return types.
336 (__do_visit_invoke_r): New. Converts return types.
337 (__visit_invoke): Adjust.
338 (__gen_vtable): Add a template parameter for enforcing
339 same return types for visit.
340 * testsuite/20_util/variant/visit_r.cc: Add a test for a visitor with
341 different return types.
342 * testsuite/20_util/variant/visit_neg.cc: New. Ensures that
343 visitors with different return types don't accidentally
344 compile with regular visitation.
345
346 2019-04-08 Christophe Lyon <christophe.lyon@linaro.org>
347
348 * testsuite/27_io/filesystem/iterators/caching.cc: Add
349 dg-require-filesystem-ts.
350
351 2019-04-05 Jonathan Wakely <jwakely@redhat.com>
352
353 * doc/xml/manual/status_cxx2020.xml: Update status.
354 * include/std/variant (visit<R>): Define for C++2a (P0655R1).
355 * testsuite/20_util/variant/visit_r.cc: New test.
356
357 * include/bits/fs_dir.h (directory_iterator::operator*)
358 (directory_iterator::operator->): Add noexcept.
359 (operator==, operator!=): Replace namespace-scope equality operators
360 for directory iterators with hidden friends.
361
362 PR libstdc++/89986
363 * config/abi/pre/gnu.ver: Add missing exports.
364 * testsuite/27_io/filesystem/iterators/directory_iterator.cc: Test
365 increment member.
366
367 * config/abi/pre/gnu.ver: Export new symbols.
368 * include/bits/fs_dir.h (recursive_directory_iterator::options())
369 (recursive_directory_iterator::recursion_pending())
370 (recursive_directory_iterator::disable_recursion_pending()): Remove
371 inline definitions. Make noexcept.
372 (recursive_directory_iterator::depth())
373 (recursive_directory_iterator::operator*())
374 (recursive_directory_iterator::operator->()): Make noexcept.
375 (recursive_directory_iterator::_M_options)
376 (recursive_directory_iterator::_M_pending): Remove data members.
377 * src/c++17/fs_path.cc (_Dir_stack): Add constructor and data members.
378 (recursive_directory_iterator::recursive_directory_iterator): Remove
379 ctor-initializer. Use new constructor for _Dir_stack.
380 (recursive_directory_iterator::options())
381 (recursive_directory_iterator::recursion_pending())
382 (recursive_directory_iterator::disable_recursion_pending()): Add
383 non-inline definitions.
384 (recursive_directory_iterator::depth()): Make noexcept.
385 (recursive_directory_iterator::increment(error_code&))
386 (recursive_directory_iterator::pop(error_code&)): Adjust to new
387 location of options and recursion_pending members.
388 * testsuite/27_io/filesystem/iterators/recursion_pending.cc: New test.
389 * testsuite/util/testsuite_fs.h (__gnu_test::scoped_file): Add
390 user-declared move constructor and assignment operator, to make the
391 type move-only.
392
393 * src/c++17/fs_dir.cc (_Dir::advance(bool, error_code&)): Handle
394 d_type == DT_UNKNOWN immediately.
395 (_Dir::should_recurse(bool, error_code&)): Remove file_type::unknown
396 handling here.
397 * testsuite/27_io/filesystem/iterators/caching.cc: New test.
398
399 * include/bits/fs_path.h (path::operator=(path&&)): Check for self
400 assignment.
401 * src/c++17/fs_path.cc (path::operator=(const path&)): Likewise.
402 * testsuite/27_io/filesystem/path/assign/copy.cc: Test self
403 assignment.
404
405 PR libstdc++/87431 (again)
406 * include/bits/basic_string.h (__variant::_Never_valueless_alt):
407 Define partial specialization for basic_string.
408 * include/bits/shared_ptr.h (_Never_valueless_alt): Likewise for
409 shared_ptr and weak_ptr.
410 * include/bits/std_function.h (_Never_valueless_alt): Likewise for
411 function.
412 * include/bits/stl_vector.h (_Never_valueless_alt): Likewise for
413 vector.
414 * include/bits/unique_ptr.h (_Never_valueless_alt): Likewise for
415 unique_ptr.
416 * include/debug/vector (_Never_valueless_alt): Likewise for debug
417 vector.
418 * include/std/any (_Never_valueless_alt): Define explicit
419 specialization for any.
420 * include/std/variant (_Never_valueless_alt): Define primary template.
421 (__never_valueless): Use _Never_valueless_alt instead of
422 is_trivially_copyable.
423 (variant::emplace<N>(Args&&...)): Add special case for non-throwing
424 initializations to avoid try-catch overhead. Add special case for
425 scalars produced by potentially-throwing conversions. Use
426 _Never_valueless_alt instead of is_trivially_copyable for the
427 remaining strong exception-safety cases.
428 (variant::emplace<N>(initializer_list<U>, Args&&...)): Likewise.
429 * testsuite/20_util/variant/87431.cc: Run both test functions.
430 * testsuite/20_util/variant/exception_safety.cc: New test.
431 * testsuite/20_util/variant/run.cc: Use pmr::string instead of string,
432 so the variant becomes valueless.
433
434 2019-04-03 Jonathan Wakely <jwakely@redhat.com>
435
436 PR libstdc++/85184
437 * include/std/variant (_Copy_assign_base, _Move_assign_base, variant):
438 Remove assertions.
439 (variant::emplace<_Tp>): Return result of emplace<N> directly.
440
441 * include/std/string (__hash_string_base): New class template defining
442 operator() for hashing strings.
443 (hash<pmr::string>, hash<pmr::u8string>, hash<pmr::u16string>)
444 (hash<pmr::u32string>, hash<pmr::wstring>): Define for C++17.
445 * testsuite/21_strings/basic_string/hash/hash.cc: New test.
446 * testsuite/21_strings/basic_string/hash/hash_char8_t.cc: New test.
447
448 2019-04-01 Ville Voutilainen <ville.voutilainen@gmail.com>
449
450 Use single-visitation in variant assignment and swap and relops.
451 Also use indices instead of types when checking whether
452 variants hold the same thing.
453 * include/std/variant (__do_visit): Add a template parameter
454 for index visitation, invoke with indices if index visitation
455 is used.
456 (__variant_idx_cookie): New.
457 (__visit_with_index): Likewise.
458 (_Copy_assign_base::operator=): Do single-visitation with
459 an index visitor.
460 (_Move_assign_base::operator=): Likewise.
461 (_Extra_visit_slot_needed): Adjust.
462 (__visit_invoke): Call with indices if it's an index visitor.
463 (relops): Do single-visitation with an index visitor.
464 (swap): Likewise.
465 (__visitor_result_type): New.
466
467 2019-03-30 Eric Botcazou <ebotcazou@adacore.com>
468
469 * src/c++17/fs_ops.cc (fs::permissions): Use std::errc::not_supported.
470
471 2019-03-28 Ville Voutilainen <ville.voutilainen@gmail.com>
472
473 Don't revisit a variant we are already visiting.
474 * include/std/variant (__variant_construct_single): New.
475 (__variant_construct): Use it.
476 (_M_destructive_move): Likewise.
477 (_M_destructive_copy): Likewise.
478 (_Copy_assign_base::operator=): Adjust.
479 (_Move_assign_base::operator=): Likewise.
480 (swap): Likewise.
481
482 2019-03-26 Jonathan Wakely <jwakely@redhat.com>
483
484 PR libstdc++/85965
485 * include/bits/hashtable.h (_Hashtable): Move static assertions to
486 destructor so they are not evaluated until the _Key type is complete.
487 * include/bits/stl_tree.h (_Rb_tree): Likewise.
488 * testsuite/23_containers/set/85965.cc: New test.
489 * testsuite/23_containers/unordered_set/85965.cc: New test.
490 * testsuite/23_containers/map/48101_neg.cc: Replace "here" errors
491 with regexp matching the corresponding _Rb_tree specialization.
492 * testsuite/23_containers/multimap/48101_neg.cc: Likewise.
493 * testsuite/23_containers/multiset/48101_neg.cc: Remove "here" error.
494 * testsuite/23_containers/set/48101_neg.cc: Likewise.
495 * testsuite/23_containers/unordered_map/48101_neg.cc: Likewise.
496 * testsuite/23_containers/unordered_multimap/48101_neg.cc: Likewise.
497 * testsuite/23_containers/unordered_multiset/48101_neg.cc: Likewise.
498 * testsuite/23_containers/unordered_set/48101_neg.cc: Likewise.
499
500 2019-03-26 Ville Voutilainen <ville.voutilainen@gmail.com>
501
502 PR libstdc++/89825
503 Fix based on a suggestion by Antony Polukhin.
504 * include/std/variant (__never_valueless): New.
505 (_M_valid): Use it.
506 (_Extra_visit_slot_needed): New.
507 (_Multi_array): Use it.
508 (_S_apply_all_alts): Likewise.
509
510 2019-03-26 Ville Voutilainen <ville.voutilainen@gmail.com>
511
512 PR libstdc++/89824
513 Fix based on a suggestion by Antony Polukhin.
514 * include/std/variant (__gen_vtable): Don't reserve an
515 additional table slot, _Multi_array already does that.
516
517 2019-03-26 Ville Voutilainen <ville.voutilainen@gmail.com>
518
519 PR libstdc++/89816
520 Fix based on a suggestion by Antony Polukhin.
521 * include/std/variant (__variant_construct): Capture a pointer
522 to the storage and visit just one variant.
523
524 2019-03-22 Jonathan Wakely <jwakely@redhat.com>
525
526 * doc/xml/manual/backwards_compatibility.xml: Remove link to
527 Doxygen-generated pages with unstable URL.
528 * doc/xml/manual/concurrency_extensions.xml: Likewise.
529 * doc/xml/manual/extensions.xml: Likewise.
530 * doc/xml/manual/parallel_mode.xml: Likewise.
531 * doc/xml/manual/support.xml: Likewise.
532
533 * include/bits/stl_algobase.h (__lg): Do arithmetic on type int to
534 avoid -Wconversion warnings.
535
536 2019-03-21 Thomas Rodgers <trodgers@redhat.com>
537
538 * include/Makefile.am (std_header): Add ${std_srcdir}/execution.
539 (pstl_srcdir, pstl_builddir, pstl_headers): New variables.
540 (allstamped): Add stamp-pstl.
541 (install-headers): Add ptsl_builddir.
542 * include/Makefile.in: Regenerate.
543 * include/bits/c++config: Add pstl configuration.
544 * include/pstl/LICENSE.txt: New file.
545 * include/pstl/algorithm_fwd.h: New file.
546 * include/pstl/algorithm_impl.h: New file.
547 * include/pstl/execution_defs.h: New file.
548 * include/pstl/execution_impl.h: New file.
549 * include/pstl/glue_algorithm_defs.h: New file.
550 * include/pstl/glue_algorithm_impl.h: New file.
551 * include/pstl/glue_execution_defs.h: New file.
552 * include/pstl/glue_memory_defs.h: New file.
553 * include/pstl/glue_memory_impl.h: New file.
554 * include/pstl/glue_numeric_defs.h: New file.
555 * include/pstl/glue_numeric_impl.h: New file.
556 * include/pstl/memory_impl.h: New file.
557 * include/pstl/numeric_fwd.h: New file.
558 * include/pstl/numeric_impl.h: New file.
559 * include/pstl/parallel_backend.h: New file.
560 * include/pstl/parallel_backend_tbb.h: New file.
561 * include/pstl/parallel_backend_utils.h: New file.
562 * include/pstl/parallel_impl.h: New file.
563 * include/pstl/pstl_config.h: New file.
564 * include/pstl/unseq_backend_simd.h: New file.
565 * include/pstl/utils.h: New file.
566 * include/std/algorithm: Include parallel algorithm implementations.
567 * include/std/execution: New file.
568 * include/std/memory: Include parallel algorithm implementations.
569 * include/std/numeric: Include parallel algorithm implementations.
570 * include/std/version: Add parallel algorithms feature test macro.
571 * testsuite/util/pstl/pstl_test_config.h: New file.
572 * testsuite/util/pstl/test_utils.h: New file.
573 * testsuite/20_util/specialized_algorithms/pstl/uninitialized_construct.cc: New file.
574 * testsuite/20_util/specialized_algorithms/pstl/uninitialized_copy_move.cc: New file.
575 * testsuite/20_util/specialized_algorithms/pstl/uninitialized_fill_destroy.cc: New file.
576 * testsuite/25_algorithms/pstl/alg_merge/inplace_merge.cc: New file.
577 * testsuite/25_algorithms/pstl/alg_merge/merge.cc: New file.
578 * testsuite/25_algorithms/pstl/alg_modifying_operations/copy_if.cc: New file.
579 * testsuite/25_algorithms/pstl/alg_modifying_operations/copy_move.cc: New file.
580 * testsuite/25_algorithms/pstl/alg_modifying_operations/fill.cc: New file.
581 * testsuite/25_algorithms/pstl/alg_modifying_operations/generate.cc: New file.
582 * testsuite/25_algorithms/pstl/alg_modifying_operations/is_partitioned.cc: New file.
583 * testsuite/25_algorithms/pstl/alg_modifying_operations/partition.cc: New file.
584 * testsuite/25_algorithms/pstl/alg_modifying_operations/partition_copy.cc: New file.
585 * testsuite/25_algorithms/pstl/alg_modifying_operations/remove.cc: New file.
586 * testsuite/25_algorithms/pstl/alg_modifying_operations/remove_copy.cc: New file.
587 * testsuite/25_algorithms/pstl/alg_modifying_operations/replace.cc: New file.
588 * testsuite/25_algorithms/pstl/alg_modifying_operations/replace_copy.cc: New file.
589 * testsuite/25_algorithms/pstl/alg_modifying_operations/rotate.cc: New file.
590 * testsuite/25_algorithms/pstl/alg_modifying_operations/rotate_copy.cc: New file.
591 * testsuite/25_algorithms/pstl/alg_modifying_operations/swap_ranges.cc: New file.
592 * testsuite/25_algorithms/pstl/alg_modifying_operations/transform_binary.cc: New file.
593 * testsuite/25_algorithms/pstl/alg_modifying_operations/transform_unary.cc: New file.
594 * testsuite/25_algorithms/pstl/alg_modifying_operations/unique.cc: New file.
595 * testsuite/25_algorithms/pstl/alg_modifying_operations/unique_copy_equal.cc: New file.
596 * testsuite/25_algorithms/pstl/alg_nonmodifying/adjacent_find.cc: New file.
597 * testsuite/25_algorithms/pstl/alg_nonmodifying/all_of.cc: New file.
598 * testsuite/25_algorithms/pstl/alg_nonmodifying/any_of.cc: New file.
599 * testsuite/25_algorithms/pstl/alg_nonmodifying/count.cc: New file.
600 * testsuite/25_algorithms/pstl/alg_nonmodifying/equal.cc: New file.
601 * testsuite/25_algorithms/pstl/alg_nonmodifying/find.cc: New file.
602 * testsuite/25_algorithms/pstl/alg_nonmodifying/find_end.cc: New file.
603 * testsuite/25_algorithms/pstl/alg_nonmodifying/find_first_of.cc: New file.
604 * testsuite/25_algorithms/pstl/alg_nonmodifying/find_if.cc: New file.
605 * testsuite/25_algorithms/pstl/alg_nonmodifying/for_each.cc: New file.
606 * testsuite/25_algorithms/pstl/alg_nonmodifying/mismatch.cc: New file.
607 * testsuite/25_algorithms/pstl/alg_nonmodifying/none_of.cc: New file.
608 * testsuite/25_algorithms/pstl/alg_nonmodifying/nth_element.cc: New file.
609 * testsuite/25_algorithms/pstl/alg_nonmodifying/reverse.cc: New file.
610 * testsuite/25_algorithms/pstl/alg_nonmodifying/reverse_copy.cc: New file.
611 * testsuite/25_algorithms/pstl/alg_nonmodifying/search_n.cc: New file.
612 * testsuite/25_algorithms/pstl/alg_sorting/includes.cc: New file.
613 * testsuite/25_algorithms/pstl/alg_sorting/is_heap.cc: New file.
614 * testsuite/25_algorithms/pstl/alg_sorting/is_sorted.cc: New file.
615 * testsuite/25_algorithms/pstl/alg_sorting/lexicographical_compare.cc: New file.
616 * testsuite/25_algorithms/pstl/alg_sorting/minmax_element.cc: New file.
617 * testsuite/25_algorithms/pstl/alg_sorting/partial_sort.cc: New file.
618 * testsuite/25_algorithms/pstl/alg_sorting/partial_sort_copy.cc: New file.
619 * testsuite/25_algorithms/pstl/alg_sorting/set.cc: New file.
620 * testsuite/25_algorithms/pstl/alg_sorting/sort.cc: New file.
621 * testsuite/26_numerics/pstl/numeric_ops/adjacent_difference.cc: New file.
622 * testsuite/26_numerics/pstl/numeric_ops/reduce.cc: New file.
623 * testsuite/26_numerics/pstl/numeric_ops/scan.cc: New file.
624 * testsuite/26_numerics/pstl/numeric_ops/transform_reduce.cc: New file.
625 * testsuite/26_numerics/pstl/numeric_ops/transform_scan.cc: New file.
626 * testsuite/testsuite/20_util/specialized_algorithms/pstl/uninitialized_construct.cc: New file.
627 * testsuite/testsuite/20_util/specialized_algorithms/pstl/uninitialized_copy_move.cc: New file.
628 * testsuite/testsuite/20_util/specialized_algorithms/pstl/uninitialized_fill_destroy.cc: New file.
629 * testsuite/testsuite/25_algorithms/pstl/alg_merge/inplace_merge.cc: New file.
630 * testsuite/testsuite/25_algorithms/pstl/alg_merge/merge.cc: New file.
631 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/copy_if.cc: New file.
632 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/copy_move.cc: New file.
633 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/fill.cc: New file.
634 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/generate.cc: New file.
635 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/is_partitioned.cc: New file.
636 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/partition.cc: New file.
637 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/partition_copy.cc: New file.
638 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/remove.cc: New file.
639 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/remove_copy.cc: New file.
640 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/replace.cc: New file.
641 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/replace_copy.cc: New file.
642 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/rotate.cc: New file.
643 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/rotate_copy.cc: New file.
644 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/swap_ranges.cc: New file.
645 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/transform_binary.cc: New file.
646 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/transform_unary.cc: New file.
647 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/unique.cc: New file.
648 * testsuite/testsuite/25_algorithms/pstl/alg_modifying_operations/unique_copy_equal.cc: New file.
649 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/adjacent_find.cc: New file.
650 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/all_of.cc: New file.
651 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/any_of.cc: New file.
652 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/count.cc: New file.
653 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/equal.cc: New file.
654 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/find.cc: New file.
655 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/find_end.cc: New file.
656 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/find_first_of.cc: New file.
657 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/find_if.cc: New file.
658 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/for_each.cc: New file.
659 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/mismatch.cc: New file.
660 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/none_of.cc: New file.
661 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/nth_element.cc: New file.
662 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/reverse.cc: New file.
663 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/reverse_copy.cc: New file.
664 * testsuite/testsuite/25_algorithms/pstl/alg_nonmodifying/search_n.cc: New file.
665 * testsuite/testsuite/25_algorithms/pstl/alg_sorting/includes.cc: New file.
666 * testsuite/testsuite/25_algorithms/pstl/alg_sorting/is_heap.cc: New file.
667 * testsuite/testsuite/25_algorithms/pstl/alg_sorting/is_sorted.cc: New file.
668 * testsuite/testsuite/25_algorithms/pstl/alg_sorting/lexicographical_compare.cc: New file.
669 * testsuite/testsuite/25_algorithms/pstl/alg_sorting/minmax_element.cc: New file.
670 * testsuite/testsuite/25_algorithms/pstl/alg_sorting/partial_sort.cc: New file.
671 * testsuite/testsuite/25_algorithms/pstl/alg_sorting/partial_sort_copy.cc: New file.
672 * testsuite/testsuite/25_algorithms/pstl/alg_sorting/set.cc: New file.
673 * testsuite/testsuite/25_algorithms/pstl/alg_sorting/sort.cc: New file.
674 * testsuite/testsuite/26_numerics/pstl/numeric_ops/adjacent_difference.cc: New file.
675 * testsuite/testsuite/26_numerics/pstl/numeric_ops/reduce.cc: New file.
676 * testsuite/testsuite/26_numerics/pstl/numeric_ops/scan.cc: New file.
677 * testsuite/testsuite/26_numerics/pstl/numeric_ops/transform_reduce.cc: New file.
678 * testsuite/testsuite/26_numerics/pstl/numeric_ops/transform_scan.cc: New file.
679
680 2019-03-21 Jonathan Wakely <jwakely@redhat.com>
681
682 * include/c_compatibility/math.h [!__STDCPP_WANT_MATH_SPEC_FUNCS__]
683 (assoc_laguerre, assoc_laguerref, assoc_laguerrel, assoc_legendre)
684 (assoc_legendref, assoc_legendrel, beta, betaf, betal, comp_ellint_1)
685 (comp_ellint_1f, comp_ellint_1l, comp_ellint_2, comp_ellint_2f)
686 (comp_ellint_2l, comp_ellint_3, comp_ellint_3f, comp_ellint_3l)
687 (cyl_bessel_i, cyl_bessel_if, cyl_bessel_il, cyl_bessel_j)
688 (cyl_bessel_jf, cyl_bessel_jl, cyl_bessel_k, cyl_bessel_kf)
689 (cyl_bessel_kl, cyl_neumann, cyl_neumannf, cyl_neumannl, ellint_1)
690 (ellint_1f, ellint_1l, ellint_2, ellint_2f, ellint_2l, ellint_3)
691 (ellint_3f, ellint_3l, expint, expintf, expintl, hermite, hermitef)
692 (hermitel, laguerre, laguerref, laguerrel, legendre, legendref)
693 (legendrel, riemann_zeta, riemann_zetaf, riemann_zetal, sph_bessel)
694 (sph_besself, sph_bessell, sph_legendre, sph_legendref, sph_legendrel)
695 (sph_neumann, sph_neumannf, sph_neumannl): Only add using-declarations
696 when the special functions IS is enabled, not for C++17.
697 * testsuite/26_numerics/headers/cmath/functions_global_c++17.cc:
698 Replace with ...
699 * testsuite/26_numerics/headers/cmath/functions_global.cc: New test,
700 without checks for special functions in C++17.
701 * testsuite/26_numerics/headers/cmath/special_functions_global.cc:
702 New test.
703
704 PR libstdc++/88066
705 * include/backward/hash_map: Use <> for includes not "".
706 * include/backward/hash_set: Likewise.
707 * include/backward/strstream: Likewise.
708 * include/tr1/bessel_function.tcc: Likewise.
709 * include/tr1/exp_integral.tcc: Likewise.
710 * include/tr1/legendre_function.tcc: Likewise.
711 * include/tr1/modified_bessel_func.tcc: Likewise.
712 * include/tr1/riemann_zeta.tcc: Likewise.
713
714 2019-03-19 Jonathan Wakely <jwakely@redhat.com>
715
716 * doc/xml/manual/allocator.xml: Link to table documenting evolution
717 of extension allocators.
718 * doc/xml/manual/evolution.xml: Use angle brackets for header names.
719 Document new headers in 7.2, 8.1 and 9.1 releases.
720 * doc/xml/manual/using.xml: Adjust link target for new_allocator.
721 * doc/html/*: Regenerate.
722
723 2019-03-12 John David Anglin <dave.anglin@bell.net>
724
725 PR libstdc++/89461
726 * testsuite/lib/libstdc++.exp: Locate libatomic.
727 * testsuite/lib/dg-options.exp (add_options_for_libatomic): New.
728 * testsuite/20_util/shared_ptr/thread/default_weaktoshared.cc: Add
729 libatomic options.
730 * testsuite/20_util/shared_ptr/thread/mutex_weaktoshared.cc: Likewise.
731 * testsuite/experimental/net/timer/waitable/cons.cc: Likewise.
732 * testsuite/experimental/net/timer/waitable/dest.cc: Likewise.
733 * testsuite/experimental/net/timer/waitable/ops.cc: Likewise.
734
735 2019-03-11 Jonathan Wakely <jwakely@redhat.com>
736
737 PR libstdc++/89460
738 * configure.ac: Check for sockatmark.
739 * crossconfig.m4: Check for sockatmark.
740 * config.h.in: Regenerate.
741 * configure: Regenerate.
742 * include/experimental/internet (address_v4::_S_hton): Rename
743 overloaded functions to _S_hton_16 and _S_ntoh_16.
744 (address_v4::_S_ntoh): Rename to _S_ntoh_16 and _S_ntoh_32.
745 (basic_endpoint): Adjust calls to _S_hton and _S_ntoh.
746 * include/experimental/socket (basic_socket::at_mark): Check
747 _GLIBCXX_HAVE_SOCKATMARK.
748
749 * testsuite/29_atomics/atomic_flag/test_and_set/explicit-hle.cc: Use
750 const variables instead of macros.
751
752 PR libstdc++/89629
753 * libsupc++/hash_bytes.cc [__SIZEOF_SIZE_T__ == 8] (_Hash_bytes):
754 Use correct type for len_aligned.
755 * testsuite/20_util/hash/89629.cc: New test.
756
757 2019-03-11 Jakub Jelinek <jakub@redhat.com>
758
759 PR libstdc++/89641
760 * include/std/atomic (atomic<T>::store, atomic<T>::load,
761 atomic<T>::exchange, atomic<T>::compare_exchange_weak,
762 atomic<T>::compare_exchange_strong): Cast __m or __s and __f to int.
763 * include/bits/atomic_base.h (__atomic_base<T>::operator++,
764 __atomic_base<T>::operator--, __atomic_base<T>::operator+=,
765 __atomic_base<T>::operator-=, __atomic_base<T>::operator&=,
766 __atomic_base<T>::operator|=, __atomic_base<T>::operator^=,
767 __atomic_base<T*>::operator++, __atomic_base<T*>::operator--,
768 __atomic_base<T*>::operator+=, __atomic_base<T*>::operator-=): Cast
769 memory_order_seq_cst to int.
770
771 2019-03-08 Jonathan Wakely <jwakely@redhat.com>
772
773 * doc/xml/manual/using.xml: Use link element instead of xref.
774 * doc/html/*: Regenerate.
775
776 * include/bits/fs_path.h (path::format): Add fixed underlying type.
777
778 2019-03-08 François Dumont <fdumont@gcc.gnu.org>
779
780 PR libstdc++/89477
781 * include/debug/map.h (map): Use _RequireNotAllocator to constrain
782 parameters in deduction guides.
783 * include/debug/multimap.h (multimap): Likewise.
784 * include/debug/set.h (multimap): Likewise.
785 * include/debug/multiset.h (multimap): Likewise.
786 * include/debug/unordered_map (unordered_map): Likewise.
787 (unordered_multimap): Likewise.
788 * include/debug/unordered_set (unordered_set): Likewise.
789 (unordered_multiset): Likewise.
790
791 PR libstdc++/89608
792 * include/debug/unordered_map (unordered_map<>::_M_check_rehashed):
793 Invalidate all iterators in case of rehash.
794 (unordered_multimap<>::_M_check_rehashed): Likewise.
795 * include/debug/unordered_set
796 (unordered_set<>::_M_check_rehashed): Likewise.
797 (unordered_multiset<>::_M_check_rehashed): Likewise.
798 * testsuite/23_containers/unordered_set/debug/89608_neg.cc: New.
799
800 2019-03-07 Andreas Schwab <schwab@suse.de>
801
802 * config/abi/post/riscv64-linux-gnu: New directory.
803 * config/abi/post/riscv64-linux-gnu/baseline_symbols.txt: New file.
804
805 2019-03-07 Jonathan Wakely <jwakely@redhat.com>
806
807 * testsuite/20_util/function_objects/bind_front/1.cc: Change from
808 compile test to run. Fix typo.
809
810 * doc/xml/manual/status_cxx2020.xml: Update C++20 status.
811 * doc/html/*: Regenerate.
812
813 P0356R5 Simplified partial function application
814 * include/std/functional [C++20] (_Bind_front, _Bind_front_t): Define
815 helpers for bind_front.
816 (bind_front, __cpp_lib_bind_front): Define.
817 * testsuite/20_util/function_objects/bind_front/1.cc: New test.
818
819 2019-03-06 Jonathan Wakely <jwakely@redhat.com>
820
821 * include/std/type_traits (__cpp_lib_bounded_array_traits): Define.
822 * include/std/version (__cpp_lib_bounded_array_traits): Likewise.
823 * testsuite/20_util/is_bounded_array/value.cc: Check for macro.
824 * testsuite/20_util/is_unbounded_array/value.cc: Likewise.
825
826 2019-03-06 Edward Smith-Rowland <3dw4rd@verizon.net>
827
828 PR libstdc++/86655 - std::assoc_legendre should not constrain
829 the value of m (or x).
830 * include/tr1/legendre_function.tcc (__assoc_legendre_p,
831 __sph_legendre): If degree > order Don't throw, return 0.
832 (__legendre_p, __assoc_legendre_p): Don't constrain x either.
833 * testsuite/special_functions/02_assoc_legendre/pr86655.cc: New test.
834 * testsuite/special_functions/20_sph_legendre/pr86655.cc: New test.
835 * testsuite/tr1/5_numerical_facilities/special_functions/
836 02_assoc_legendre/pr86655.cc: New test.
837 * testsuite/tr1/5_numerical_facilities/special_functions/
838 22_sph_legendre/pr86655.cc: New test.
839
840 2019-03-06 Ville Voutilainen <ville.voutilainen@gmail.com>
841
842 Rewrite variant.
843 Also PR libstdc++/85517
844 * include/std/variant (__do_visit): New.
845 (__variant_cast): Likewise.
846 (__variant_cookie): Likewise.
847 (__erased_*): Remove.
848 (_Variant_storage::_S_vtable): Likewise.
849 (_Variant_storage::__M_reset_impl): Adjust to use __do_visit.
850 (_Variant_storage::__M_reset): Adjust.
851 (__variant_construct): New.
852 (_Copy_ctor_base(const _Copy_ctor_base&)): Adjust to use
853 __variant_construct.
854 (_Move_ctor_base(_Move_ctor_base&&)): Likewise.
855 (_Move_ctor_base::__M_destructive_copy): New.
856 (_Move_ctor_base::__M_destructive_move): Adjust to use
857 __variant_construct.
858 (_Copy_assign_base::operator=): Adjust to use __do_visit.
859 (_Copy_assign_alias): Adjust to check both copy assignment
860 and copy construction for triviality.
861 (_Move_assign_base::operator=): Adjust to use __do_visit.
862 (_Multi_array): Add support for visitors that accept and return
863 a __variant_cookie.
864 (__gen_vtable_impl::_S_apply_all_alts): Likewise.
865 (__gen_vtable_impl::_S_apply_single_alt): Likewise.
866 (__gen_vtable_impl::__element_by_index_or_cookie): New. Generate
867 a __variant_cookie temporary for a variant that is valueless and..
868 (__gen_vtable_impl::__visit_invoke): ..adjust here.
869 (__gen_vtable::_Array_type): Conditionally make space for
870 the __variant_cookie visitor case.
871 (__variant_construct_by_index): New.
872 (get_if): Adjust to use std::addressof.
873 (relops): Adjust to use __do_visit.
874 (variant): Add __variant_cast and __variant_construct_by_index
875 as friends.
876 (variant::emplace): Use _M_reset() and __variant_construct_by_index
877 instead of self-destruction.
878 (variant::swap): Adjust to use __do_visit.
879 (visit): Reimplement in terms of __do_visit.
880 (__variant_hash_call_base_impl::operator()): Adjust to use __do_visit.
881 * testsuite/20_util/variant/compile.cc: Adjust.
882 * testsuite/20_util/variant/run.cc: Likewise.
883
884 2019-03-06 Jonathan Wakely <jwakely@redhat.com>
885
886 * include/bits/c++config.h (_cpp_lib_char8_t): Add L suffix to
887 constant.
888 * testsuite/experimental/feat-char8_t.cc: Likewise.
889
890 * include/std/type_traits [C++20] (is_bounded_array)
891 (is_unbounded_array, is_bounded_array_v, is_unbounded_array_v):
892 Define.
893 * testsuite/20_util/is_bounded_array/requirements/
894 explicit_instantiation.cc: New test.
895 * testsuite/20_util/is_bounded_array/requirements/typedefs.cc: New
896 test.
897 * testsuite/20_util/is_bounded_array/value.cc: New test.
898 * testsuite/20_util/is_unbounded_array/requirements/
899 explicit_instantiation.cc: New test.
900 * testsuite/20_util/is_unbounded_array/requirements/typedefs.cc: New
901 * test.
902 * testsuite/20_util/is_unbounded_array/value.cc: New test.
903
904 * include/bits/ptr_traits.h [C++20] (pointer_traits<T*>::pointer_to):
905 Add constexpr.
906 * testsuite/20_util/pointer_traits/pointer_to_constexpr.cc: New test.
907
908 2019-03-05 Jonathan Wakely <jwakely@redhat.com>
909
910 * include/c_compatibility/math.h [C++20] (lerp): Add using
911 declaration.
912 * include/c_global/cmath [C++20] (__cpp_lib_interpolate): Define.
913 (__lerp): Define function template to implement lerp.
914 (lerp(float, float, float), lerp(double, double, double))
915 (lerp(long double, long double, long double)): Define for C++20.
916 * include/std/numeric [C++20] (__cpp_lib_interpolate): Define.
917 (midpoint(T, T), midpoint(T*, T*)): Define.
918 * include/std::version [C++20] (__cpp_lib_interpolate): Define.
919 * testsuite/26_numerics/lerp.cc: New test.
920 * testsuite/26_numerics/midpoint/floating.cc: New test.
921 * testsuite/26_numerics/midpoint/integral.cc: New test.
922 * testsuite/26_numerics/midpoint/pointer.cc: New test.
923
924 2019-03-04 Edward Smith-Rowland <3dw4rd@verizon.net>
925
926 PR libstdc++/88996 Implement P0439R0
927 Make std::memory_order a scoped enumeration.
928 * include/bits/atomic_base.h: For C++20 make memory_order a scoped enum,
929 add variables for the old enumerators. Adjust calls.
930 * testsuite/29_atomics/headers/atomic/types_std_c++2a.cc: New test.
931 * testsuite/29_atomics/headers/atomic/types_std_c++2a_neg.cc: New test.
932
933 2019-03-04 Jonathan Wakely <jwakely@redhat.com>
934
935 * testsuite/26_numerics/bit/bitops.rot/rotl.cc: Remove bogus dg-do
936 directive.
937
938 * include/std/memory_resource (polymorphic_allocator): Add default
939 template argument for C++20.
940 (polymorphic_allocator::allocate_bytes)
941 (polymorphic_allocator::deallocate_bytes)
942 (polymorphic_allocator::allocate_object)
943 (polymorphic_allocator::deallocate_object)
944 (polymorphic_allocator::new_object)
945 (polymorphic_allocator::delete_object): New member functions for
946 C++20.
947 * testsuite/20_util/polymorphic_allocator/allocate_object.cc: New
948 test.
949
950 2019-03-03 Jonathan Wakely <jwakely@redhat.com>
951
952 PR libstdc++/89562
953 * src/filesystem/ops-common.h (do_copy_file): Open files in binary
954 mode for mingw.
955
956 2019-03-01 Jonathan Wakely <jwakely@redhat.com>
957
958 * testsuite/util/testsuite_allocator.h (__gnu_test::memory_resource)
959 [!__cpp_sized_deallocation]: Do not pass size to operator delete.
960
961 * include/std/memory (uses_allocator_construction_args): New set of
962 overloaded functions.
963 (make_obj_using_allocator, uninitialized_construct_using_allocator):
964 New functions.
965 * include/std/memory_resource (polymorphic_allocator::construct)
966 [__cplusplus > 201703l]: Replace all overloads with a single function
967 using uses_allocator_construction_args.
968 * testsuite/20_util/polymorphic_allocator/construct_c++2a.cc: New
969 test.
970 * testsuite/20_util/uses_allocator/make_obj.cc: New test.
971
972 2019-02-27 Jonathan Wakely <jwakely@redhat.com>
973
974 PR libstdc++/89466
975 * acinclude.m4 (GLIBCXX_CONFIGURE_DOCBOOK): Reorder check for local
976 stylesheet directories before check for xsltproc. Try to use
977 xmlcatalog to find local stylesheet directory before trying hardcoded
978 paths. Add path used by suse to hardcoded paths. Adjust xsltproc
979 check to look for the same stylesheet as doc/Makefile.am uses. Don't
980 use xsltproc if xmlcatalog fails to find a local stylesheet.
981 * configure.ac: Check for xmlcatalog.
982 * Makefile.in: Regenerate.
983 * configure: Likewise.
984 * doc/Makefile.in: Likewise.
985 * include/Makefile.in: Likewise.
986 * libsupc++/Makefile.in: Likewise.
987 * po/Makefile.in: Likewise.
988 * python/Makefile.in: Likewise.
989 * src/Makefile.in: Likewise.
990 * src/c++11/Makefile.in: Likewise.
991 * src/c++17/Makefile.in: Likewise.
992 * src/c++98/Makefile.in: Likewise.
993 * src/filesystem/Makefile.in: Likewise.
994 * testsuite/Makefile.in: Likewise.
995
996 2019-02-26 Jonathan Wakely <jwakely@redhat.com>
997
998 PR libstdc++/89477
999 * include/bits/alloc_traits.h (_RequireNotAllocator): New helper for
1000 container deduction guides.
1001 * include/bits/hashtable.h (_RequireNotAllocatorOrIntegral): Likewise.
1002 * include/bits/stl_map.h (map): Use _RequireNotAllocator to constrain
1003 parameters in deduction guides.
1004 * include/bits/stl_multimap.h (multimap): Likewise.
1005 * include/bits/stl_multiset.h (multiset): Likewise.
1006 * include/bits/stl_queue.h (queue, priority_queue): Likewise.
1007 * include/bits/stl_set.h (set): Likewise.
1008 * include/bits/stl_stack.h (stack): Likewise.
1009 * include/bits/unordered_map.h (unordered_map, unordered_multimap):
1010 use _RequireNotAllocator and _RequireNotAllocatorOrIntegral to
1011 constrain parameters in deduction guides.
1012 * include/bits/unordered_set.h (unordered_set, unordered_multiset):
1013 Likewise.
1014 * testsuite/23_containers/map/cons/deduction.cc: Test additional
1015 deduction cases.
1016 * testsuite/23_containers/multiset/cons/deduction.cc: Likewise.
1017 * testsuite/23_containers/set/cons/deduction.cc: Likewise.
1018 * testsuite/23_containers/unordered_map/cons/deduction.cc: Likewise.
1019 * testsuite/23_containers/unordered_multimap/cons/deduction.cc:
1020 Likewise.
1021 * testsuite/23_containers/unordered_multiset/cons/deduction.cc:
1022 Likewise.
1023 * testsuite/23_containers/unordered_set/cons/deduction.cc: Likewise.
1024
1025 PR libstdc++/89416
1026 * include/bits/alloc_traits.h (__is_alloc_insertable_impl): Change
1027 to class template and partial specialization using void_t.
1028 (__is_copy_insertable, __is_move_insertable): Adjust base class.
1029
1030 2019-02-24 Jonathan Wakely <jwakely@redhat.com>
1031
1032 PR libstdc++/89416
1033 * include/bits/alloc_traits.h (__is_alloc_insertable_impl): Make
1034 copy and move members public.
1035
1036 2019-02-23 Jonathan Wakely <jwakely@redhat.com>
1037
1038 * include/std/type_traits (__underlying_type_impl): New helper to
1039 make underlying_type SFINAE-friendly.
1040 (underlying_type): Derive from __underlying_type_impl.
1041 * testsuite/20_util/underlying_type/requirements/typedefs-3.cc: New
1042 test.
1043
1044 PR libstdc++/89446
1045 * include/bits/char_traits.h (__constant_char_array): Check index is
1046 in range before dereferencing.
1047 (char_traits<char>::compare, char_traits<char>::find)
1048 (char_traits<char8_t>::compare, char_traits<char8_t>::find): Return
1049 immediately if n is zero.
1050 (char_traits<wchar_t>::compare, char_traits<wchar_t>::find): Likewise.
1051 Remove workarounds for PR 67026.
1052 * testsuite/21_strings/basic_string_view/operators/char/89446.cc:
1053 New test.
1054 * testsuite/21_strings/basic_string_view/operators/wchar_t/89446.cc:
1055 New test.
1056
1057 2019-02-22 Eric Botcazou <ebotcazou@adacore.com>
1058
1059 * config/abi/post/sparc64-linux-gnu/baseline_symbols.txt: Adjust.
1060 * config/abi/post/sparc64-linux-gnu/32/baseline_symbols.txt: Likewise.
1061
1062 2019-02-22 Jakub Jelinek <jakub@redhat.com>
1063
1064 PR libstdc++/89402
1065 * src/c++98/compatibility-ldbl.cc (_ZNKSt4hashIeEclEe): Change return
1066 type to std::size_t and argument to type to long double.
1067
1068 2019-02-22 Eric Botcazou <ebotcazou@adacore.com>
1069
1070 * configure.host (abi_baseline_pair): Adjust for SPARC64/Linux.
1071 * config/abi/post/sparc64-linux-gnu: New directory.
1072 * config/abi/post/sparc64-linux-gnu/baseline_symbols.txt: New file.
1073 * config/abi/post/sparc64-linux-gnu/32: New directory.
1074 * config/abi/post/sparc64-linux-gnu/32/baseline_symbols.txt: New file.
1075
1076 2019-02-21 Jonathan Wakely <jwakely@redhat.com>
1077
1078 * testsuite/29_atomics/headers/atomic/types_std_c++20.cc: New test.
1079 * testsuite/29_atomics/headers/atomic/types_std_c++20_neg.cc: New
1080 test.
1081
1082 2019-02-22 Tom Honermann <tom@honermann.net>
1083
1084 * python/libstdcxx/v6/printers.py (register_type_printers): Add type
1085 printers for u8string and u8string_view.
1086
1087 2019-02-22 Tom Honermann <tom@honermann.net>
1088
1089 * testsuite/18_support/byte/ops.cc: Validate
1090 std::to_integer<char8_t>, std::to_integer<char16_t>, and
1091 std::to_integer<char32_t>.
1092 * testsuite/18_support/numeric_limits/dr559.cc: Validate
1093 std::numeric_limits<char8_t>.
1094 * testsuite/18_support/numeric_limits/lowest.cc: Validate
1095 std::numeric_limits<char8_t>::lowest().
1096 * testsuite/18_support/numeric_limits/max_digits10.cc: Validate
1097 std::numeric_limits<char8_t>::max_digits10.
1098 * testsuite/18_support/type_info/fundamental.cc: Validate
1099 typeinfo for char8_t.
1100 * testsuite/20_util/from_chars/1_c++20_neg.cc: New test, validating
1101 std::from_chars with char8_t.
1102 * testsuite/20_util/hash/requirements/explicit_instantiation.cc:
1103 Validate explicit instantiation of std::hash<char8_t>.
1104 * testsuite/20_util/is_integral/value.cc: Validate
1105 std::is_integral<char8_t>.
1106 * testsuite/20_util/make_signed/requirements/typedefs-4.cc:
1107 Validate std::make_signed<char8_t>.
1108 * testsuite/21_strings/basic_string/cons/char/deduction.cc:
1109 Validate u8string construction from char8_t sources.
1110 * testsuite/21_strings/basic_string/types/pmr_typedefs.cc: Validate
1111 std::pmr::u8string.
1112 * testsuite/21_strings/basic_string_view/operations/compare/
1113 char/70483.cc: Validate substr operations on u8string_view.
1114 * testsuite/21_strings/basic_string_view/typedefs.cc: Validate that
1115 the u8string_view typedef is defined.
1116 * testsuite/21_strings/char_traits/requirements/
1117 constexpr_functions.cc: Validate char_traits<char8_t> constexpr
1118 member functions.
1119 * testsuite/21_strings/char_traits/requirements/
1120 constexpr_functions_c++17.cc: Validate char_traits<char8_t> C++17
1121 constexpr member functions.
1122 * testsuite/21_strings/headers/string/types_std_c++0x.cc: Validate
1123 that the u8string typedef is defined.
1124 * testsuite/22_locale/locale/cons/unicode.cc: Validate the presence
1125 of the std::codecvt<char16_t, char8_t, std::mbstate_t> and
1126 std::codecvt<char32_t, char8_t, std::mbstate_t> facets.
1127 * testsuite/29_atomics/atomic/cons/assign_neg.cc: Update line
1128 numbers.
1129 * testsuite/29_atomics/atomic/cons/copy_neg.cc: Likewise.
1130 * testsuite/29_atomics/atomic_integral/cons/assign_neg.cc:
1131 Likewise.
1132 * testsuite/29_atomics/atomic_integral/cons/copy_neg.cc: Likewise.
1133 * testsuite/29_atomics/atomic_integral/is_always_lock_free.cc:
1134 Validate std::atomic<char8_t>::is_always_lock_free
1135 * testsuite/29_atomics/atomic_integral/operators/bitwise_neg.cc:
1136 Update line numbers.
1137 * testsuite/29_atomics/atomic_integral/operators/decrement_neg.cc:
1138 Likewise.
1139 * testsuite/29_atomics/atomic_integral/operators/increment_neg.cc:
1140 Likewise.
1141 * testsuite/experimental/polymorphic_allocator/pmr_typedefs_string.cc:
1142 Validate std::experimental::pmr::u8string.
1143 * testsuite/experimental/string_view/typedefs.cc: Validate that the
1144 u8string_view typedef is defined.
1145 * testsuite/util/testsuite_common_types.h: Add char8_t, char16_t and
1146 char32_t to the typelists.
1147
1148 2019-02-22 Tom Honermann <tom@honermann.net>
1149
1150 * include/ext/typelist.h: Constrain a partial specialization of
1151 typelist::detail::append_ to only match chain<T1,T2>.
1152
1153 2019-02-21 Jonathan Wakely <jwakely@redhat.com>
1154
1155 PR libstdc++/89416
1156 * include/bits/alloc_traits.h (__is_alloc_insertable_impl): Replace
1157 class template with class. Replace move and copy member types with
1158 member alias templates, so they are only instantiated when needed.
1159 (__is_copy_insertable, __is_move_insertable): Adjust base class.
1160 * testsuite/23_containers/vector/modifiers/push_back/89130.cc: Enable
1161 test for C++11/14/17 as well.
1162 * testsuite/23_containers/vector/modifiers/push_back/89416.cc: New
1163 test.
1164
1165 2019-02-20 Jakub Jelinek <jakub@redhat.com>
1166
1167 PR libstdc++/89402
1168 * src/c++98/compatibility-ldbl.cc (_ZNKSt4hashIeEclEe): Add
1169 _GLIBCXX_PURE to the alias declaration.
1170
1171 2019-02-19 Jonathan Wakely <jwakely@redhat.com>
1172
1173 * testsuite/21_strings/basic_string/literals/types.cc
1174 [_GLIBCXX_USE_CHAR8_T]: Adjust expected string type for u8 literal.
1175 * testsuite/21_strings/basic_string/literals/values.cc
1176 [_GLIBCXX_USE_CHAR8_T]: Likewise.
1177 * testsuite/22_locale/codecvt/char16_t.cc: Adjust for u8 literals
1178 potentially having different type.
1179 * testsuite/22_locale/codecvt/char32_t.cc: Likewise.
1180 * testsuite/22_locale/codecvt/codecvt_utf8/79980.cc: Cast u8 literal
1181 to char.
1182 * testsuite/22_locale/codecvt/codecvt_utf8/wchar_t/1.cc: Likewise.
1183 * testsuite/22_locale/codecvt/utf8.cc: Likewise.
1184 * testsuite/22_locale/conversions/string/2.cc: Remove u8 prefix from
1185 string literals only using basic character set.
1186 * testsuite/22_locale/conversions/string/3.cc: Likewise. Cast other
1187 u8 literals to char.
1188 * testsuite/29_atomics/headers/atomic/macros.cc [_GLIBCXX_USE_CHAR8_T]:
1189 Test ATOMIC_CHAR8_T_LOCK_FREE.
1190 Add missing #error to ATOMIC_CHAR16_T_LOCK_FREE test.
1191 * testsuite/29_atomics/headers/atomic/types_std_c++0x.cc
1192 [_GLIBCXX_USE_CHAR8_T]: Check for std::atomic_char8_t.
1193 * testsuite/experimental/string_view/literals/types.cc
1194 [_GLIBCXX_USE_CHAR8_T]: Adjust expected string_view type for u8
1195 literal.
1196 * testsuite/experimental/string_view/literals/values.cc
1197 [_GLIBCXX_USE_CHAR8_T]: Likewise.
1198
1199 2019-02-19 Tom Honermann <tom@honermann.net>
1200
1201 * testsuite/18_support/numeric_limits/char8_t.cc: New test cloned
1202 from char16_32_t.cc; validates numeric_limits<char8_t>.
1203 * testsuite/21_strings/basic_string/literals/types-char8_t.cc: New
1204 test cloned from types.cc; validates operator""s for char8_t
1205 returns u8string.
1206 * testsuite/21_strings/basic_string/literals/values-char8_t.cc: New
1207 test cloned from values.cc; validates construction and comparison
1208 of u8string values.
1209 * testsuite/21_strings/basic_string/requirements/
1210 /explicit_instantiation/char8_t/1.cc: New test cloned from
1211 char16_t/1.cc; validates explicit instantiation of
1212 basic_string<char8_t>.
1213 * testsuite/21_strings/basic_string_view/literals/types-char8_t.cc:
1214 New test cloned from types.cc; validates operator""sv for char8_t
1215 returns u8string_view.
1216 * testsuite/21_strings/basic_string_view/literals/
1217 values-char8_t.cc: New test cloned from values.cc; validates
1218 construction and comparison of u8string_view values.
1219 * testsuite/21_strings/basic_string_view/requirements/
1220 explicit_instantiation/char8_t/1.cc: New test cloned from
1221 char16_t/1.cc; validates explicit instantiation of
1222 basic_string_view<char8_t>.
1223 * testsuite/21_strings/char_traits/requirements/char8_t/65049.cc:
1224 New test cloned from char16_t/65049.cc; validates that
1225 char_traits<char8_t> is not vulnerable to the concerns in PR65049.
1226 * testsuite/21_strings/char_traits/requirements/char8_t/
1227 typedefs.cc: New test cloned from char16_t/typedefs.cc; validates
1228 that char_traits<char8_t> member typedefs are present and correct.
1229 * testsuite/21_strings/char_traits/requirements/
1230 explicit_instantiation/char8_t/1.cc: New test cloned from
1231 char16_t/1.cc; validates explicit instantiation of
1232 char_traits<char8_t>.
1233 * testsuite/22_locale/codecvt/char16_t-char8_t.cc: New test cloned
1234 from char16_t.cc: validates
1235 codecvt<char16_t, char8_t, mbstate_t>.
1236 * testsuite/22_locale/codecvt/char32_t-char8_t.cc: New test cloned
1237 from char32_t.cc: validates
1238 codecvt<char32_t, char8_t, mbstate_t>.
1239 * testsuite/22_locale/codecvt/utf8-char8_t.cc: New test cloned from
1240 utf8.cc; validates codecvt<char16_t, char8_t, std::mbstate_t> and
1241 codecvt<char32_t, char8_t, std::mbstate_t>.
1242 * testsuite/27_io/filesystem/path/native/string-char8_t.cc: New
1243 test cloned from string.cc; validates filesystem::path construction
1244 from char8_t input.
1245 * testsuite/experimental/feat-char8_t.cc: New test; validates that
1246 the __cpp_lib_char8_t feature test macro is defined with the
1247 correct value.
1248 * testsuite/experimental/filesystem/path/native/string-char8_t.cc:
1249 New test cloned from string.cc; validates filesystem::path
1250 construction from char8_t input.
1251 * testsuite/experimental/string_view/literals/types-char8_t.cc: New
1252 test cloned from types.cc; validates operator""sv for char8_t
1253 returns u8string_view.
1254 * testsuite/experimental/string_view/literals/values-char8_t.cc:
1255 New test cloned from values.cc; validates construction and
1256 comparison of u8string_view values.
1257 * testsuite/experimental/string_view/requirements/
1258 explicit_instantiation/char8_t/1.cc: New test cloned from
1259 char16_t/1.cc; validates explicit instantiation of
1260 basic_string_view<char8_t>.
1261 * testsuite/ext/char8_t/atomic-1.cc: New test; validates that
1262 ATOMIC_CHAR8_T_LOCK_FREE is not defined if char8_t support is not
1263 enabled.
1264
1265 2019-02-19 Tom Honermann <tom@honermann.net>
1266
1267 P0482R5 char8_t: Standard library support
1268 * config/abi/pre/gnu-versioned-namespace.ver (CXXABI_2.0): Add
1269 typeinfo symbols for char8_t.
1270 * config/abi/pre/gnu.ver: Add CXXABI_1.3.12.
1271 (GLIBCXX_3.4.26): Add symbols for specializations of
1272 numeric_limits and codecvt that involve char8_t.
1273 (CXXABI_1.3.12): Add typeinfo symbols for char8_t.
1274 * include/bits/atomic_base.h: Add atomic_char8_t.
1275 * include/bits/basic_string.h: Add std::hash<u8string> and
1276 operator""s(const char8_t*, size_t).
1277 * include/bits/c++config: Define _GLIBCXX_USE_CHAR8_T and
1278 __cpp_lib_char8_t.
1279 * include/bits/char_traits.h: Add char_traits<char8_t>.
1280 * include/bits/codecvt.h: Add
1281 codecvt<char16_t, char8_t, mbstate_t>,
1282 codecvt<char32_t, char8_t, mbstate_t>,
1283 codecvt_byname<char16_t, char8_t, mbstate_t>, and
1284 codecvt_byname<char32_t, char8_t, mbstate_t>.
1285 * include/bits/cpp_type_traits.h: Add __is_integer<char8_t> to
1286 recognize char8_t as an integral type.
1287 * include/bits/fs_path.h: (path::__is_encoded_char): Recognize
1288 char8_t.
1289 (path::u8string): Return std::u8string when char8_t support is
1290 enabled.
1291 (path::generic_u8string): Likewise.
1292 (path::_S_convert): Handle conversion from char8_t input.
1293 (path::_S_str_convert): Likewise.
1294 * include/bits/functional_hash.h: Add hash<char8_t>.
1295 * include/bits/locale_conv.h (__str_codecvt_out): Add overloads for
1296 char8_t.
1297 * include/bits/locale_facets.h (_GLIBCXX_NUM_UNICODE_FACETS): Bump
1298 for new char8_t specializations.
1299 * include/bits/localefwd.h: Add missing declarations of
1300 codecvt<char16_t, char, mbstate_t> and
1301 codecvt<char32_t, char, mbstate_t>. Add char8_t declarations
1302 codecvt<char16_t, char8_t, mbstate_t> and
1303 codecvt<char32_t, char8_t, mbstate_t>.
1304 * include/bits/postypes.h: Add u8streampos
1305 * include/bits/stringfwd.h: Add declarations of
1306 char_traits<char8_t> and u8string.
1307 * include/c_global/cstddef: Add __byte_operand<char8_t>.
1308 * include/experimental/bits/fs_path.h (path::__is_encoded_char):
1309 Recognize char8_t.
1310 (path::u8string): Return std::u8string when char8_t support is
1311 enabled.
1312 (path::generic_u8string): Likewise.
1313 (path::_S_convert): Handle conversion from char8_t input.
1314 (path::_S_str_convert): Likewise.
1315 * include/experimental/string: Add u8string.
1316 * include/experimental/string_view: Add u8string_view,
1317 hash<experimental::u8string_view>, and
1318 operator""sv(const char8_t*, size_t).
1319 * include/std/atomic: Add atomic<char8_t> and atomic_char8_t.
1320 * include/std/charconv (__is_int_to_chars_type): Recognize char8_t
1321 as a character type.
1322 * include/std/limits: Add numeric_limits<char8_t>.
1323 * include/std/string_view: Add u8string_view,
1324 hash<experimental::u8string_view>, and
1325 operator""sv(const char8_t*, size_t).
1326 * include/std/type_traits: Add __is_integral_helper<char8_t>,
1327 __make_unsigned<char8_t>, and __make_signed<char8_t>.
1328 * libsupc++/atomic_lockfree_defines.h: Define
1329 ATOMIC_CHAR8_T_LOCK_FREE.
1330 * src/c++11/Makefile.am: Compile with -fchar8_t when compiling
1331 codecvt.cc and limits.cc so that char8_t specializations of
1332 numeric_limits and codecvt and emitted.
1333 * src/c++11/Makefile.in: Likewise.
1334 * src/c++11/codecvt.cc: Define members of
1335 codecvt<char16_t, char8_t, mbstate_t>,
1336 codecvt<char32_t, char8_t, mbstate_t>,
1337 codecvt_byname<char16_t, char8_t, mbstate_t>, and
1338 codecvt_byname<char32_t, char8_t, mbstate_t>.
1339 * src/c++11/limits.cc: Define members of
1340 numeric_limits<char8_t>.
1341 * src/c++98/Makefile.am: Compile with -fchar8_t when compiling
1342 locale_init.cc and localename.cc.
1343 * src/c++98/Makefile.in: Likewise.
1344 * src/c++98/locale_init.cc: Add initialization for the
1345 codecvt<char16_t, char8_t, mbstate_t> and
1346 codecvt<char32_t, char8_t, mbstate_t> facets.
1347 * src/c++98/localename.cc: Likewise.
1348 * testsuite/util/testsuite_abi.cc: Validate ABI bump.
1349
1350 2019-02-18 Wilco Dijkstra <wdijkstr@arm.com>
1351
1352 * 27_io/filesystem/operations/all.cc: Add dg-require-filesystem-ts.
1353 * 27_io/filesystem/operations/resize_file.cc: Likewise.
1354 * 27_io/filesystem/path/generation/normal2.cc: Likewise.
1355
1356 2019-02-14 Jonathan Wakely <jwakely@redhat.com>
1357
1358 * doc/xml/manual/status_cxx2020.xml: Update P0887R1 status.
1359 * doc/html/*: Regenerate.
1360
1361 * doc/xml/manual/status_cxx2017.xml: Add P0063R3 to status table.
1362 * doc/html/*: Regenerate.
1363
1364 * doc/xml/manual/intro.xml: Document LWG 2586 status.
1365 * include/bits/uses_allocator.h (__uses_alloc): Use const lvalue
1366 allocator type in is_constructible checks.
1367 * testsuite/20_util/scoped_allocator/69293_neg.cc: Adjust dg-error.
1368 * testsuite/20_util/scoped_allocator/dr2586.cc: New test.
1369 * testsuite/20_util/tuple/cons/allocators.cc: Add test using
1370 problematic type from LWG 2586 discussion.
1371 * testsuite/20_util/uses_allocator/69293_neg.cc: Adjust dg-error.
1372 * testsuite/20_util/uses_allocator/cons_neg.cc: Likewise.
1373
1374 * configure.ac: Check for C11 timespec_get function.
1375 * crossconfig.m4 (freebsd, linux, gnu, cygwin, solaris, netbsd)
1376 (openbsd): Likewise
1377 * config.h.in: Regenerate.
1378 * configure: Regenerate.
1379 * include/c_global/ctime (timespec, timespec_get): Add to namespace
1380 std for C++17 and up.
1381
1382 * doc/xml/manual/intro.xml: Document LWG 2537 status.
1383 * include/bits/stl_queue.h
1384 (priority_queue(const Compare&, const Container&, const Alloc&))
1385 (priority_queue(const Compare&, Container&&, const Alloc&)): Call
1386 make_heap.
1387 * testsuite/23_containers/priority_queue/dr2537.cc: New test.
1388
1389 * doc/xml/manual/intro.xml: Document LWG 2566 status.
1390 * include/bits/stl_queue.h (queue, priority_queue): Add static
1391 assertions to enforce LWG 2566 requirement on value_type.
1392 * include/bits/stl_stack.h (stack): Likewise.
1393
1394 PR middle-end/89303
1395 * testsuite/20_util/enable_shared_from_this/89303.cc: New test.
1396
1397 * doc/xml/manual/intro.xml: Document LWG 2735 status.
1398 * include/bits/std_abs.h: Add comment about LWG 2735.
1399 * testsuite/26_numerics/headers/cstdlib/dr2735.cc: New test.
1400
1401 2019-02-13 Jonathan Wakely <jwakely@redhat.com>
1402
1403 PR libstdc++/89345
1404 * include/std/version [__cpp_impl_destroying_delete]
1405 (__cpp_lib_destroying_delete): Only define for C++2a and later.
1406 * libsupc++/new [__cpp_impl_destroying_delete]
1407 (__cpp_lib_destroying_delete): Likewise.
1408 (destroying_delete_t, destroying_delete): Likewise, but define even
1409 when __cpp_impl_destroying_delete is not defined.
1410 * testsuite/18_support/destroying_delete.cc: New test.
1411
1412 2019-02-11 Jonathan Wakely <jwakely@redhat.com>
1413
1414 PR libstdc++/89023
1415 * testsuite/17_intro/headers/c++2011/parallel_mode.cc: New test.
1416 * testsuite/17_intro/headers/c++2014/parallel_mode.cc: New test.
1417 * testsuite/17_intro/headers/c++2017/parallel_mode.cc: New test.
1418 * testsuite/28_regex/headers/regex/parallel_mode.cc: Remove.
1419
1420 2019-02-09 Jonathan Wakely <jwakely@redhat.com>
1421
1422 PR libstdc++/71044
1423 * include/bits/fs_path.h (path::has_root_name)
1424 (path::has_root_directory, path::has_root_path)
1425 (path::has_relative_path, path::has_parent_path)
1426 (path::has_filename, path::has_stem, path::has_extension)
1427 (path::is_absolute, path::is_relative, path::_M_find_extension): Add
1428 noexcept.
1429 * src/c++17/fs_path.cc (path::has_root_name)
1430 (path::has_root_directory, path::has_root_path)
1431 (path::has_relative_path, path::has_parent_path)
1432 (path::has_filename, path::_M_find_extension): Add noexcept.
1433
1434 2019-02-06 Jonathan Wakely <jwakely@redhat.com>
1435
1436 PR libstdc++/89102 (partial)
1437 * include/std/type_traits (common_type<>): Define.
1438 (common_type<T>): Derive from common_type<T, T>.
1439 * testsuite/20_util/common_type/requirements/explicit_instantiation.cc:
1440 Test zero-length template argument list.
1441 * testsuite/20_util/common_type/requirements/sfinae_friendly_1.cc:
1442 Test additional single argument cases.
1443 * testsuite/20_util/common_type/requirements/sfinae_friendly_2.cc:
1444 Adjust expected error.
1445
1446 2019-02-05 Jonathan Wakely <jwakely@redhat.com>
1447
1448 PR libstdc++/89128
1449 * include/bits/stl_queue.h (queue, priority_queue): Add deduction
1450 guides.
1451 * include/bits/stl_stack.h (stack): Likewise.
1452 * testsuite/23_containers/priority_queue/deduction.cc: New test.
1453 * testsuite/23_containers/queue/deduction.cc: New test.
1454 * testsuite/23_containers/stack/deduction.cc: New test.
1455
1456 PR libstdc++/89194
1457 * include/std/type_traits (__is_convertible_helper)
1458 (__is_convertible_helper<_From, _To, false>): Revert changes to
1459 support is_nothrow_convertible.
1460 (__is_nt_convertible_helper): New helper.
1461 (is_nothrow_convertible): Use __is_nt_convertible_helper.
1462
1463 * testsuite/23_containers/vector/modifiers/push_back/49836.cc: Restore
1464 use of CopyConsOnlyType, but also test DelAnyAssign for completeness.
1465
1466 PR libstdc++/89130
1467 * include/bits/alloc_traits.h (__is_copy_insertable_impl): Rename to
1468 __is_alloc_insertable_impl. Replace single type member with two
1469 members, one for each of copy and move insertable.
1470 (__is_move_insertable): New trait for internal use.
1471 * include/bits/stl_vector.h (vector::_S_nothrow_relocate(true_type))
1472 (vector::_S_nothrow_relocate(true_type)): New functions to
1473 conditionally check if __relocate_a can throw.
1474 (vector::_S_use_relocate()): Dispatch to _S_nothrow_relocate based
1475 on __is_move_insertable.
1476 (vector::_S_do_relocate): New overloaded functions to conditionally
1477 call __relocate_a.
1478 (vector::_S_relocate): New function that dispatches to _S_do_relocate
1479 based on _S_use_relocate.
1480 * include/bits/vector.tcc (vector::reserve, vector::_M_realloc_insert)
1481 (vector::_M_default_append): Call _S_relocate instead of __relocate_a.
1482 * testsuite/23_containers/vector/modifiers/push_back/89130.cc: New.
1483
1484 PR libstdc++/89090
1485 * include/bits/stl_uninitialized.h (__relocate_a_1): Make unused
1486 parameter unnamed. Add message to static assertion.
1487 * include/bits/vector.tcc (vector::reserve, vector::_M_realloc_insert)
1488 (vector::_M_default_append): Use _GLIBCXX17_CONSTEXPR for if constexpr
1489 in C++11 code.
1490
1491 2019-02-05 Marc Glisse <marc.glisse@inria.fr>
1492
1493 PR libstdc++/87106
1494 * include/bits/stl_uninitialized.h (__is_trivially_relocatable):
1495 Rename...
1496 (__is_bitwise_relocatable): ... to this.
1497 (__relocate_a_1): Adapt.
1498 * include/bits/stl_deque.h (__is_trivially_relocatable): Rename...
1499 (__is_bitwise_relocatable): ... to this.
1500
1501 2019-01-30 Jonathan Wakely <jwakely@redhat.com>
1502
1503 PR libstdc++/89117
1504 * src/c++17/fs_path.cc (path::replace_extension): Erase extension from
1505 final component as well as from _M_pathname. Append the dot using
1506 operator+= instead of only to _M_pathname.
1507 (path::_M_find_extension): Reformat slightly.
1508 * testsuite/27_io/filesystem/path/modifiers/replace_extension.cc:
1509 Add more test cases.
1510
1511 2019-01-30 Ulrich Drepper <drepper@redhat.com>
1512
1513 * doc/xml/manual/status_cxx2020.xml: Update P0600 entry.
1514
1515 2019-01-29 Jonathan Wakely <jwakely@redhat.com>
1516
1517 * testsuite/26_numerics/headers/complex/synopsis.cc: Remove incorrect
1518 constexpr specifiers from arg and proj.
1519
1520 * config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Add missing exports for
1521 __shared_ptr instantiations used by gcc4-compatible ABI.
1522
1523 * include/experimental/forward_list (experimental::erase): Qualify
1524 call to erase_if.
1525 * include/experimental/list (experimental::erase): Likewise.
1526 * include/std/forward_list (std::erase): Likewise.
1527 * include/std/list (std::erase): Likewise.
1528
1529 * testsuite/20_util/reference_wrapper/result_type.cc: Disable for
1530 C++2a.
1531 * testsuite/20_util/reference_wrapper/typedefs-2.cc: Likewise.
1532 * testsuite/20_util/reference_wrapper/typedefs-3.cc: Likewise.
1533 * testsuite/20_util/reference_wrapper/typedefs.cc: Likewise.
1534 * testsuite/30_threads/async/54297.cc: Suppress nodiscard warning.
1535 * testsuite/ext/array_allocator/26875.cc: Likewise.
1536 * testsuite/ext/pool_allocator/allocate_chunk.cc: Likewise.
1537 * testsuite/util/replacement_memory_operators.h: Likewise.
1538 * testsuite/util/testsuite_allocator.h: Likewise.
1539
1540 * include/std/memory_resource (__pool_resource::_M_unpooled): Use
1541 normal mode vector, even for debug mode.
1542 * include/std/vector [_GLIBCXX_DEBUG] (_GLIBCXX_STD_C::pmr::vector):
1543 Define alias template for normal mode vector.
1544
1545 2019-01-28 Jonathan Wakely <jwakely@redhat.com>
1546
1547 PR libstdc++/68737
1548 * config/locale/generic/c_locale.h (__convert_from_v)
1549 [_GLIBCXX_USE_C99_STDIO]: Also check _GLIBCXX_HAVE_BROKEN_VSNPRINTF.
1550 * config/os/hpux/os_defines.h: Define _GLIBCXX_HAVE_BROKEN_VSNPRINTF.
1551 * include/bits/locale_facets.tcc (num_put::_M_insert_float)
1552 [_GLIBCXX_USE_C99_STDIO]: Also check _GLIBCXX_HAVE_BROKEN_VSNPRINTF.
1553
1554 2019-01-24 Jonathan Wakely <jwakely@redhat.com>
1555
1556 PR libstdc++/88840
1557 * include/bits/stl_vector.h (vector::__use_relocate): Replace static
1558 data member with static member function _S_use_relocate().
1559 * include/bits/vector.tcc (vector::reserve, vector::_M_realloc_insert)
1560 (vector::_M_default_append): Use _S_use_relocate() instead of
1561 __use_relocate.
1562
1563 * testsuite/27_io/filesystem/path/compare/strings.cc: Only compare
1564 sign of results.
1565
1566 2019-01-22 Jonathan Wakely <jwakely@redhat.com>
1567
1568 PR libstdc++/88740
1569 * testsuite/util/testsuite_hooks.h [stderr] (VERIFY): Use fprintf to
1570 write to stderr instead of using printf.
1571
1572 2019-01-21 Jakub Jelinek <jakub@redhat.com>
1573
1574 PR libstdc++/86590
1575 * include/bits/char_traits.h (__constant_string_p,
1576 __constant_char_array_p): Use __builtin_is_constant_evaluated if
1577 available.
1578
1579 2019-01-20 Ulrich Drepper <drepper@redhat.com>
1580
1581 Implement C++20 P0600r1.
1582 * include/backward/hash_map: Add nodiscard attribute to empty.
1583 * include/backward/hash_set: Likewise.
1584 * backward/hashtable.h: Likewise.
1585 * include/bits/basic_string.h: Likewise.
1586 * include/bits/forward_list.h: Likewise.
1587 * include/bits/hashtable.h: Likewise.
1588 * include/bits/regex.h: Likewise.
1589 * include/bits/stl_deque.h: Likewise.
1590 * include/bits/stl_list.h: Likewise.
1591 * include/bits/stl_map.h: Likewise.
1592 * include/bits/stl_multimap.h: Likewise.
1593 * include/bits/stl_multiset.h: Likewise.
1594 * include/bits/stl_queue.h: Likewise.
1595 * include/bits/stl_set.h: Likewise.
1596 * include/bits/stl_stack.h: Likewise.
1597 * include/bits/stl_tree.h: Likewise.
1598 * include/bits/stl_vector.h: Likewise.
1599 * include/bits/unordered_map.h: Likewise.
1600 * include/bits/unordered_set.h: Likewise.
1601 * include/debug/array: Likewise.
1602 * include/experimental/any: Likewise.
1603 * include/experimental/bits/fs_path.h: Likewise.
1604 * include/experimental/internet: Likewise.
1605 * include/experimental/string_view: Likewise.
1606 * include/ext/pb_ds/detail/bin_search_tree_/info_fn_imps.hpp:
1607 Likewise.
1608 * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp:
1609 Likewise.
1610 * include/ext/pb_ds/detail/binary_heap_/info_fn_imps.hpp:
1611 Likewise.
1612 * include/ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp:
1613 Likewise.
1614 * include/ext/pb_ds/detail/cc_hash_table_map_/info_fn_imps.hpp:
1615 Likewise.
1616 * include/ext/pb_ds/detail/cc_hash_table_map_/size_fn_imps.hpp:
1617 Likewise.
1618 * include/ext/pb_ds/detail/gp_hash_table_map_/gp_ht_map_.hpp:
1619 Likewise.
1620 * include/ext/pb_ds/detail/gp_hash_table_map_/info_fn_imps.hpp:
1621 Likewise.
1622 * include/ext/pb_ds/detail/left_child_next_sibling_heap_/
1623 info_fn_imps.hpp: Likewise.
1624 * include/ext/pb_ds/detail/left_child_next_sibling_heap_/
1625 left_child_next_sibling_heap_.hpp: Likewise.
1626 * include/ext/pb_ds/detail/list_update_map_/info_fn_imps.hpp:
1627 Likewise.
1628 * include/ext/pb_ds/detail/list_update_map_/lu_map_.hpp:
1629 Likewise.
1630 * include/ext/pb_ds/detail/ov_tree_map_/info_fn_imps.hpp:
1631 Likewise.
1632 * include/ext/pb_ds/detail/ov_tree_map_/ov_tree_map_.hp:
1633 Likewise.
1634 * include/ext/pb_ds/detail/pat_trie_/info_fn_imps.hpp:
1635 Likewise.
1636 * include/ext/pb_ds/detail/pat_trie_/pat_trie_.hpp:
1637 Likewise.
1638 * include/ext/pb_ds/detail/rc_binomial_heap_/rc.hpp:
1639 Likewise.
1640 * include/ext/pb_ds/detail/tree_trace_base.hpp: Likewise.
1641 * include/ext/pb_ds/trie_policy.hpp: Likewise.
1642 * include/ext/rope: Likewise.
1643 * include/ext/slist: Likewise.
1644 * include/ext/vstring.h: Likewise.
1645 * include/profile/array: Likewise.
1646 * include/std/array: Likewise.
1647 * include/tr1/array: Likewise.
1648 * include/tr1/hashtable.h: Likewise.
1649 * include/tr1/regex: Likewise.
1650 * include/tr2/dynamic_bitset: Likewise.
1651 * include/bits/alloc_traits.h: Add nodiscard attribute to
1652 allocate.
1653 * include/experimental/memory_resource: Likewise.
1654 * include/ext/alloc_traits.h: Likewise.
1655 * include/ext/array_allocator.h: Likewise.
1656 * include/ext/bitmap_allocator.h: Likewise.
1657 * include/ext/debug_allocator.h: Likewise.
1658 * include/ext/extptr_allocator.h: Likewise.
1659 * include/ext/mt_allocator.h: Likewise.
1660 * include/ext/new_allocator.h: Likewise.
1661 * include/ext/pool_allocator.h: Likewise.
1662 * include/ext/throw_allocator.h: Likewise.
1663 * include/std/scoped_allocator: Likewise.
1664 * libsupc++/eh_alloc.cc: Likewise.
1665 * include/std/future: Add nodiscard attribute to async.
1666 * libsupc++/new: Add nodiscard attribute to new.
1667
1668 2019-01-18 Jonathan Wakely <jwakely@redhat.com>
1669
1670 PR libstdc++/87514
1671 PR libstdc++/87520
1672 PR libstdc++/88782
1673 * config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Export new symbol.
1674 * include/bits/shared_ptr.h
1675 (shared_ptr(_Sp_make_shared_tag, const Alloc&, Args&&...))
1676 (allocate_shared): Change to use new tag type.
1677 * include/bits/shared_ptr_base.h (_Sp_make_shared_tag::_S_eq):
1678 Declare new member function.
1679 (_Sp_alloc_shared_tag): Define new type.
1680 (_Sp_counted_ptr_inplace): Declare __shared_count<_Lp> as a friend.
1681 (_Sp_counted_ptr_inplace::_M_get_deleter) [!__cpp_rtti]: Use
1682 _Sp_make_shared_tag::_S_eq to check type_info.
1683 (__shared_count(Ptr, Deleter),__shared_count(Ptr, Deleter, Alloc)):
1684 Constrain to prevent being called with _Sp_alloc_shared_tag.
1685 (__shared_count(_Sp_make_shared_tag, const _Alloc&, Args&&...)):
1686 Replace constructor with ...
1687 (__shared_count(Tp*&, _Sp_alloc_shared_tag<_Alloc>, Args&&...)): Use
1688 reference parameter so address of the new object can be returned to
1689 the caller. Obtain the allocator from the tag type.
1690 (__shared_ptr(_Sp_make_shared_tag, const Alloc&, Args&&...)): Replace
1691 constructor with ...
1692 (__shared_ptr(_Sp_alloc_shared_tag<Alloc>, Args&&...)): Pass _M_ptr
1693 to the __shared_count constructor.
1694 (__allocate_shared): Change to use new tag type.
1695 * src/c++11/shared_ptr.cc (_Sp_make_shared_tag::_S_eq): Define.
1696
1697 2019-01-17 Jonathan Wakely <jwakely@redhat.com>
1698
1699 * src/c++17/fs_ops.cc
1700 (equivalent(const path&, const path&, error_code&))
1701 [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Use GetFileInformationByHandle to
1702 compare files instead of relying on incomplete info returned by stat.
1703
1704 PR libstdc++/88884
1705 * src/c++17/fs_ops.cc (absolute(const path&, error_code&)): Do nothing
1706 if the path is already absolute.
1707 [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Normalize root-directory.
1708 [!_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Pass error_code to current_path.
1709
1710 PR libstdc++/88881
1711 * src/c++17/fs_ops.cc (canonical(const path&, error_code&))
1712 [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Normalize path, to match behaviour
1713 of filesystem::exists.
1714 (create_directories(const path&, error_code&)): Add assertions.
1715 (status(const path&, error_code&)) [_GLIBCXX_FILESYSTEM_IS_WINDOWS]:
1716 Add workaround for bug in _wstat for paths with trailing slash.
1717 * testsuite/27_io/filesystem/operations/create_directories.cc: Adjust
1718 for expected behaviour on mingw.
1719 * testsuite/experimental/filesystem/operations/create_directories.cc:
1720 Likewise.
1721 * testsuite/27_io/filesystem/operations/temp_directory_path.cc: Use
1722 "TMP" instead of "TMPDIR" and clean environment before each test. Do
1723 not test permissions on mingw targets.
1724
1725 2019-01-16 Jonathan Wakely <jwakely@redhat.com>
1726
1727 * config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Add exports for fstream
1728 constructors and open members taking wide strings. Fix patterns for
1729 filesystem::path members to match wstring_view parameters. Add
1730 exports for shared_ptr members used by directory iterators.
1731 * src/c++17/fs_ops.cc (remove(const path&, error_code&)): Clear the
1732 error code parameter if the file doesn't exist.
1733 * src/filesystem/ops.cc (remove(const path&, error_code&)):
1734 Likewise.
1735 * testsuite/27_io/filesystem/operations/canonical.cc: Fix expected
1736 values for mingw targets, where "/" is not an absolute path. Do not
1737 test symlinks on mingw targets.
1738 * testsuite/experimental/filesystem/operations/canonical.cc: Likewise.
1739 * testsuite/27_io/filesystem/operations/copy.cc: Do not test symlinks
1740 on mingw targets.
1741 * testsuite/experimental/filesystem/operations/copy.cc: Likewise.
1742 * testsuite/27_io/filesystem/operations/create_directories.cc: Check
1743 that each component of the path is created.
1744 * testsuite/experimental/filesystem/operations/create_directories.cc:
1745 Likewise.
1746 * testsuite/27_io/filesystem/operations/exists.cc: Do not test
1747 permissions on mingw targets.
1748 * testsuite/experimental/filesystem/operations/exists.cc: Likewise.
1749 * testsuite/27_io/filesystem/operations/is_empty.cc: Likewise.
1750 * testsuite/experimental/filesystem/operations/is_empty.cc: Likewise.
1751 * testsuite/27_io/filesystem/operations/permissions.cc: XFAIL for
1752 mingw targets.
1753 * testsuite/experimental/filesystem/operations/permissions.cc:
1754 Likewise.
1755 * testsuite/27_io/filesystem/operations/remove.cc: Do not test
1756 symlinks or permissions on mingw targets.
1757 * testsuite/experimental/filesystem/operations/remove.cc: Likewise.
1758 * testsuite/27_io/filesystem/operations/remove_all.cc: Do not test
1759 symlinks on mingw targets.
1760 * testsuite/experimental/filesystem/operations/remove_all.cc:
1761 Likewise.
1762 * testsuite/27_io/filesystem/operations/status.cc: Do not test
1763 permissions on mingw targets.
1764 * testsuite/27_io/filesystem/operations/weakly_canonical.cc: Do not
1765 test symlinks on mingw targets.
1766 * testsuite/experimental/filesystem/operations/space.cc: Fix test
1767 for mingw targets.
1768
1769 2019-02-14 Ulrich Drepper <drepper@redhat.com>
1770
1771 PR libstdc++/88738
1772 Warn about unused comparisons of shared_ptr/unique_ptr
1773 * include/bits/c++config [_GLIBCXX_NODISCARD]: Define.
1774 * include/bits/shared_ptr.h: Use it for operator ==, !=,
1775 <, <=, >, >= for shared_ptr.
1776 * include/bits/unique_ptr.h: Likewise for unique_ptr.
1777
1778 2019-01-15 Jonathan Wakely <jwakely@redhat.com>
1779
1780 * include/bits/shared_ptr_base.h (__cpp_lib_shared_ptr_arrays): Define
1781 as 201611L, because P0497R0 changes are supported.
1782 * include/std/version (__cpp_lib_shared_ptr_arrays): Likewise.
1783
1784 * include/bits/erase_if.h [__cplusplus > 201703L]
1785 (__cpp_lib_erase_if): Only define for C++2a.
1786 * include/std/iterator [__cplusplus >= 201402L && !_GLIBCXX_DEBUG]
1787 (__cpp_lib_null_iterators): Define.
1788 * include/std/version [__cplusplus >= 201402L && !_GLIBCXX_DEBUG]
1789 (__cpp_lib_null_iterators): Define.
1790 [__cpp_impl_destroying_delete] (__cpp_lib_destroying_delete): Define.
1791
1792 * doc/xml/manual/status_cxx2017.xml: Document P0032R3 and P0307R2
1793 status.
1794 * include/bits/stl_uninitialized.h (__cpp_lib_raw_memory_algorithms):
1795 Define.
1796 * include/std/any (__cpp_lib_any): Define as 201606L, because P0032R3
1797 changes are supported.
1798 * include/std/optional (__cpp_lib_optional): Likewise.
1799 * include/std/variant (__cpp_lib_variant): Likewise.
1800 * include/std/version [!__STRICT_ANSI__]
1801 (__cpp_lib_uncaught_exceptions): Define as long integer.
1802 [__cplusplus >= 201703L] (__cpp_lib_any)
1803 (__cpp_lib_raw_memory_algorithms, __cpp_lib_uncaught_exceptions)
1804 (__cpp_lib_variant): Define for C++17.
1805 [__cplusplus >= 201703L] (__cpp_lib_optional): Update value and define
1806 as long integer.
1807 * libsupc++/exception (__cpp_lib_uncaught_exceptions): Define as long
1808 integer.
1809
1810 * doc/xml/manual/status_cxx2020.xml: Update P1123R0 status.
1811
1812 2019-01-12 Jonathan Wakely <jwakely@redhat.com>
1813
1814 PR libstdc++/88811
1815 PR libstdc++/83306
1816 * src/filesystem/path.cc: Fix typo. If first path is empty, show []
1817 before second path.
1818 * testsuite/experimental/filesystem/filesystem_error/cons.cc: New
1819 test.
1820
1821 2019-01-11 Jonathan Wakely <jwakely@redhat.com>
1822
1823 * doc/xml/manual/intro.xml: Include new section.
1824 * doc/xml/manual/status_cxx2017.xml: Document more
1825 implementation-defined properties of the library.
1826 * doc/xml/manual/status_cxx2020.xml: Document C++2a status.
1827 * doc/html/*: Regenerate.
1828
1829 * include/bits/refwrap.h [__cplusplus > 201703L]
1830 (_Refwrap_base_arg1, _Refwrap_base_arg2, _Reference_wrapper_base)
1831 (_Reference_wrapper_base_memfun): Do not define for C++2a.
1832 (reference_wrapper): Do not derive from _Reference_wrapper_base_memfun
1833 for C++2a.
1834 (reference_wrapper::operator()): Add static assertion.
1835 * testsuite/20_util/reference_wrapper/incomplete.cc: New test.
1836
1837 * include/std/chrono (duration_values::zero(), duration_values::min())
1838 (duration_values::max()): Add noexcept.
1839 (duration::zero(), duration::min(), duration::max()): Likewise.
1840 (time_point::zero(), time_point::min(), time_point::max()): Likewise.
1841 * testsuite/20_util/duration/requirements/noexcept.cc: New test.
1842 * testsuite/20_util/time_point/requirements/noexcept.cc: New test.
1843
1844 * include/std/version (__cpp_lib_erase_if): Move to C++20 group.
1845
1846 2019-01-11 Jakub Jelinek <jakub@redhat.com>
1847
1848 * include/std/type_traits (__cpp_lib_is_constant_evaluated): Define.
1849 * include/std/version (__cpp_lib_is_constant_evaluated): Define.
1850
1851 2019-01-11 Jonathan Wakely <jwakely@redhat.com>
1852
1853 PR libstdc++/88802
1854 * include/bits/functional_hash.h (hash<nullptr_t>): Define
1855 specialization for C++17 (P0513R0, LWG 2817).
1856 * testsuite/20_util/hash/nullptr.cc: New test.
1857
1858 PR libstdc++/88125
1859 * config/abi/pre/gnu.ver (GLIBCXX_3.4.6): Remove unused duplicate
1860 pattern for std::basic_stringbuf::str().
1861
1862 * config/abi/pre/gnu.ver (GLIBCXX_3.4): Correct recent changes to
1863 basic_ostream::operator<< patterns.
1864
1865 2019-01-10 Jonathan Wakely <jwakely@redhat.com>
1866
1867 * testsuite/27_io/filesystem/operations/last_write_time.cc: Fix
1868 test failures on targets with 32-bit time_t.
1869
1870 * include/bits/erase_if.h: Define __cpp_lib_erase_if.
1871 * include/std/deque: Likewise.
1872 * include/std/forward_list: Likewise.
1873 * include/std/list: Likewise.
1874 * include/std/string: Likewise.
1875 * include/std/vector: Likewise.
1876 * include/std/version: Likewise.
1877 * testsuite/21_strings/basic_string/erasure.cc: Test macro.
1878 * testsuite/23_containers/deque/erasure.cc: Likewise.
1879 * testsuite/23_containers/forward_list/erasure.cc: Likewise.
1880 * testsuite/23_containers/list/erasure.cc: Likewise.
1881 * testsuite/23_containers/map/erasure.cc: Likewise.
1882 * testsuite/23_containers/set/erasure.cc: Likewise.
1883 * testsuite/23_containers/unordered_map/erasure.cc: Likewise.
1884 * testsuite/23_containers/unordered_set/erasure.cc: Likewise.
1885 * testsuite/23_containers/vector/erasure.cc: Likewise.
1886
1887 * include/experimental/internet [AI_NUMERICSERV]
1888 (resolver_base::numeric_service): Define conditionally.
1889 * testsuite/experimental/net/internet/resolver/base.cc: Test it
1890 conditionally.
1891 * testsuite/experimental/net/internet/resolver/ops/lookup.cc:
1892 Likewise.
1893
1894 2019-01-10 Ville Voutilainen <ville.voutilainen@gmail.com>
1895 Jonathan Wakely <jwakely@redhat.com>
1896
1897 Implement LWG 2221
1898 * config/abi/pre/gnu.ver (GLIBCXX_3.4): Tighten patterns.
1899 (GLIBCXX_3.4.26): Add new exports.
1900 * include/Makefile.am: Add ostream-inst.cc. Move string-inst.cc to
1901 correct list of sources.
1902 * include/Makefile.in: Regenerate.
1903 * include/std/ostream (operator<<(nullptr_t)): New member function.
1904 * src/c++17/ostream-inst.cc: New file.
1905 * testsuite/27_io/basic_ostream/inserters_other/char/lwg2221.cc: New
1906 test.
1907
1908 2019-01-10 Jonathan Wakely <jwakely@redhat.com>
1909
1910 * testsuite/util/testsuite_fs.h (nonexistent_path): Include name
1911 of the source file containing the caller.
1912 * testsuite/27_io/filesystem/iterators/directory_iterator.cc: Remove
1913 directories created by test.
1914 * testsuite/27_io/filesystem/iterators/recursive_directory_iterator.cc:
1915 Likewise.
1916 * testsuite/experimental/filesystem/iterators/directory_iterator.cc:
1917 Likewise.
1918 * testsuite/experimental/filesystem/iterators/
1919 recursive_directory_iterator.cc: Likewise.
1920
1921 2019-01-10 Jakub Jelinek <jakub@redhat.com>
1922
1923 PR tree-optimization/88775
1924 * include/bits/stl_function.h (greater<_Tp*>::operator(),
1925 less<_Tp*>::operator(), greater_equal<_Tp*>::operator(),
1926 less_equal<_Tp*>::operator()): Use __builtin_is_constant_evaluated
1927 instead of __builtin_constant_p if available. Don't bother with
1928 the pointer comparison in C++11 and earlier.
1929
1930 2019-01-09 Sandra Loosemore <sandra@codesourcery.com>
1931
1932 PR other/16615
1933
1934 * include/ext/bitmap_allocator.h: Mechanically replace "can not"
1935 with "cannot".
1936
1937 2019-01-09 Jonathan Wakely <jwakely@redhat.com>
1938
1939 * testsuite/libstdc++-prettyprinters/cxx17.cc: Fix expected output
1940 for filesystem::path. Give variables more distinctive names.
1941
1942 * include/std/optional (_Optional_payload_base::_M_copy_assign): New
1943 member function to perform non-trivial assignment.
1944 (_Optional_payload_base::_M_move_assign): Likewise.
1945 (_Optional_payload<T, true, false, true>::operator=)
1946 (_Optional_payload<T, true, true, false>::operator=)
1947 (_Optional_payload<T, true, false, false>::operator=): Call
1948 _M_copy_assign and/or _M_move_assign to do non-trivial assignments.
1949
1950 PR libstdc++/88204
1951 * testsuite/26_numerics/complex/operators/more_constexpr.cc: Do not
1952 test std::complex<long double> if long double format is IBM128.
1953 * testsuite/26_numerics/complex/requirements/more_constexpr.cc:
1954 Likewise.
1955
1956 2019-01-08 Jonathan Wakely <jwakely@redhat.com>
1957
1958 * testsuite/libstdc++-prettyprinters/compat.cc: Test printer support
1959 for old std::unique_ptr layout.
1960 * testsuite/libstdc++-prettyprinters/cxx17.cc: Fix std::variant test
1961 to become valueless. Add filesystem::path tests.
1962
1963 PR libstdc++/87855
1964 * include/std/optional (_Optional_payload_base): New class template
1965 for common code hoisted from _Optional_payload specializations. Use
1966 a template for the union, to allow a partial specialization for
1967 types with non-trivial destructors. Add constructors for in-place
1968 initialization to the union.
1969 (_Optional_payload(bool, const _Optional_payload&)): Use _M_construct
1970 to perform non-trivial copy construction, instead of relying on
1971 non-standard copy elision in a delegating constructor.
1972 (_Optional_payload(bool, _Optional_payload&&)): Likewise for
1973 non-trivial move construction.
1974 (_Optional_payload): Derive from _Optional_payload_base and use it
1975 for everything except the non-trivial assignment operators, which are
1976 defined as needed.
1977 (_Optional_payload<false, C, M>): Derive from the specialization
1978 _Optional_payload<true, false, false> and add a destructor.
1979 (_Optional_base_impl::_M_destruct, _Optional_base_impl::_M_reset):
1980 Forward to corresponding members of _Optional_payload.
1981 (_Optional_base_impl::_M_is_engaged, _Optional_base_impl::_M_get):
1982 Hoist common members from _Optional_base.
1983 (_Optional_base): Make all members and base class public.
1984 (_Optional_base::_M_get, _Optional_base::_M_is_engaged): Move to
1985 _Optional_base_impl.
1986 * python/libstdcxx/v6/printers.py (StdExpOptionalPrinter): Add
1987 support for new std::optional layout.
1988 * testsuite/libstdc++-prettyprinters/compat.cc: New test.
1989
1990 PR libstdc++/88066
1991 * include/bits/locale_conv.h: Use <> for includes not "".
1992 * include/ext/random: Likewise.
1993 * include/ext/vstring.h: Likewise.
1994
1995 2019-01-08 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1996
1997 * config/abi/pre/gnu.ver (GLIBCXX_3.4): Tighten existing patterns.
1998 (GLIBCXX_3.4.21): Likewise.
1999
2000 2019-01-08 Jonathan Wakely <jwakely@redhat.com>
2001
2002 PR libstdc++/88749
2003 * src/filesystem/ops.cc (last_write_time): Fix preprocessor condition
2004 to match the one that controls whether utimbuf and utime are declared.
2005
2006 2019-01-07 Jonathan Wakely <jwakely@redhat.com>
2007
2008 PR libstdc++/87787
2009 * include/bits/char_traits.h (char_traits::move): Do not pass null
2010 pointers to memmove.
2011 * include/bits/locale_facets.h
2012 (ctype<char>::widen(const char*, const char*, char*)): Do not
2013 pass null pointers to memcpy.
2014 (ctype<char>::narrow(const char*, const char*, char, char*)):
2015 Likewise.
2016 (ctype<char>::do_widen(const char*, const char*, char*)):
2017 Likewise.
2018 (ctype<char>::do_narrow(const char*, const char*, char, char*)):
2019 Likewise.
2020
2021 * doc/xml/manual/spine.xml: Update copyright years.
2022 * doc/xml/manual/status_cxx2017.xml: Adjust note about -lstdc++fs.
2023 * doc/xml/manual/using.xml: Remove requirement to link with -lstdc++fs
2024 for C++17 filesystem library.
2025 * doc/html/*: Regenerate.
2026
2027 * acinclude.m4 (GLIBCXX_CHECK_FILESYSTEM_DEPS): Check for truncate.
2028 * config.h.in: Regenerate.
2029 * config/abi/pre/gnu.ver: Order patterns for filesystem operations
2030 alphabetically and add missing entries for copy_symlink,
2031 hard_link_count, rename, and resize_file.
2032 * configure: Regenerate.
2033 * src/c++17/fs_ops.cc (resize_file): Remove #if so posix::truncate is
2034 used unconditionally.
2035 * src/filesystem/ops-common.h (__gnu_posix::truncate)
2036 [!_GLIBCXX_HAVE_TRUNCATE]: Provide fallback definition that only
2037 supports truncating to zero length.
2038 * testsuite/27_io/filesystem/operations/all.cc: New test.
2039 * testsuite/27_io/filesystem/operations/resize_file.cc: New test.
2040
2041 2019-01-06 Jonathan Wakely <jwakely@redhat.com>
2042
2043 PR libstdc++/86756
2044 * acinclude.m4 (GLIBCXX_CHECK_FILESYSTEM_DEPS): Check for utime and
2045 lstat and define _GLIBCXX_USE_UTIME and _GLIBCXX_USE_LSTAT.
2046 * config.h.in: Regenerate.
2047 * config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Export symbols for
2048 remaining std::filesystem types and functions.
2049 * configure: Regenerate.
2050 * src/c++17/Makefile.am: Add C++17 filesystem sources.
2051 * src/c++17/Makefile.in: Regenerate.
2052 * src/c++17/cow-fs_dir.cc: Move src/filesystem/cow-std-dir.cc to
2053 here, and change name of included file.
2054 * src/c++17/cow-fs_ops.cc: Move src/filesystem/cow-std-ops.cc to
2055 here, and change name of included file.
2056 * src/c++17/fs_dir.cc: Move src/filesystem/std-dir.cc to here. Change
2057 path to dir-common.h.
2058 * src/c++17/fs_ops.cc: Move src/filesystem/std-ops.cc to here. Change
2059 path to ops-common.h. Disable -Wunused-parameter warnings.
2060 (internal_file_clock): Define unconditionally.
2061 [!_GLIBCXX_HAVE_SYS_STAT_H] (internal_file_clock::from_stat): Do not
2062 define.
2063 (do_copy_file, do_space): Move definitions to ops.common.h.
2064 (copy, file_size, hard_link_count, last_write_time, space): Only
2065 perform operation when _GLIBCXX_HAVE_SYS_STAT_H is defined, otherwise
2066 report an error.
2067 (last_write_time, read_symlink): Remove unused attributes from
2068 parameters.
2069 * src/filesystem/Makefile.am: Remove C++17 filesystem sources.
2070 * src/filesystem/Makefile.in: Regenerate.
2071 * src/filesystem/cow-std-dir.cc: Move to src/c++17/cow-fs_dir.cc.
2072 * src/filesystem/cow-std-ops.cc: Move to src/c++17/cow-fs_ops.cc.
2073 * src/filesystem/std-dir.cc: Move to src/c++17/fs_dir.cc.
2074 * src/filesystem/std-ops.cc: Move to src/c++17/fs_ops.cc.
2075 * src/filesystem/dir-common.h [!_GLIBCXX_HAVE_DIRENT_H]: Define
2076 dummy types and functions instead of using #error.
2077 * src/filesystem/dir.cc [!_GLIBCXX_HAVE_DIRENT_H]: Use #error.
2078 * src/filesystem/ops-common.h [!_GLIBCXX_USE_LSTAT] (lstat): Define
2079 in terms of stat.
2080 [!_GLIBCXX_HAVE_UNISTD_H]: Define dummy types and functions.
2081 (do_copy_file, do_space): Move definitions here from std-ops.cc.
2082 * src/filesystem/ops.cc: Adjust calls to do_copy_file and do_space
2083 to account for new namespace.
2084 * testsuite/27_io/filesystem/directory_entry/86597.cc: Remove
2085 -lstdc++fs from dg-options.
2086 * testsuite/27_io/filesystem/directory_entry/lwg3171.cc: Likewise.
2087 * testsuite/27_io/filesystem/file_status/1.cc: Likewise.
2088 * testsuite/27_io/filesystem/filesystem_error/cons.cc: Likewise.
2089 * testsuite/27_io/filesystem/filesystem_error/copy.cc: Likewise.
2090 * testsuite/27_io/filesystem/iterators/directory_iterator.cc:
2091 Likewise.
2092 * testsuite/27_io/filesystem/iterators/pop.cc: Likewise.
2093 * testsuite/27_io/filesystem/iterators/recursive_directory_iterator.cc:
2094 Likewise.
2095 * testsuite/27_io/filesystem/operations/absolute.cc: Likewise.
2096 * testsuite/27_io/filesystem/operations/canonical.cc: Likewise.
2097 * testsuite/27_io/filesystem/operations/copy.cc: Likewise.
2098 * testsuite/27_io/filesystem/operations/copy_file.cc: Likewise.
2099 * testsuite/27_io/filesystem/operations/create_directories.cc:
2100 Likewise.
2101 * testsuite/27_io/filesystem/operations/create_directory.cc: Likewise.
2102 * testsuite/27_io/filesystem/operations/create_symlink.cc: Likewise.
2103 * testsuite/27_io/filesystem/operations/current_path.cc: Likewise.
2104 * testsuite/27_io/filesystem/operations/equivalent.cc: Likewise.
2105 * testsuite/27_io/filesystem/operations/exists.cc: Likewise.
2106 * testsuite/27_io/filesystem/operations/file_size.cc: Likewise.
2107 * testsuite/27_io/filesystem/operations/is_empty.cc: Likewise.
2108 * testsuite/27_io/filesystem/operations/last_write_time.cc: Likewise.
2109 * testsuite/27_io/filesystem/operations/permissions.cc: Likewise.
2110 * testsuite/27_io/filesystem/operations/proximate.cc: Likewise.
2111 * testsuite/27_io/filesystem/operations/read_symlink.cc: Likewise.
2112 * testsuite/27_io/filesystem/operations/relative.cc: Likewise.
2113 * testsuite/27_io/filesystem/operations/remove.cc: Likewise.
2114 * testsuite/27_io/filesystem/operations/remove_all.cc: Likewise.
2115 * testsuite/27_io/filesystem/operations/space.cc: Likewise.
2116 * testsuite/27_io/filesystem/operations/status.cc: Likewise.
2117 * testsuite/27_io/filesystem/operations/symlink_status.cc: Likewise.
2118 * testsuite/27_io/filesystem/operations/temp_directory_path.cc:
2119 Likewise.
2120 * testsuite/27_io/filesystem/operations/weakly_canonical.cc: Likewise.
2121
2122
2123 PR libstdc++/86756
2124 * config/abi/pre/gnu.ver (GLIBCXX_3.4): Make various patterns for
2125 typeinfo and vtables less greedy.
2126 (GLIBCXX_3.4.26): Export symbols for std::filesystem::path.
2127 * src/c++17/Makefile.am: Add fs_path.cc and cow-fs_path.cc.
2128 * src/c++17/Makefile.in: Regenerate.
2129 * src/c++17/cow-fs_path.cc: Move src/filesystem/cow-std-path.cc to
2130 here, and change name of included file.
2131 * src/c++17/fs_path.cc: Move src/filesystem/std-path.cc to here.
2132 * src/filesystem/Makefile.am: Remove std-path.cc and cow-std-path.cc
2133 from sources.
2134 * src/filesystem/Makefile.in: Regenerate.
2135 * src/filesystem/cow-std-path.cc: Move to src/c++17/cow-fs_path.cc.
2136 * src/filesystem/std-path.cc: Move to src/c++17/fs_path.cc.
2137 * testsuite/27_io/filesystem/path/append/path.cc: Remove -lstdc++fs
2138 from dg-options and remove dg-require-filesystem-ts.
2139 * testsuite/27_io/filesystem/path/append/source.cc: Likewise.
2140 * testsuite/27_io/filesystem/path/assign/assign.cc: Likewise.
2141 * testsuite/27_io/filesystem/path/assign/copy.cc: Likewise.
2142 * testsuite/27_io/filesystem/path/compare/compare.cc: Likewise.
2143 * testsuite/27_io/filesystem/path/compare/lwg2936.cc: Likewise.
2144 * testsuite/27_io/filesystem/path/compare/path.cc: Likewise.
2145 * testsuite/27_io/filesystem/path/compare/strings.cc: Likewise.
2146 * testsuite/27_io/filesystem/path/concat/path.cc: Likewise.
2147 * testsuite/27_io/filesystem/path/concat/strings.cc: Likewise.
2148 * testsuite/27_io/filesystem/path/construct/80762.cc: Likewise.
2149 * testsuite/27_io/filesystem/path/construct/copy.cc: Likewise.
2150 * testsuite/27_io/filesystem/path/construct/default.cc: Likewise.
2151 * testsuite/27_io/filesystem/path/construct/format.cc: Likewise.
2152 * testsuite/27_io/filesystem/path/construct/locale.cc: Likewise.
2153 * testsuite/27_io/filesystem/path/construct/range.cc: Likewise.
2154 * testsuite/27_io/filesystem/path/construct/string_view.cc: Likewise.
2155 * testsuite/27_io/filesystem/path/decompose/extension.cc: Likewise.
2156 * testsuite/27_io/filesystem/path/decompose/filename.cc: Likewise.
2157 * testsuite/27_io/filesystem/path/decompose/parent_path.cc: Likewise.
2158 * testsuite/27_io/filesystem/path/decompose/relative_path.cc: Likewise.
2159 * testsuite/27_io/filesystem/path/decompose/root_directory.cc:
2160 Likewise.
2161 * testsuite/27_io/filesystem/path/decompose/root_name.cc: Likewise.
2162 * testsuite/27_io/filesystem/path/decompose/root_path.cc: Likewise.
2163 * testsuite/27_io/filesystem/path/decompose/stem.cc: Likewise.
2164 * testsuite/27_io/filesystem/path/generation/normal.cc: Likewise.
2165 * testsuite/27_io/filesystem/path/generation/normal2.cc: Likewise.
2166 * testsuite/27_io/filesystem/path/generation/proximate.cc: Likewise.
2167 * testsuite/27_io/filesystem/path/generation/relative.cc: Likewise.
2168 * testsuite/27_io/filesystem/path/generic/generic_string.cc: Likewise.
2169 * testsuite/27_io/filesystem/path/itr/components.cc: Likewise.
2170 * testsuite/27_io/filesystem/path/itr/traversal.cc: Likewise.
2171 * testsuite/27_io/filesystem/path/modifiers/clear.cc: Likewise.
2172 * testsuite/27_io/filesystem/path/modifiers/make_preferred.cc:
2173 Likewise.
2174 * testsuite/27_io/filesystem/path/modifiers/remove_filename.cc:
2175 Likewise.
2176 * testsuite/27_io/filesystem/path/modifiers/replace_extension.cc:
2177 Likewise.
2178 * testsuite/27_io/filesystem/path/modifiers/replace_filename.cc:
2179 Likewise.
2180 * testsuite/27_io/filesystem/path/modifiers/swap.cc: Likewise.
2181 * testsuite/27_io/filesystem/path/native/string.cc: Likewise.
2182 * testsuite/27_io/filesystem/path/nonmember/append.cc: Likewise.
2183 * testsuite/27_io/filesystem/path/nonmember/hash_value.cc: Likewise.
2184 * testsuite/27_io/filesystem/path/query/empty.cc: Likewise.
2185 * testsuite/27_io/filesystem/path/query/has_extension.cc: Likewise.
2186 * testsuite/27_io/filesystem/path/query/has_filename.cc: Likewise.
2187 * testsuite/27_io/filesystem/path/query/has_parent_path.cc: Likewise.
2188 * testsuite/27_io/filesystem/path/query/has_relative_path.cc: Likewise.
2189 * testsuite/27_io/filesystem/path/query/has_root_directory.cc:
2190 Likewise.
2191 * testsuite/27_io/filesystem/path/query/has_root_name.cc: Likewise.
2192 * testsuite/27_io/filesystem/path/query/has_root_path.cc: Likewise.
2193 * testsuite/27_io/filesystem/path/query/has_stem.cc: Likewise.
2194 * testsuite/27_io/filesystem/path/query/is_absolute.cc: Likewise.
2195 * testsuite/27_io/filesystem/path/query/is_relative.cc: Likewise.
2196
2197 PR libstdc++/87431
2198 * include/std/variant (_Variant_storage<true, _Types...>::_M_valid):
2199 Check is_trivially_copyable instead of is_scalar.
2200 (variant::emplace<N, Args>(Args&&...)): If construction of the new
2201 contained value can throw and its type is trivially copyable then
2202 construct into a temporary variant and move from it, to provide the
2203 strong exception safety guarantee.
2204 (variant::emplace<N, U, Args>(initializer_list<U>, Args&&...)):
2205 Likewise.
2206 * testsuite/20_util/variant/87431.cc: New test.
2207 * testsuite/20_util/variant/run.cc: Adjust test so that throwing
2208 conversion causes valueless state.
2209
2210 PR libstdc++/88607
2211 * testsuite/17_intro/headers/c++1998/charset.cc: New test.
2212 * testsuite/17_intro/headers/c++2011/charset.cc: New test.
2213 * testsuite/17_intro/headers/c++2014/charset.cc: New test.
2214 * testsuite/17_intro/headers/c++2017/charset.cc: New test.
2215 * testsuite/17_intro/headers/c++2020/charset.cc: New test.
2216
2217 2019-01-05 Jonathan Wakely <jwakely@redhat.com>
2218
2219 * include/bits/fs_fwd.h (__file_clock): Define new clock.
2220 (file_time_type): Redefine in terms of __file_clock.
2221 * src/filesystem/ops-common.h (file_time): Add FIXME comment about
2222 overflow.
2223 * src/filesystem/std-ops.cc (is_set(perm_options, perm_options)): Give
2224 internal linkage.
2225 (internal_file_lock): New helper type for accessing __file_clock.
2226 (do_copy_file): Use internal_file_lock to convert system time to
2227 file_time_type.
2228 (last_write_time(const path&, error_code&)): Likewise.
2229 (last_write_time(const path&, file_time_type, error_code&)): Likewise.
2230
2231 2019-01-04 Jonathan Wakely <jwakely@redhat.com>
2232
2233 * config/abi/pre/gnu.ver (GLIBCXX_3.4.21): Make patterns less greedy
2234 for const member functions of std::basic_string.
2235 (GLIBCXX_3.4.26): Export member functions of std::basic_string added
2236 in C++17.
2237 * include/bits/basic_string.h (basic_string(__sv_wrapper, const A&)):
2238 Make non-standard constructor private.
2239 [!_GLIBCXX_USE_CXX11_ABI] (basic_string(__sv_wrapper, const A&)):
2240 Likewise.
2241 * include/bits/basic_string.tcc (std::string, std::wstring): Declare
2242 explicit instantiations for C++17 as well as earlier dialects.
2243 * src/c++17/Makefile.am: Add new source files.
2244 * src/c++17/Makefile.in: Regenerate.
2245 * src/c++17/cow-string-inst.cc: New file defining explicit
2246 instantiations for basic_string member functions added in C++17.
2247 * src/c++17/string-inst.cc: Likewise.
2248
2249 * config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Export allocator-extended
2250 copy/move constructors for old std::basic_string.
2251 * include/bits/basic_string.h [!_GLIBCXX_USE_CXX11_ABI]
2252 (basic_string::reference, basic_string::const_reference): Define
2253 as plain references for C++11 and later.
2254 (basic_string::basic_string()): Put constructor body outside
2255 preprocessor conditional groups.
2256 (basic_string::basic_string(basic_string&&)): Move _Alloc_hider
2257 instead of copying it.
2258 (basic_string::basic_string(const basic_string&, const _Alloc&)):
2259 Define.
2260 (basic_string::basic_string(basic_string&&, const _Alloc&)):
2261 Define.
2262 * include/bits/fs_path.h [!_GLIBCXX_USE_CXX11_ABI]: Remove special
2263 cases for old basic_string.
2264 * testsuite/21_strings/basic_string/cons/char/8.cc: Test
2265 allocator-extended constructors unconditionally. Add extra members to
2266 allocator type when using old string ABI.
2267 * testsuite/21_strings/basic_string/allocator/71964.cc: Enable test
2268 for old string ABI.
2269 * testsuite/21_strings/basic_string/cons/wchar_t/8.cc: Likewise.
2270
2271 * testsuite/23_containers/list/61347.cc: Avoid spurious failure when
2272 -fno-inline added to test flags.
2273
2274 * testsuite/21_strings/basic_string/requirements/
2275 explicit_instantiation/debug.cc: Remove XFAIL for old ABI.
2276
2277 * testsuite/27_io/filesystem/filesystem_error/copy.cc: Fix static
2278 assertion failures with old std::string ABI.
2279
2280 * include/bits/fs_path.h (path::_List::erase): Replace both overloads
2281 with ...
2282 (path::pop_back(), path::_M_erase_from(const_iterator)): New member
2283 functions that will only erase elements at the end.
2284 * src/filesystem/std-path.cc (path::_List::_Impl::pop_back()): Define.
2285 (path::_List::_Impl::_M_erase_from(const_iterator)): Define.
2286 (path::_List::operator=(const _List&)): Use _M_erase_from(p) instead
2287 of erase(p, end()).
2288 (path::_List::pop_back()): Define.
2289 (path::_List::_M_erase_from(const_iterator)): Define.
2290 (path::operator/=(const path&)): Use pop_back to remove last component
2291 and _M_erase_from to remove multiple components.
2292 (path::_M_append(basic_string_view<value_type>)): Likewise.
2293 (path::operator+=(const path&)): Likewise.
2294 (path::_M_concat(basic_string_view<value_type>)): Likewise.
2295 (path::remove_filename()): Likewise.
2296 (path::lexically_normal()): Use _List::_Impl iterators instead of
2297 path::iterator. Use pop_back to remove components from the end. Clear
2298 trailing filename, instead of using erase(const_iterator) to remove
2299 a non-final component.
2300 * testsuite/27_io/filesystem/path/generation/normal.cc: Test
2301 additional cases.
2302 * testsuite/27_io/filesystem/path/generation/normal2.cc: New test.
2303
2304 * src/filesystem/std-path.cc (path::operator+=(const path&)): Fix
2305 incorrect treatment of empty filename after trailing slash.
2306 * testsuite/27_io/filesystem/path/concat/path.cc: Test problem case.
2307
2308 * testsuite/21_strings/basic_string/modifiers/assign/char/
2309 move_assign_optim.cc: Avoid spurious failure when -fno-inline added
2310 to test flags.
2311 * testsuite/21_strings/basic_string/modifiers/assign/wchar_t/
2312 move_assign_optim.cc: Likewise.
2313
2314 2019-01-03 Jonathan Wakely <jwakely@redhat.com>
2315 Jakub Jelinek <jakub@redhat.com>
2316
2317 PR libstdc++/88607
2318 * include/experimental/memory: Replace UTF-8 quote characters.
2319 * include/std/future: Replace UTF-8 "em dash" characters.
2320
2321 2019-01-03 Jonathan Wakely <jwakely@redhat.com>
2322
2323 PR libstdc++/88607
2324 * include/bits/forward_list.h: Replace UTF-8 "ligature fi" character.
2325 * include/debug/forward_list: Likewise.
2326 * include/experimental/bits/shared_ptr.h: Remove UTF-8 "section sign"
2327 character.
2328 * include/experimental/chrono: Likewise.
2329 * include/experimental/functional: Likewise.
2330 * include/experimental/ratio: Likewise.
2331 * include/experimental/system_error: Likewise.
2332 * include/experimental/tuple: Likewise.
2333 * include/experimental/type_traits: Likewise.
2334 * include/parallel/workstealing.h: Replace UTF-8 "en dash" character.
2335 * include/parallel/multiseq_selection.h: Likewise.
2336
2337 PR libstdc++/88681
2338 * config/abi/pre/gnu.ver: Add missing exports.
2339 * testsuite/22_locale/collate_byname/88681.cc: New test.
2340 * testsuite/22_locale/time_get/get/char/88681.cc: New test.
2341 * testsuite/22_locale/time_get/get/wchar_t/88681.cc: New test.
2342
2343 2019-01-02 Jonathan Wakely <jwakely@redhat.com>
2344
2345 * testsuite/23_containers/map/cons/deduction.cc: Test deduction from
2346 initializer_list<value_type> and from input iterator ranges.
2347 * testsuite/23_containers/multimap/cons/deduction.cc: Likewise.
2348
2349 * testsuite/experimental/string_view/element_access/char/empty.cc:
2350 Fix year range in copyright header.
2351
2352 2019-01-02 Joel Brobecker <brobecker@adacore.com>
2353
2354 * testsuite/21_strings/basic_string_view/element_access/char/empty.cc:
2355 Fix year range in copyright header.
2356
2357 2019-01-01 Jakub Jelinek <jakub@redhat.com>
2358
2359 Update copyright years.
2360 \f
2361 Copyright (C) 2019 Free Software Foundation, Inc.
2362
2363 Copying and distribution of this file, with or without modification,
2364 are permitted in any medium without royalty provided the copyright
2365 notice and this notice are preserved.