Fix handling of POSIX paths containing a root-name
[gcc.git] / libstdc++-v3 / ChangeLog
1 2018-12-13 Jonathan Wakely <jwakely@redhat.com>
2
3 * src/filesystem/std-path.cc (SLASHSLASH_IS_ROOT_NAME): New macro to
4 control whether interpret paths with two slashes as a root-name.
5 (path::operator/=(const path&)) [SLASHSLASH_IS_ROOT_NAME]: Add a
6 root-directory when appending to a root-name.
7 (path::_M_append(basic_string_view<value_type>))
8 [SLASHSLASH_IS_ROOT_NAME]: Likewise.
9 (path::operator/=(const path&)) [SLASHSLASH_IS_ROOT_NAME]: Likewise.
10 (path::_M_concat(basic_string_view<value_type>))
11 [SLASHSLASH_IS_ROOT_NAME]: Likewise.
12 (path::lexically_normal()) [SLASHSLASH_IS_ROOT_NAME]: Use += instead
13 of /= to add a root-directory to the result.
14 * testsuite/27_io/filesystem/path/decompose/root_directory.cc: Fix
15 expected result for Cygwin.
16
17 PR libstdc++/71044
18 * include/bits/fs_path.h (path::path(path&&)): Add noexcept when
19 appropriate. Move _M_cmpts instead of reparsing the native pathname.
20 (path::operator=(const path&)): Do not define as defaulted.
21 (path::operator/=, path::append): Call _M_append.
22 (path::concat): Call _M_concat.
23 (path::path(string_type, _Type): Change type of first parameter to
24 basic_string_view<value_type>.
25 (path::_M_append(basic_string_view<value_type>)): New member function.
26 (path::_M_concat(basic_string_view<value_type>)): New member function.
27 (_S_convert(value_type*, __null_terminated)): Return string view.
28 (_S_convert(const value_type*, __null_terminated)): Return string view.
29 (_S_convert(value_type*, value_type*))
30 (_S_convert(const value_type*, const value_type*)): Add overloads for
31 pairs of pointers.
32 (_S_convert(_InputIterator, __null_terminated)): Construct string_type
33 explicitly, for cases where _S_convert returns a string view.
34 (path::_S_is_dir_sep): Replace with non-member is_dir_sep.
35 (path::_M_trim, path::_M_add_root_name, path::_M_add_root_dir)
36 (path::_M_add_filename): Remove.
37 (path::_M_type()): New member function to replace _M_type data member.
38 (path::_List): Define new struct type instead of using std::vector.
39 (path::_Cmpt::_Cmpt(string_type, _Type, size_t)): Change type of
40 first parameter to basic_string_view<value_type>.
41 (path::operator+=(const path&)): Do not define inline.
42 (path::operator+=(const string_type&)): Call _M_concat.
43 (path::operator+=(const value_type*)): Likewise.
44 (path::operator+=(value_type)): Likewise.
45 (path::operator+=(basic_string_view<value_type>)): Likewise.
46 (path::operator/=(const path&)): Do not define inline.
47 (path::_M_append(path)): Remove.
48 * python/libstdcxx/v6/printers.py (StdPathPrinter): New printer that
49 understands the new path::_List type.
50 * src/filesystem/std-path.cc (is_dir_sep): New function to replace
51 path::_S_is_dir_sep.
52 (path::_Parser): New helper class to parse strings as paths.
53 (path::_List::_Impl): Define container type for path components.
54 (path::_List): Define members.
55 (path::operator=(const path&)): Define explicitly, to provide the
56 strong exception safety guarantee.
57 (path::operator/=(const path&)): Implement manually by processing
58 each component of the argument, rather than using _M_split_cmpts
59 to parse the entire string again.
60 (path::_M_append(string_type)): Likewise.
61 (path::operator+=(const path&)): Likewise.
62 (path::_M_concat(string_type)): Likewise.
63 (path::remove_filename()): Perform trim directly instead of calling
64 _M_trim().
65 (path::_M_split_cmpts()): Rewrite in terms of _Parser class.
66 (path::_M_trim, path::_M_add_root_name, path::_M_add_root_dir)
67 (path::_M_add_filename): Remove.
68 * testsuite/27_io/filesystem/path/append/source.cc: Test appending a
69 string view that aliases the path.
70 testsuite/27_io/filesystem/path/concat/strings.cc: Test concatenating
71 a string view that aliases the path.
72
73 * testsuite/27_io/filesystem/path/generation/proximate.cc: Use
74 preferred directory separators for normalized paths.
75 * testsuite/27_io/filesystem/path/generation/relative.cc: Likewise.
76
77 * testsuite/27_io/filesystem/path/itr/traversal.cc: Fix test for
78 mingw.
79
80 * testsuite/27_io/filesystem/path/construct/80762.cc: Skip test if
81 the Filesystem TS support is not configured.
82 * testsuite/experimental/filesystem/path/construct/80762.cc: Likewise.
83
84 2018-12-12 Jonathan Wakely <jwakely@redhat.com>
85
86 PR libstdc++/71044 (partial)
87 * include/bits/fs_path.h (__path_iter_distance, __path_iter_advance):
88 New friend functions to implement std::distance and std::advance more
89 efficiently.
90 (distance, advance): Add overloads for path::iterator.
91 * testsuite/27_io/filesystem/path/itr/components.cc: Test new
92 overload.
93
94 PR libstdc++/80762
95 * include/bits/fs_path.h (path::_Path): Use remove_cv_t and is_void.
96 * include/experimental/bits/fs_path.h (path::_Path): Likewise.
97 * testsuite/27_io/filesystem/path/construct/80762.cc: New test.
98 * testsuite/experimental/filesystem/path/construct/80762.cc: New test.
99
100 2018-12-12 Jakub Jelinek <jakub@redhat.com>
101
102 P0595R2 - is_constant_evaluated
103 * include/bits/c++config (_GLIBCXX_HAVE_BUILTIN_IS_CONSTANT_EVALUATED):
104 Define if __builtin_is_constant_evaluated is available.
105 * include/std/type_traits (std::is_constant_evaluated): New constexpr
106 inline function.
107 * testsuite/20_util/is_constant_evaluated/1.cc: New test.
108 * testsuite/20_util/is_constant_evaluated/noexcept.cc: New test.
109
110 2018-12-10 Gerald Pfeifer <gerald@pfeifer.com>
111
112 * doc/xml/manual/documentation_hacking.xml: Update reference
113 to epubcheck.
114
115 2018-12-10 Jonathan Wakely <jwakely@redhat.com>
116
117 * testsuite/experimental/filesystem/path/query/is_absolute.cc: Fix
118 test to use TS, not C++17.
119
120 2018-12-06 Iain Sandoe <iain@sandoe.co.uk>
121
122 * scripts/make_exports.pl (check names): Don’t try to export
123 construction vtable symbols.
124
125 2018-12-06 Jonathan Wakely <jwakely@redhat.com>
126 Iain Sandoe <iain@sandoe.co.uk>
127
128 PR libstdc++/64883
129 * testsuite/17_intro/headers/c++1998/all_attributes.cc: Don't test
130 always_inline on Darwin.
131 * testsuite/17_intro/headers/c++2011/all_attributes.cc: Likewise.
132 * testsuite/17_intro/headers/c++2014/all_attributes.cc: Likewise.
133 * testsuite/17_intro/headers/c++2017/all_attributes.cc: Likewise.
134 * testsuite/17_intro/headers/c++2020/all_attributes.cc: Likewise.
135
136 2018-12-03 Edward Smith-Rowland <3dw4rd@verizon.net>
137
138 PR libstdc++/88341 - Complex norm doesn't compile with C++11
139 * include/std/complex (_S_do_it): Make C++20 constexpr.
140 * testsuite/26_numerics/complex/value_operations/pr88341.cc: New test.
141
142 2018-11-30 Edward Smith-Rowland <3dw4rd@verizon.net>
143
144 Implement P0457R2 String Prefix and Suffix Checking.
145 * include/bits/basic_string.h: Add starts_with, ends_with members.
146 * include/std/string_view: Ditto.
147 * testsuite/21_strings/basic_string/operations/starts_with/
148 char/1.cc: New test.
149 * testsuite/21_strings/basic_string/operations/starts_with/
150 wchar_t/1.cc: New test.
151 * testsuite/21_strings/basic_string/operations/ends_with/
152 char/1.cc: New test.
153 * testsuite/21_strings/basic_string/operations/ends_with/
154 wchar_t/1.cc: New test.
155 * testsuite/21_strings/basic_string_view/operations/starts_with/
156 char/1.cc: New test.
157 * testsuite/21_strings/basic_string_view/operations/starts_with/
158 wchar_t/1.cc: New test.
159 * testsuite/21_strings/basic_string_view/operations/ends_with/
160 char/1.cc: New test.
161 * testsuite/21_strings/basic_string_view/operations/ends_with/
162 wchar_t/1.cc: New test.
163
164 2018-11-30 Edward Smith-Rowland <3dw4rd@verizon.net>
165
166 Pre-emptively support P0646R1 for std container erasure.
167 * include/bits/erase_if.h: Accumulate and return number of erased nodes.
168 * include/std/forward_list (): Return number of erased items.
169 * include/std/list (): Ditto.
170 * include/std/map (): Ditto.
171 * include/std/set (): Ditto.
172 * include/std/string (): Ditto.
173 * include/std/unordered_map (): Ditto.
174 * include/std/unordered_set (): Ditto.
175 * include/std/vector (): Ditto.
176 * include/std/deque (): Ditto.
177 * testsuite/21_strings/basic_string/erasure.cc: Test number of erasures.
178 * testsuite/23_containers/deque/erasure.cc: Ditto.
179 * testsuite/23_containers/forward_list/erasure.cc: Ditto.
180 * testsuite/23_containers/list/erasure.cc: Ditto.
181 * testsuite/23_containers/map/erasure.cc: Ditto.
182 * testsuite/23_containers/set/erasure.cc: Ditto.
183 * testsuite/23_containers/unordered_map/erasure.cc: Ditto.
184 * testsuite/23_containers/unordered_set/erasure.cc: Ditto.
185 * testsuite/23_containers/vector/erasure.cc: Ditto.
186
187 2018-11-29 Edward Smith-Rowland <3dw4rd@verizon.net>
188
189 Only include bits/stl_algo.h for C++20.
190 * include/std/deque: Only include bits/stl_algo.h for C++20.
191 * include/std/string: Ditto.
192 * include/std/vector: Ditto.
193
194 2018-11-29 Edward Smith-Rowland <3dw4rd@verizon.net>
195
196 Fix erasure goofs.
197 * include/experimental/deque: Make inline.
198 * include/std/deque: Include bits/stl_algo.h.
199 (erase, erase_if): Make inline.
200 * include/std/string: Include bits/stl_algo.h.
201 * include/std/unordered_set: Add erase, erase_if!
202 * include/std/vector: Include bits/stl_algo.h.
203 * testsuite/21_strings/basic_string/erasure.cc:
204 Add { dg-options "-std=gnu++2a" }.
205 * testsuite/23_containers/deque/erasure.cc: Ditto.
206 * testsuite/23_containers/forward_list/erasure.cc: Ditto.
207 * testsuite/23_containers/list/erasure.cc: Ditto.
208 * testsuite/23_containers/map/erasure.cc: Ditto.
209 * testsuite/23_containers/set/erasure.cc: Ditto.
210 * testsuite/23_containers/unordered_map/erasure.cc: Ditto.
211 * testsuite/23_containers/unordered_set/erasure.cc: Ditto.
212 * testsuite/23_containers/vector/erasure.cc: Ditto.
213
214 2018-11-29 Jonathan Wakely <jwakely@redhat.com>
215
216 PR libstdc++/88119
217 * include/ext/aligned_buffer.h (__aligned_membuf): Add comment.
218 (__aligned_buffer): Use __alignof__ instead of std::alignment_of.
219 * include/std/type_traits (alignment_of): Use alignof instead of
220 __alignof__.
221 * testsuite/20_util/alignment_of/value.cc: Fix test to check values
222 match alignof not __alignof__, as required by the standard.
223
224 PR libstdc++/86910
225 PR libstdc++/87846
226 * src/filesystem/ops.cc (experimental::create_directories): Report
227 an error when the path resolves to an existing non-directory (P1164).
228 * src/filesystem/std-ops.cc (create_directories): Likewise. Handle
229 empty filenames due to trailing slashes.
230 * testsuite/27_io/filesystem/operations/create_directories.cc: Test
231 when some component of the path exists and is not a directory. Test
232 trailing slashes.
233 * testsuite/experimental/filesystem/operations/create_directories.cc:
234 Likewise.
235
236 2018-11-28 Jonathan Wakely <jwakely@redhat.com>
237
238 PR libstdc++/83306
239 * src/filesystem/path.cc (filesystem_error::_M_gen_what()): Create
240 string directly, instead of calling fs_err_concat.
241
242 PR libstdc++/83511
243 * include/std/string_view (basic_string_view::substr): Add default
244 argument to first parameter.
245 * include/experimental/string_view (basic_string_view::substr):
246 Likewise.
247 * testsuite/21_strings/basic_string_view/operations/substr/char/
248 83511.cc: New test.
249 * testsuite/21_strings/basic_string_view/operations/substr/wchar_t/
250 83511.cc: New test.
251 * testsuite/experimental/string_view/operations/substr/char/83511.cc:
252 New test.
253 * testsuite/experimental/string_view/operations/substr/wchar_t/83511.cc:
254 New test.
255
256 2018-11-28 Edward Smith-Rowland <3dw4rd@verizon.net>
257
258 Implement uniform container erasure for C++20.
259 * include/Makefile.am: Move erase_if.h.
260 * include/Makefile.in: Move erase_if.h.
261 * include/experimental/bits/erase_if.h: Move ...
262 * include/bits/erase_if.h: ... here.
263 * include/experimental/map: Move erase_if.h.
264 * include/experimental/set: Move erase_if.h.
265 * include/experimental/unordered_map: Move erase_if.h.
266 * include/experimental/unordered_set: Move erase_if.h.
267 * include/std/deque (erase_if, erase): New functions.
268 * include/std/forward_list: Ditto.
269 * include/std/list: Ditto.
270 * include/std/map: Ditto.
271 * include/std/set: Ditto.
272 * include/std/string: Ditto.
273 * include/std/unordered_map: Ditto.
274 * include/std/unordered_set: Ditto.
275 * include/std/vector: Ditto.
276 * testsuite/21_strings/basic_string/erasure.cc: New test.
277 * testsuite/23_containers/deque/erasure.cc: New test.
278 * testsuite/23_containers/forward_list/erasure.cc: New test.
279 * testsuite/23_containers/list/erasure.cc: New test.
280 * testsuite/23_containers/map/erasure.cc: New test.
281 * testsuite/23_containers/set/erasure.cc: New test.
282 * testsuite/23_containers/unordered_map/erasure.cc: New test.
283 * testsuite/23_containers/unordered_set/erasure.cc: New test.
284 * testsuite/23_containers/vector/erasure.cc: New test.
285
286 2018-11-28 Jonathan Wakely <jwakely@redhat.com>
287
288 * doc/xml/manual/intro.xml: Document LWG 3096 change.
289 * src/filesystem/std-path.cc (path::lexically_relative(const path&)):
290 Treat a final empty element equivalently to a final dot element.
291 * testsuite/27_io/filesystem/path/generation/relative.cc: Add checks
292 for the examples in the DR.
293
294 PR libstdc++/83306
295 * include/bits/fs_path.h (filesystem_error): Move data members into
296 pimpl class owned by shared_ptr. Remove inline definitions of member
297 functions.
298 * src/filesystem/std-path.cc (filesystem_error::_Impl): Define.
299 (filesystem_error): Define member functions.
300 * testsuite/27_io/filesystem/filesystem_error/cons.cc: New test.
301 * testsuite/27_io/filesystem/filesystem_error/copy.cc: New test.
302
303 * doc/xml/manual/status_cxx2017.xml: Update C++17 status.
304 * doc/html/*: Regenerate.
305
306 2018-11-27 Jonathan Wakely <jwakely@redhat.com>
307
308 * testsuite/27_io/filesystem/operations/canonical.cc: Remove
309 directory created by test.
310 * testsuite/27_io/filesystem/operations/symlink_status.cc: Remove
311 symlink created by test.
312
313 PR libstdc++/67843
314 * acinclude.m4 (GLIBCXX_ENABLE_LOCK_POLICY): Add new macro
315 that defines _GLIBCXX_HAVE_ATOMIC_LOCK_POLICY.
316 * config.h.in: Regenerate.
317 * configure: Regenerate.
318 * configure.ac: Use GLIBCXX_ENABLE_LOCK_POLICY.
319 * doc/xml/manual/configure.xml: Document new configure option.
320 * include/bits/fs_dir.h (directory_iterator): Use __shared_ptr
321 instead of shared_ptr.
322 (recursive_directory_iterator): Likewise.
323 (__shared_ptr<_Dir>): Add explicit instantiation declaration.
324 (__shared_ptr<recursive_directory_iterator::_Dir_stack>): Likewise.
325 * include/bits/shared_ptr_base.h (__allocate_shared, __make_shared):
326 Add default template argument for _Lock_policy template parameter.
327 * include/ext/concurrence.h (__default_lock_policy): Check macro
328 _GLIBCXX_HAVE_ATOMIC_LOCK_POLICY instead of checking if the current
329 target supports the builtins for compare-and-swap.
330 * src/filesystem/std-dir.cc (__shared_ptr<_Dir>): Add explicit
331 instantiation definition.
332 (__shared_ptr<recursive_directory_iterator::_Dir_stack>): Likewise.
333 (directory_iterator, recursive_directory_iterator): Use __make_shared
334 instead of make_shared.
335
336 2018-11-27 François Dumont <fdumont@gcc.gnu.org>
337
338 PR libstdc++/88199
339 * include/bits/hashtable.h (_Hashtable<>::_M_assign_elements): New.
340 (_Hashtable<>::operator=(const _Hashtable&)): Use latter.
341 (_Hashtable<>::_M_move_assign(_Hashtable&&, false_type)): Likewise.
342 * testsuite/23_containers/unordered_set/allocator/move_assign.cc
343 (test03): New.
344
345 2018-11-26 Jonathan Wakely <jwakely@redhat.com>
346
347 * testsuite/26_numerics/complex/requirements/more_constexpr.cc: Fix
348 failure on targets without __float128.
349
350 2018-11-23 Edward Smith-Rowland <3dw4rd@verizon.net>
351
352 Implement P0415 More constexpr for std::complex.
353 * include/std/complex (conj(complex<Tp>), norm(complex<Tp>)): Constexpr;
354 (real(Tp), imag(Tp)): Constexpr;
355 (operator@=(Tp), operator@=(complex<Tp>)): Constexpr;
356 (operator@(Tp,complex<Tp>), operator@(complex<Tp>,Tp)
357 operator@(complex<Tp>,complex<Tp>)): Constexpr.
358 * testsuite/26_numerics/complex/comparison_operators/
359 more_constexpr.cc: New test.
360 * testsuite/26_numerics/complex/operators/more_constexpr.cc: New test.
361 * testsuite/26_numerics/complex/requirements/
362 more_constexpr.cc: New test.
363 * testsuite/26_numerics/complex/value_operations/
364 more_constexpr.cc: New test.
365 * testsuite/26_numerics/headers/complex/synopsis.cc:
366 Add _GLIBCXX20_CONSTEXPR to applicable operators; Add missing proj().
367 * testsuite/26_numerics/headers/complex/synopsis.cc:
368 Add _GLIBCXX20_CONSTEXPR to relevant decls.
369
370 2018-11-23 Martin Sebor <msebor@redhat.com>
371 Jonathan Wakely <jwakely@redhat.com>
372
373 PR libstdc++/65229
374 * python/libstdcxx/v6/printers.py (StdBitsetPrinter): Handle
375 exception thrown for std::bitset<0>.
376 * testsuite/libstdc++-prettyprinters/simple.cc: Test std::bitset<0>.
377
378 2018-11-23 Jonathan Wakely <jwakely@redhat.com>
379
380 PR libstdc++/87308 (partial)
381 * python/libstdcxx/v6/printers.py (StdExpAnyPrinter): Adjust regex to
382 work around PR 88166.
383 * testsuite/libstdc++-prettyprinters/cxx17.cc: Test std::any
384 containing a local type.
385
386 2018-11-22 Marc Glisse <marc.glisse@inria.fr>
387
388 PR libstdc++/87106
389 * include/bits/stl_algobase.h: Include <type_traits>.
390 (__niter_base): Add noexcept specification.
391 * include/bits/stl_deque.h: Include <bits/stl_uninitialized.h>.
392 (__is_trivially_relocatable): Specialize for deque.
393 * include/bits/stl_iterator.h: Include <type_traits>.
394 (__niter_base): Add noexcept specification.
395 * include/bits/stl_uninitialized.h (__is_trivially_relocatable):
396 Add parameter for meta-programming.
397 (__relocate_a_1, __relocate_a): Add noexcept specification.
398 * include/bits/stl_vector.h (__use_relocate): Test __relocate_a.
399
400 2018-11-22 Jonathan Wakely <jwakely@redhat.com>
401
402 PR libstdc++/85930
403 PR libstdc++/87520
404 * include/bits/shared_ptr_base.h (_Sp_make_shared_tag::_S_ti)
405 [__cpp_rtti]: Define even when RTTI is enabled. Use array of
406 sizeof(type_info) so that type-punned reference binds to an object
407 of the correct size as well as correct alignment.
408 (_Sp_counted_ptr_inplace::_M_get_deleter) [__cpp_rtti]: Check for
409 _S_ti() reference even when RTTI is enabled.
410 (__shared_ptr(_Sp_make_shared_tag, const _Alloc&, _Args&&...))
411 [__cpp_rtti]: Pass _S_ti() instead of typeid(_Sp_make_shared_tag).
412
413 2018-11-21 Jakub Jelinek <jakub@redhat.com>
414
415 PR c++/87386
416 * testsuite/20_util/scoped_allocator/69293_neg.cc: Adjust expected
417 line.
418 * testsuite/20_util/uses_allocator/cons_neg.cc: Likewise.
419 * testsuite/20_util/uses_allocator/69293_neg.cc: Likewise.
420 * testsuite/experimental/propagate_const/requirements2.cc: Likewise.
421 * testsuite/experimental/propagate_const/requirements3.cc: Likewise.
422 * testsuite/experimental/propagate_const/requirements4.cc: Likewise.
423 * testsuite/experimental/propagate_const/requirements5.cc: Likewise.
424
425 2018-11-21 Jonathan Wakely <jwakely@redhat.com>
426
427 PR libstdc++/88111
428 * include/std/memory_resource (pool_options): Add Doxygen comments.
429 * src/c++17/memory_resource.cc (pool_sizes): Only use suitable values
430 on targets with 16-bit or 20-bit size_t type.
431 (munge_options): Make default values depend on width of size_t type.
432
433 PR libstdc++/88113
434 * src/c++17/memory_resource.cc (bitset::size_type): Use the smaller
435 of uint32_t and size_t.
436 (bitset::size(), bitset::free(), bitset::update_next_word())
437 (bitset::max_blocks_per_chunk(), bitset::max_word_index()): Use
438 size_type consistently instead of size_t.
439 (chunk): Adjust static_assert checking sizeof(chunk).
440
441 2018-11-20 Ville Voutilainen <ville.voutilainen@gmail.com>
442
443 Housekeeping for the effective targets of optional's tests.
444 * testsuite/20_util/optional/77288.cc: Adjust.
445 * testsuite/20_util/optional/84601.cc: Likewise.
446 * testsuite/20_util/optional/assignment/1.cc: Likewise.
447 * testsuite/20_util/optional/assignment/2.cc: Likewise.
448 * testsuite/20_util/optional/assignment/3.cc: Likewise.
449 * testsuite/20_util/optional/assignment/4.cc: Likewise.
450 * testsuite/20_util/optional/assignment/5.cc: Likewise.
451 * testsuite/20_util/optional/assignment/6.cc: Likewise.
452 * testsuite/20_util/optional/assignment/7.cc: Likewise.
453 * testsuite/20_util/optional/assignment/8.cc: Likewise.
454 * testsuite/20_util/optional/cons/77727.cc: Likewise.
455 * testsuite/20_util/optional/cons/copy.cc: Likewise.
456 * testsuite/20_util/optional/cons/deduction.cc: Likewise.
457 * testsuite/20_util/optional/cons/default.cc: Likewise.
458 * testsuite/20_util/optional/cons/move.cc: Likewise.
459 * testsuite/20_util/optional/cons/trivial.cc: Likewise.
460 * testsuite/20_util/optional/cons/value.cc: Likewise.
461 * testsuite/20_util/optional/cons/value_neg.cc: Likewise.
462 * testsuite/20_util/optional/constexpr/cons/default.cc: Likewise.
463 * testsuite/20_util/optional/constexpr/cons/value.cc: Likewise.
464 * testsuite/20_util/optional/constexpr/in_place.cc: Likewise.
465 * testsuite/20_util/optional/constexpr/nullopt.cc: Likewise.
466 * testsuite/20_util/optional/constexpr/observers/1.cc: Likewise.
467 * testsuite/20_util/optional/constexpr/observers/4.cc: Likewise.
468 * testsuite/20_util/optional/constexpr/observers/5.cc: Likewise.
469 * testsuite/20_util/optional/constexpr/relops/1.cc: Likewise.
470 * testsuite/20_util/optional/constexpr/relops/2.cc: Likewise.
471 * testsuite/20_util/optional/constexpr/relops/3.cc: Likewise.
472 * testsuite/20_util/optional/constexpr/relops/4.cc: Likewise.
473 * testsuite/20_util/optional/constexpr/relops/5.cc: Likewise.
474 * testsuite/20_util/optional/constexpr/relops/6.cc: Likewise.
475 * testsuite/20_util/optional/in_place.cc: Likewise.
476 * testsuite/20_util/optional/make_optional.cc: Likewise.
477 * testsuite/20_util/optional/nullopt.cc: Likewise.
478 * testsuite/20_util/optional/observers/1.cc: Likewise.
479 * testsuite/20_util/optional/observers/2.cc: Likewise.
480 * testsuite/20_util/optional/observers/3.cc: Likewise.
481 * testsuite/20_util/optional/observers/4.cc: Likewise.
482 * testsuite/20_util/optional/observers/5.cc: Likewise.
483 * testsuite/20_util/optional/observers/6.cc: Likewise.
484 * testsuite/20_util/optional/relops/1.cc: Likewise.
485 * testsuite/20_util/optional/relops/2.cc: Likewise.
486 * testsuite/20_util/optional/relops/3.cc: Likewise.
487 * testsuite/20_util/optional/relops/4.cc: Likewise.
488 * testsuite/20_util/optional/relops/5.cc: Likewise.
489 * testsuite/20_util/optional/relops/6.cc: Likewise.
490 * testsuite/20_util/optional/relops/7.cc: Likewise.
491 * testsuite/20_util/optional/requirements.cc: Likewise.
492 * testsuite/20_util/optional/swap/1.cc: Likewise.
493 * testsuite/20_util/optional/swap/2.cc: Likewise.
494 * testsuite/20_util/optional/typedefs.cc: Likewise.
495
496 2018-11-19 François Dumont <fdumont@gcc.gnu.org>
497
498 * include/ext/throw_allocator.h
499 (annotate_base::insert(void*, size_t)): Use insert result to check for
500 double insert attempt.
501 (annotate_base::insert_construct(void*)): Likewise.
502 (annotate_base::check_allocated(void*, size_t)): Return found iterator.
503 (annotate_base::erase(void*, size_t)): Use latter method returned
504 iterator.
505 (annotate_base::check_constructed(void*, size_t)): Return found iterator.
506 (annotate_base::erase_construct(void*)): Use latter method returned
507 iterator.
508
509 2018-11-19 Ville Voutilainen <ville.voutilainen@gmail.com>
510
511 PR libstdc++/87855
512 Also implement P0602R4 (variant and optional
513 should propagate copy/move triviality) for std::optional.
514 * include/std/optional (_Optional_payload): Change
515 the main constraints to check constructibility in
516 addition to assignability.
517 (operator=): Make constexpr.
518 (_M_reset): Likewise.
519 (_M_construct): Likewise.
520 (operator->): Likewise.
521 * testsuite/20_util/optional/assignment/8.cc: Adjust.
522 * testsuite/20_util/optional/assignment/9.cc: New.
523
524 2018-11-19 Jonathan Wakely <jwakely@redhat.com>
525
526 PR libstdc++/88084 - Implement LWG 2777
527 * include/std/string_view (basic_string_view::copy): Use traits to
528 copy.
529 * testsuite/21_strings/basic_string_view/operations/copy/char/2.cc:
530 New test.
531 * testsuite/21_strings/basic_string_view/operations/copy/wchar_t/2.cc:
532 New test.
533
534 2018-11-18 Michele Pezzutti <mpezz@tiscali.it>
535 Edward Smith-Rowland <3dw4rd@verizon.net>
536
537 PR libstdc++/83566 - cyl_bessel_j returns wrong result for x>1000
538 for high orders.
539 * include/tr1/bessel_function.tcc: Perform no fewer than nu/2 iterations
540 of the asymptotic series (nu is the Bessel order).
541 * testsuite/tr1/5_numerical_facilities/special_functions/
542 09_cyl_bessel_j/check_value.cc: Add tests at nu=100, 1000<=x<=2000.
543 * testsuite/tr1/5_numerical_facilities/special_functions/
544 11_cyl_neumann/check_value.cc: Ditto.
545 * testsuite/special_functions/08_cyl_bessel_j/check_value.cc: Ditto.
546 * testsuite/special_functions/10_cyl_neumann/check_value.cc: Ditto.
547
548 2018-11-17 Jonathan Wakely <jwakely@redhat.com>
549
550 Implement std::pmr::synchronized_pool_resource
551 * config/abi/pre/gnu.ver: Add new symbols.
552 * include/std/memory_resource [_GLIBCXX_HAS_GTHREADS]
553 (__cpp_lib_memory_resource): Define to expected value, 201603.
554 (synchronized_pool_resource): New class.
555 [!_GLIBCXX_HAS_GTHREADS] (__cpp_lib_memory_resource): Define to 1.
556 * include/std/shared_mutex (__glibcxx_rwlock_rdlock)
557 (__glibcxx_rwlock_tryrdlock, __glibcxx_rwlock_wrlock)
558 (__glibcxx_rwlock_trywrlock, __glibcxx_rwlock_unlock)
559 (__glibcxx_rwlock_destroy, __glibcxx_rwlock_init)
560 (__glibcxx_rwlock_timedrdlock, __glibcxx_rwlock_timedwrlock): Define
561 weak symbols for POSIX rwlock functions.
562 (__shared_mutex_pthread): Use weak symbols.
563 * include/std/version (__cpp_lib_memory_resource): Define.
564 * src/c++17/memory_resource.cc [_GLIBCXX_HAS_GTHREADS]
565 (synchronized_pool_resource::_TPools): New class.
566 (destroy_TPools): New function for pthread_key_create destructor.
567 (synchronized_pool_resource::synchronized_pool_resource)
568 (synchronized_pool_resource::~synchronized_pool_resource)
569 (synchronized_pool_resource::release)
570 (synchronized_pool_resource::do_allocate)
571 (synchronized_pool_resource::do_deallocate): Define public members.
572 (synchronized_pool_resource::_M_thread_specific_pools)
573 (synchronized_pool_resource::_M_alloc_tpools)
574 (synchronized_pool_resource::_M_alloc_shared_tpools): Define private
575 members.
576 * testsuite/20_util/synchronized_pool_resource/allocate.cc: New test.
577 * testsuite/20_util/synchronized_pool_resource/cons.cc: New test.
578 * testsuite/20_util/synchronized_pool_resource/is_equal.cc: New test.
579 * testsuite/20_util/synchronized_pool_resource/multithreaded.cc: New
580 test.
581 * testsuite/20_util/synchronized_pool_resource/release.cc: New test.
582 * testsuite/performance/20_util/memory_resource/pools.cc: Add
583 multithreaded tests using pmr::synchronized_pool_resource.
584
585 2018-11-16 Renlin Li <renlin.li@arm.com>
586 Tejas Belagod <tejas.belagod@arm.com>
587
588 testsuite/lib/libstdc++.exp (check_v3_target_prop_cached): New proc.
589 (check_v3_target): Use the check_v3_target_prop_cached.
590
591 2018-11-15 Jonathan Wakely <jwakely@redhat.com>
592
593 * scripts/check_performance: Allow tests to choose a -std flag.
594 * src/c++17/memory_resource.cc (bitset::get_first_unset()): Use local
595 variables of the right types. Call update_next_word() unconditionally.
596 * testsuite/20_util/unsynchronized_pool_resource/cons.cc: New test.
597 * testsuite/performance/20_util/memory_resource/pools.cc: New test.
598 * testsuite/util/testsuite_performance.h (time_counter): Allow
599 timer to be restarted.
600
601 * testsuite/20_util/unsynchronized_pool_resource/allocate.cc: Fix
602 test for 32-bit targets. Test additional allocation sizes.
603
604 2018-11-14 Jonathan Wakely <jwakely@redhat.com>
605
606 * scripts/create_testsuite_files: Add special_functions to the list
607 of directories to search. Add comment referring to conformance.exp.
608 * testsuite/libstdc++-dg/conformance.exp: Add comment referring
609 to create_testsuite_files.
610
611 2018-11-13 Jonathan Wakely <jwakely@redhat.com>
612
613 * src/c++17/memory_resource.cc (select_num_pools): Fix off-by-one
614 error when block_size is equal to one of the values in the array.
615
616 * src/c++17/memory_resource.cc (_Pool::deallocate): Restore
617 attributes to parameters that are only used in assertions.
618
619 * src/c++17/memory_resource.cc (bitset::find_first_unset()): Remove
620 unused function.
621 (bitset::get_first_unset()): Remove loop, if there's are unset bits
622 then _M_next_word refers to the first one and there's no need to loop.
623 (_Pool::_Pool(size_t, size_t), _Pool::block_size()): Remove dead code.
624
625 * src/c++17/memory_resource.cc (munge_options): Round up value of
626 largest_required_pool_block to multiple of smallest pool size. Round
627 excessively large values down to largest pool size.
628 (select_num_pools): Increase number of pools by one unless it exactly
629 matches requested largest_required_pool_block.
630 (__pool_resource::_M_alloc_pools()): Make largest pool size equal
631 largest_required_pool_block.
632 * testsuite/20_util/unsynchronized_pool_resource/options.cc: Check
633 that pool_options::largest_required_pool_block is set appropriately.
634
635 * src/c++17/memory_resource.cc (big_block): Improve comments.
636 (big_block::all_ones): Remove.
637 (big_block::big_block(size_t, size_t)): Use alloc_size.
638 (big_block::size()): Add comment, replace all_ones with equivalent
639 expression.
640 (big_block::align()): Shift value of correct type.
641 (big_block::alloc_size(size_t)): New function to round up size.
642 (__pool_resource::allocate(size_t, size_t)): Add comment.
643 (__pool_resource::deallocate(void*, size_t, size_t)): Likewise. Fix
644 incorrect assertion by using big_block::alloc_size(size_t).
645 * testsuite/20_util/unsynchronized_pool_resource/allocate.cc: Add
646 more tests for unpooled allocations.
647
648 * src/c++17/memory_resource.cc (bitset::full()): Handle edge case
649 for _M_next_word maximum value.
650 (bitset::get_first_unset(), bitset::set(size_type)): Use
651 update_next_word() to update _M_next_word.
652 (bitset::update_next_word()): New function, avoiding wraparound of
653 unsigned _M_next_word member.
654 (bitset::max_word_index()): New function.
655 (chunk::chunk(void*, uint32_t, void*, size_t)): Add assertion.
656 (chunk::max_bytes_per_chunk()): New function.
657 (pool::replenish(memory_resource*, const pool_options&)): Prevent
658 _M_blocks_per_chunk from exceeding max_blocks_per_chunk or from
659 causing chunk::max_bytes_per_chunk() to be exceeded.
660 * testsuite/20_util/unsynchronized_pool_resource/allocate-max-chunks.cc:
661 New test.
662
663 2018-11-12 Jason Merrill <jason@redhat.com>
664
665 * libsupc++/new (std::destroying_delete_t): New.
666
667 2018-11-12 Jonathan Wakely <jwakely@redhat.com>
668
669 PR libstdc++/87963
670 * src/c++17/memory_resource.cc (chunk::_M_bytes): Change type from
671 unsigned to uint32_t.
672 (chunk): Fix static assertion for 64-bit targets that aren't LP64.
673 (bigblock::all_ones): Fix undefined shift.
674
675 2018-11-11 Hans-Peter Nilsson <hp@axis.com>
676
677 PR libstdc++-v3/54005
678 * include/bits/atomic_base.h (__atomic_base<_TTp>::is_lock_free(),
679 __atomic_base<_PTp*>::is_lock_free()): Call __atomic_is_lock_free
680 with the type-derived _S_alignment instead of __alignof the object.
681 * include/std/atomic (atomic<T>::is_lock_free()): Likewise.
682
683 2018-11-11 Jonathan Wakely <jwakely@redhat.com>
684
685 Implement P0318R1 unwrap_ref_decay and unwrap_reference
686 * include/std/type_traits (unwrap_reference, unwrap_reference_t)
687 (unwrap_ref_decay, unwrap_ref_decay_t): New traits and aliases.
688 * testsuite/20_util/unwrap_reference/1.cc: New test.
689 * testsuite/20_util/unwrap_reference/2.cc: New test.
690
691 Implement P1007R3 std::assume_aligned
692 * include/std/memory (assume_aligned): Implement for C++17.
693 * testsuite/20_util/assume_aligned/1.cc: New test.
694 * testsuite/20_util/assume_aligned/2_neg.cc: New test.
695 * testsuite/20_util/assume_aligned/3.cc: New test.
696
697 2018-11-09 Jonathan Wakely <jwakely@redhat.com>
698
699 PR libstdc++/87787
700 * include/bits/stl_uninitialized.h (__relocate_a_1): Do not call
701 memmove when there's nothing to copy (and pointers could be null).
702
703 2018-11-07 Hafiz Abid Qadeer <abidh@codesourcery.com>
704
705 * configure: Regenerated.
706
707 2018-11-07 Jonathan Wakely <jwakely@redhat.com>
708
709 * config/abi/pre/gnu.ver: Fix patterns for size_t parameters.
710
711 2018-11-06 Jonathan Wakely <jwakely@redhat.com>
712
713 Implement std::pmr::unsynchronized_pool_resource
714 * config/abi/pre/gnu.ver: Add new symbols.
715 * include/std/memory_resource (std::pmr::__pool_resource): New class.
716 (std::pmr::unsynchronized_pool_resource): New class.
717 * src/c++17/Makefile.am: Add -fimplicit-templates to flags for
718 memory_resource.cc
719 * src/c++17/Makefile.in: Regenerate.
720 * src/c++17/memory_resource.cc (bitset, chunk, big_block): New
721 internal classes.
722 (__pool_resource::_Pool): Define new class.
723 (munge_options, pool_index, select_num_pools): New internal functions.
724 (__pool_resource::__pool_resource, __pool_resource::~__pool_resource)
725 (__pool_resource::allocate, __pool_resource::deallocate)
726 (__pool_resource::_M_alloc_pools): Define member functions.
727 (unsynchronized_pool_resource::unsynchronized_pool_resource)
728 (unsynchronized_pool_resource::~unsynchronized_pool_resource)
729 (unsynchronized_pool_resource::release)
730 (unsynchronized_pool_resource::_M_find_pool)
731 (unsynchronized_pool_resource::do_allocate)
732 (unsynchronized_pool_resource::do_deallocate): Define member
733 functions.
734 * testsuite/20_util/unsynchronized_pool_resource/allocate.cc: New
735 test.
736 * testsuite/20_util/unsynchronized_pool_resource/is_equal.cc: New
737 test.
738 * testsuite/20_util/unsynchronized_pool_resource/options.cc: New
739 test.
740 * testsuite/20_util/unsynchronized_pool_resource/release.cc: New
741 test.
742
743 2018-11-06 John Bytheway <jbytheway@gmail.com>
744
745 PR libstdc++/87872
746 * include/debug/safe_sequence.tcc
747 (_Safe_sequence<>::_M_transfer_from_if): Skip transfer to self.
748
749 2018-10-31 Joseph Myers <joseph@codesourcery.com>
750
751 PR bootstrap/82856
752 * Makefile.am: Include multilib.am.
753 * configure.ac: Remove AC_PREREQ.
754 * Makefile.in, aclocal.m4, configure, doc/Makefile.in,
755 include/Makefile.in, libsupc++/Makefile.in, po/Makefile.in,
756 python/Makefile.in, src/Makefile.in, src/c++11/Makefile.in,
757 src/c++17/Makefile.in, src/c++98/Makefile.in,
758 src/filesystem/Makefile.in, testsuite/Makefile.in: Regenerate.
759
760 2018-10-31 Jonathan Wakely <jwakely@redhat.com>
761
762 * testsuite/20_util/pair/87822.cc: Test deeper nesting.
763
764 PR libstdc++/87822
765 * include/bits/stl_pair.h (__pair_base): Change to class template.
766 (pair): Make base class type depend on template parameters.
767 * testsuite/20_util/pair/87822.cc: New test.
768
769 2018-10-30 Marek Polacek <polacek@redhat.com>
770
771 Implement P0892R2, explicit(bool).
772 * testsuite/20_util/any/cons/explicit.cc: Adjust dg-error.
773 * testsuite/20_util/pair/cons/explicit_construct.cc: Likewise.
774 * testsuite/20_util/tuple/cons/explicit_construct.cc: Likewise.
775
776 2018-10-30 Jonathan Wakely <jwakely@redhat.com>
777
778 PR libstdc++/87809
779 * include/bits/forward_list.h (_Fwd_list_impl::_Fwd_list_impl()): Use
780 trait in exception-specification instead of possibly invalid
781 expression.
782 * include/bits/stl_bvector.h (_Bvector_impl::_Bvector_impl()):
783 Likewise.
784 * include/bits/stl_list.h (_List_impl::_List_impl()): Likewise.
785 * include/bits/stl_vector.h (_Vector_impl::_Vector_impl()): Likewise.
786 * testsuite/23_containers/forward_list/cons/87809.cc: New test.
787 * testsuite/23_containers/list/cons/87809.cc: New test.
788 * testsuite/23_containers/vector/bool/cons/87809.cc: New test.
789 * testsuite/23_containers/vector/cons/87809.cc: New test.
790
791 PR libstdc++/87784
792 * include/tr2/dynamic_bitset (dynamic_bitset::push_back): When there
793 are no unused bits in the last block, append a new block with the
794 right value so the bit doesn't need to be set. Only increment size
795 after setting the new bit, not before.
796 * testsuite/tr2/dynamic_bitset/pr87784.cc: New test.
797
798 2018-10-29 David Malcolm <dmalcolm@redhat.com>
799
800 * testsuite/17_intro/using_namespace_std_exp_neg.cc: Remove
801 "expected namespace-name before" error.
802 * testsuite/17_intro/using_namespace_std_tr1_neg.cc: Likewise.
803
804 2018-10-28 François Dumont <fdumont@gcc.gnu.org>
805
806 * testsuite/23_containers/deque/48101_neg.cc: Remove dg-prune-output
807 'std' from regex pattern for versioned namespace compatibility.
808 * testsuite/23_containers/vector/48101_neg.cc: Likewise.
809 * testsuite/27_io/filesystem/path/io/dr2989.cc: Likewise.
810
811 2018-10-25 Jonathan Wakely <jwakely@redhat.com>
812
813 PR libstdc++/87749
814 * include/bits/basic_string.h [_GLIBCXX_USE_CXX11_ABI]
815 (basic_string::operator=(basic_string&&)): For short strings copy the
816 buffer inline. Only fall back to using assign(const basic_string&) to
817 do a deep copy when reallocation is needed.
818 * testsuite/21_strings/basic_string/modifiers/assign/char/87749.cc:
819 New test.
820 * testsuite/21_strings/basic_string/modifiers/assign/char/
821 move_assign_optim.cc: New test.
822 * testsuite/21_strings/basic_string/modifiers/assign/wchar_t/87749.cc:
823 New test.
824 * testsuite/21_strings/basic_string/modifiers/assign/wchar_t/
825 move_assign_optim.cc: New test.
826
827 2018-10-25 Marc Glisse <marc.glisse@inria.fr>
828
829 PR libstdc++/87106
830 * include/bits/alloc_traits.h (_S_construct, _S_destroy, construct,
831 destroy): Add noexcept specification.
832 * include/bits/allocator.h (construct, destroy): Likewise.
833 * include/ext/alloc_traits.h (construct, destroy): Likewise.
834 * include/ext/malloc_allocator.h (construct, destroy): Likewise.
835 * include/ext/new_allocator.h (construct, destroy): Likewise.
836 * include/bits/stl_uninitialized.h (__relocate_object_a, __relocate_a,
837 __relocate_a_1): New functions.
838 (__is_trivially_relocatable): New class.
839 * include/bits/stl_vector.h (__use_relocate): New static member.
840 * include/bits/vector.tcc (reserve, _M_realloc_insert,
841 _M_default_append): Use __relocate_a.
842 (reserve, _M_assign_aux, _M_realloc_insert, _M_fill_insert,
843 _M_default_append, _M_range_insert): Move _GLIBCXX_ASAN_ANNOTATE_REINIT
844 after _Destroy.
845 * testsuite/23_containers/vector/modifiers/push_back/49836.cc:
846 Replace CopyConsOnlyType with DelAnyAssign.
847
848 2018-10-24 François Dumont <fdumont@gcc.gnu.org>
849
850 * include/debug/safe_unordered_container.h
851 (_Safe_unordered_container<>::_M_invalidate_locals): Take lambda
852 parameter type from local end variable.
853 (_Safe_unordered_container<>::_M_invalidate_all): Likewise.
854 * include/debug/unordered_map
855 (unordered_map<>::begin()): Use C++11 direct initialization.
856 (unordered_map<>::end()): Likewise.
857 (unordered_map<>::cbegin()): Likewise.
858 (unordered_map<>::cend()): Likewise.
859 (unordered_map<>::begin(size_type)): Likewise.
860 (unordered_map<>::end(size_type)): Likewise.
861 (unordered_map<>::cbegin(size_type)): Likewise.
862 (unordered_map<>::cend(size_type)): Likewise.
863 (unordered_map<>::emplace<>(_Args&&...)): Likewise.
864 (unordered_map<>::emplace_hint<>(const_iterator, _Args&&...)): Likewise.
865 (unordered_map<>::insert(const value_type&)): Likewise.
866 (unordered_map<>::insert(value_type&&)): Likewise.
867 (unordered_map<>::insert<>(_Pair&&)): Likewise.
868 (unordered_map<>::insert(const_iterator, const value_type&)): Likewise.
869 (unordered_map<>::insert(const_iterator, value_type&&)): Likewise.
870 (unordered_map<>::insert<>(const_iterator, _Pair&&)): Likewise.
871 (unordered_map<>::try_emplace<>(const key_type&, _Args&&...)): Likewise.
872 (unordered_map<>::try_emplace<>(key_type&&, _Args&&...)): Likewise.
873 (unordered_map<>::try_emplace<>(const_iterator, const key_type&,
874 _Args&&...)): Likewise.
875 (unordered_map<>::try_emplace<>(const_iterator, key_type&&,
876 _Args&&...)): Likewise.
877 (unordered_map<>::insert_or_assign<>(const key_type&, _Obj&&)): Likewise.
878 (unordered_map<>::insert_or_assign<>(key_type&&, _Obj&&)): Likewise.
879 (unordered_map<>::insert_or_assign<>(const_iterator, const key_type&,
880 _Obj&&)): Likewise.
881 (unordered_map<>::insert_or_assign<>(const_iterator, key_type&&,
882 _Obj&&)): Likewise.
883 (unordered_map<>::insert(note_type&&)): Likewise.
884 (unordered_map<>::find(const key_type&)): Likewise.
885 (unordered_map<>::equal_range(const key_type&)): Likewise.
886 (unordered_map<>::_M_extract): New.
887 (unordered_map<>::extract(const_iterator)): Use latter.
888 (unordered_map<>::extract(const key_type&)): Likewise.
889 (unordered_map<>::_M_erase): New.
890 (unordered_map<>::erase(const key_type&)): Use latter.
891 (unordered_map<>::erase(const_iterator)): Likewise.
892 (unordered_map<>::erase(iterator)): Likewise.
893 (unordered_map<>::_M_invalidate): New.
894 (unordered_map<>::erase(const_iterator, const_iterator)): Use latter.
895 (unordered_multimap<>::begin()): Use C++11 direct initialization.
896 (unordered_multimap<>::end()): Likewise.
897 (unordered_multimap<>::cbegin()): Likewise.
898 (unordered_multimap<>::cend()): Likewise.
899 (unordered_multimap<>::begin(size_type)): Likewise.
900 (unordered_multimap<>::end(size_type)): Likewise.
901 (unordered_multimap<>::cbegin(size_type)): Likewise.
902 (unordered_multimap<>::cend(size_type)): Likewise.
903 (unordered_multimap<>::emplace<>(_Args&&...)): Likewise.
904 (unordered_multimap<>::emplace_hint<>(const_iterator, _Args&&...)): Likewise.
905 (unordered_multimap<>::insert(const value_type&)): Likewise.
906 (unordered_multimap<>::insert(const_iterator, const value_type&)): Likewise.
907 (unordered_multimap<>::insert(const_iterator, value_type&&)): Likewise.
908 (unordered_multimap<>::insert<>(_Pair&&)): Likewise.
909 (unordered_multimap<>::insert<>(const_iterator, _Pair&&)): Likewise.
910 (unordered_multimap<>::insert(note_type&&)): Likewise.
911 (unordered_multimap<>::insert(const_iterator, note_type&&)): Likewise.
912 (unordered_multimap<>::find(const key_type&)): Likewise.
913 (unordered_multimap<>::equal_range(const key_type&)): Likewise.
914 (unordered_multimap<>::_M_extract): New.
915 (unordered_multimap<>::extract(const_iterator)): Use latter.
916 (unordered_multimap<>::extract(const key_type&)): Likewise.
917 (unordered_multimap<>::_M_erase): New.
918 (unordered_multimap<>::erase(const_iterator)): Likewise.
919 (unordered_multimap<>::erase(iterator)): Likewise.
920 (unordered_multimap<>::_M_invalidate): New.
921 (unordered_multimap<>::erase(const key_type&)): Use latter.
922 (unordered_multimap<>::erase(const_iterator, const_iterator)): Likewise.
923 * include/debug/unordered_set
924 (unordered_set<>::begin()): Use C++11 direct initialization.
925 (unordered_set<>::end()): Likewise.
926 (unordered_set<>::cbegin()): Likewise.
927 (unordered_set<>::cend()): Likewise.
928 (unordered_set<>::begin(size_type)): Likewise.
929 (unordered_set<>::end(size_type)): Likewise.
930 (unordered_set<>::cbegin(size_type)): Likewise.
931 (unordered_set<>::cend(size_type)): Likewise.
932 (unordered_set<>::emplace<>(_Args&&...)): Likewise.
933 (unordered_set<>::emplace_hint<>(const_iterator, _Args&&...)): Likewise.
934 (unordered_set<>::insert(const value_type&)): Likewise.
935 (unordered_set<>::insert(value_type&&)): Likewise.
936 (unordered_set<>::insert(const_iterator, const value_type&)): Likewise.
937 (unordered_set<>::insert(const_iterator, value_type&&)): Likewise.
938 (unordered_set<>::insert(note_type&&)): Likewise.
939 (unordered_set<>::insert(const_iterator, note_type&&)): Likewise.
940 (unordered_set<>::find(const key_type&)): Likewise.
941 (unordered_set<>::equal_range(const key_type&)): Likewise.
942 (unordered_set<>::_M_extract): New.
943 (unordered_set<>::extract(const_iterator)): Use latter.
944 (unordered_set<>::extract(const key_type&)): Likewise.
945 (unordered_set<>::_M_erase): New.
946 (unordered_set<>::erase(const key_type&)): Use latter.
947 (unordered_set<>::erase(const_iterator)): Likewise.
948 (unordered_set<>::erase(iterator)): Likewise.
949 (unordered_set<>::_M_invalidate): New.
950 (unordered_set<>::erase(const_iterator, const_iterator)): Use latter.
951 (unordered_multiset<>::begin()): Use C++11 direct initialization.
952 (unordered_multiset<>::end()): Likewise.
953 (unordered_multiset<>::cbegin()): Likewise.
954 (unordered_multiset<>::cend()): Likewise.
955 (unordered_multiset<>::begin(size_type)): Likewise.
956 (unordered_multiset<>::end(size_type)): Likewise.
957 (unordered_multiset<>::cbegin(size_type)): Likewise.
958 (unordered_multiset<>::cend(size_type)): Likewise.
959 (unordered_multiset<>::emplace<>(_Args&&...)): Likewise.
960 (unordered_multiset<>::emplace_hint<>(const_iterator, _Args&&...)): Likewise.
961 (unordered_multiset<>::insert(const value_type&)): Likewise.
962 (unordered_multiset<>::insert(const_iterator, const value_type&)): Likewise.
963 (unordered_multiset<>::insert(value_type&&)): Likewise.
964 (unordered_multiset<>::insert(const_iterator, value_type&&)): Likewise.
965 (unordered_multiset<>::insert(node_type&&)): Likewise.
966 (unordered_multiset<>::insert(const_iterator, node_type&&)): Likewise.
967 (unordered_multiset<>::find(const key_type&)): Likewise.
968 (unordered_multiset<>::equal_range(const key_type&)): Likewise.
969 (unordered_multiset<>::_M_extract): New.
970 (unordered_multiset<>::extract(const_iterator)): Use latter.
971 (unordered_multiset<>::extract(const key_type&)): Likewise.
972 (unordered_multiset<>::_M_erase): New.
973 (unordered_multiset<>::erase(const_iterator)): Likewise.
974 (unordered_multiset<>::erase(iterator)): Likewise.
975 (unordered_multiset<>::_M_invalidate): New.
976 (unordered_multiset<>::erase(const key_type&)): Use latter.
977 (unordered_multiset<>::erase(const_iterator, const_iterator)): Likewise.
978
979 * include/c_global/cstddef: Add versioned namespace.
980
981 2018-10-23 Jonathan Wakely <jwakely@redhat.com>
982
983 PR libstdc++/87704
984 * include/bits/unique_ptr.h (unique_ptr::unique_ptr(nullptr_t)): Do
985 not delegate to default constructor.
986 (unique_ptr<T[], D>::unique_ptr(nullptr_t)): Likewise.
987 * testsuite/20_util/unique_ptr/cons/incomplete.cc: New test.
988
989 2018-10-20 François Dumont <fdumont@gcc.gnu.org>
990
991 * testsuite/util/testsuite_containers.h
992 (forward_members_unordered<>::forward_members_unordered
993 (const value_type&)): Add local_iterator pre and post increment checks.
994 * config/abi/pre/gnu.ver: Add GLIBCXX_3.4.26 new symbol.
995
996 2018-10-19 Jonathan Wakely <jwakely@redhat.com>
997
998 * testsuite/23_containers/array/requirements/explicit_instantiation/
999 3.cc: Skip test when compiled with a -std=c++NN strict mode.
1000 * testsuite/23_containers/deque/requirements/explicit_instantiation/
1001 3.cc: Likewise.
1002 * testsuite/23_containers/forward_list/requirements/
1003 explicit_instantiation/3.cc: Likewise.
1004 * testsuite/23_containers/list/requirements/explicit_instantiation/
1005 3.cc: Likewise.
1006 * testsuite/23_containers/map/requirements/explicit_instantiation/
1007 3.cc: Likewise.
1008 * testsuite/23_containers/multimap/requirements/explicit_instantiation/
1009 3.cc: Likewise.
1010 * testsuite/23_containers/multiset/requirements/explicit_instantiation/
1011 3.cc: Likewise.
1012 * testsuite/23_containers/set/requirements/explicit_instantiation/
1013 3.cc: Likewise.
1014 * testsuite/23_containers/unordered_map/requirements/
1015 explicit_instantiation/3.cc: Likewise.
1016 * testsuite/23_containers/unordered_multimap/requirements/
1017 explicit_instantiation/3.cc: Likewise.
1018 * testsuite/23_containers/unordered_multiset/requirements/
1019 explicit_instantiation/3.cc: Likewise.
1020 * testsuite/23_containers/unordered_set/requirements/
1021 explicit_instantiation/3.cc: Likewise.
1022 * testsuite/23_containers/vector/ext_pointer/explicit_instantiation/
1023 3.cc: Likewise.
1024 * testsuite/23_containers/vector/requirements/explicit_instantiation/
1025 3.cc: Likewise.
1026
1027 * testsuite/23_containers/deque/48101_neg.cc: Prune additional errors
1028 printed when __STRICT_ANSI__ is defined.
1029 * testsuite/23_containers/forward_list/48101_neg.cc: Likewise.
1030 * testsuite/23_containers/list/48101_neg.cc: Likewise.
1031 * testsuite/23_containers/multiset/48101_neg.cc: Likewise.
1032 * testsuite/23_containers/set/48101_neg.cc: Likewise.
1033 * testsuite/23_containers/unordered_multiset/48101_neg.cc: Likewise.
1034 * testsuite/23_containers/unordered_set/48101_neg.cc: Likewise.
1035 * testsuite/23_containers/vector/48101_neg.cc: Likewise.
1036
1037 * testsuite/23_containers/forward_list/requirements/
1038 explicit_instantiation/5.cc [__STRICT_ANSI__]: Don't test non-standard
1039 extension.
1040 * testsuite/23_containers/list/requirements/explicit_instantiation/
1041 5.cc [__STRICT_ANSI__]: Likewise.
1042 * testsuite/23_containers/map/requirements/explicit_instantiation/5.cc
1043 [__STRICT_ANSI__]: Likewise.
1044 * testsuite/23_containers/multimap/requirements/explicit_instantiation/
1045 5.cc [__STRICT_ANSI__]: Likewise.
1046 * testsuite/23_containers/multiset/requirements/explicit_instantiation/
1047 5.cc [__STRICT_ANSI__]: Likewise.
1048 * testsuite/23_containers/set/requirements/explicit_instantiation/5.cc
1049 [__STRICT_ANSI__]: Likewise.
1050 * testsuite/23_containers/unordered_map/requirements/debug_container.cc
1051 [__STRICT_ANSI__]: Likewise.
1052 * testsuite/23_containers/unordered_map/requirements/
1053 explicit_instantiation/5.cc [__STRICT_ANSI__]: Likewise.
1054 * testsuite/23_containers/unordered_multimap/requirements/
1055 explicit_instantiation/5.cc [__STRICT_ANSI__]: Likewise.
1056 * testsuite/23_containers/unordered_multiset/requirements/
1057 explicit_instantiation/5.cc [__STRICT_ANSI__]: Likewise.
1058 * testsuite/23_containers/unordered_set/requirements/
1059 explicit_instantiation/5.cc [__STRICT_ANSI__]: Likewise.
1060
1061 * testsuite/20_util/scoped_allocator/1.cc: Use allocator with correct
1062 value type for the container.
1063 * testsuite/23_containers/forward_list/cons/14.cc: Likewise.
1064 * testsuite/23_containers/map/56613.cc: Likewise.
1065 * testsuite/23_containers/unordered_map/55043.cc: Likewise.
1066 * testsuite/23_containers/unordered_map/allocator/copy.cc: Likewise.
1067 * testsuite/23_containers/unordered_map/allocator/copy_assign.cc:
1068 Likewise.
1069 * testsuite/23_containers/unordered_map/allocator/minimal.cc:
1070 Likewise.
1071 * testsuite/23_containers/unordered_map/allocator/move.cc: Likewise.
1072 * testsuite/23_containers/unordered_map/allocator/move_assign.cc:
1073 Likewise.
1074 * testsuite/23_containers/unordered_map/allocator/noexcept.cc:
1075 Likewise.
1076 * testsuite/23_containers/unordered_map/cons/81891.cc: Likewise.
1077 * testsuite/23_containers/unordered_map/requirements/exception/
1078 basic.cc: Likewise.
1079 * testsuite/23_containers/unordered_map/requirements/exception/
1080 generation_prohibited.cc: Likewise.
1081 * testsuite/23_containers/unordered_map/requirements/exception/
1082 propagation_consistent.cc: Likewise.
1083 * testsuite/23_containers/unordered_multimap/55043.cc: Likewise.
1084 * testsuite/23_containers/unordered_multimap/allocator/copy.cc:
1085 Likewise.
1086 * testsuite/23_containers/unordered_multimap/allocator/copy_assign.cc:
1087 Likewise.
1088 * testsuite/23_containers/unordered_multimap/allocator/minimal.cc:
1089 Likewise.
1090 * testsuite/23_containers/unordered_multimap/allocator/move.cc:
1091 Likewise.
1092 * testsuite/23_containers/unordered_multimap/allocator/move_assign.cc:
1093 Likewise.
1094 * testsuite/23_containers/unordered_multimap/allocator/noexcept.cc:
1095 Likewise.
1096 * testsuite/23_containers/unordered_multimap/requirements/exception/
1097 basic.cc: Likewise.
1098 * testsuite/23_containers/unordered_multimap/requirements/exception/
1099 generation_prohibited.cc: Likewise.
1100 * testsuite/23_containers/unordered_multimap/requirements/exception/
1101 propagation_consistent.cc: Likewise.
1102 * testsuite/23_containers/unordered_multimap/requirements/
1103 explicit_instantiation/5.cc: Likewise.
1104 * testsuite/ext/malloc_allocator/sanity.cc: Likewise.
1105
1106 * ext/special_functions/airy_ai/check_nan.cc: Skip test for
1107 non-standard extension when a strict -std=c++NN dialect is used.
1108 * ext/special_functions/airy_ai/check_value.cc: Likewise.
1109 * ext/special_functions/airy_ai/compile.cc: Likewise.
1110 * ext/special_functions/airy_bi/check_nan.cc: Likewise.
1111 * ext/special_functions/airy_bi/check_value.cc: Likewise.
1112 * ext/special_functions/airy_bi/compile.cc: Likewise.
1113 * ext/special_functions/conf_hyperg/check_nan.cc: Likewise.
1114 * ext/special_functions/conf_hyperg/check_value.cc: Likewise.
1115 * ext/special_functions/conf_hyperg/compile.cc: Likewise.
1116 * ext/special_functions/hyperg/check_nan.cc: Likewise.
1117 * ext/special_functions/hyperg/check_value.cc: Likewise.
1118 * ext/special_functions/hyperg/compile.cc: Likewise.
1119
1120 * testsuite/23_containers/list/requirements/explicit_instantiation/
1121 5_c++0x.cc: Remove redundant test that is functionally identical to
1122 the 5.cc test.
1123 * testsuite/23_containers/map/requirements/explicit_instantiation/
1124 5_c++0x.cc: Likewise.
1125 * testsuite/23_containers/multimap/requirements/explicit_instantiation/
1126 5_c++0x.cc: Likewise.
1127 * testsuite/23_containers/multiset/requirements/explicit_instantiation/
1128 5_c++0x.cc: Likewise.
1129 * testsuite/23_containers/set/requirements/explicit_instantiation/
1130 5_c++0x.cc: Likewise.
1131
1132 * include/bits/regex_executor.tcc (_Backref_matcher::_M_apply): Use
1133 _GLIBCXX_STD_A to refer to normal mode algorithms.
1134 * testsuite/28_regex/headers/regex/parallel_mode.cc: New test.
1135 * testsuite/28_regex/headers/regex/std_c++0x_neg.cc: Remove empty
1136 whitespace.
1137
1138 * include/debug/map.h (map::erase(iterator)): Add abi-tag so that
1139 C++11 version mangles differently from incompatible C++98 version.
1140 * include/debug/multimap.h (multimap::erase(iterator)): Likewise.
1141 * include/debug/multiset.h (multiset::erase(iterator))
1142 (multiset::erase(const_iterator, const_iterator)): Likewise.
1143 * include/debug/set.h (set::erase(iterator))
1144 (multiset::erase(const_iterator, const_iterator)): Likewise.
1145
1146 2018-10-18 Jonathan Wakely <jwakely@redhat.com>
1147
1148 * testsuite/20_util/duration/cons/2.cc: Add -ffloat-store to fix
1149 failure when compiled without optimisation.
1150 * testsuite/ext/profile/mutex_extensions_neg.cc: Prune additional
1151 errors caused by C++17 std::pmr alias templates.
1152
1153 PR libstdc++/87642
1154 * config/locale/gnu/monetary_members.cc
1155 (moneypunct<char, true>::_M_initialize_moneypunct): Use
1156 __narrow_multibyte_chars to convert multibyte thousands separators
1157 to a single char.
1158 * config/locale/gnu/numeric_members.cc
1159 (numpunct<char>::_M_initialize_numpunct): Likewise.
1160 (__narrow_multibyte_chars): New function.
1161
1162 PR libstdc++/87641
1163 * include/bits/valarray_array.h (__valarray_sum): Use first element
1164 to initialize accumulator instead of value-initializing it.
1165 (__valarray_product<_Tp>): Move to ...
1166 * src/c++98/valarray.cc (__valarray_product<_Tp>): Here. Use first
1167 element to initialize accumulator.
1168 (__valarray_product(const valarray<size_t>&)): Remove const_cast made
1169 unnecessary by LWG 389.
1170 * testsuite/26_numerics/valarray/87641.cc: New test.
1171
1172 2018-10-18 François Dumont <fdumont@gcc.gnu.org>
1173
1174 Partial revert.
1175 2018-10-08 François Dumont <fdumont@gcc.gnu.org>
1176
1177 * include/debug/list (list<>::cbegin()): Use C++11 direct
1178 initialization.
1179 (list<>::cend()): Likewise.
1180 (list<>::erase(const_iterator, const_iterator)): Ensure consistent
1181 iterator comparisons.
1182 (list<>::splice(const_iterator, list&&, const_iterator,
1183 const_iterator)): Likewise.
1184
1185 Partial revert.
1186 2018-10-15 François Dumont <fdumont@gcc.gnu.org>
1187
1188 * include/debug/vector (vector<>::cbegin()): Use C++11 direct
1189 initialization.
1190 (vector<>::cend()): Likewise.
1191 (vector<>::insert(const_iterator, const _Tp&)): Use consistent
1192 iterator comparison.
1193 (vector<>::erase(const_iterator)): Likewise.
1194 (vector<>::erase(const_iterator, const_iterator)): Likewise.
1195
1196 2018-10-17 Ville Voutilainen <ville.voutilainen@gmail.com>
1197
1198 PR libstdc++/87619
1199 * include/std/variant (__select_index): Fix an off-by-one.
1200 * testsuite/20_util/variant/87619.cc: New.
1201
1202 2018-10-16 Jonathan Wakely <jwakely@redhat.com>
1203
1204 * include/bits/random.h (random_device) [!_GLIBCXX_USE_DEV_RANDOM]:
1205 Fix default constructor to call correct function.
1206
1207 * testsuite/experimental/net/internet/address/v4/creation.cc: Do not
1208 declare ip in global namespace, to avoid collision with struct ip
1209 defined in <netinet/ip.h>.
1210
1211 * include/experimental/bits/net.h: Move versioned namespace macros
1212 to correct location.
1213 * include/experimental/buffer: Likewise.
1214 * include/experimental/executor: Likewise.
1215 * include/experimental/internet: Likewise.
1216 * include/experimental/io_context: Likewise.
1217 * include/experimental/netfwd: Likewise.
1218 * include/experimental/socket: Likewise.
1219 * include/experimental/timer: Likewise.
1220
1221 * config.h.in: Regenerate.
1222 * configure: Regenerate.
1223 * configure.ac: Check for headers used by Networking TS.
1224 * include/experimental/executor: Include <condition_variable>
1225 instead of <mutex>.
1226 * include/experimental/internet: Use autoconf macros for available
1227 headers. Include <sys/socket.h> for. Remove <cstring> and use
1228 __builtin_memcpy and __builtin_strchr.
1229 (resolver_errc) [!_GLIBCXX_HAVE_NETDB_H]: Do not define.
1230 (address_v4::to_string, address_v6::to_string)
1231 [!_GLIBCXX_HAVE_ARPA_INET_H]: Likewise.
1232 (basic_resolver_results) [!_GLIBCXX_HAVE_NETDB_H]: Make private
1233 constructors report errors.
1234 [!_GLIBCXX_HAVE_NETINET_TCP_H] (tcp::no_delay): Do not define.
1235 * include/experimental/io_context: Likewise.
1236 * include/experimental/socket: Likewise.
1237 [!_GLIBCXX_HAVE_SYS_SOCKET_H, !_GLIBCXX_HAVE_POLL_H] (socket_base): Do
1238 not define nested types when relevant header not available.
1239 (__socket_impl::native_non_blocking) [!_GLIBCXX_HAVE_FCNTL_H]: Report
1240 an error.
1241 (__basic_socket_impl::open, __basic_socket_impl::local_endpoint)
1242 (__basic_socket_impl::bind) [!_GLIBCXX_HAVE_SYS_SOCKET_H]: Likewise.
1243 (__basic_socket_impl::io_control) [!_GLIBCXX_HAVE_SYS_IOCTL_H]:
1244 Likewise.
1245 (basic_socket::at_mark, basic_socket::shutdown)
1246 (basic_socket::remote_endpoint, basic_socket::connect)
1247 (basic_socket::async_connect) [!_GLIBCXX_HAVE_SYS_SOCKET_H]: Likewise.
1248 (basic_socket::available) [_GLIBCXX_HAVE_SYS_IOCTL_H]: Check macro
1249 for <sys/ioctl.h> availability.
1250 (basic_socket::wait) [!_GLIBCXX_HAVE_POLL_H]: Likewise.
1251 (basic_datagram_socket::receive, basic_datagram_socket::async_receive)
1252 (basic_datagram_socket::receive_from)
1253 (basic_datagram_socket::async_receive_from)
1254 (basic_datagram_socket::send, basic_datagram_socket::async_send)
1255 (basic_datagram_socket::send_to, basic_datagram_socket::async_send_to)
1256 [!_GLIBCXX_HAVE_SYS_SOCKET_H]: Likewise.
1257 (basic_stream_socket::receive, basic_stream_socket::async_receive)
1258 (basic_stream_socket::send, basic_stream_socket::async_send)
1259 [!_GLIBCXX_HAVE_SYS_SOCKET_H]: Likewise.
1260 (basic_socket_acceptor::listen, basic_socket_acceptor::accept)
1261 (basic_socket_acceptor::async_accept) [!_GLIBCXX_HAVE_SYS_SOCKET_H]:
1262 Likewise.
1263 (basic_socket_acceptor::wait) [!_GLIBCXX_HAVE_POLL_H]: Likewise.
1264
1265 * testsuite/experimental/net/headers.cc: Remove dg-options.
1266 * testsuite/experimental/net/buffer/arithmetic.cc: Replace dg-options
1267 with dg-do using effective target.
1268 * testsuite/experimental/net/buffer/const.cc: Likewise.
1269 * testsuite/experimental/net/buffer/creation.cc: Likewise.
1270 * testsuite/experimental/net/buffer/mutable.cc: Likewise.
1271 * testsuite/experimental/net/buffer/size.cc: Likewise.
1272 * testsuite/experimental/net/buffer/traits.cc: Likewise.
1273 * testsuite/experimental/net/execution_context/use_service.cc:
1274 Likewise.
1275 * testsuite/experimental/net/internet/address/v4/comparisons.cc:
1276 Likewise.
1277 * testsuite/experimental/net/internet/address/v4/cons.cc: Likewise.
1278 * testsuite/experimental/net/internet/address/v4/creation.cc:
1279 Likewise.
1280 * testsuite/experimental/net/internet/address/v4/members.cc: Likewise.
1281 * testsuite/experimental/net/internet/resolver/base.cc: Likewise.
1282 * testsuite/experimental/net/internet/resolver/ops/lookup.cc:
1283 Likewise.
1284 * testsuite/experimental/net/internet/resolver/ops/reverse.cc:
1285 Likewise.
1286 * testsuite/experimental/net/timer/waitable/cons.cc: Likewise.
1287 * testsuite/experimental/net/timer/waitable/dest.cc: Likewise.
1288 * testsuite/experimental/net/timer/waitable/ops.cc: Likewise.
1289
1290 * include/experimental/socket (basic_socket::at_mark): Add missing
1291 return.
1292
1293 * acinclude.m4 (GLIBCXX_CHECK_RANDOM_TR1): Replace with ...
1294 (GLIBCXX_CHECK_DEV_RANDOM): New macro with more descriptive name.
1295 Define _GLIBCXX_USE_DEV_RANDOM as well as _GLIBCXX_USE_RANDOM_TR1.
1296 * config.h.in: Regenerate.
1297 * configure: Regenerate.
1298 * configure.ac: Use GLIBCXX_CHECK_DEV_RANDOM instead of
1299 GLIBCXX_CHECK_RANDOM_TR1.
1300 crossconfig.m4: Likewise.
1301 * include/bits/random.h (random_device): Use _GLIBCXX_USE_DEV_RANDOM
1302 instead of _GLIBCXX_USE_RANDOM_TR1.
1303 * testsuite/26_numerics/random/random_device/cons/token.cc: Likewise.
1304
1305 2018-10-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1306
1307 * testsuite/lib/dg-options.exp (add_options_for_net_ts): New proc.
1308 * testsuite/experimental/net/internet/address/v4/comparisons.cc:
1309 Add dg-add-options net_ts.
1310 * testsuite/experimental/net/internet/address/v4/cons.cc: Likewise.
1311 * testsuite/experimental/net/internet/address/v4/creation.cc: Likewise.
1312 * testsuite/experimental/net/internet/address/v4/members.cc: Likewise.
1313 * testsuite/experimental/net/internet/resolver/base.cc: Likewise.
1314 * testsuite/experimental/net/internet/resolver/ops/lookup.cc: Likewise.
1315 * testsuite/experimental/net/internet/resolver/ops/reverse.cc: Likewise.
1316
1317 2018-10-16 Jonathan Wakely <jwakely@redhat.com>
1318
1319 * testsuite/20_util/duration/literals/range_neg.cc: Adjust pruned
1320 diagnostic to account for quotes around 'constexpr'.
1321 * testsuite/23_containers/deque/capacity/max_size.cc: Define static
1322 variable.
1323 * testsuite/23_containers/vector/capacity/max_size.cc: Likewise.
1324
1325 PR libstdc++/87618
1326 * config/abi/pre/gnu.ver: Fix typos in patterns for basic_stringbuf.
1327 * testsuite/27_io/basic_stringbuf/cons/char/default.cc: Disable
1328 optimisation to check constructor definition can be linked to.
1329 * testsuite/27_io/basic_stringbuf/cons/wchar_t/default.cc: Likewise.
1330
1331 2018-10-15 Jonathan Wakely <jwakely@redhat.com>
1332
1333 * testsuite/22_locale/numpunct/members/char/3.cc: Adjust test to
1334 account for change to glibc it_IT localedata (glibc bz#10797).
1335
1336 PR libstdc++/87587
1337 * src/c++11/cxx11-shim_facets.cc: Suppress -Wabi warnings.
1338
1339 2018-10-15 François Dumont <fdumont@gcc.gnu.org>
1340
1341 * include/debug/vector (vector<>::cbegin()): Use C++11 direct
1342 initialization.
1343 (vector<>::cend()): Likewise.
1344 (vector<>::emplace(const_iterator, _Args&&...)): Likewise and use
1345 consistent iterator comparison.
1346 (vector<>::insert(const_iterator, size_type, const _Tp&)): Likewise.
1347 (vector<>::insert(const_iterator, _InputIterator, _InputIterator)):
1348 Likewise.
1349 (vector<>::erase(const_iterator)): Likewise.
1350 (vector<>::erase(const_iterator, const_iterator)): Likewise.
1351
1352 2018-10-12 Jonathan Wakely <jwakely@redhat.com>
1353
1354 Initial commit of Networking TS implementation.
1355 * include/Makefile.am: Add new headers.
1356 * include/Makefile.in: Regenerate.
1357 * include/experimental/bits/net.h: New header for common
1358 implementation details of Networking TS.
1359 * include/experimental/buffer: New header.
1360 * include/experimental/executor: New header.
1361 * include/experimental/internet: New header.
1362 * include/experimental/io_context: New header.
1363 * include/experimental/net: New header.
1364 * include/experimental/netfwd: New header.
1365 * include/experimental/socket: New header.
1366 * include/experimental/timer: New header.
1367 * testsuite/experimental/net/buffer/arithmetic.cc: New test.
1368 * testsuite/experimental/net/buffer/const.cc: New test.
1369 * testsuite/experimental/net/buffer/creation.cc: New test.
1370 * testsuite/experimental/net/buffer/mutable.cc: New test.
1371 * testsuite/experimental/net/buffer/size.cc: New test.
1372 * testsuite/experimental/net/buffer/traits.cc: New test.
1373 * testsuite/experimental/net/execution_context/use_service.cc: New
1374 test.
1375 * testsuite/experimental/net/headers.cc: New test.
1376 * testsuite/experimental/net/internet/address/v4/comparisons.cc: New
1377 test.
1378 * testsuite/experimental/net/internet/address/v4/cons.cc: New test.
1379 * testsuite/experimental/net/internet/address/v4/creation.cc: New
1380 test.
1381 * testsuite/experimental/net/internet/address/v4/members.cc: New
1382 test.
1383 * testsuite/experimental/net/internet/resolver/base.cc: New test.
1384 * testsuite/experimental/net/internet/resolver/ops/lookup.cc: New
1385 test.
1386 * testsuite/experimental/net/internet/resolver/ops/reverse.cc: New
1387 test.
1388 * testsuite/experimental/net/timer/waitable/cons.cc: New test.
1389 * testsuite/experimental/net/timer/waitable/dest.cc: New test.
1390 * testsuite/experimental/net/timer/waitable/ops.cc: New test.
1391
1392 PR libstdc++/77691
1393 * include/experimental/memory_resource (__resource_adaptor_imp): Do
1394 not allocate sizes smaller than alignment when relying on guaranteed
1395 alignment.
1396 * testsuite/experimental/memory_resource/new_delete_resource.cc:
1397 Adjust expected number of bytes allocated for alignof(max_align_t).
1398
1399 2018-10-11 François Dumont <fdumont@gcc.gnu.org>
1400
1401 * include/debug/forward_list
1402 (forward_list<>::before_begin()): Use C++11 direct initialization.
1403 (forward_list<>::begin()): Likewise.
1404 (forward_list<>::end()): Likewise.
1405 (forward_list<>::cbefore_begin()): Likewise.
1406 (forward_list<>::cbegin()): Likewise.
1407 (forward_list<>::cend()): Likewise.
1408 (forward_list<>::emplace_after<>(const_iterator, _Args&&...)): Likewise.
1409 (forward_list<>::insert_after(const_iterator, const _Tp&)): Likewise.
1410 (forward_list<>::insert_after(const_iterator, _Tp&&)): Likewise.
1411 (forward_list<>::insert_after(const_iterator, size_type, const _Tp&)):
1412 Likewise.
1413 (forward_list<>::insert_after(const_iterator, initializer_list<>)):
1414 Likewise.
1415 (forward_list<>::erase_after(const_iterator)): Likewise.
1416 (forward_list<>::erase_after(const_iterator, const_iterator)): Likewise
1417 and ensure consistent iterator comparison.
1418
1419 * include/bits/forward_list.h
1420 (_Fwd_list_iterator<>::operator==): Replace member function with inline
1421 friend.
1422 (_Fwd_list_iterator<>::operator!=): Likewise.
1423 (_Fwd_list_const_iterator<>::operator==): Likewise.
1424 (_Fwd_list_const_iterator<>::operator!=): Likewise.
1425 (operator==(const _Fwd_list_iterator<>&,
1426 const _Fwd_list_const_iterator<>&)): Remove.
1427 (operator!=(const _Fwd_list_iterator<>&,
1428 const _Fwd_list_const_iterator<>&)): Remove.
1429 (forward_list<>::_Node): Take typedef from base type.
1430 (forward_list<>::iterator): Likewise.
1431 (forward_list<>::const_iterator): Likewise.
1432
1433 2018-10-11 Jonathan Wakely <jwakely@redhat.com>
1434
1435 PR libstdc++/80538
1436 * src/c++11/thread.cc (this_thread::__sleep_for)
1437 [_GLIBCXX_HAVE_SLEEP]: Only call sleep for non-zero values.
1438 Loop while sleep call is interrupted and until steady_clock
1439 shows requested duration has elapsed.
1440 (!_GLIBCXX_HAVE_USLEEP]: Use the _GLIBCXX_HAVE_SLEEP code path, but
1441 avoiding the usleep call.
1442 * testsuite/30_threads/this_thread/60421.cc: Test repeated
1443 signal interruptions.
1444
1445 * include/bits/allocator.h
1446 (operator==(const allocator<_Tp>&, const allocator<_Tp>))
1447 (operator!=(const allocator<_Tp>&, const allocator<_Tp>)): Replace
1448 with inline friends.
1449 * include/ext/debug_allocator.h (operator==, operator!=): Replace
1450 with inline friend functions that compare to rebound allocators.
1451 * include/ext/malloc_allocator.h (operator==, operator!=): Likewise.
1452 * include/ext/new_allocator.h (operator==, operator!=): Likewise.
1453 * testsuite/ext/debug_allocator/eq.cc: New test.
1454 * testsuite/ext/ext_pointer/alloc_eq.cc: New test.
1455 * testsuite/ext/malloc_allocator/eq.cc: New test.
1456 * testsuite/ext/new_allocator/eq.cc: New test.
1457
1458 2018-10-10 Jonathan Wakely <jwakely@redhat.com>
1459
1460 PR libstdc++/87544
1461 * include/bits/stl_vector.h (vector::_S_max_size): Limit size to
1462 PTRDIFF_MAX / sizeof(value_type).
1463 * include/ext/malloc_allocator.h (malloc_allocator::max_size):
1464 Likewise.
1465 * include/ext/new_allocator.h (new_allocator::max_size): Likewise.
1466 * testsuite/23_containers/vector/allocator/minimal.cc: Adjust
1467 expected value for max_size().
1468 * testsuite/23_containers/vector/capacity/87544.cc: New test.
1469
1470 2018-10-09 François Dumont <fdumont@gcc.gnu.org>
1471
1472 * include/bits/stl_list.h
1473 (_List_operator<>::operator==): Replace member function with inline
1474 friend.
1475 (_List_operator<>::operator!=): Likewise.
1476 (_List_const_operator<>::operator==): Likewise.
1477 (_List_const_operator<>::operator!=): Likewise.
1478 (operator==(const _List_iterator<>&, const _List_const_iterator<>&)):
1479 Remove.
1480 (operator!=(const _List_iterator<>&, const _List_const_iterator<>&)):
1481 Remove.
1482
1483 2018-10-09 Jonathan Wakely <jwakely@redhat.com>
1484
1485 * include/bits/stringfwd.h (string, wstring, u16string, u32string):
1486 Define typedefs outside of __cxx11 inline namespace.
1487 * python/libstdcxx/v6/printers.py (register_type_printers): Also
1488 register printers for typedefs in new location.
1489
1490 2018-10-08 Jonathan Wakely <jwakely@redhat.com>
1491
1492 PR libstdc++/87538
1493 * testsuite/experimental/functional/87538.cc: New test.
1494
1495 PR libstdc++/87538
1496 * include/std/functional (_Not_fn::operator()): Check value of
1497 __is_nothrow_invocable as well.
1498 * testsuite/20_util/function_objects/not_fn/87538.cc: New test.
1499
1500 2018-10-08 François Dumont <fdumont@gcc.gnu.org>
1501
1502 * include/debug/list (list<>::cbegin()): Use C++11 direct
1503 initialization.
1504 (list<>::cend()): Likewise.
1505 (list<>::emplace<>(const_iterator, _Args&&...)): Likewise.
1506 (list<>::insert(const_iterator, initializer_list<>)): Likewise.
1507 (list<>::insert(const_iterator, size_type, const _Tp&)): Likewise.
1508 (list<>::erase(const_iterator, const_iterator)): Ensure consistent
1509 iterator comparisons.
1510 (list<>::splice(const_iterator, list&&, const_iterator,
1511 const_iterator)): Likewise.
1512
1513 2018-10-05 François Dumont <fdumont@gcc.gnu.org>
1514
1515 * include/bits/stl_tree.h
1516 (_Rb_tree_iterator<>::operator==): Make inline friend.
1517 (_Rb_tree_iterator<>::operator!=): Likewise.
1518 (_Rb_tree_const_iterator<>::operator==): Likewise.
1519 (_Rb_tree_const_iterator<>::operator!=): Likewise.
1520 (operator==(const _Rb_tree_iterator<>&,
1521 const _Rb_tree_const_iterator&)): Remove.
1522 (operator!=(const _Rb_tree_iterator<>&,
1523 const _Rb_tree_const_iterator&)): Remove.
1524 (operator==(const _Rb_tree<>&, const _Rb_tree<>&)): Make inline friend.
1525 (operator<(const _Rb_tree<>&, const _Rb_tree<>&)): Likewise.
1526 (operator!=(const _Rb_tree<>&, const _Rb_tree<>&)): Likewise and
1527 deprecate.
1528 (operator>(const _Rb_tree<>&, const _Rb_tree<>&)): Likewise.
1529 (operator<=(const _Rb_tree<>&, const _Rb_tree<>&)): Likewise.
1530 (operator>=(const _Rb_tree<>&, const _Rb_tree<>&)): Likewise.
1531 * include/debug/map.h (map<>::erase(const_iterator, const_iterator)):
1532 Compare __victim with _Base::cend().
1533 * include/debug/multimap.h
1534 (multimap<>::erase(const_iterator, const_iterator)): Likewise.
1535 * include/debug/set.h (set<>::erase(const_iterator, const_iterator)):
1536 Compare __victim with _Base::cend().
1537 * include/debug/multiset.h
1538 (multiset<>::erase(const_iterator, const_iterator)): Likewise.
1539
1540 2018-10-03 Jonathan Wakely <jwakely@redhat.com>
1541
1542 PR libstdc++/59439
1543 * src/c++98/locale.cc (locale::locale(const locale&)): Bypass
1544 reference count updates for the classic locale.
1545 (locale::~locale()): Likewise.
1546 (locale::operator=(const locale&)): Likewise.
1547 * src/c++98/locale_init.cc (locale::locale()): Likewise.
1548 (locale::global(const locale&)): Likewise.
1549
1550 2018-10-03 François Dumont <fdumont@gcc.gnu.org>
1551
1552 * include/debug/map.h
1553 (map<>::emplace<>(_Args&&...)): Use C++11 direct initialization.
1554 (map<>::emplace_hint<>(const_iterator, _Args&&...)): Likewise.
1555 (map<>::insert(value_type&&)): Likewise.
1556 (map<>::insert<>(_Pair&&)): Likewise.
1557 (map<>::insert<>(const_iterator, _Pair&&)): Likewise.
1558 (map<>::try_emplace): Likewise.
1559 (map<>::insert_or_assign): Likewise.
1560 (map<>::insert(node_type&&)): Likewise.
1561 (map<>::insert(const_iterator, node_type&&)): Likewise.
1562 (map<>::erase(const_iterator)): Likewise.
1563 (map<>::erase(const_iterator, const_iterator)): Likewise.
1564 * include/debug/multimap.h
1565 (multimap<>::emplace<>(_Args&&...)): Use C++11 direct initialization.
1566 (multimap<>::emplace_hint<>(const_iterator, _Args&&...)): Likewise.
1567 (multimap<>::insert<>(_Pair&&)): Likewise.
1568 (multimap<>::insert<>(const_iterator, _Pair&&)): Likewise.
1569 (multimap<>::insert(node_type&&)): Likewise.
1570 (multimap<>::insert(const_iterator, node_type&&)): Likewise.
1571 (multimap<>::erase(const_iterator)): Likewise.
1572 (multimap<>::erase(const_iterator, const_iterator)): Likewise.
1573 * include/debug/set.h
1574 (set<>::emplace<>(_Args&&...)): Use C++11 direct initialization.
1575 (set<>::emplace_hint<>(const_iterator, _Args&&...)): Likewise.
1576 (set<>::insert(value_type&&)): Likewise.
1577 (set<>::insert<>(const_iterator, value_type&&)): Likewise.
1578 (set<>::insert(const_iterator, node_type&&)): Likewise.
1579 (set<>::erase(const_iterator)): Likewise.
1580 (set<>::erase(const_iterator, const_iterator)): Likewise.
1581 * include/debug/multiset.h
1582 (multiset<>::emplace<>(_Args&&...)): Use C++11 direct initialization.
1583 (multiset<>::emplace_hint<>(const_iterator, _Args&&...)): Likewise.
1584 (multiset<>::insert<>(value_type&&)): Likewise.
1585 (multiset<>::insert<>(const_iterator, value_type&&)): Likewise.
1586 (multiset<>::insert(node_type&&)): Likewise.
1587 (multiset<>::insert(const_iterator, node_type&&)): Likewise.
1588 (multiset<>::erase(const_iterator)): Likewise.
1589 (multiset<>::erase(const_iterator, const_iterator)): Likewise.
1590
1591 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
1592
1593 PR libstdc++/87258
1594 * include/bits/stl_bvector.h (vector::begin(), vector::cbegin()):
1595 Rebuild _M_start with an explicit 0 offset.
1596
1597 2018-10-02 Jonathan Wakely <jwakely@redhat.com>
1598
1599 * include/std/variant (__gen_vtable_impl::__visit_invoke): Call __get
1600 directly instead of get, as caller ensures correct index is used.
1601 (holds_alternative, get, get_if): Remove redundant inline specifiers.
1602 (_VARIANT_RELATION_FUNCTION_TEMPLATE): Likewise.
1603
1604 2018-10-02 Joseph Myers <joseph@codesourcery.com>
1605
1606 * testsuite/lib/libstdc++.exp (libstdc++_init): Use
1607 -fno-show-column in default cxxflags.
1608
1609 2018-10-01 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
1610
1611 * config/os/uclibc/os_defines.h (__NO_STRING_INLINES): Delete.
1612
1613 2018-10-01 Gerald Pfeifer <gerald@pfeifer.com>
1614
1615 * doc/xml/manual/allocator.xml: Adjust link to "Reconsidering
1616 Custom Memory Allocation".
1617
1618 2018-10-01 Jonathan Wakely <jwakely@redhat.com>
1619
1620 * doc/html/*: Regenerate.
1621
1622 2018-09-30 Gerald Pfeifer <gerald@pfeifer.com>
1623
1624 * doc/xml/manual/messages.xml: Switch link to www.oracle.com
1625 to https.
1626
1627 2018-09-30 Gerald Pfeifer <gerald@pfeifer.com>
1628
1629 * doc/xml/manual/policy_data_structures_biblio.xml: Update
1630 link to Microsoft Component Model Object Technologies.
1631
1632 2018-09-29 Gerald Pfeifer <gerald@pfeifer.com>
1633
1634 * doc/xml/gnu/fdl-1.3.xml: The Free Software Foundation web
1635 site now uses https. Also omit the unnecessary trailing slash.
1636 * doc/xml/gnu/gpl-3.0.xml: Ditto.
1637
1638 2018-09-28 François Dumont <fdumont@gcc.gnu.org>
1639
1640 * include/debug/functions.h
1641 (__foreign_iterator_aux3(const _Safe_iterator<>&, const _InputeIter&,
1642 const _InputIter&, __true_type)): Use empty() rather than begin() ==
1643 end().
1644
1645 2018-09-25 Mike Crowe <mac@mcrowe.com>
1646
1647 * include/std/condition_variable (condition_variable::wait_for): Use
1648 steady clock in overload that uses a predicate.
1649
1650 2018-09-25 Jonathan Wakely <jwakely@redhat.com>
1651
1652 PR libstdc++/87431
1653 * include/std/variant (_Variant_storage<true, _Types...>::_M_valid):
1654 Avoid runtime test when all alternatives are scalars and so cannot
1655 throw during initialization.
1656
1657 2018-09-25 Gerald Pfeifer <gerald@pfeifer.com>
1658
1659 * doc/xml/manual/codecvt.xml: Move link to "UTF-8 and Unicode FAQ"
1660 to https.
1661
1662 2018-09-24 Gerald Pfeifer <gerald@pfeifer.com>
1663
1664 * doc/xml/manual/policy_data_structures_biblio.xml: Update link
1665 to "Priority Queues and the STL".
1666
1667 2018-09-23 Gerald Pfeifer <gerald@pfeifer.com>
1668
1669 * doc/xml/manual/using_exceptions.xml: Move boost.orgs link to
1670 https.
1671
1672 2018-09-21 François Dumont <fdumont@gcc.gnu.org>
1673
1674 PR libstdc++/87135
1675 * src/c++11/hashtable_c++0x.cc (_Prime_rehash_policy::_M_next_bkt):
1676 Use __builtin_floor to compute _M_next_resize.
1677 * testsuite/23_containers/unordered_set/hash_policy/71181.cc: Adapt.
1678 * testsuite/23_containers/unordered_set/hash_policy/prime_rehash.cc:
1679 Adapt.
1680
1681 2018-09-21 Jonathan Wakely <jwakely@redhat.com>
1682
1683 * testsuite/26_numerics/headers/cmath/hypot-long-double.cc: Remove.
1684 * testsuite/26_numerics/headers/cmath/hypot.cc: Restore test for
1685 long double unconditionally, but use lower tolerance when
1686 sizeof(long double) == sizeof(double).
1687
1688 2018-09-20 Christophe Lyon <christophe.lyon@linaro.org>
1689
1690 * testsuite/26_numerics/headers/cmath/hypot-long-double.cc: Skip
1691 on arm*.
1692
1693 2018-09-19 Jonathan Wakely <jwakely@redhat.com>
1694
1695 * include/bits/regex_automaton.tcc (_StateSeq<_TraitsT>::_M_clone()):
1696 Remove __glibcxx_assert statements and use map::find instead of
1697 map::operator[].
1698
1699 2018-09-18 François Dumont <fdumont@gcc.gnu.org>
1700
1701 PR libstdc++/87135
1702 * src/c++11/hashtable_c++0x.cc:
1703 (_Prime_rehash_policy::_M_next_bkt): Return a prime no smaller than
1704 requested size, but not necessarily greater.
1705 (_Prime_rehash_policy::_M_need_rehash): Rehash only if target size is
1706 strictly greater than next resize threshold.
1707 * testsuite/23_containers/unordered_map/modifiers/reserve.cc: Adapt test
1708 to validate that there is no rehash as long as number of insertion is
1709 lower or equal to the reserved number of elements.
1710
1711 2018-09-18 Jonathan Wakely <jwakely@redhat.com>
1712
1713 * include/bits/unique_ptr.h (__uniq_ptr_impl): Remove static assertion
1714 checking invocable condition.
1715 (unique_ptr::~unique_ptr, unique_ptr::reset): Restore static assertion
1716 here, where types must be complete. Pass pointer to deleter as an
1717 rvalue.
1718 * testsuite/20_util/unique_ptr/requirements/incomplete.cc: New test.
1719
1720 2018-09-13 Jonathan Wakely <jwakely@redhat.com>
1721
1722 * include/std/variant (variant) [__clang__]: Limit workaround to
1723 Clang 7 and older.
1724
1725 2018-09-11 Jonathan Wakely <jwakely@redhat.com>
1726
1727 PR libstdc++/87278
1728 * include/bits/shared_ptr.h (make_shared): Use remove_cv instead of
1729 remove_const.
1730 * testsuite/20_util/shared_ptr/creation/87278.cc: New test.
1731
1732 Implement LWG 2905 changes to constrain unique_ptr constructors
1733 * include/bits/unique_ptr.h (__uniq_ptr_impl): Add assertions to
1734 check deleter type.
1735 (unique_ptr::unique_ptr(pointer, const deleter_type&)): Add copy
1736 constructible constraint.
1737 (unique_ptr::unique_ptr(pointer, deleter_type&&)): Disable for
1738 deleters of reference type and add move constructible constraint.
1739 (unique_ptr::unique_ptr(pointer, remove_reference_t<deleter_type>&&)):
1740 Disable for deleters of non-reference type. Define as deleted.
1741 (unique_ptr<T[], D>): Likewise.
1742 * testsuite/20_util/unique_ptr/assign/48635_neg.cc: Replace dg-error
1743 directives with unstable line numbers with dg-prune-output.
1744 * testsuite/20_util/unique_ptr/cons/cv_qual_neg.cc: Likewise.
1745 * testsuite/20_util/unique_ptr/cons/lwg2905.cc: New test.
1746 * testsuite/20_util/unique_ptr/specialized_algorithms/swap_cxx17.cc:
1747 Make deleter types invocable.
1748
1749 2018-09-05 Jonathan Wakely <jwakely@redhat.com>
1750
1751 * libsupc++/cxxabi.h (__cxa_demangle): Clarify doxygen comment.
1752
1753 2018-09-03 Jonathan Wakely <jwakely@redhat.com>
1754
1755 PR libstdc++/78179
1756 * testsuite/26_numerics/headers/cmath/hypot-long-double.cc: New test
1757 that runs the long double part of hypot.cc.
1758 * testsuite/26_numerics/headers/cmath/hypot.cc: Disable long double
1759 tests unless TEST_HYPOT_LONG_DOUBLE is defined.
1760
1761 * include/bits/stl_vector.h (vector::_Temporary_value::_M_ptr):
1762 Return raw pointer not allocator's pointer type.
1763 (vector::_Temporary_value::_M_val): Use _M_ptr.
1764
1765 PR libstdc++/87194
1766 * include/bits/stl_map.h
1767 (map::map(initializer_list<value_type>, const Compare&, const Alloc&))
1768 (map::map(initializer_list<value_type>, const Alloc&))
1769 (map::map(InputIterator, InputIterator, const Alloc&))
1770 (map::map(InputIterator, InputIterator))
1771 (map::map(InputIterator, InputIterator, const Compare&, const Alloc&))
1772 (map::insert(InputIterator, InputIterator)):
1773 Call _M_insert_range_unique instead of _M_insert_unique.
1774 * include/bits/stl_multimap.h
1775 (multimap::multimap(initializer_list<value_type>, const C&, const A&))
1776 (multimap::multimap(initializer_list<value_type>, const A&))
1777 (multimap::multimap(InputIterator, InputIterator, const A&))
1778 (multimap::multimap(InputIterator, InputIterator))
1779 (multimap::multimap(InputIterator, InputIterator, const C&, const A&))
1780 (multimap::insert(InputIterator, InputIterator)): Call
1781 _M_insert_range_equal instead of _M_insert_equal.
1782 * include/bits/stl_multiset.h
1783 (multiset::multiset(InputIterator, InputIterator))
1784 (multiset::multiset(InputIterator, InputIterator, const C&, const A&))
1785 (multiset::multiset(initializer_list<value_type>, const C&, const A&))
1786 (multiset::multiset(initializer_list<value_type>, const A&))
1787 (multiset::multiset(InputIterator, InputIterator, const A&))
1788 (multiset::insert(InputIterator, InputIterator)): Call
1789 _M_insert_range_equal instead of _M_insert_equal.
1790 * include/bits/stl_set.h
1791 (set::set(InputIterator, InputIterator))
1792 (set::set(InputIterator, InputIterator, const Compare&, const Alloc&))
1793 (set::set(initializer_list<value_type>, const Compare&, const Alloc&))
1794 (set::set(initializer_list<value_type>, const Alloc&))
1795 (set::set(InputIterator, InputIterator, const Alloc&))
1796 (set::insert(InputIterator, InputIterator)):
1797 Call _M_insert_range_unique instead of _M_insert_unique.
1798 * include/bits/stl_tree.h
1799 [__cplusplus >= 201103L] (_Rb_tree::__same_value_type): New alias
1800 template for SFINAE constraints.
1801 [__cplusplus >= 201103L] (_Rb_tree::_M_insert_range_unique): Pair of
1802 constrained overloads that either insert or emplace, depending on
1803 iterator's value_type.
1804 [__cplusplus >= 201103L] (_Rb_tree::_M_insert_range_equal): Likewise.
1805 [__cplusplus < 201103L] (_Rb_tree::_M_insert_range_unique)
1806 (_Rb_tree::_M_insert_range_equal): New functions replacing range
1807 versions of _M_insert_unique and _M_insert_equal.
1808 (_Rb_tree::_M_insert_unique(_InputIterator, _InputIterator))
1809 (_Rb_tree::_M_insert_equal(_InputIterator, _InputIterator)): Remove.
1810 * testsuite/23_containers/map/modifiers/insert/87194.cc: New test.
1811 * testsuite/23_containers/multimap/modifiers/insert/87194.cc: New test.
1812 * testsuite/23_containers/multiset/modifiers/insert/87194.cc: New test.
1813 * testsuite/23_containers/set/modifiers/insert/87194.cc: New test.
1814
1815 PR libstdc++/78595
1816 * include/bits/stl_map.h (map::insert(_Pair&&))
1817 (map::insert(const_iterator, _Pair&&)): Do emplace instead of insert.
1818 * include/bits/stl_multimap.h (multimap::insert(_Pair&&))
1819 (multimap::insert(const_iterator, _Pair&&)): Likewise.
1820 * include/bits/unordered_map.h (unordered_map::insert(_Pair&&))
1821 (unordered_map::insert(const_iterator, _Pair&&))
1822 (unordered_multimap::insert(_Pair&&))
1823 (unordered_multimap::insert(const_iterator, _Pair&&)): Likewise.
1824 * testsuite/23_containers/map/modifiers/insert/78595.cc: New test.
1825 * testsuite/23_containers/multimap/modifiers/insert/78595.cc: New test.
1826 * testsuite/23_containers/unordered_map/modifiers/78595.cc: New test.
1827 * testsuite/23_containers/unordered_multimap/modifiers/78595.cc: New
1828 test.
1829
1830 2018-09-02 François Dumont <fdumont@gcc.gnu.org>
1831
1832 * include/debug/safe_iterator.h
1833 (_Safe_iterator<_It, _Seq, _Cat>::_Self): New.
1834 (_Safe_iterator<_It, _Seq, std::random_access_iterator_tag>::_Self):
1835 New.
1836 (_Safe_iterator<_It, _Seq, std::random_access_iterator_tag>
1837 ::_OtherSelf): New.
1838 (_GLIBCXX_DEBUG_VERIFY_OPERANDS, _GLIBCXX_DEBUG_VERIFY_EQ_OPERANDS)
1839 (_GLIBCXX_DEBUG_VERIFY_REL_OPERANDS)
1840 (_GLIBCXX_DEBUG_VERIFY_DIST_OPERANDS): Define macros.
1841 (_Safe_iterator<_It, _Seq, std::random_access_iterator_tag>
1842 ::operator+(difference_type)): Use latters, inline as friend.
1843 (_Safe_iterator<_It, _Seq, std::random_access_iterator_tag>
1844 ::operator-(difference_type)): Likewise.
1845 (operator==(const _Safe_iterator<>&, const _Safe_iterator<>&)):
1846 Likewise.
1847 (operator!=(const _Safe_iterator<>&, const _Safe_iterator<>&)):
1848 Likewise.
1849 (operator<(const _Safe_iterator<>&, const _Safe_iterator<>&)): Likewise.
1850 (operator<=(const _Safe_iterator<>&, const _Safe_iterator<>&)):
1851 Likewise.
1852 (operator>(const _Safe_iterator<>&, const _Safe_iterator<>&)): Likewise.
1853 (operator>=(const _Safe_iterator<>&, const _Safe_iterator<>&)):
1854 Likewise.
1855 (operator-(const _Safe_iterator<>&, const _Safe_iterator<>&)): Likewise.
1856 (operator+(difference_type, const _Safe_iterator<>&)): Likewise.
1857 (operator-(const _Safe_iterator<>&, difference_type)): Likewise.
1858 * include/debug/safe_iterator.tcc
1859 (_Safe_iterator<>::_M_can_advance(difference_type)): Take parameter by
1860 copy.
1861 * include/debug/safe_local_iterator.h
1862 (_Safe_local_iterator<_It, _Seq>::_Self): New.
1863 (_Safe_local_iterator<_It, _Seq>::_OtherSelf): New.
1864 (_GLIBCXX_DEBUG_VERIFY_OPERANDS): Define macro.
1865 (operator==(const _Safe_local_iterator<>&,
1866 const _Safe_local_iterator<>&)): Use latter, inline as friend.
1867 (operator!=(const _Safe_local_iterator<>&,
1868 const _Safe_local_iterator<>&)): Likewise.
1869 * testsuite/util/testsuite_containers.h: Include utility.
1870 (struct forward_members_unordered<_Tp, bool>): Remove 2nd template
1871 parameter.
1872 (forward_members_unordered<>::forward_members_unordered(value_type&)):
1873 Add using namespace std::rel_ops.
1874 Add iterator_concept_checks on local_iterator and const_local_iterator.
1875 Add asserts on comparison between const_local_iterator and
1876 local_iterator.
1877 (struct forward_members_unordered<_Tp, false>): Remove partial
1878 specialization.
1879 * testsuite/23_containers/forward_list/types/1.cc: New.
1880 * testsuite/23_containers/list/types/1.cc: New.
1881
1882 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
1883
1884 * doc/xml/manual/profile_mode.xml: Update three ieeexplore.ieee.org
1885 references.
1886
1887 2018-08-31 Sandra Loosemore <sandra@codesourcery.com>
1888
1889 * testsuite/21_strings/basic_string/inserters_extractors/wchar_t/10.cc:
1890 Add dg-require-fileio.
1891 * testsuite/21_strings/basic_string/inserters_extractors/wchar_t/11.cc:
1892 Likewise.
1893 * testsuite/21_strings/basic_string/inserters_extractors/wchar_t/5.cc:
1894 Likewise.
1895 * testsuite/21_strings/basic_string_view/inserters/wchar_t/2.cc:
1896 Likewise.
1897 * testsuite/25_algorithms/copy/streambuf_iterators/wchar_t/4.cc:
1898 Likewise.
1899 * testsuite/25_algorithms/find/istreambuf_iterators/wchar_t/2.cc:
1900 Likewise.
1901 * testsuite/27_io/basic_filebuf/close/wchar_t/12790-1.cc: Likewise.
1902 * testsuite/27_io/basic_filebuf/close/wchar_t/12790-2.cc: Likewise.
1903 * testsuite/27_io/basic_filebuf/close/wchar_t/12790-3.cc: Likewise.
1904 * testsuite/27_io/basic_filebuf/close/wchar_t/12790-4.cc: Likewise.
1905 * testsuite/27_io/basic_filebuf/seekoff/wchar_t/11543.cc: Likewise.
1906 * testsuite/27_io/basic_filebuf/seekoff/wchar_t/12790-1.cc:
1907 Likewise.
1908 * testsuite/27_io/basic_filebuf/seekoff/wchar_t/12790-2.cc:
1909 Likewise.
1910 * testsuite/27_io/basic_filebuf/seekoff/wchar_t/12790-3.cc:
1911 Likewise.
1912 * testsuite/27_io/basic_filebuf/seekoff/wchar_t/12790-4.cc:
1913 Likewise.
1914 * testsuite/27_io/basic_filebuf/seekpos/wchar_t/12790-1.cc:
1915 Likewise.
1916 * testsuite/27_io/basic_filebuf/seekpos/wchar_t/12790-2.cc:
1917 Likewise.
1918 * testsuite/27_io/basic_filebuf/seekpos/wchar_t/12790-4.cc:
1919 Likewise.
1920 * testsuite/27_io/basic_filebuf/underflow/wchar_t/2.cc: Likewise.
1921 * testsuite/27_io/basic_filebuf/underflow/wchar_t/3.cc: Likewise.
1922 * testsuite/27_io/basic_ifstream/cons/wchar_t/1.cc: Likewise.
1923 * testsuite/27_io/basic_ifstream/open/wchar_t/1.cc: Likewise.
1924 * testsuite/27_io/basic_istream/extractors_character/wchar_t/4.cc:
1925 Likewise.
1926 * testsuite/27_io/basic_istream/extractors_other/wchar_t/2.cc:
1927 Likewise.
1928 * testsuite/27_io/basic_istream/get/wchar_t/2.cc: Likewise.
1929 * testsuite/27_io/basic_istream/getline/wchar_t/5.cc: Likewise.
1930 * testsuite/27_io/basic_istream/ignore/wchar_t/2.cc: Likewise.
1931 * testsuite/27_io/basic_istream/ignore/wchar_t/3.cc: Likewise.
1932 * testsuite/27_io/basic_istream/seekg/wchar_t/sstream.cc: Likewise.
1933 * testsuite/27_io/basic_istream/tellg/wchar_t/sstream.cc: Likewise.
1934 * testsuite/27_io/basic_ofstream/cons/wchar_t/1.cc: Likewise.
1935 * testsuite/27_io/basic_ofstream/open/wchar_t/1.cc: Likewise.
1936 * testsuite/27_io/basic_ostream/inserters_other/wchar_t/1.cc:
1937 Likewise.
1938 * testsuite/27_io/objects/wchar_t/10.cc: Likewise.
1939 * testsuite/27_io/objects/wchar_t/12048-1.cc: Likewise.
1940 * testsuite/27_io/objects/wchar_t/12048-2.cc: Likewise.
1941 * testsuite/27_io/objects/wchar_t/12048-3.cc: Likewise.
1942 * testsuite/27_io/objects/wchar_t/12048-4.cc: Likewise.
1943 * testsuite/27_io/objects/wchar_t/12048-5.cc: Likewise.
1944 * testsuite/experimental/string_view/inserters/wchar_t/2.cc:
1945 Likewise.
1946 * testsuite/ext/stdio_sync_filebuf/wchar_t/1.cc: Likewise.
1947
1948 2018-08-30 Sandra Loosemore <sandra@codesourcery.com>
1949
1950 * testsuite/experimental/propagate_const/observers/1.cc: Make
1951 dependence on -fdelete-null-pointer-checks explicit.
1952
1953 2018-08-30 Jonathan Wakely <jwakely@redhat.com>
1954
1955 * include/bits/hashtable_policy.h (__clp2): Fix calculation for LLP64
1956 targets where sizeof(size_t) > sizeof(long). Avoid undefined shifts
1957 of the number of bits in the type.
1958 * include/std/bit (__ceil2): Avoid undefined shifts.
1959 * testsuite/26_numerics/bit/bit.pow.two/ceil2.cc: Test values with
1960 the most signifiant bit set.
1961
1962 * config/abi/pre/gnu.ver: Add missing exports for mingw.
1963
1964 * include/ext/pointer.h (_Pointer_adapter): Define operators for
1965 pointer arithmetic using long long offsets.
1966 * testsuite/ext/ext_pointer/1.cc: Test pointer arithmetic using
1967 long long values.
1968
1969 2018-08-29 Jonathan Wakely <jwakely@redhat.com>
1970
1971 PR libstdc++/31413
1972 * testsuite/22_locale/time_get/get_date/wchar_t/4.cc: Check D_FMT
1973 string for alternative format.
1974
1975 2018-08-28 Jonathan Wakely <jwakely@redhat.com>
1976
1977 PR libstdc++/87116
1978 * src/filesystem/std-path.cc (path::lexically_normal): When handling
1979 a dot-dot filename, preserve an empty final component in the iteration
1980 sequence.
1981 [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Use preferred-separator for
1982 root-directory.
1983 * testsuite/27_io/filesystem/path/generation/normal.cc: Add new tests
1984 for more than two adjacent dot-dot filenames.
1985 [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Replace slashes with
1986 preferred-separator in expected normalized strings.
1987
1988 2018-08-25 Iain Sandoe <iain@sandoe.co.uk>
1989
1990 PR libstdc++/70694
1991 * configure.host (OPT_LDFLAGS): Don't append
1992 -fvisibility-inlines-hidden for newer Darwin.
1993
1994 2018-08-24 Marc Glisse <marc.glisse@inria.fr>
1995
1996 PR libstdc++/86822
1997 * libsupc++/new (operator new(size_t, nothrow_t), operator
1998 new[](size_t, nothrow_t), operator new(size_t, align_val_t, nothrow_t),
1999 operator new[](size_t, align_val_t, nothrow_t)): Add malloc attribute.
2000
2001 2018-08-24 Jonathan Wakely <jwakely@redhat.com>
2002
2003 * include/debug/deque (std::__debug::deque): Declare.
2004 * include/debug/forward_list (std::__debug::forward_list): Declare.
2005 * include/debug/list (std::__debug::list): Declare.
2006 * include/debug/map (std::__debug::map): Declare.
2007 * include/debug/set (std::__debug::set): Declare.
2008 * include/debug/unordered_map (std::__debug::unordered_map): Declare.
2009 * include/debug/unordered_set (std::__debug::unordered_set): Declare.
2010 * include/debug/vector (std::__debug::vector): Declare.
2011 * testsuite/23_containers/deque/types/pmr_typedefs_debug.cc: New test.
2012 * testsuite/23_containers/forward_list/pmr_typedefs_debug.cc: New
2013 test.
2014 * testsuite/23_containers/list/pmr_typedefs_debug.cc: New test.
2015 * testsuite/23_containers/map/pmr_typedefs_debug.cc: New test.
2016 * testsuite/23_containers/multimap/pmr_typedefs_debug.cc: New test.
2017 * testsuite/23_containers/multiset/pmr_typedefs_debug.cc: New test.
2018 * testsuite/23_containers/set/pmr_typedefs_debug.cc: New test.
2019 * testsuite/23_containers/unordered_map/pmr_typedefs_debug.cc: New
2020 test.
2021 * testsuite/23_containers/unordered_multimap/pmr_typedefs_debug.cc:
2022 New test.
2023 * testsuite/23_containers/unordered_multiset/pmr_typedefs_debug.cc:
2024 New test.
2025 * testsuite/23_containers/unordered_set/pmr_typedefs_debug.cc: New
2026 test.
2027 * testsuite/23_containers/vector/cons/destructible_debug_neg.cc:
2028 Adjust dg-error lineno.
2029 * testsuite/23_containers/vector/types/pmr_typedefs_debug.cc: New
2030 test.
2031
2032 2018-08-23 Jonathan Wakely <jwakely@redhat.com>
2033
2034 * testsuite/util/testsuite_allocator.h (__gnu_test::memory_resource):
2035 Only define when RTTI is enabled.
2036
2037 * include/debug/vector (__niter_base): Define for C++98.
2038
2039 * testsuite/25_algorithms/partial_sort_copy/debug/irreflexive_neg.cc:
2040 Fix C++98 test to not use C++11 features.
2041 * testsuite/25_algorithms/fill_n/2.cc: Likewise.
2042
2043 * scripts/check_compile: Fix comments.
2044
2045 * include/debug/string (insert(__const_iterator, _InIter, _InIter)):
2046 [!_GLIBCXX_USE_CXX11_ABI]: Replace use of C++11-only cbegin() with
2047 begin(), for C++98 compatibility.
2048
2049 * include/bits/basic_string.h [_GLIBCXX_USE_CXX11_ABI]
2050 (basic_string::__const_iterator): Change access to protected.
2051 [!_GLIBCXX_USE_CXX11_ABI] (basic_string::__const_iterator): Define
2052 as typedef for iterator.
2053 * include/debug/string (__const_iterator): Use typedef from base.
2054 (insert(const_iterator, _CharT))
2055 (replace(const_iterator, const_iterator, const basic_string&))
2056 (replace(const_iterator, const_iterator, const _CharT*, size_type))
2057 (replace(const_iterator, const_iterator, const CharT*))
2058 (replace(const_iterator, const_iterator, size_type, _CharT))
2059 (replace(const_iterator, const_iterator, _InputIter, _InputIter))
2060 (replace(const_iterator, const_iterator, initializer_list<_CharT>)):
2061 Change const_iterator parameters to __const_iterator.
2062 (insert(iterator, size_type, _CharT)): Add C++98 overload.
2063 (insert(const_iterator, _InputIterator, _InputIterator)): Change
2064 const_iterator parameter to __const_iterator.
2065 [!_GLIBCXX_USE_CXX11_ABI]: Add workaround for incorrect return type
2066 of base's member function.
2067 (insert(const_iterator, size_type, _CharT)) [!_GLIBCXX_USE_CXX11_ABI]:
2068 Likewise.
2069 (insert(const_iterator, initializer_list<_CharT>))
2070 [!_GLIBCXX_USE_CXX11_ABI]: Likewise.
2071 * testsuite/21_strings/basic_string/init-list.cc: Remove effective
2072 target directive.
2073
2074 * testsuite/20_util/reference_wrapper/lwg2993.cc: Fix C++11 test to
2075 not use C++14 feature.
2076 * testsuite/23_containers/list/68222_neg.cc: Likewise.
2077
2078 * testsuite/21_strings/basic_string/init-list.cc:
2079 Require cxx11-abi.
2080 * testsuite/experimental/polymorphic_allocator/pmr_typedefs_match.cc:
2081 Likewise.
2082 * testsuite/experimental/polymorphic_allocator/pmr_typedefs_string.cc:
2083 Likewise.
2084
2085 * testsuite/23_containers/deque/capacity/max_size.cc: Fix test for
2086 C++98 mode.
2087 * testsuite/23_containers/deque/modifiers/assign/1.cc: Likewise.
2088 * testsuite/23_containers/list/modifiers/assign/1.cc: Likewise.
2089 * testsuite/23_containers/vector/bool/modifiers/assign/1.cc: Likewise.
2090 * testsuite/23_containers/vector/capacity/max_size.cc: Likewise.
2091 * testsuite/23_containers/vector/modifiers/assign/1.cc: Likewise.
2092
2093 2018-08-22 Jonathan Wakely <jwakely@redhat.com>
2094
2095 PR libstdc++/87061
2096 * include/experimental/regex [!_GLIBCXX_USE_CXX11_ABI]
2097 (experimental::pmr::match_results, experimental::pmr::cmatch)
2098 (experimental::pmr::smatch, experimental::pmr::wcmatch)
2099 (experimental::pmr::wsmatch): Do not declare for gcc4-compatible ABI,
2100 because COW strings don't support C++11 allocator model.
2101 * include/experimental/string [!_GLIBCXX_USE_CXX11_ABI]
2102 (experimental::pmr::basic_string, experimental::pmr::string)
2103 (experimental::pmr::u16string, experimental::pmr::u32string)
2104 (experimental::pmr::wstring): Likewise.
2105 * include/std/regex [!_GLIBCXX_USE_CXX11_ABI] (pmr::match_results)
2106 (pmr::cmatch, pmr::smatch, pmr::wcmatch, pmr::wsmatch): Likewise.
2107 * include/std/string [!_GLIBCXX_USE_CXX11_ABI] (pmr::basic_string)
2108 (pmr::string, pmr::u16string, pmr::u32string, pmr::wstring): Likewise.
2109 * testsuite/21_strings/basic_string/types/pmr_typedefs.cc: Require
2110 cxx11-abi.
2111 * testsuite/28_regex/match_results/pmr_typedefs.cc: Likewise.
2112
2113 PR libstdc++/78448
2114 * include/bits/deque.tcc (deque::_M_range_initialize): Use
2115 _S_check_init_len to check size.
2116 (deque::_M_push_back_aux, deque::_M_push_front_aux): Throw length
2117 error if size would exceed max_size().
2118 * include/bits/stl_deque.h (_Deque_base::size_type): Remove typedef.
2119 (_Deque_base(_Deque_base&&, const allocator_type&, size_t)): Use
2120 size_t instead of size_type.
2121 (deq(size_type, const allocator_type&)
2122 (deq(size_type, const value_type&, const allocator_type&)
2123 (deque::_M_initialize_dispatch): Use _S_check_init_len to check size.
2124 (deque::max_size): Call _S_max_size.
2125 (deque::_S_check_init_len, deque::_S_max_size): New functions.
2126 * include/bits/stl_vector.h (vector(size_type, const allocator_type&))
2127 (vector(size_type, const value_type&, const allocator_type&))
2128 (vector::_M_initialize_dispatch, vector::_M_range_initialize): Use
2129 _S_check_init_len to check size.
2130 (vector::max_size): Call _S_max_size.
2131 (vector::_M_check_len): Prevent max from being expanded as a
2132 function-like macro.
2133 (vector::_S_check_init_len, vector::_S_max_size): New functions.
2134 * include/bits/vector.tcc (vector::_M_assign_aux): Use
2135 _S_check_init_len to check size.
2136 * testsuite/23_containers/deque/capacity/max_size.cc: New test.
2137 * testsuite/23_containers/vector/capacity/max_size.cc: New test.
2138
2139 2018-08-22 François Dumont <fdumont@gcc.gnu.org>
2140
2141 PR libstdc++/68222
2142 * include/debug/safe_iterator.h
2143 (_Safe_iterator<_It, _Sq, _Cat>): Add category template parameter.
2144 (_Safe_iterator<>::_Const_iterator): Remove.
2145 (_Safe_iterator<>::_IsConstant): New.
2146 (_Safe_iterator<>::_OtherIterator): New.
2147 (_Safe_iterator<_It, _Sq, _Cat>::_Safe_iterator<_MutIte>(
2148 const _Safe_iterator<_MutIte, _Sq, _Cat>&)): Add _IsConstant::__value in
2149 __gnu_cxx::__enable_if condition.
2150 (_Safe_iterator<_It, _Sq, _Cat>::_M_get_distance_to): New.
2151 (_Safe_iterator<_It, _Sq, _Cat>::_M_get_distance_from_begin): New.
2152 (_Safe_iterator<_It, _Sq, _Cat>::_M_get_distance_to_end): New.
2153 (_Safe_iterator<_It, _Sq, std::bidirectional_iterator_tag>): New.
2154 (_Safe_iterator<_It, _Sq, _Cat>::operator--()): Move...
2155 (_Safe_iterator<_It, _Sq, std::bidirectional_iterator_tag>
2156 ::operator--()): ...here.
2157 (_Safe_iterator<_It, _Sq, _Cat>::operator--(int)): Move...
2158 (_Safe_iterator<_It, _Sq, std::bidirectional_iterator_tag>
2159 ::operator--(int)): ...here.
2160 (_Safe_iterator<_It, _Sq, _Cat>::_M_decrementable()): Move...
2161 (_Safe_iterator<_It, _Sq, std::bidirectional_iterator_tag>
2162 ::_M_decrementable()): ...here.
2163 (_Safe_iterator<_It, _Sq, std::random_access_iterator_tag>): New.
2164 (_Safe_iterator<_It, _Sq, _Cat>::operator[](const difference_type&)):
2165 Move...
2166 (_Safe_iterator<_It, _Sq, std::random_access_iterator_tag>
2167 ::operator[](const difference_type&)): ...here.
2168 (_Safe_iterator<_It, _Sq, _Cat>::operator+=(const difference_type&)):
2169 Move...
2170 (_Safe_iterator<_It, _Sq, std::random_access_iterator_tag>
2171 ::operator+=(const difference_type&)): ...here.
2172 (_Safe_iterator<_It, _Sq, _Cat>::operator+(const difference_type&)):
2173 Move...
2174 (_Safe_iterator<_It, _Sq, std::random_access_iterator_tag>
2175 ::operator+(const difference_type&)): ...here.
2176 (_Safe_iterator<_It, _Sq, _Cat>::operator-=(const difference_type&)):
2177 Move...
2178 (_Safe_iterator<_It, _Sq, std::random_access_iterator_tag>
2179 ::operator-=(const difference_type&)): ...here.
2180 (_Safe_iterator<_It, _Sq, _Cat>::operator-(const difference_type&)):
2181 Move...
2182 (_Safe_iterator<_It, _Sq, std::random_access_iterator_tag>
2183 ::operator-(const difference_type&)): ...here.
2184 (operator<(const _Safe_iterator<>&, const _Safe_iterator<>&)):
2185 Constraint to random access iterators.
2186 (operator<=(const _Safe_iterator<>&, const _Safe_iterator<>&)):
2187 Likewise.
2188 (operator>(const _Safe_iterator<>&, const _Safe_iterator<>&)): Likewise.
2189 (operator>=(const _Safe_iterator<>&, const _Safe_iterator<>&)):
2190 Likewise.
2191 (operator-(const _Safe_iterator<>&, const _Safe_iterator<>&)): Likewise.
2192 (operator+(const difference_type&, const _Safe_iterator<>&)): Likewise.
2193 (__check_dereferenceable(const _Safe_iterator<>&)): Remove.
2194 (__get_distance): Remove.
2195 (__get_distance_from_begin): Remove.
2196 (__get_distance_to_end): Remove.
2197 (struct __is_safe_random_iterator<_Safe_iterator<>>): Remove partial
2198 specialization.
2199 (__base(const _Safe_iterator<>&, std::input_iterator_tag)): Remove.
2200 (__base(const _Safe_iterator<>&, std::random_access_iterator_tag)): Remove.
2201 (__base(const _Safe_iterator<>&)): Constraint to random access iterator.
2202 * include/debug/safe_iterator.tcc
2203 (_Safe_iterator<>::_M_get_distance_from_begin()): New.
2204 (_Safe_iterator<>::_M_get_distance_to_end()): New.
2205 (_Safe_iterator<>::_M_get_distance_to(const _Safe_iterator<>&)): New.
2206 (_Safe_iterator<_It, _Seq, std::random_access_iterator_tag>
2207 ::_M_valid_range): New.
2208 * include/debug/safe_local_iterator.h
2209 (_Safe_local_iterator<>::_Const_local_iterator): Remove.
2210 (_Safe_local_iterator<>::_IsConstant): New.
2211 (_Safe_local_iterator<>::_OtherIterator): New.
2212 (_Safe_local_iterator<_It, _Cont>::_Safe_local_iterator<_MutIte, _Cont>(
2213 const _Safe_local_iterator<_MutIte, _Seq>&)): Add _IsConstant::__value
2214 in __gnu_cxx::__enable_if condition. If singular compare base iterator
2215 with _MutIte rather than _It.
2216 (_Safe_local_iterator<>::_S_constant): Make constexpr.
2217 (_Safe_local_iterator<>::_M_get_distance_to): New.
2218 (__check_dereferenceable(const _Safe_local_iterator<>&)): Remove.
2219 (__get_distance(const _Safe_local_iterator<>&,
2220 const _Safe_local_iterator<>&, std::input_iterator_tag)): Remove.
2221 (__valid_range(const _Safe_local_iterator<>&,
2222 const _Safe_local_iterator<>&)): New.
2223 * include/debug/safe_local_iterator.tcc
2224 (_Safe_local_iterator<>::_M_get_distance_to): New.
2225 * include/debug/deque (std::__debug::deque<>): Add
2226 ::__gnu_debug::_Safe_iterator<> friend declaration.
2227 * include/debug/forward_list (std::__debug::forward_list<>): Likewise.
2228 * include/debug/list (std::__debug::list<>): Likewise.
2229 * include/debug/map.h (std::__debug::map<>): Likewise.
2230 * include/debug/multimap.h (std::__debug::multimap<>): Likewise.
2231 * include/debug/set.h (std::__debug::set<>): Likewise.
2232 * include/debug/multiset.h (std::__debug::multiset<>): Likewise.
2233 * include/debug/string (std::__debug::basic_string<>): Likewise.
2234 * include/debug/unordered_map (std::__debug::unordered_map<>): Likewise
2235 and add ::__gnu_debug::_Safe_local_iterator<> friend declaration.
2236 (std::__debug::unordered_multimap<>): Likewise.
2237 * include/debug/unordered_set (std::__debug::unordered_set<>): Likewise.
2238 (std::__debug::unordered_multiset<>): Likewise.
2239 * include/debug/formatter.h: Adapt.
2240 * include/debug/helper_functions.h
2241 (__gnu_debug::_Safe_local_iterator<>): Add declaration.
2242 (__get_distance<_Ite>(_Ite, _Ite, std::random_access_iterator_tag):
2243 Pass parameter by copy.
2244 (__get_distance<_Ite>(_Ite, _Ite, std::input_iterator_tag): Likewise.
2245 (__get_distance<_Ite>(_Ite, _Ite): Likewise.
2246 (__valid_range_aux<_Integral>): Pass _Integral by copy.
2247 (__valid_range<_InputIterator>): Pass _InputIterator by copy.
2248 (__valid_range<>(const _Safe_iterator<>&,
2249 const _Safe_iterator<>&, typename _Distance_traits<>::__type&)):
2250 Declare.
2251 (__valid_range(const _Safe_local_iterator<>&,
2252 const _Safe_local_iterator<>&, typename _Distance_traits<>::__type&)):
2253 Declare.
2254 (__valid_range<>(const _Safe_iterator<>&, const _Safe_iterator<>&)):
2255 Declare.
2256 (__valid_range(const _Safe_local_iterator<>&, const _Safe_local_iterator<>&)):
2257 Declare.
2258 (__can_advance): Adapt.
2259 (struct __is_safe_random_iterator<>): Remove.
2260 (struct _SIter_base<>): Remove.
2261 * include/debug/functions.h: Include <bits/stl_iterator.h>.
2262 (__check_dereferenceable): Remove.
2263 (__foreign_iterator_aux4, __foreign_iterator_aux3): Adapt.
2264 (__foreign_iterator_aux2, __foreign_iterator_aux): Adapt.
2265 (__foreign_iterator): Adapt.
2266 * include/debug/stl_iterator.h
2267 (__is_safe_random_iterator<std::reverse_iterator<>>): Remove.
2268 (__base(const std::reverse_iterator<_Safe_iterator<_It, _Sq>)):
2269 Constraint for random access iterators.
2270 (__niter_base): Adapt.
2271 * testsuite/util/testsuite_containers.h:
2272 Include <bits/boost_concept_check.h>.
2273 (iterator_concept_checks<_It, _Mutable, _Category>): New.
2274 (citerator<_Cont>::forward_members::forward_members()): Instantiate
2275 latter for container iterator and const_iterator.
2276 * testsuite/23_containers/list/68222_neg.cc: New.
2277 * testsuite/23_containers/vector/cons/destructible_debug_neg.cc: Adapt
2278 line number.
2279 * testsuite/23_containers/unordered_set/debug/debug_functions.cc:
2280 (test01): Remove.
2281 * testsuite/23_containers/vector/debug/debug_functions.cc (test01):
2282 Remove.
2283
2284 2018-08-22 Jonathan Wakely <jwakely@redhat.com>
2285
2286 PR libstdc++/77854
2287 * doc/xml/manual/status_cxx1998.xml: Document size_type and
2288 difference_type for containers.
2289 * doc/html/*: Regenerate.
2290
2291 2018-08-21 François Dumont <fdumont@gcc.gnu.org>
2292
2293 P0646R1 Improving the Return Value of Erase-Like Algorithms I
2294 * include/debug/forward_list (forward_list::__remove_return_type):
2295 Define typedef as size_type or void, according to __cplusplus value.
2296 (_GLIBCXX_FWDLIST_REMOVE_RETURN_TYPE_TAG): Define macro as abi-tag or
2297 empty, according to __cplusplus value.
2298 (_GLIBCXX20_ONLY): Define macro.
2299 (forward_list::remove, forward_list::unique): Use typedef and macro
2300 to change return type and add abi-tag for C++2a. Return number of
2301 removed elements for C++2a.
2302 (forward_list::remove_if<Pred>, forward_list::unique<BinPred>): Use
2303 typedef to change return type for C++2a. Return number of removed
2304 elements for C++2a.
2305 * include/debug/list (list::__remove_return_type): Define typedef as
2306 size_type or void, according to __cplusplus value.
2307 (_GLIBCXX_LIST_REMOVE_RETURN_TYPE_TAG): Define macro as abi-tag or
2308 empty, according to __cplusplus value.
2309 (_GLIBCXX20_ONLY): Define macro.
2310 (list::remove, list::unique): Use typedef and macro to change return
2311 type and add abi-tag for C++2a. Return number of removed elements for
2312 C++2a.
2313 (list::remove_if<Predicate>, list::unique<BinaryPredicate>): Use typedef
2314 to change return type for C++2a. Return number of removed elements for
2315 C++2a.
2316
2317 2018-08-21 David Edelsohn <dje.gcc@gmail.com>
2318
2319 * testsuite/18_support/new_nothrow.cc: XFAIL on AIX.
2320
2321 2018-08-21 Jonathan Wakely <jwakely@redhat.com>
2322
2323 * testsuite/26_numerics/bit/bitops.count/countl_one.cc: Remove
2324 redundant dg-do directive.
2325 * testsuite/26_numerics/bit/bitops.count/countl_zero.cc: Likewise.
2326 * testsuite/26_numerics/bit/bitops.count/countr_one.cc: Likewise.
2327 * testsuite/26_numerics/bit/bitops.count/countr_zero.cc: Likewise.
2328 * testsuite/26_numerics/bit/bitops.count/popcount.cc: Likewise.
2329
2330 2018-08-20 Jonathan Wakely <jwakely@redhat.com>
2331
2332 PR libstdc++/86963
2333 * include/std/tuple (_Tuple_impl::operator=): Define as deleted.
2334 (_Tuple_impl::_M_assign): New functions to perform assignment instead
2335 of assignment operators.
2336 (_Tuple_impl::_M_swap): Remove exception specification.
2337 (_Tuple_impl<_Idx, _Head>): Likewise.
2338 (_TC::_NonNestedTuple, _TC::_NotSameTuple): Use __remove_cvref_t.
2339 (__tuple_base): Remove.
2340 (tuple, tuple<_T1, _T2>): Remove inheritance from __tuple_base.
2341 (tuple::operator=, tuple<_T1, _T2>::operator=): Call _M_assign.
2342 (tuple::swap, tuple<_T1, _T2>::swap): Define exception specification
2343 using __is_nothrow_swappable.
2344 (tuple<_T1, _T2>::tuple(_U1&&, _U2&&)): Use __remove_cvref_t.
2345
2346 * include/std/optional (_Optional_payload): Use variable templates
2347 for conditions in default template arguments and exception
2348 specifications.
2349 (optional): Likewise. Adjust indentation.
2350 (optional::__not_self, optional::__not_tag, optional::_Requires): New
2351 SFINAE helpers.
2352 (optional::optional): Use new helpers in constructor constraints.
2353 * include/std/type_traits (__or_v, __and_v): New variable templates.
2354 * testsuite/20_util/optional/cons/value_neg.cc: Change dg-error to
2355 dg-prune-output. Remove unused header.
2356
2357 2018-08-18 François Dumont <fdumont@gcc.gnu.org>
2358
2359 * testsuite/25_algorithms/copy/86658.cc: Use dg-options to define
2360 _GLIBCXX_DEBUG.
2361
2362 2018-08-17 Jonathan Wakely <jwakely@redhat.com>
2363
2364 PR libstdc++/86963
2365 * include/std/tuple (__tuple_base): New class template with deleted
2366 copy assignment operator.
2367 (tuple, tuple<_T1, _T2>): Derive from __tuple_base<tuple> so that
2368 implicit copy/move assignment operator will be deleted/suppressed.
2369 (tuple::__assignable, tuple<_T1, _T2>::__assignable): New helper
2370 functions for SFINAE constraints on assignment operators.
2371 (tuple::__nothrow_assignable, tuple<_T1, _T2>::__nothrow_assignable):
2372 New helper functions for exception specifications.
2373 (tuple::operator=(const tuple&), tuple::operator=(tuple&&))
2374 (tuple<_T1, _T2>::operator=(const tuple&))
2375 (tuple<_T1, _T2>::operator=(tuple&&)): Change parameter types to
2376 __nonesuch_no_braces when the operator should be defined implicitly.
2377 Use __nothrow_assignable for exception specifications.
2378 (tuple::operator=(const tuple<_UElements...>&))
2379 (tuple::operator=(tuple<_UElements...>&&))
2380 (tuple<_T1, _T2>::operator=(const tuple<_U1, _U2>&))
2381 (tuple<_T1, _T2>::operator=(tuple<_U1, _U2>&&))
2382 (tuple<_T1, _T2>::operator=(const pair<_U1, _U2>&))
2383 (tuple<_T1, _T2>::operator=(pair<_U1, _U2>&&)): Constrain using
2384 __assignable and use __nothrow_assignable for exception
2385 specifications.
2386 * python/libstdcxx/v6/printers.py (is_specialization_of): Accept
2387 gdb.Type as first argument, instead of a string.
2388 (StdTuplePrinter._iterator._is_nonempty_tuple): New method to check
2389 tuple for expected structure.
2390 (StdTuplePrinter._iterator.__init__): Use _is_nonempty_tuple.
2391 * testsuite/20_util/tuple/dr2729.cc: New test.
2392 * testsuite/20_util/tuple/element_access/get_neg.cc: Change dg-error
2393 to dg-prune-output.
2394
2395 2018-08-16 Jonathan Wakely <jwakely@redhat.com>
2396
2397 * include/tr1/legendre_function.tcc (__sph_legendre): Avoid warning
2398 about signed/unsigned comparison.
2399
2400 * include/std/ostream (basic_ostream::sentry::~sentry): Suppress
2401 deprecation warnings for using uncaught_exception().
2402
2403 PR libstdc++/86447
2404 * src/c++11/cow-stdexcept.cc [_GLIBCXX_FULLY_DYNAMIC_STRING]
2405 (logic_error::logic_error(logic_error&&))
2406 (logic_error::operator=(logic_error&&))
2407 (runtime_error::runtime_error(runtime_error&&))
2408 (runtime_error::operator=(runtime_error&&)): Copy strings instead of
2409 moving, to avoid allocating empty reps for moved-from strings.
2410
2411 2018-08-15 Jonathan Wakely <jwakely@redhat.com>
2412
2413 * include/experimental/regex: Remove begin/end macros for namespace.
2414 * include/experimental/string: Likewise.
2415 * testsuite/experimental/polymorphic_allocator/pmr_typedefs_deque.cc:
2416 New test.
2417 * testsuite/experimental/polymorphic_allocator/
2418 pmr_typedefs_forward_list.cc: New test.
2419 * testsuite/experimental/polymorphic_allocator/pmr_typedefs_list.cc:
2420 New test.
2421 * testsuite/experimental/polymorphic_allocator/pmr_typedefs_map.cc:
2422 New test.
2423 * testsuite/experimental/polymorphic_allocator/pmr_typedefs_match.cc:
2424 New test.
2425 * testsuite/experimental/polymorphic_allocator/
2426 pmr_typedefs_multimap.cc: New test.
2427 * testsuite/experimental/polymorphic_allocator/
2428 pmr_typedefs_multiset.cc: New test.
2429 * testsuite/experimental/polymorphic_allocator/pmr_typedefs_set.cc:
2430 New test.
2431 * testsuite/experimental/polymorphic_allocator/pmr_typedefs_string.cc:
2432 New test.
2433 * testsuite/experimental/polymorphic_allocator/
2434 pmr_typedefs_unordered_map.cc: New test.
2435 * testsuite/experimental/polymorphic_allocator/
2436 pmr_typedefs_unordered_multimap.cc: New test.
2437 * testsuite/experimental/polymorphic_allocator/
2438 pmr_typedefs_unordered_multiset.cc: New test.
2439 * testsuite/experimental/polymorphic_allocator/
2440 pmr_typedefs_unordered_set.cc: New test.
2441 * testsuite/experimental/polymorphic_allocator/pmr_typedefs_vector.cc:
2442 New test.
2443
2444 * include/bits/uses_allocator.h (__uses_allocator_construct): Qualify
2445 calls to __uses_allocator_construct_impl and __use_alloc.
2446 * include/experimental/memory_resource
2447 (polymorphic_allocator::_M_construct): Remove.
2448 (polymorphic_allocator::construct): Call __uses_allocator_construct.
2449 Qualify calls to __use_alloc.
2450 * include/std/memory_resource (polymorphic_allocator::construct): Fix
2451 type in SFINAE constraint. Use constexpr if instead of tag dispatching
2452 to _S_construct overloads.
2453 (polymorphic_allocator::construct(pair<T1, T2>*, ...)): Fix order of
2454 arguments to _S_construct_p.
2455 (polymorphic_allocator::_S_construct): Remove.
2456 (polymorphic_allocator::_S_construct_p): Return allocators by value
2457 not by reference.
2458 * include/std/scoped_allocator (scoped_allocator_adaptor::construct):
2459 Qualify calls to __use_alloc.
2460 * testsuite/20_util/polymorphic_allocator/construct_pair.cc: New test,
2461 copied from testsuite/20_util/scoped_allocator/construct_pair.cc.
2462 * testsuite/experimental/polymorphic_allocator/1.cc: New test.
2463 * testsuite/experimental/polymorphic_allocator/construct_pair.cc:
2464 New test.
2465
2466 * src/c++17/memory_resource.cc [!_GLIBCXX_HAS_GTHREADS]
2467 (atomic_mem_res): Add unsynchronized definition for single-threaded.
2468
2469 2018-08-14 Jonathan Wakely <jwakely@redhat.com>
2470
2471 PR libstdc++/86954
2472 * include/bits/stl_tempbuf.h (return_temporary_buffer): Use
2473 non-placement delete.
2474
2475 * include/std/chrono (__check_overflow): Simplify definition.
2476 (_Checked_integral_constant): Remove.
2477
2478 PR libstdc++/86846
2479 * src/c++17/default_resource.h: New file, defining default_res.
2480 * src/c++17/memory_resource.cc [ATOMIC_POINTER_LOCK_FREE != 2]
2481 (atomic_mem_res): Define alternative for atomic<memory_resource*>
2482 using a mutex instead of atomics.
2483
2484 PR libstdc++/85343
2485 * config/abi/pre/gnu.ver: Export new symbol.
2486 * doc/xml/manual/abi.xml: Document new versions.
2487 * include/bits/fstream.tcc (basic_filebuf<C, T>::underflow)
2488 (basic_filebuf<C, T>::xsgetn): Pass errno to __throw_ios_failure.
2489 * include/bits/functexcept.h (__throw_ios_failure(const char*, int)):
2490 Declare new overload.
2491 * src/c++11/cxx11-ios_failure.cc (__ios_failure): Add new constructor
2492 and static member function.
2493 (__throw_ios_failure(const char*, int)): Define.
2494 * src/c++98/ios_failure.cc [!_GLIBCXX_USE_DUAL_ABI]
2495 (__throw_ios_failure(const char*, int)): Define.
2496
2497 2018-08-14 Jeremy Sawicki <jeremy-gcc@sawicki.us>
2498
2499 * include/ext/rope (_Rope_iterator_base(const _Rope_iterator_base&))
2500 (_Rope_const_iterator::operator=(const _Rope_const_iterator&))
2501 (_Rope_iterator::operator=(const _Rope_iterator&)): Ensure
2502 copied/assigned rope iterators don't retain pointers to the iterator
2503 they were copied/assigned from.
2504 * testsuite/ext/rope/7.cc: New.
2505
2506 2018-08-13 Jonathan Wakely <jwakely@redhat.com>
2507
2508 PR libstdc++/45093
2509 * include/bits/stl_tree.h (_Rb_tree::_M_destroy_node(_Link_type)):
2510 Combine definitions to avoid --detect-odr-violations warning.
2511
2512 * libsupc++/new_opa.cc (operator new(size_t, align_val_t)): Use
2513 __is_pow2 to check for valid alignment. Avoid branching when rounding
2514 size to multiple of alignment.
2515
2516 * include/Makefile.am: Install <bit> and <version> for freestanding.
2517 * include/Makefile.in: Regenerate.
2518 * testsuite/17_intro/freestanding.cc: Check for <bit> and <version>.
2519
2520 Revert
2521 2018-08-10 Sebastian Huber <sebastian.huber@embedded-brains.de>
2522
2523 PR target/85904
2524 * configure.ac: Define HAVE_ALIGNED_ALLOC if building for
2525 Newlib.
2526 * configure: Regenerate.
2527
2528 2018-08-10 Jonathan Wakely <jwakely@redhat.com>
2529
2530 PR libstdc++/68210
2531 * doc/xml/manual/intro.xml: Document LWG 206 change.
2532 * libsupc++/del_op.cc: Replace _GLIBCXX_USE_NOEXCEPT with noexcept.
2533 * libsupc++/del_opa.cc: Likewise.
2534 * libsupc++/del_opant.cc: Likewise.
2535 * libsupc++/del_opnt.cc: Likewise. Call operator delete(ptr) instead
2536 of free(ptr).
2537 * libsupc++/del_ops.cc: Replace _GLIBCXX_USE_NOEXCEPT with noexcept.
2538 * libsupc++/del_opsa.cc: Likewise.
2539 * libsupc++/del_opva.cc: Likewise.
2540 * libsupc++/del_opvant.cc: Likewise.
2541 * libsupc++/del_opvnt.cc: Likewise. Call operator delete[](ptr)
2542 instead of operator delete(ptr).
2543 * libsupc++/del_opvs.cc: Replace _GLIBCXX_USE_NOEXCEPT with noexcept.
2544 * libsupc++/del_opvsa.cc: Likewise.
2545 * libsupc++/new_op.cc: Use __builtin_expect in check for zero size.
2546 * libsupc++/new_opa.cc: Use nullptr instead of literal 0.
2547 * libsupc++/new_opant.cc: Likewise. Replace _GLIBCXX_USE_NOEXCEPT
2548 with noexcept.
2549 * libsupc++/new_opnt.cc: Likewise. Call operator new(sz) instead of
2550 malloc(sz).
2551 * libsupc++/new_opvant.cc: Use nullptr and noexcept.
2552 * libsupc++/new_opvnt.cc: Likewise. Call operator new[](sz) instead of
2553 operator new(sz, nothrow).
2554 * testsuite/18_support/new_nothrow.cc: New test.
2555
2556 2018-08-10 Martin Liska <mliska@suse.cz>
2557
2558 * libsupc++/new_op.cc (new): Remove __builtin_expect as malloc
2559 predictor can handle that.
2560 * libsupc++/new_opa.cc: Likewise.
2561 * libsupc++/new_opnt.cc (new): Likewise.
2562
2563 2018-08-10 Sebastian Huber <sebastian.huber@embedded-brains.de>
2564
2565 PR target/85904
2566 * configure.ac: Define HAVE_ALIGNED_ALLOC if building for
2567 Newlib.
2568 * configure: Regenerate.
2569
2570 2018-08-10 Jonathan Wakely <jwakely@redhat.com>
2571
2572 * include/std/deque (std::pmr::deque): Declare alias.
2573 * include/std/forward_list (std::pmr::forward_list): Likewise.
2574 * include/std/list (std::pmr::list): Likewise.
2575 * include/std/map (std::pmr::map, std::pmr::multimap): Likewise.
2576 * include/std/regex (std::pmr::match_results, std::pmr::cmatch)
2577 (std::pmr::smatch, std::pmr::wcmatch, std::pmr::wsmatch): Likewise.
2578 * include/std/set (std::pmr::set, std::pmr::multiset): Likewise.
2579 * include/std/string (std::pmr::basic_string, std::pmr::string)
2580 (std::pmr::u16string, std::pmr::u32string, std::pmr::wstring):
2581 Likewise.
2582 * include/std/unordered_map (std::pmr::unordered_map)
2583 (std::pmr::unordered_multimap): Likewise.
2584 * include/std/unordered_set (std::pmr::unordered_set)
2585 (std::pmr::unordered_multiset): Likewise.
2586 * include/std/vector (std::pmr::vector): Likewise.
2587 * testsuite/21_strings/basic_string/types/pmr_typedefs.cc: New test.
2588 * testsuite/23_containers/deque/types/pmr_typedefs.cc: New test.
2589 * testsuite/23_containers/forward_list/pmr_typedefs.cc: New test.
2590 * testsuite/23_containers/list/pmr_typedefs.cc: New test.
2591 * testsuite/23_containers/map/pmr_typedefs.cc: New test.
2592 * testsuite/23_containers/multimap/pmr_typedefs.cc: New test.
2593 * testsuite/23_containers/multiset/pmr_typedefs.cc: New test.
2594 * testsuite/23_containers/set/pmr_typedefs.cc: New test.
2595 * testsuite/23_containers/unordered_map/pmr_typedefs.cc: New test.
2596 * testsuite/23_containers/unordered_multimap/pmr_typedefs.cc: New
2597 test.
2598 * testsuite/23_containers/unordered_multiset/pmr_typedefs.cc: New
2599 test.
2600 * testsuite/23_containers/unordered_set/pmr_typedefs.cc: New test.
2601 * testsuite/23_containers/vector/pmr_typedefs.cc: New test.
2602 * testsuite/28_regex/match_results/pmr_typedefs.cc: New test.
2603
2604 2018-08-08 François Dumont <fdumont@gcc.gnu.org>
2605
2606 * include/bits/stl_algo.h
2607 (__rotate(_Ite, _Ite, _Ite, forward_iterator_tag))
2608 (__rotate(_Ite, _Ite, _Ite, bidirectional_iterator_tag))
2609 (__rotate(_Ite, _Ite, _Ite, random_access_iterator_tag)): Move code
2610 duplication...
2611 (rotate(_Ite, _Ite, _Ite)): ...here.
2612 (__stable_partition_adaptive(_FIt, _FIt, _Pred, _Dist, _Pointer, _Dist)):
2613 Simplify rotate call.
2614 (__rotate_adaptive(_BIt1, _BIt1, _BIt1, _Dist, _Dist, _Bit2, _Dist)):
2615 Likewise.
2616 (__merge_without_buffer(_BIt, _BIt, _BIt, _Dist, _Dist, _Comp)):
2617 Likewise.
2618
2619 2018-08-08 Jonathan Wakely <jwakely@redhat.com>
2620
2621 * libsupc++/new_opa.cc (aligned_alloc): Declare inside namespace to
2622 avoid clashing with an ::aligned_alloc function that was not detected
2623 by configure.
2624
2625 * doc/xml/manual/using.xml: Fix markup for empty table entry.
2626 * doc/html/*: Regenerate.
2627
2628 * doc/xml/manual/using.xml: Add missing header to table and fix typo.
2629 * doc/html/*: Regenerate.
2630
2631 PR libstdc++/86597
2632 * include/bits/fs_dir.h (directory_entry::_M_file_type(error_code&)):
2633 Clear error_code when cached type is used.
2634 * testsuite/27_io/filesystem/directory_entry/86597.cc: New test.
2635
2636 2018-08-07 Jonathan Wakely <jwakely@redhat.com>
2637
2638 PR libstdc++/86874
2639 * include/std/variant (_Copy_ctor_base::_M_destructive_move): Define
2640 here instead of in _Move_assign_base.
2641 (_Copy_ctor_base<true, _Types...>::_M_destructive_move): Define.
2642 (_Copy_assign_base::operator=): Use _M_destructive_move when changing
2643 the contained value to another alternative.
2644 (_Move_assign_base::operator=): Likewise.
2645 (_Move_assign_base::_M_destructive_move): Remove.
2646 * testsuite/20_util/variant/86874.cc: New test.
2647
2648 PR libstdc++/86861
2649 * libsupc++/new_opa.cc [_GLIBCXX_HAVE_MEMALIGN] (aligned_alloc):
2650 Replace macro with inline function.
2651 [__sun]: Increase alignment to meet memalign precondition.
2652 [!HAVE__ALIGNED_MALLOC && !HAVE_POSIX_MEMALIGN && !HAVE_MEMALIGN]
2653 (aligned_alloc): Move check for valid alignment to operator new.
2654 Remove redundant check for non-zero size, it's enforced by the caller.
2655 (operator new): Move check for valid alignment here. Use
2656 __builtin_expect on check for zero size.
2657
2658 * config/abi/pre/gnu.ver: Export monotonic_buffer_resource members.
2659 * include/std/memory_resource (monotonic_buffer_resource::release):
2660 Call _M_release_buffers to free buffers.
2661 (monotonic_buffer_resource::do_allocate): Call _M_new_buffer to
2662 allocate a new buffer from upstream.
2663 (monotonic_buffer_resource::_M_new_buffer): Declare.
2664 (monotonic_buffer_resource::_M_release_buffers): Declare.
2665 (monotonic_buffer_resource::_Chunk): Replace definition with
2666 declaration as opaque type.
2667 * src/c++17/memory_resource.cc (monotonic_buffer_resource::_Chunk):
2668 Define.
2669 (monotonic_buffer_resource::_M_new_buffer): Define.
2670 (monotonic_buffer_resource::_M_release_buffers): Define.
2671
2672 2018-08-05 François Dumont <fdumont@gcc.gnu.org>
2673
2674 * include/bits/stl_iterator.h: Fix comment.
2675
2676 2018-08-03 Jonathan Wakely <jwakely@redhat.com>
2677
2678 * src/c++11/system_error.cc
2679 (system_error_category::default_error_condition): Add workaround for
2680 ENOTEMPTY and EEXIST having the same value on AIX.
2681 * testsuite/19_diagnostics/error_category/system_category.cc: Add
2682 extra testcases for EDOM, EILSEQ, ERANGE, EEXIST and ENOTEMPTY.
2683
2684 2018-08-01 Jonathan Wakely <jwakely@redhat.com>
2685
2686 * configure: Regenerate.
2687 * configure.ac: Add -D_GLIBCXX_ASSERTIONS to default DEBUG_FLAGS.
2688 * src/c++11/futex.cc: Use __glibcxx_assert instead of
2689 _GLIBCXX_DEBUG_ASSERT.
2690
2691 2018-08-01 Mike Crowe <mac@mcrowe.com>
2692
2693 * include/std/condition_variable (wait_for): Use steady_clock.
2694
2695 2018-08-01 Mike Crowe <mac@mcrowe.com>
2696
2697 * include/std/condition_variable (wait_until): Only report timeout
2698 if we really have timed out when measured against the
2699 caller-supplied clock.
2700 * testsuite/30_threads/condition_variable/members/2.cc: Add test
2701 case to confirm above behaviour.
2702
2703 2018-08-01 Jonathan Wakely <jwakely@redhat.com>
2704
2705 PR libstdc++/60555
2706 * src/c++11/system_error.cc
2707 (system_error_category::default_error_condition): New override to
2708 check for POSIX errno values.
2709 * testsuite/19_diagnostics/error_category/generic_category.cc: New
2710 * testsuite/19_diagnostics/error_category/system_category.cc: New
2711 test.
2712
2713 2018-07-31 Jonathan Wakely <jwakely@redhat.com>
2714
2715 PR libstdc++/86751
2716 * include/bits/stl_pair.h (__pair_base): New class with deleted copy
2717 assignment operator.
2718 (pair): Derive from __pair_base.
2719 (pair::operator=): Remove deleted overload.
2720 * python/libstdcxx/v6/printers.py (StdPairPrinter): New pretty printer
2721 so that new base class isn't shown in GDB.
2722 * testsuite/20_util/pair/86751.cc: New test.
2723 * testsuite/20_util/pair/ref_assign.cc: New test.
2724
2725 * include/bits/c++config (_GLIBCXX_HAVE_BUILTIN_HAS_UNIQ_OBJ_REP)
2726 (_GLIBCXX_HAVE_BUILTIN_IS_AGGREGATE): Move definitions here.
2727 (_GLIBCXX_HAVE_BUILTIN_LAUNDER): Likewise. Use !__is_identifier
2728 instead of __has_builtin.
2729 * include/std/type_traits (_GLIBCXX_HAVE_BUILTIN_HAS_UNIQ_OBJ_REP)
2730 (_GLIBCXX_HAVE_BUILTIN_IS_AGGREGATE): Remove definitions from here.
2731 * include/std/version [!_GLIBCXX_HAS_GTHREADS]
2732 (__cpp_lib_shared_timed_mutex, __cpp_lib_scoped_lock)
2733 (__cpp_lib_shared_mutex): Don't define when Gthreads not in use.
2734 [!_GLIBCXX_HAVE_BUILTIN_HAS_UNIQ_OBJ_REP]
2735 (__cpp_lib_has_unique_object_representations): Don't define when
2736 builtin not available.
2737 [!_GLIBCXX_HAVE_BUILTIN_IS_AGGREGATE] (__cpp_lib_is_aggregate):
2738 Likewise.
2739 [!_GLIBCXX_HAVE_BUILTIN_LAUNDER] (__cpp_lib_launder): Likewise.
2740 * libsupc++/new (_GLIBCXX_HAVE_BUILTIN_LAUNDER): Remove definition
2741 from here.
2742
2743 * doc/xml/manual/test.xml: Improve documentation on writing tests for
2744 newer standards.
2745 * doc/xml/manual/using.xml: Document all headers for C++11 and later.
2746 * doc/html/*: Regenerate.
2747
2748 * include/ext/pointer.h [__cplusplus >= 201103L]
2749 (_Pointer_adapter::operator bool): Add explicit conversion operator
2750 to replace safe bool idiom.
2751
2752 2018-07-30 Jonathan Wakely <jwakely@redhat.com>
2753
2754 PR libstdc++/86734
2755 * include/bits/stl_iterator.h (reverse_iterator::operator->): Call
2756 _S_to_pointer (LWG 1052, LWG 2118).
2757 (reverse_iterator::_S_to_pointer): Define overloaded helper functions.
2758 * testsuite/24_iterators/reverse_iterator/dr1052.cc: New test.
2759 * testsuite/24_iterators/reverse_iterator/dr2188.cc: New test.
2760
2761 * libsupc++/new_opa.cc (operator new(size_t, align_val_t)): Add
2762 workaround for aligned_alloc bug on AIX.
2763 * testsuite/18_support/new_aligned.cc: New test.
2764
2765 2018-07-26 Marek Polacek <polacek@redhat.com>
2766
2767 * testsuite/30_threads/condition_variable_any/cond.cc: New.
2768
2769 2018-07-26 Marek Polacek <polacek@redhat.com>
2770
2771 * src/c++98/locale_init.cc: Fix #ifdef condition.
2772
2773 2018-07-26 Jonathan Wakely <jwakely@redhat.com>
2774
2775 * testsuite/18_support/aligned_alloc/aligned_alloc.cc: Add
2776 dg-require-cstdint directive.
2777 * testsuite/20_util/allocator/overaligned.cc: Likewise.
2778 * testsuite/20_util/any/cons/aligned.cc: Likewise.
2779 * testsuite/20_util/monotonic_buffer_resource/allocate.cc: Likewise.
2780 * testsuite/20_util/monotonic_buffer_resource/deallocate.cc: Likewise.
2781 * testsuite/20_util/shared_ptr/thread/default_weaktoshared.cc:
2782 Likewise.
2783 * testsuite/20_util/shared_ptr/thread/mutex_weaktoshared.cc: Likewise.
2784 * testsuite/23_containers/list/modifiers/insert/25288.cc: Likewise.
2785 * testsuite/23_containers/set/allocator/move_assign.cc: Likewise.
2786 * testsuite/25_algorithms/make_heap/complexity.cc: Likewise.
2787 * testsuite/25_algorithms/pop_heap/complexity.cc: Require cstdint and
2788 random_device effective-target.
2789 * testsuite/25_algorithms/push_heap/complexity.cc: Likewise.
2790 * testsuite/25_algorithms/sample/1.cc: Require cstdint.
2791 * testsuite/25_algorithms/sample/2.cc: Likewise.
2792 * testsuite/25_algorithms/sort_heap/complexity.cc: Require cstdint
2793 and random_device.
2794 * testsuite/26_numerics/headers/random/types_std_c++0x.cc: Require
2795 cstdint.
2796 * testsuite/26_numerics/random/chi_squared_distribution/83833.cc:
2797 Likewise.
2798 * testsuite/26_numerics/random/discard_block_engine/requirements/
2799 constexpr_data.cc: Likewise.
2800 * testsuite/26_numerics/random/discard_block_engine/requirements/
2801 constexpr_functions.cc: Likewise.
2802 * testsuite/26_numerics/random/independent_bits_engine/requirements/
2803 constexpr_functions.cc: Likewise.
2804 * testsuite/26_numerics/random/linear_congruential_engine/requirements/
2805 constexpr_data.cc: Likewise.
2806 * testsuite/26_numerics/random/linear_congruential_engine/requirements/
2807 constexpr_functions.cc: Likewise.
2808 * testsuite/26_numerics/random/mersenne_twister_engine/requirements/
2809 constexpr_data.cc: Likewise.
2810 * testsuite/26_numerics/random/mersenne_twister_engine/requirements/
2811 constexpr_functions.cc: Likewise.
2812 * testsuite/26_numerics/random/pr60037-neg.cc: Likewise.
2813 * testsuite/26_numerics/random/seed_seq/cons/65631.cc: Likewise.
2814 * testsuite/26_numerics/random/shuffle_order_engine/requirements/
2815 constexpr_data.cc: Add dg-require-cstdint directive.
2816 * testsuite/26_numerics/random/shuffle_order_engine/requirements/
2817 constexpr_functions.cc: Likewise.
2818 * testsuite/26_numerics/random/subtract_with_carry_engine/requirements/
2819 constexpr_data.cc: Likewise.
2820 * testsuite/26_numerics/random/subtract_with_carry_engine/requirements/
2821 constexpr_functions.cc: Likewise.
2822 * testsuite/26_numerics/random/uniform_real_distribution/operators/
2823 64351.cc: Likewise.
2824 * testsuite/29_atomics/headers/atomic/types_std_c++0x.cc: Likewise.
2825 * testsuite/experimental/algorithm/sample-2.cc: Likewise.
2826 * testsuite/experimental/algorithm/sample.cc: Likewise.
2827 * testsuite/experimental/algorithm/search.cc: Likewise.
2828 * testsuite/experimental/algorithm/shuffle.cc: Likewise.
2829 * testsuite/experimental/any/cons/aligned.cc: Likewise.
2830 * testsuite/experimental/memory_resource/new_delete_resource.cc:
2831 Likewise.
2832 * testsuite/experimental/memory_resource/resource_adaptor.cc: Likewise.
2833 * testsuite/experimental/random/randint.cc: Likewise.
2834 * testsuite/experimental/source_location/1.cc: Likewise.
2835 * testsuite/ext/bitmap_allocator/overaligned.cc: Likewise.
2836 * testsuite/ext/malloc_allocator/overaligned.cc: Likewise.
2837 * testsuite/ext/mt_allocator/overaligned.cc: Likewise.
2838 * testsuite/ext/new_allocator/overaligned.cc: Likewise.
2839 * testsuite/ext/pb_ds/regression/hash_map_rand.cc: Likewise.
2840 * testsuite/ext/pb_ds/regression/hash_set_rand.cc: Likewise.
2841 * testsuite/ext/pb_ds/regression/list_update_map_rand.cc: Likewise.
2842 * testsuite/ext/pb_ds/regression/list_update_set_rand.cc: Likewise.
2843 * testsuite/ext/pb_ds/regression/priority_queue_rand.cc: Likewise.
2844 * testsuite/ext/pb_ds/regression/tree_map_rand.cc: Likewise.
2845 * testsuite/ext/pb_ds/regression/tree_set_rand.cc: Likewise.
2846 * testsuite/ext/pb_ds/regression/trie_map_rand.cc: Likewise.
2847 * testsuite/ext/pb_ds/regression/trie_set_rand.cc: Likewise.
2848 * testsuite/ext/pool_allocator/overaligned.cc: Likewise.
2849 * testsuite/ext/throw_allocator/check_allocate_max_size.cc: Likewise.
2850 * testsuite/ext/throw_allocator/check_deallocate_null.cc: Likewise.
2851 * testsuite/ext/throw_allocator/check_delete.cc: Likewise.
2852 * testsuite/ext/throw_allocator/check_new.cc: Likewise.
2853 * testsuite/ext/throw_allocator/deallocate_global.cc: Likewise.
2854 * testsuite/ext/throw_allocator/deallocate_local.cc: Likewise.
2855 * testsuite/ext/throw_allocator/explicit_instantiation.cc: Likewise.
2856 * testsuite/ext/throw_allocator/variadic_construct.cc: Likewise.
2857 * testsuite/tr1/8_c_compatibility/cinttypes/functions.cc: Likewise.
2858
2859 * testsuite/30_threads/recursive_mutex/cons/1.cc: Likewise.
2860 * testsuite/30_threads/recursive_mutex/cons/assign_neg.cc: Likewise.
2861 * testsuite/30_threads/recursive_mutex/cons/copy_neg.cc: Likewise.
2862 * testsuite/30_threads/recursive_mutex/dest/destructor_locked.cc:
2863 Likewise.
2864 * testsuite/30_threads/recursive_mutex/lock/1.cc: Likewise.
2865 * testsuite/30_threads/recursive_mutex/native_handle/1.cc: Likewise.
2866 * testsuite/30_threads/recursive_mutex/native_handle/typesizes.cc:
2867 Likewise.
2868 * testsuite/30_threads/recursive_mutex/requirements/standard_layout.cc:
2869 Likewise.
2870 * testsuite/30_threads/recursive_mutex/requirements/typedefs.cc:
2871 Likewise.
2872 * testsuite/30_threads/recursive_mutex/try_lock/1.cc: Likewise.
2873 * testsuite/30_threads/recursive_mutex/try_lock/2.cc: Likewise.
2874 * testsuite/30_threads/recursive_mutex/unlock/1.cc: Likewise.
2875 * testsuite/30_threads/recursive_mutex/unlock/2.cc: Likewise.
2876 * testsuite/30_threads/recursive_timed_mutex/cons/1.cc: Likewise.
2877 * testsuite/30_threads/recursive_timed_mutex/cons/assign_neg.cc:
2878 Likewise.
2879 * testsuite/30_threads/recursive_timed_mutex/cons/copy_neg.cc:
2880 Likewise.
2881 * testsuite/30_threads/recursive_timed_mutex/dest/
2882 destructor_locked.cc: Likewise.
2883 * testsuite/30_threads/recursive_timed_mutex/lock/1.cc: Likewise.
2884 * testsuite/30_threads/recursive_timed_mutex/lock/2.cc: Likewise.
2885 * testsuite/30_threads/recursive_timed_mutex/native_handle/1.cc:
2886 Likewise.
2887 * testsuite/30_threads/recursive_timed_mutex/native_handle/
2888 typesizes.cc: Likewise.
2889 * testsuite/30_threads/recursive_timed_mutex/requirements/typedefs.cc:
2890 Likewise.
2891 * testsuite/30_threads/recursive_timed_mutex/try_lock/1.cc:
2892 Likewise.
2893 * testsuite/30_threads/recursive_timed_mutex/try_lock/2.cc:
2894 Likewise.
2895 * testsuite/30_threads/recursive_timed_mutex/try_lock_for/1.cc:
2896 Likewise.
2897 * testsuite/30_threads/recursive_timed_mutex/try_lock_for/2.cc:
2898 Likewise.
2899 * testsuite/30_threads/recursive_timed_mutex/try_lock_for/3.cc:
2900 Likewise.
2901 * testsuite/30_threads/recursive_timed_mutex/try_lock_until/1.cc:
2902 Likewise.
2903 * testsuite/30_threads/recursive_timed_mutex/try_lock_until/2.cc:
2904 Likewise.
2905 * testsuite/30_threads/recursive_timed_mutex/unlock/1.cc: Likewise.
2906 * testsuite/30_threads/recursive_timed_mutex/unlock/2.cc: Likewise.
2907 * testsuite/30_threads/scoped_lock/cons/1.cc: Likewise.
2908 * testsuite/30_threads/scoped_lock/requirements/
2909 explicit_instantiation.cc: Likewise.
2910 * testsuite/30_threads/scoped_lock/requirements/typedefs.cc: Likewise.
2911 * testsuite/30_threads/shared_future/cons/assign.cc: Likewise.
2912 * testsuite/30_threads/shared_future/cons/constexpr.cc: Likewise.
2913 * testsuite/30_threads/shared_future/cons/copy.cc: Likewise.
2914 * testsuite/30_threads/shared_future/cons/default.cc: Likewise.
2915 * testsuite/30_threads/shared_future/cons/move.cc: Likewise.
2916 * testsuite/30_threads/shared_future/cons/move_assign.cc: Likewise.
2917 * testsuite/30_threads/shared_future/members/45133.cc: Likewise.
2918 * testsuite/30_threads/shared_future/members/get.cc: Likewise.
2919 * testsuite/30_threads/shared_future/members/get2.cc: Likewise.
2920 * testsuite/30_threads/shared_future/members/valid.cc: Likewise.
2921 * testsuite/30_threads/shared_future/members/wait.cc: Likewise.
2922 * testsuite/30_threads/shared_future/members/wait_for.cc: Likewise.
2923 * testsuite/30_threads/shared_future/members/wait_until.cc: Likewise.
2924 * testsuite/30_threads/shared_future/requirements/
2925 explicit_instantiation.cc: Likewise.
2926 * testsuite/30_threads/shared_lock/cons/1.cc: Likewise.
2927 * testsuite/30_threads/shared_lock/cons/2.cc: Likewise.
2928 * testsuite/30_threads/shared_lock/cons/3.cc: Likewise.
2929 * testsuite/30_threads/shared_lock/cons/4.cc: Likewise.
2930 * testsuite/30_threads/shared_lock/cons/5.cc: Likewise.
2931 * testsuite/30_threads/shared_lock/cons/6.cc: Likewise.
2932 * testsuite/30_threads/shared_lock/locking/1.cc: Likewise.
2933 * testsuite/30_threads/shared_lock/locking/2.cc: Likewise.
2934 * testsuite/30_threads/shared_lock/locking/3.cc: Likewise.
2935 * testsuite/30_threads/shared_lock/locking/4.cc: Likewise.
2936 * testsuite/30_threads/shared_lock/modifiers/1.cc: Likewise.
2937 * testsuite/30_threads/shared_lock/requirements/
2938 explicit_instantiation.cc: Likewise.
2939 * testsuite/30_threads/shared_lock/requirements/typedefs.cc: Likewise.
2940 * testsuite/30_threads/shared_mutex/cons/1.cc: Likewise.
2941 * testsuite/30_threads/shared_mutex/cons/assign_neg.cc: Likewise.
2942 * testsuite/30_threads/shared_mutex/cons/copy_neg.cc: Likewise.
2943 * testsuite/30_threads/shared_mutex/requirements/standard_layout.cc:
2944 Likewise.
2945 * testsuite/30_threads/shared_mutex/try_lock/1.cc: Likewise.
2946 * testsuite/30_threads/shared_mutex/try_lock/2.cc: Likewise.
2947 * testsuite/30_threads/shared_mutex/unlock/1.cc: Likewise.
2948 * testsuite/30_threads/shared_timed_mutex/cons/1.cc: Likewise.
2949 * testsuite/30_threads/shared_timed_mutex/cons/assign_neg.cc: Likewise.
2950 * testsuite/30_threads/shared_timed_mutex/cons/copy_neg.cc: Likewise.
2951 * testsuite/30_threads/shared_timed_mutex/requirements/
2952 standard_layout.cc: Likewise.
2953 * testsuite/30_threads/shared_timed_mutex/try_lock/1.cc: Likewise.
2954 * testsuite/30_threads/shared_timed_mutex/try_lock/2.cc: Likewise.
2955 * testsuite/30_threads/shared_timed_mutex/try_lock/3.cc: Likewise.
2956 * testsuite/30_threads/shared_timed_mutex/unlock/1.cc: Likewise.
2957 * testsuite/30_threads/this_thread/1.cc: Likewise.
2958 * testsuite/30_threads/this_thread/2.cc: Likewise.
2959 * testsuite/30_threads/this_thread/3.cc: Likewise.
2960 * testsuite/30_threads/this_thread/4.cc: Likewise.
2961 * testsuite/30_threads/this_thread/58038.cc: Likewise.
2962 * testsuite/30_threads/thread/70503.cc: Likewise.
2963 * testsuite/30_threads/thread/84532.cc: Likewise.
2964 * testsuite/30_threads/thread/adl.cc: Likewise.
2965 * testsuite/30_threads/thread/cons/1.cc: Likewise.
2966 * testsuite/30_threads/thread/cons/2.cc: Likewise.
2967 * testsuite/30_threads/thread/cons/3.cc: Likewise.
2968 * testsuite/30_threads/thread/cons/4.cc: Likewise.
2969 * testsuite/30_threads/thread/cons/49668.cc: Likewise.
2970 * testsuite/30_threads/thread/cons/5.cc: Likewise.
2971 * testsuite/30_threads/thread/cons/6.cc: Likewise.
2972 * testsuite/30_threads/thread/cons/7.cc: Likewise.
2973 * testsuite/30_threads/thread/cons/8.cc: Likewise.
2974 * testsuite/30_threads/thread/cons/84535.cc: Likewise.
2975 * testsuite/30_threads/thread/cons/9.cc: Likewise.
2976 * testsuite/30_threads/thread/cons/assign_neg.cc: Likewise.
2977 * testsuite/30_threads/thread/cons/copy_neg.cc: Likewise.
2978 * testsuite/30_threads/thread/cons/lwg2097.cc: Likewise.
2979 * testsuite/30_threads/thread/cons/moveable.cc: Likewise.
2980 * testsuite/30_threads/thread/cons/terminate.cc: Likewise.
2981 * testsuite/30_threads/thread/id/operators.cc: Likewise.
2982 * testsuite/30_threads/thread/members/1.cc: Likewise.
2983 * testsuite/30_threads/thread/members/2.cc: Likewise.
2984 * testsuite/30_threads/thread/members/3.cc: Likewise.
2985 * testsuite/30_threads/thread/members/4.cc: Likewise.
2986 * testsuite/30_threads/thread/members/5.cc: Likewise.
2987 * testsuite/30_threads/thread/members/hardware_concurrency.cc:
2988 Likewise.
2989 * testsuite/30_threads/thread/native_handle/cancel.cc: Likewise.
2990 * testsuite/30_threads/thread/swap/1.cc: Likewise.
2991 * testsuite/30_threads/timed_mutex/cons/1.cc: Likewise.
2992 * testsuite/30_threads/timed_mutex/cons/assign_neg.cc: Likewise.
2993 * testsuite/30_threads/timed_mutex/cons/copy_neg.cc: Likewise.
2994 * testsuite/30_threads/timed_mutex/dest/destructor_locked.cc: Likewise.
2995 * testsuite/30_threads/timed_mutex/lock/1.cc: Likewise.
2996 * testsuite/30_threads/timed_mutex/native_handle/1.cc: Likewise.
2997 * testsuite/30_threads/timed_mutex/native_handle/typesizes.cc:
2998 Likewise.
2999 * testsuite/30_threads/timed_mutex/requirements/
3000 standard_layout.cc: Likewise.
3001 * testsuite/30_threads/timed_mutex/requirements/typedefs.cc: Likewise.
3002 * testsuite/30_threads/timed_mutex/try_lock/1.cc: Likewise.
3003 * testsuite/30_threads/timed_mutex/try_lock/2.cc: Likewise.
3004 * testsuite/30_threads/timed_mutex/try_lock_for/1.cc: Likewise.
3005 * testsuite/30_threads/timed_mutex/try_lock_for/2.cc: Likewise.
3006 * testsuite/30_threads/timed_mutex/try_lock_for/3.cc: Likewise.
3007 * testsuite/30_threads/timed_mutex/try_lock_until/1.cc: Likewise.
3008 * testsuite/30_threads/timed_mutex/try_lock_until/2.cc: Likewise.
3009 * testsuite/30_threads/timed_mutex/try_lock_until/57641.cc: Likewise.
3010 * testsuite/30_threads/timed_mutex/unlock/1.cc: Likewise.
3011 * testsuite/30_threads/timed_mutex/unlock/2.cc: Likewise.
3012 * testsuite/30_threads/try_lock/1.cc: Likewise.
3013 * testsuite/30_threads/try_lock/2.cc: Likewise.
3014 * testsuite/30_threads/try_lock/3.cc: Likewise.
3015 * testsuite/30_threads/try_lock/4.cc: Likewise.
3016 * testsuite/30_threads/unique_lock/cons/1.cc: Likewise.
3017 * testsuite/30_threads/unique_lock/cons/2.cc: Likewise.
3018 * testsuite/30_threads/unique_lock/cons/3.cc: Likewise.
3019 * testsuite/30_threads/unique_lock/cons/4.cc: Likewise.
3020 * testsuite/30_threads/unique_lock/cons/5.cc: Likewise.
3021 * testsuite/30_threads/unique_lock/cons/6.cc: Likewise.
3022 * testsuite/30_threads/unique_lock/locking/1.cc: Likewise.
3023 * testsuite/30_threads/unique_lock/locking/2.cc: Likewise.
3024 * testsuite/30_threads/unique_lock/locking/3.cc: Likewise.
3025 * testsuite/30_threads/unique_lock/locking/4.cc: Likewise.
3026 * testsuite/30_threads/unique_lock/modifiers/1.cc: Likewise.
3027 * testsuite/30_threads/unique_lock/requirements/
3028 explicit_instantiation.cc: Likewise.
3029 * testsuite/30_threads/unique_lock/requirements/typedefs.cc: Likewise.
3030
3031 * testsuite/30_threads/async/42819.cc: Remove dg-require-cstdint
3032 directive.
3033 * testsuite/30_threads/async/49668.cc: Likewise.
3034 * testsuite/30_threads/async/54297.cc: Likewise.
3035 * testsuite/30_threads/async/84532.cc: Likewise.
3036 * testsuite/30_threads/async/any.cc: Likewise.
3037 * testsuite/30_threads/async/async.cc: Likewise.
3038 * testsuite/30_threads/async/except.cc: Likewise.
3039 * testsuite/30_threads/async/forced_unwind.cc: Likewise.
3040 * testsuite/30_threads/async/launch.cc: Likewise.
3041 * testsuite/30_threads/async/lwg2021.cc: Likewise.
3042 * testsuite/30_threads/async/sync.cc: Likewise.
3043 * testsuite/30_threads/call_once/39909.cc: Likewise.
3044 * testsuite/30_threads/call_once/49668.cc: Likewise.
3045 * testsuite/30_threads/call_once/60497.cc: Likewise.
3046 * testsuite/30_threads/call_once/call_once1.cc: Likewise.
3047 * testsuite/30_threads/call_once/constexpr.cc: Likewise.
3048 * testsuite/30_threads/call_once/dr2442.cc: Likewise.
3049 * testsuite/30_threads/call_once/once_flag.cc: Likewise.
3050 * testsuite/30_threads/condition_variable/54185.cc: Likewise.
3051 * testsuite/30_threads/condition_variable/cons/1.cc: Likewise.
3052 * testsuite/30_threads/condition_variable/cons/assign_neg.cc:
3053 Likewise.
3054 * testsuite/30_threads/condition_variable/cons/copy_neg.cc: Likewise.
3055 * testsuite/30_threads/condition_variable/members/1.cc: Likewise.
3056 * testsuite/30_threads/condition_variable/members/2.cc: Likewise.
3057 * testsuite/30_threads/condition_variable/members/3.cc: Likewise.
3058 * testsuite/30_threads/condition_variable/members/53841.cc: Likewise.
3059 * testsuite/30_threads/condition_variable/members/68519.cc: Likewise.
3060 * testsuite/30_threads/condition_variable/native_handle/typesizes.cc:
3061 Likewise.
3062 * testsuite/30_threads/condition_variable/requirements/
3063 standard_layout.cc: Likewise.
3064 * testsuite/30_threads/condition_variable/requirements/typedefs.cc:
3065 * Likewise.
3066 * testsuite/30_threads/condition_variable_any/50862.cc: Likewise.
3067 * testsuite/30_threads/condition_variable_any/53830.cc: Likewise.
3068 * testsuite/30_threads/condition_variable_any/cons/1.cc: Likewise.
3069 * testsuite/30_threads/condition_variable_any/cons/assign_neg.cc:
3070 Likewise.
3071 * testsuite/30_threads/condition_variable_any/cons/copy_neg.cc:
3072 Likewise.
3073 * testsuite/30_threads/condition_variable_any/members/1.cc: Likewise.
3074 * testsuite/30_threads/condition_variable_any/members/2.cc: Likewise.
3075 * testsuite/30_threads/future/cons/assign_neg.cc: Likewise.
3076 * testsuite/30_threads/future/cons/constexpr.cc: Likewise.
3077 * testsuite/30_threads/future/cons/copy_neg.cc: Likewise.
3078 * testsuite/30_threads/future/cons/default.cc: Likewise.
3079 * testsuite/30_threads/future/cons/move.cc: Likewise.
3080 * testsuite/30_threads/future/cons/move_assign.cc: Likewise.
3081 * testsuite/30_threads/future/members/45133.cc: Likewise.
3082 * testsuite/30_threads/future/members/get.cc: Likewise.
3083 * testsuite/30_threads/future/members/get2.cc: Likewise.
3084 * testsuite/30_threads/future/members/share.cc: Likewise.
3085 * testsuite/30_threads/future/members/valid.cc: Likewise.
3086 * testsuite/30_threads/future/members/wait.cc: Likewise.
3087 * testsuite/30_threads/future/members/wait_for.cc: Likewise.
3088 * testsuite/30_threads/future/members/wait_until.cc: Likewise.
3089 * testsuite/30_threads/future/requirements/explicit_instantiation.cc:
3090 Likewise.
3091 * testsuite/30_threads/headers/condition_variable/types_std_c++0x.cc:
3092 Likewise.
3093 * testsuite/30_threads/headers/future/types_std_c++0x.cc: Likewise.
3094 * testsuite/30_threads/headers/mutex/types_std_c++0x.cc: Likewise.
3095 * testsuite/30_threads/headers/thread/std_c++0x_neg.cc: Likewise.
3096 * testsuite/30_threads/headers/thread/types_std_c++0x.cc: Likewise.
3097 * testsuite/30_threads/lock/1.cc: Likewise.
3098 * testsuite/30_threads/lock/2.cc: Likewise.
3099 * testsuite/30_threads/lock/3.cc: Likewise.
3100 * testsuite/30_threads/lock/4.cc: Likewise.
3101 * testsuite/30_threads/lock_guard/cons/1.cc: Likewise.
3102 * testsuite/30_threads/lock_guard/requirements/
3103 explicit_instantiation.cc: Likewise.
3104 * testsuite/30_threads/lock_guard/requirements/typedefs.cc: Likewise.
3105 * testsuite/30_threads/mutex/cons/1.cc: Likewise.
3106 * testsuite/30_threads/mutex/cons/assign_neg.cc: Likewise.
3107 * testsuite/30_threads/mutex/cons/constexpr.cc: Likewise.
3108 * testsuite/30_threads/mutex/cons/copy_neg.cc: Likewise.
3109 * testsuite/30_threads/mutex/dest/destructor_locked.cc: Likewise.
3110 * testsuite/30_threads/mutex/lock/1.cc: Likewise.
3111 * testsuite/30_threads/mutex/native_handle/1.cc: Likewise.
3112 * testsuite/30_threads/mutex/native_handle/typesizes.cc: Likewise.
3113 * testsuite/30_threads/mutex/requirements/standard_layout.cc::
3114 Likewise.
3115 * testsuite/30_threads/mutex/requirements/typedefs.cc: Likewise.
3116 * testsuite/30_threads/mutex/try_lock/1.cc: Likewise.
3117 * testsuite/30_threads/mutex/try_lock/2.cc: Likewise.
3118 * testsuite/30_threads/mutex/unlock/1.cc: Likewise.
3119 * testsuite/30_threads/mutex/unlock/2.cc: Likewise.
3120 * testsuite/30_threads/once_flag/cons/constexpr.cc: Likewise.
3121 * testsuite/30_threads/packaged_task/49668.cc: Likewise.
3122 * testsuite/30_threads/packaged_task/60564.cc: Likewise.
3123 * testsuite/30_threads/packaged_task/cons/1.cc: Likewise.
3124 * testsuite/30_threads/packaged_task/cons/2.cc: Likewise.
3125 * testsuite/30_threads/packaged_task/cons/3.cc: Likewise.
3126 * testsuite/30_threads/packaged_task/cons/56492.cc: Likewise.
3127 * testsuite/30_threads/packaged_task/cons/alloc.cc: Likewise.
3128 * testsuite/30_threads/packaged_task/cons/alloc2.cc: Likewise.
3129 * testsuite/30_threads/packaged_task/cons/alloc_min.cc: Likewise.
3130 * testsuite/30_threads/packaged_task/cons/assign_neg.cc: Likewise.
3131 * testsuite/30_threads/packaged_task/cons/copy_neg.cc: Likewise.
3132 * testsuite/30_threads/packaged_task/cons/move.cc: Likewise.
3133 * testsuite/30_threads/packaged_task/cons/move_assign.cc: Likewise.
3134 * testsuite/30_threads/packaged_task/members/at_thread_exit.cc:
3135 Likewise.
3136 * testsuite/30_threads/packaged_task/members/get_future.cc: Likewise.
3137 * testsuite/30_threads/packaged_task/members/get_future2.cc: Likewise.
3138 * testsuite/30_threads/packaged_task/members/invoke.cc: Likewise.
3139 * testsuite/30_threads/packaged_task/members/invoke2.cc: Likewise.
3140 * testsuite/30_threads/packaged_task/members/invoke3.cc: Likewise.
3141 * testsuite/30_threads/packaged_task/members/invoke4.cc: Likewise.
3142 * testsuite/30_threads/packaged_task/members/invoke5.cc: Likewise.
3143 * testsuite/30_threads/packaged_task/members/reset.cc: Likewise.
3144 * testsuite/30_threads/packaged_task/members/reset2.cc: Likewise.
3145 * testsuite/30_threads/packaged_task/members/swap.cc: Likewise.
3146 * testsuite/30_threads/packaged_task/members/valid.cc: Likewise.
3147 * testsuite/30_threads/packaged_task/requirements/
3148 explicit_instantiation.cc: Likewise.
3149 * testsuite/30_threads/packaged_task/uses_allocator.cc: Likewise.
3150 * testsuite/30_threads/promise/60966.cc: Likewise.
3151 * testsuite/30_threads/promise/69106.cc: Likewise.
3152 * testsuite/30_threads/promise/cons/1.cc: Likewise.
3153 * testsuite/30_threads/promise/cons/alloc.cc: Likewise.
3154 * testsuite/30_threads/promise/cons/alloc2.cc: Likewise.
3155 * testsuite/30_threads/promise/cons/alloc_min.cc: Likewise.
3156 * testsuite/30_threads/promise/cons/assign_neg.cc: Likewise.
3157 * testsuite/30_threads/promise/cons/copy_neg.cc: Likewise.
3158 * testsuite/30_threads/promise/cons/move.cc: Likewise.
3159 * testsuite/30_threads/promise/cons/move_assign.cc: Likewise.
3160 * testsuite/30_threads/promise/members/at_thread_exit.cc: Likewise.
3161 * testsuite/30_threads/promise/members/at_thread_exit2.cc: Likewise.
3162 * testsuite/30_threads/promise/members/get_future.cc: Likewise.
3163 * testsuite/30_threads/promise/members/get_future2.cc: Likewise.
3164 * testsuite/30_threads/promise/members/set_exception.cc: Likewise.
3165 * testsuite/30_threads/promise/members/set_exception2.cc: Likewise.
3166 * testsuite/30_threads/promise/members/set_value.cc: Likewise.
3167 * testsuite/30_threads/promise/members/set_value2.cc: Likewise.
3168 * testsuite/30_threads/promise/members/set_value3.cc: Likewise.
3169 * testsuite/30_threads/promise/members/swap.cc: Likewise.
3170 * testsuite/30_threads/promise/requirements/explicit_instantiation.cc:
3171 * Likewise.
3172 * testsuite/30_threads/promise/uses_allocator.cc: Likewise.
3173
3174 * testsuite/18_support/numeric_limits/char16_32_t.cc: Qualify names
3175 from namespace std.
3176 * testsuite/20_util/align/2.cc: Remove dg-require-cstdint directive.
3177 * testsuite/20_util/duration/arithmetic/1.cc: Likewise.
3178 * testsuite/20_util/duration/arithmetic/2.cc: Likewise.
3179 * testsuite/20_util/duration/arithmetic/dr2020.cc: Likewise.
3180 * testsuite/20_util/duration/arithmetic/dr934-1.cc: Likewise.
3181 * testsuite/20_util/duration/arithmetic/dr934-2.cc: Likewise.
3182 * testsuite/20_util/duration/comparison_operators/1.cc: Likewise.
3183 * testsuite/20_util/duration/cons/1.cc: Likewise.
3184 * testsuite/20_util/duration/cons/1_neg.cc: Likewise.
3185 * testsuite/20_util/duration/cons/2.cc: Likewise.
3186 * testsuite/20_util/duration/cons/54025.cc: Likewise.
3187 * testsuite/20_util/duration/cons/dr974_neg.cc: Likewise.
3188 * testsuite/20_util/duration/requirements/explicit_instantiation/
3189 explicit_instantiation.cc: Likewise.
3190 * testsuite/20_util/duration/requirements/typedefs_neg1.cc: Likewise.
3191 * testsuite/20_util/duration/requirements/typedefs_neg2.cc: Likewise.
3192 * testsuite/20_util/duration/requirements/typedefs_neg3.cc: Likewise.
3193 * testsuite/20_util/make_signed/requirements/typedefs-4.cc: Likewise.
3194 * testsuite/20_util/ratio/comparisons/comp1.cc: Likewise.
3195 * testsuite/20_util/ratio/comparisons/comp2.cc: Likewise.
3196 * testsuite/20_util/ratio/comparisons/comp3.cc: Likewise.
3197 * testsuite/20_util/ratio/cons/cons1.cc: Likewise.
3198 * testsuite/20_util/ratio/operations/45866.cc: Likewise.
3199 * testsuite/20_util/ratio/operations/47913.cc: Likewise.
3200 * testsuite/20_util/ratio/operations/53840.cc: Likewise.
3201 * testsuite/20_util/ratio/operations/ops1.cc: Likewise.
3202 * testsuite/20_util/shared_ptr/atomic/3.cc: Likewise.
3203 * testsuite/20_util/system_clock/1.cc: Likewise.
3204 * testsuite/20_util/time_point/1.cc: Likewise.
3205 * testsuite/20_util/time_point/2.cc: Likewise.
3206 * testsuite/20_util/time_point/3.cc: Likewise.
3207 * testsuite/20_util/time_point/requirements/explicit_instantiation/
3208 explicit_instantiation.cc: Likewise.
3209 * testsuite/21_strings/basic_string/requirements/
3210 explicit_instantiation/char16_t/1.cc: Likewise.
3211 * testsuite/21_strings/basic_string/requirements/
3212 explicit_instantiation/char32_t/1.cc: Likewise.
3213 * testsuite/21_strings/basic_string_view/requirements/
3214 explicit_instantiation/char16_t/1.cc: Likewise.
3215 * testsuite/21_strings/basic_string_view/requirements/
3216 explicit_instantiation/char32_t/1.cc: Likewise.
3217 * testsuite/21_strings/char_traits/requirements/
3218 explicit_instantiation/char16_t/1.cc: Likewise.
3219 * testsuite/21_strings/char_traits/requirements/
3220 explicit_instantiation/char32_t/1.cc: Likewise.
3221 * testsuite/21_strings/headers/string/types_std_c++0x.cc: Likewise.
3222 * testsuite/22_locale/codecvt/char16_t.cc: Likewise.
3223 * testsuite/22_locale/codecvt/char32_t.cc: Likewise.
3224 * testsuite/22_locale/codecvt/codecvt_utf16/requirements/1.cc:
3225 Likewise.
3226 * testsuite/22_locale/codecvt/codecvt_utf8/requirements/1.cc:
3227 Likewise.
3228 * testsuite/22_locale/codecvt/codecvt_utf8_utf16/requirements/1.cc:
3229 Likewise.
3230 * testsuite/22_locale/codecvt/utf8.cc: Likewise.
3231 * testsuite/23_containers/vector/bool/72847.cc: Likewise.
3232 * testsuite/23_containers/vector/debug/multithreaded_swap.cc:
3233 Likewise.
3234 * testsuite/experimental/string_view/requirements/
3235 explicit_instantiation/char16_t/1.cc: Likewise.
3236 * testsuite/experimental/string_view/requirements/
3237 explicit_instantiation/char32_t/1.cc: Likewise.
3238 * testsuite/ext/vstring/requirements/explicit_instantiation/char16_t/
3239 1.cc: Likewise.
3240 * testsuite/ext/vstring/requirements/explicit_instantiation/char32_t/
3241 1.cc: Likewise.
3242
3243 * include/ext/throw_allocator.h [!_GLIBCXX_USE_C99_STDINT_TR1]
3244 (random_condition, throw_value_random, throw_allocator_random)
3245 (std::hash<throw_value_random>): Do not define when <tr1/random> is
3246 not usable.
3247 * src/c++11/cow-stdexcept.cc [!_GLIBCXX_USE_C99_STDINT_TR1]: Do not
3248 define transactional memory support when <stdint.h> is not usable.
3249
3250 * include/bits/hashtable_policy.h (__detail::__clp2): Use faster
3251 implementation that doesn't depend on <stdint.h> types.
3252 * include/std/memory (align) [!_GLIBCXX_USE_C99_STDINT_TR1]: Use
3253 std::size_t when std::uintptr_t is not usable.
3254 [!_GLIBCXX_USE_C99_STDINT_TR1] (pointer_safety, declare_reachable)
3255 (undeclare_reachable, declare_no_pointers, undeclare_no_pointers):
3256 Define independent of _GLIBCXX_USE_C99_STDINT_TR1.
3257
3258 * include/bits/basic_string.h [!_GLIBCXX_USE_C99_STDINT_TR1]
3259 (hash<u16string>, hash<u32string>): Remove dependency on
3260 _GLIBCXX_USE_C99_STDINT_TR1.
3261 * include/bits/char_traits.h [!_GLIBCXX_USE_C99_STDINT_TR1]
3262 (char_traits<char16_t>, char_traits<char32_t>): Remove dependency on
3263 _GLIBCXX_USE_C99_STDINT_TR1. Use __UINT_LEAST16_TYPE__ and
3264 __UINT_LEAST32_TYPE__ or make_unsigned when <stdint.h> is not usable.
3265 * include/bits/codecvt.h [!_GLIBCXX_USE_C99_STDINT_TR1]
3266 (codecvt<char16_t, char, mbstate_t>)
3267 (codecvt<char32_t, char, mbstate_t>)
3268 (codecvt_byname<char16_t, char, mbstate_t>)
3269 (codecvt_byname<char32_t, char, mbstate_t>): Remove dependency
3270 on _GLIBCXX_USE_C99_STDINT_TR1.
3271 * include/bits/locale_facets.h [!_GLIBCXX_USE_C99_STDINT_TR1]
3272 (_GLIBCXX_NUM_UNICODE_FACETS): Likewise.
3273 * include/bits/stringfwd.h [!_GLIBCXX_USE_C99_STDINT_TR1]
3274 (char_traits<char16_t>, char_traits<char32_t>)
3275 (basic_string<char16_t>, basic_string<char32_t>): Remove dependency
3276 on _GLIBCXX_USE_C99_STDINT_TR1.
3277 * include/experimental/string_view [!_GLIBCXX_USE_C99_STDINT_TR1]
3278 (u16string_view, u32string_view, hash<u16string_view>)
3279 (hash<u32string_view>, operator""sv(const char16_t, size_t))
3280 (operator""sv(const char32_t, size_t)): Likewise.
3281 * include/ext/vstring.h [!_GLIBCXX_USE_C99_STDINT_TR1]
3282 (hash<__u16vstring>, hash<__u32vstring>): Likewise.
3283 * include/ext/vstring_fwd.h [!_GLIBCXX_USE_C99_STDINT_TR1]
3284 (__u16vstring, __u16sso_string, __u16rc_string, __u32vstring)
3285 (__u32sso_string, __u32rc_string): Likewise.
3286 * include/std/codecvt [!_GLIBCXX_USE_C99_STDINT_TR1] (codecvt_mode)
3287 (codecvt_utf8, codecvt_utf16, codecvt_utf8_utf16): Likewise.
3288 * include/std/string_view [!_GLIBCXX_USE_C99_STDINT_TR1]
3289 (u16string_view, u32string_view, hash<u16string_view>)
3290 (hash<u32string_view>, operator""sv(const char16_t, size_t))
3291 (operator""sv(const char32_t, size_t)): Likewise.
3292 * src/c++11/codecvt.cc: Likewise.
3293 * src/c++98/locale_init.cc: Likewise.
3294 * src/c++98/localename.cc: Likewise.
3295
3296 * include/bits/atomic_futex.h [!_GLIBCXX_USE_C99_STDINT_TR1]
3297 (__atomic_futex_unsigned_base): Remove dependency on
3298 _GLIBCXX_USE_C99_STDINT_TR1 macro.
3299 * include/bits/unique_lock.h [!_GLIBCXX_USE_C99_STDINT_TR1]
3300 (unique_lock): Remove dependency on _GLIBCXX_USE_C99_STDINT_TR1.
3301 * include/c_global/cstdint [!_GLIBCXX_USE_C99_STDINT_TR1] (intmax_t)
3302 (uintmax_t): Define using predefined macros.
3303 * include/std/chrono [!_GLIBCXX_USE_C99_STDINT_TR1] (duration)
3304 (time_point, system_clock, high_resolution_clock, steady_clock): Remove
3305 dependency on _GLIBCXX_USE_C99_STDINT_TR1 macro.
3306 (nanoseconds, microseconds, milliseconds, seconds, minutes, hours):
3307 [!_GLIBCXX_USE_C99_STDINT_TR1]: Define using __INT64_TYPE__ or
3308 long long when <stdint.h> is not usable.
3309 * include/std/condition_variable [!_GLIBCXX_USE_C99_STDINT_TR1]
3310 (condition_variable, condition_variable_any): Remove dependency on
3311 _GLIBCXX_USE_C99_STDINT_TR1.
3312 * include/std/future [!_GLIBCXX_USE_C99_STDINT_TR1] (future, promise)
3313 (packaged_task, async): Likewise.
3314 * include/std/mutex [!_GLIBCXX_USE_C99_STDINT_TR1] (recursive_mutex)
3315 (timed_mutex, recursive_timed_mutex, try_lock, lock, scoped_lock)
3316 (once_flag, call_once): Likewise.
3317 * include/std/ratio [!_GLIBCXX_USE_C99_STDINT_TR1] (ratio): Likewise.
3318 * include/std/shared_mutex [!_GLIBCXX_USE_C99_STDINT_TR1]
3319 (shared_mutex, shared_timed_mutex, shared_lock): Likewise.
3320 * include/std/thread [!_GLIBCXX_USE_C99_STDINT_TR1] (thread)
3321 (this_thread::get_id, this_thread::yield, this_thread::sleep_for)
3322 (this_thread::sleep_until): Likewise.
3323 * src/c++11/chrono.cc: Remove dependency on
3324 _GLIBCXX_USE_C99_STDINT_TR1 macro.
3325 * src/c++11/condition_variable.cc: Likewise.
3326 * src/c++11/futex.cc: Likewise.
3327 * src/c++11/future.cc: Likewise.
3328 * src/c++11/mutex.cc: Likewise.
3329 * src/c++11/thread.cc: Likewise.
3330 * testsuite/20_util/duration/literals/range_neg.cc: Adjust dg-error.
3331 * testsuite/20_util/duration/requirements/typedefs_neg1.cc: Likewise.
3332 * testsuite/20_util/duration/requirements/typedefs_neg2.cc: Likewise.
3333 * testsuite/20_util/duration/requirements/typedefs_neg3.cc: Likewise.
3334 * testsuite/20_util/ratio/cons/cons_overflow_neg.cc: Likewise.
3335 * testsuite/20_util/ratio/operations/ops_overflow_neg.cc: Likewise.
3336
3337 2018-07-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3338
3339 PR libstdc++/77691
3340 * testsuite/experimental/memory_resource/new_delete_resource.cc:
3341 xfail execution on 32-bit Solaris/x86.
3342
3343 2018-07-26 Marc Glisse <marc.glisse@inria.fr>
3344
3345 * include/bits/stl_vector.h (_Vector_impl_data::_M_copy_data): New.
3346 (_Vector_impl_data::_M_swap_data): Use _M_copy_data.
3347 (vector::_M_move_assign): Reorder the swaps.
3348
3349 2018-07-26 Jonathan Wakely <jwakely@redhat.com>
3350
3351 PR libstdc++/86676
3352 * testsuite/20_util/monotonic_buffer_resource/release.cc: Request
3353 same alignment for post-release allocation.
3354
3355 2018-07-25 Jonathan Wakely <jwakely@redhat.com>
3356
3357 PR libstdc++/86676
3358 * testsuite/20_util/monotonic_buffer_resource/release.cc: Allow for
3359 buffer being misaligned and so returned pointer not being at start.
3360
3361 * include/experimental/memory_resource: Include <cstddef> header.
3362
3363 * acinclude.m4 (glibcxx_SUBDIRS): Add src/c++17.
3364 * src/Makefile.am: Add comment.
3365 * src/c++17/Makefile.in: Regenerate.
3366
3367 * include/Makefile.am: Add new <bits/unique_lock.h> header.
3368 * include/Makefile.in: Regenerate.
3369 * include/bits/std_mutex.h [!_GLIBCXX_USE_C99_STDINT_TR1] (mutex)
3370 (lock_guard): Define independent of _GLIBCXX_USE_C99_STDINT_TR1.
3371 (unique_lock): Move definition to ...
3372 * include/bits/unique_lock.h: New header.
3373 [!_GLIBCXX_USE_C99_STDINT_TR1] (unique_lock): Define unconditionally.
3374 [_GLIBCXX_USE_C99_STDINT_TR1] (unique_lock(mutex_type&, time_point))
3375 (unique_lock(mutex_type&, duration), unique_lock::try_lock_until)
3376 (unique_lock::try_lock_for): Define only when <chrono> is usable.
3377 * include/std/condition_variable: Include <bits/unique_lock.h>.
3378 * include/std/mutex: Likewise.
3379
3380 2018-07-24 Jonathan Wakely <jwakely@redhat.com>
3381
3382 * config/abi/pre/gnu.ver: Export new symbols.
3383 * configure: Regenerate.
3384 * include/Makefile.am: Add new <memory_resource> header.
3385 * include/Makefile.in: Regenerate.
3386 * include/precompiled/stdc++.h: Include <memory_resource> for C++17.
3387 * include/std/memory_resource: New header.
3388 (memory_resource, polymorphic_allocator, new_delete_resource)
3389 (null_memory_resource, set_default_resource, get_default_resource)
3390 (pool_options, monotonic_buffer_resource): Define.
3391 * src/Makefile.am: Add c++17 directory.
3392 * src/Makefile.in: Regenerate.
3393 * src/c++11/Makefile.am: Fix comment.
3394 * src/c++17/Makefile.am: Add makefile for new sub-directory.
3395 * src/c++17/Makefile.in: Generate.
3396 * src/c++17/memory_resource.cc: New.
3397 (newdel_res_t, null_res_t, constant_init, newdel_res, null_res)
3398 (default_res, new_delete_resource, null_memory_resource)
3399 (set_default_resource, get_default_resource): Define.
3400 * testsuite/20_util/memory_resource/1.cc: New test.
3401 * testsuite/20_util/memory_resource/2.cc: New test.
3402 * testsuite/20_util/monotonic_buffer_resource/1.cc: New test.
3403 * testsuite/20_util/monotonic_buffer_resource/allocate.cc: New test.
3404 * testsuite/20_util/monotonic_buffer_resource/deallocate.cc: New test.
3405 * testsuite/20_util/monotonic_buffer_resource/release.cc: New test.
3406 * testsuite/20_util/monotonic_buffer_resource/upstream_resource.cc:
3407 New test.
3408 * testsuite/20_util/polymorphic_allocator/1.cc: New test.
3409 * testsuite/20_util/polymorphic_allocator/resource.cc: New test.
3410 * testsuite/20_util/polymorphic_allocator/select.cc: New test.
3411 * testsuite/util/testsuite_allocator.h (__gnu_test::memory_resource):
3412 Define concrete memory resource for testing.
3413 (__gnu_test::default_resource_mgr): Define RAII helper for changing
3414 default resource.
3415
3416 PR libstdc++/86658
3417 * include/bits/stl_algobase.h (__niter_wrap<_Iterator>): Pass unused
3418 parameter by reference, to avoid copying invalid iterators.
3419 * testsuite/25_algorithms/copy/86658.cc: New test.
3420
3421 * include/std/bit (__countl_zero, __countr_zero, __popcount): Use
3422 local variables for number of digits instead of type aliases.
3423 (__log2p1): Remove redundant branch also checked in __countl_zero.
3424
3425 * include/bits/uses_allocator.h (__is_erased_or_convertible): Reorder
3426 conditions. Add comments.
3427 * testsuite/20_util/uses_allocator/69293_neg.cc: Adjust dg-error line.
3428 * testsuite/20_util/uses_allocator/cons_neg.cc: Likewise.
3429 * testsuite/20_util/scoped_allocator/69293_neg.cc: Likewise.
3430
3431 * include/bits/uses_allocator.h (__is_erased_or_convertible): Remove.
3432 (__uses_allocator_helper): Check conditions directly instead of
3433 using __is_erased_or_convertible.
3434
3435 * include/experimental/memory_resource: Adjust comments and
3436 whitespace.
3437 (__resource_adaptor_imp): Add second template parameter for type of
3438 memory resource base class.
3439 (memory_resource): Define default constructor, destructor, copy
3440 constructor and copy assignment operator as defaulted.
3441
3442 PR libstdc++/70966
3443 * include/experimental/memory_resource (__get_default_resource): Use
3444 placement new to create an object with dynamic storage duration.
3445
3446 2018-07-23 Jonathan Wakely <jwakely@redhat.com>
3447
3448 PR libstdc++/70940
3449 * include/experimental/memory_resource
3450 (__resource_adaptor_common::_AlignMgr::_M_unadjust): Add assertion.
3451 (__resource_adaptor_common::__guaranteed_alignment): New helper to
3452 give maximum alignment an allocator guarantees. Specialize for known
3453 allocators using new and malloc.
3454 (__resource_adaptor_imp::do_allocate): Use __guaranteed_alignment.
3455 (__resource_adaptor_imp::do_deallocate): Likewise.
3456 * testsuite/experimental/memory_resource/new_delete_resource.cc:
3457 Check that new and delete are called with expected sizes.
3458
3459 2018-07-20 Jonathan Wakely <jwakely@redhat.com>
3460
3461 PR libstdc++/86595
3462 * include/bits/fs_dir.h (directory_entry::refresh(error_code&)): Add
3463 noexcept.
3464
3465 2018-07-20 Fangrui Song <maskray@google.com>
3466
3467 * include/bits/shared_ptr_base.h (_Sp_make_shared_tag::_S_ti): Use
3468 _GLIBCXX_VISIBILITY(default).
3469
3470 2018-07-20 Jonathan Wakely <jwakely@redhat.com>
3471
3472 PR libstdc++/86603
3473 * include/std/version: Move __cpp_lib_list_remove_return_type macro.
3474
3475 2018-07-19 Jonathan Wakely <jwakely@redhat.com>
3476
3477 * include/std/type_traits (__is_member_object_pointer_helper): Use
3478 __not_<is_function<_Tp>>::type instead of integral_constant.
3479 (__is_member_function_pointer_helper): Likewise for
3480 is_function<_Tp>::type.
3481 (is_compund): Likewise for __not_<is_fundamental<_Tp>>::type.
3482 (__do_is_nt_destructible_impl): Use __bool_constant and reindent.
3483 (is_trivially_constructible): Remove redundant use of
3484 is_constructible.
3485 (__is_trivially_copy_assignable_impl): Remove redundant use of
3486 is_copy_assignable.
3487 (__is_trivially_move_assignable_impl): Remove redundant use of
3488 is_move_assignable.
3489 (is_trivially_destructible): Use __bool_constant.
3490 * testsuite/20_util/is_trivially_assignable/value.cc: Add some more
3491 tests for scalar types.
3492
3493 2018-07-19 Glen Joseph Fernandes <glenjofe@gmail.com>
3494
3495 * include/bits/stl_algobase.h (__copy_move_a): Used
3496 __is_trivially_copyable.
3497 (__copy_move_backward_a): Likewise.
3498 * testsuite/20_util/specialized_algorithms/uninitialized_copy/1.cc:
3499 New test.
3500
3501 2018-07-17 Jonathan Wakely <jwakely@redhat.com>
3502
3503 PR libstdc++/86450
3504 * acinclude.m4 (GLIBCXX_CHECK_COMPILER_FEATURES): Don't define WERROR.
3505 (GLIBCXX_EXPORT_FLAGS): Use -Wabi=2 instead of -Wabi.
3506 * configure: Regenerate.
3507 * configure.ac: Change GLIBCXX_ENABLE_WERROR default to "no".
3508 * doc/Makefile.in: Regenerate.
3509 * fragment.am: Set WERROR_FLAG to -Werror instead of $(WERROR).
3510 * include/Makefile.in: Regenerate.
3511 * libsupc++/Makefile.in: Regenerate.
3512 * po/Makefile.in: Regenerate.
3513 * python/Makefile.in: Regenerate.
3514 * src/Makefile.in: Regenerate.
3515 * src/c++11/Makefile.in: Regenerate.
3516 * src/c++11/debug.cc: Use diagnostic pragmas to suppress warnings
3517 from -Wabi=2 that don't affect exported symbols.
3518 * src/c++98/Makefile.in: Regenerate.
3519 * src/filesystem/Makefile.in: Regenerate.
3520 * testsuite/Makefile.in: Regenerate.
3521
3522 * src/c++11/compatibility-thread-c++0x.cc [_GLIBCXX_SHARED]
3523 (_Async_state_common::_M_join): Simplify use of std::call_once and
3524 corresponding explicit instantiation.
3525 (_Maybe_wrap_member_pointer, _Bind_simple, _Bind_simple_helper)
3526 (__bind_simple): Remove definitions and explicit instantiation that
3527 are not required by exported symbols.
3528
3529 2018-07-16 Jonathan Wakely <jwakely@redhat.com>
3530
3531 * scripts/create_testsuite_files: Fix typo in comment.
3532
3533 PR libstdc++/86537
3534 * include/bits/shared_ptr.h (less<shared_ptr<_Tp>>): Remove
3535 non-standard partial specialization.
3536 * include/bits/shared_ptr_base.h (_Sp_less): Remove class definition.
3537 (less<__shared_ptr<_Tp, _Lp>): Remove partial specialization.
3538 * testsuite/20_util/shared_ptr/comparison/86537.cc: New test.
3539
3540 2018-07-16 Andreas Krebbel <krebbel@linux.ibm.com>
3541
3542 * config/abi/post/s390-linux-gnu/baseline_symbols.txt: Update.
3543 * config/abi/post/s390x-linux-gnu/32/baseline_symbols.txt: Update.
3544 * config/abi/post/s390x-linux-gnu/baseline_symbols.txt: Update.
3545
3546 2018-07-06 François Dumont <fdumont@gcc.gnu.org>
3547
3548 * include/debug/functions.h (__gnu_debug::__check_string): Move...
3549 * include/debug/string (__gnu_debug::__check_string): ... here.
3550 (_GLIBCXX_DEBUG_VERIFY_STR_COND_AT): New.
3551 (__glibcxx_check_string_n_constructor): New.
3552 (__gnu_debug::basic_string<>(const _CharT*, size_type, const _Alloc&)):
3553 Use latter.
3554 (__glibcxx_check_string_constructor): New.
3555 (__gnu_debug::basic_string<>(const _CharT*, const _Alloc&)):
3556 Use latter.
3557 * testsuite/21_strings/basic_string/debug/1_neg.cc: New.
3558 * testsuite/21_strings/basic_string/debug/2_neg.cc: New.
3559
3560 2018-07-06 Jonathan Wakely <jwakely@redhat.com>
3561
3562 PR libstdc++/84928 use std::move in <numeric> algorithms
3563 * include/bits/stl_numeric.h (_GLIBCXX_MOVE_IF_20): Define macro to
3564 conditionally move, according to __cplusplus value.
3565 (accumulate, inner_product, partial_sum, adjacent_difference): Use
3566 _GLIBCXX_MOVE_IF_20.
3567 * testsuite/26_numerics/accumulate/lwg2055.cc: New test.
3568 * testsuite/26_numerics/adjacent_difference/lwg2055.cc: New test.
3569 * testsuite/26_numerics/inner_product/lwg2055.cc: New test.
3570 * testsuite/26_numerics/partial_sum/lwg2055.cc: New test.
3571
3572 * config/abi/pre/gnu.ver: Use wildcards to combine related patterns.
3573
3574 P0935R0 Eradicating unnecessarily explicit default constructors
3575 * config/abi/pre/gnu.ver: Tighten existing patterns and export new
3576 default constructor symbols.
3577 * include/std/sstream (basic_stringbuf, basic_istringstream)
3578 (basic_ostringstream, basic_stringstream): Remove default arguments
3579 from explicit constructors taking ios_base::openmode and add separate
3580 non-explicit default constructors.
3581 * testsuite/27_io/basic_istringstream/cons/default.cc: New.
3582 * testsuite/27_io/basic_ostringstream/cons/default.cc: New.
3583 * testsuite/27_io/basic_stringstream/cons/default.cc: New.
3584 * testsuite/27_io/basic_stringbuf/cons/char/default.cc: New.
3585 * testsuite/27_io/basic_stringbuf/cons/wchar_t/default.cc: New.
3586
3587 * include/std/variant (__accepted_index): Use void_t.
3588
3589 2018-07-05 Jonathan Wakely <jwakely@redhat.com>
3590
3591 PR libstdc++/85831
3592 * config/abi/pre/gnu.ver: Export move constructors and move
3593 assignment operators for std::logic_error and std::runtime_error.
3594 * include/std/stdexcept: Use _GLIBCXX_NOTHROW instead of
3595 _GLIBCXX_USE_NOEXCEPT.
3596 (logic_error, runtime_error): Declare move constructors and move
3597 assignment operators. When not declared already, define copy
3598 constructors and copy assignment operators as explicit-defaulted.
3599 (domain_error, invalid_argument, length_error, out_of_range)
3600 (overflow_error, underflow_error): Define move constructors and move
3601 assignment operators as explicitly-defaulted.
3602 * libsupc++/exception.h (exception): Likewise.
3603 * src/c++11/cow-stdexcept.cc (logic_error, runtime_error): Define
3604 move constructors and move assignment operators as defaulted.
3605 * testsuite/19_diagnostics/stdexcept.cc: Check that constructors and
3606 assignment operators are defined.
3607
3608 * testsuite/21_strings/basic_string/cons/char/deduction.cc: XFAIL for
3609 COW strings.
3610 * testsuite/21_strings/basic_string/cons/wchar_t/deduction.cc:
3611 Likewise.
3612 * testsuite/21_strings/basic_string/requirements/
3613 explicit_instantiation/debug.cc: Likewise.
3614
3615 PR libstdc++/58265
3616 * include/bits/basic_string.h [!_GLIBCXX_USE_CXX11_ABI]
3617 (basic_string::assign(basic_string&&)): Add conditional noexcept
3618 depending on the allocator's is_always_equal property (LWG 2063).
3619 * testsuite/21_strings/basic_string/modifiers/assign/char/
3620 move_assign.cc: Check for non-throwing exception specification.
3621 * testsuite/21_strings/basic_string/modifiers/assign/wchar_t/
3622 move_assign.cc: Likewise.
3623
3624 PR libstdc++/58265
3625 * include/bits/basic_string.h [!_GLIBCXX_USE_CXX11_ABI]
3626 [_GLIBCXX_FULLY_DYNAMIC_STRING==0] (basic_string::basic_string()):
3627 Add GLIBCXX_NOEXCEPT.
3628 (basic_string::operator=(basic_string&&)): Add _GLIBCXX_NOEXCEPT_IF
3629 to depend on the allocator's is_always_equal property (LWG 2063).
3630 (basic_string::swap(basic_string&)): Likewise.
3631 * include/bits/basic_string.tcc [!_GLIBCXX_USE_CXX11_ABI]
3632 (basic_string::swap(basic_string&)): Likewise.
3633 * testsuite/21_strings/basic_string/allocator/char/move_assign.cc:
3634 Check is_nothrow_move_assignable.
3635 * testsuite/21_strings/basic_string/allocator/wchar_t/move_assign.cc:
3636 Check is_nothrow_move_assignable.
3637 * testsuite/21_strings/basic_string/cons/char/
3638 noexcept_move_construct.cc: Likewise.
3639 * testsuite/21_strings/basic_string/cons/wchar_t/
3640 noexcept_move_construct.cc: Likewise.
3641
3642 2018-07-04 Jonathan Wakely <jwakely@redhat.com>
3643
3644 P0646R1 Improving the Return Value of Erase-Like Algorithms I
3645 * include/bits/forward_list.h (__cpp_lib_list_remove_return_type):
3646 Define.
3647 (forward_list::__remove_return_type): Define typedef as size_type or
3648 void, according to __cplusplus value.
3649 (_GLIBCXX_FWDLIST_REMOVE_RETURN_TYPE_TAG): Define macro as abi-tag or
3650 empty, according to __cplusplus value.
3651 (forward_list::remove, forward_list::unique): Use typedef and macro
3652 to change return type and add abi-tag for C++2a.
3653 (forward_list::remove_if<Pred>, forward_list::unique<BinPred>): Use
3654 typedef to change return type for C++2a.
3655 * include/bits/forward_list.tcc (_GLIBCXX20_ONLY): Define macro.
3656 (forward_list::remove, forward_list::remove_if<Pred>)
3657 (forward_list::unique<BinPred>): Return number of removed elements
3658 for C++2a.
3659 * include/bits/list.tcc (_GLIBCXX20_ONLY): Define macro.
3660 (list::remove, list::unique, list::remove_if<Predicate>)
3661 (list::unique<BinaryPredicate>): Return number of removed elements
3662 for C++2a.
3663 * include/bits/stl_list.h (__cpp_lib_list_remove_return_type): Define.
3664 (list::__remove_return_type): Define typedef as size_type or
3665 void, according to __cplusplus value.
3666 (_GLIBCXX_LIST_REMOVE_RETURN_TYPE_TAG): Define macro as abi-tag or
3667 empty, according to __cplusplus value.
3668 (list::remove, list::unique): Use typedef and macro to change return
3669 type and add abi-tag for C++2a.
3670 (list::remove_if<Predicate>, list::unique<BinaryPredicate>): Use
3671 typedef to change return type for C++2a.
3672 * include/std/version (__cpp_lib_list_remove_return_type): Define.
3673 * testsuite/23_containers/forward_list/operations/
3674 remove_cxx20_return.cc: New.
3675 * testsuite/23_containers/forward_list/operations/
3676 unique_cxx20_return.cc: New.
3677
3678 P0458R2 Checking for Existence of an Element in Associative Containers
3679 * include/bits/stl_map.h (map::contains): Add for C++2a.
3680 * include/bits/stl_multimap.h (multimap::contains): Likewise.
3681 * include/bits/stl_multiset.h (multiset::contains): Likewise.
3682 * include/bits/stl_set.h (set::contains): Likewise.
3683 * include/bits/stl_tree.h (__has_is_transparent_t): Define alias.
3684 (_Rb_tree::_M_find_tr, _Rb_tree::_M_count_tr)
3685 (_Rb_tree::_M_lower_bound_tr, _Rb_tree::_M_upper_bound_tr)
3686 (_Rb_tree::_M_equal_range_tr): Use __has_is_transparent_t.
3687 * include/bits/unordered_map.h (unordered_map::contains)
3688 (unordered_multimap::contains): Add for C++2a.
3689 * include/bits/unordered_set.h (unordered_set::contains)
3690 (unordered_multiset::contains): Likewise.
3691 * testsuite/23_containers/map/operations/contains.cc: New.
3692 * testsuite/23_containers/multimap/operations/contains.cc: New.
3693 * testsuite/23_containers/multiset/operations/contains.cc: New.
3694 * testsuite/23_containers/set/operations/contains.cc: New.
3695 * testsuite/23_containers/unordered_map/operations/contains.cc: New.
3696 * testsuite/23_containers/unordered_multimap/operations/contains.cc:
3697 New.
3698 * testsuite/23_containers/unordered_multiset/operations/contains.cc:
3699 New.
3700 * testsuite/23_containers/unordered_set/operations/contains.cc: New.
3701
3702 2018-07-04 François Dumont <fdumont@gcc.gnu.org>
3703
3704 PR libstdc++/86272
3705 * include/debug/string
3706 (__gnu_debug::basic_string<>::insert<_Ite>(const_iterator, _Ite, _Ite)):
3707 Use __glibcxx_check_insert_range.
3708 * 21_strings/basic_string/cons/char/1.cc: Adapt test to use
3709 __gnu_debug::string when _GLIBCXX_DEBUG.
3710 * 21_strings/basic_string/init-list.cc: Likewise.
3711 * 21_strings/basic_string/modifiers/insert/char/1.cc: Likewise.
3712 * 21_strings/basic_string/modifiers/insert/char/2.cc: Likewise.
3713 * 21_strings/basic_string/modifiers/insert/char/83328.cc: Likewise.
3714 * 21_strings/basic_string/types/1.cc: Likewise.
3715
3716 2018-07-04 Jonathan Wakely <jwakely@redhat.com>
3717
3718 * testsuite/25_algorithms/make_heap/complexity.cc: Require effective
3719 target for std::random_device.
3720 * testsuite/26_numerics/random/random_device/cons/default.cc:
3721 Likewise.
3722 * testsuite/experimental/algorithm/sample-2.cc: Likewise.
3723 * testsuite/experimental/algorithm/shuffle.cc: Likewise.
3724 * testsuite/experimental/random/randint.cc: Likewise.
3725 * testsuite/lib/libstdc++.exp
3726 (check_effective_target_random_device): New proc.
3727
3728 2018-07-04 Jonathan Wakely <jwakely@redhat.com>
3729 Jakub Jelinek <jakub@redhat.com>
3730
3731 * include/std/bit (__rotl, __rotr): Fix for non-power of two sizes.
3732
3733 2018-07-04 Jonathan Wakely <jwakely@redhat.com>
3734
3735 PR libstdc++/86398
3736 * include/std/type_traits (is_trivially_constructible): Check
3737 is_constructible before __is_trivially_constructible.
3738 * testsuite/20_util/is_trivially_constructible/value.cc: Add more
3739 tests, including negative cases.
3740 * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Use
3741 zero for dg-error lineno.
3742 * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc:
3743 Likewise.
3744
3745 * include/std/bit (__rotl, __rotr): Avoid branch.
3746 (_If_is_unsigned_integer): Use remove_cv_t.
3747 * testsuite/26_numerics/bit/bitops.count/popcount.cc: New.
3748
3749 2018-07-03 Jonathan Wakely <jwakely@redhat.com>
3750
3751 P0556R3 Integral power-of-2 operations, P0553R2 Bit operations
3752 * include/Makefile.am: Add new header.
3753 * include/Makefile.in: Regenerate.
3754 * include/precompiled/stdc++.h: Include new header.
3755 * include/std/bit: New header.
3756 (__rotl, __rotr, __countl_zero, __countl_one, __countr_zero)
3757 (__countr_one, __popcount, __ispow2, __ceil2, __floor2, __log2p1):
3758 Define for C++14.
3759 [!__STRICT_ANSI__] (rotl, rotr, countl_zero, countl_one, countr_zero)
3760 (countr_one, popcount): Define for C++2a. Also overload for std::byte.
3761 (ispow2, ceil2, floor2, log2p1): Define for C++2a.
3762 [!__STRICT_ANSI__] (ispow2, ceil2, floor2, log2p1): Overload for
3763 std::byte.
3764 * testsuite/26_numerics/bit/bit.pow.two/ceil2.cc: New.
3765 * testsuite/26_numerics/bit/bit.pow.two/floor2.cc: New.
3766 * testsuite/26_numerics/bit/bit.pow.two/ispow2.cc: New.
3767 * testsuite/26_numerics/bit/bit.pow.two/log2p1.cc: New.
3768 * testsuite/26_numerics/bit/bitops.rot/rotl.cc: New.
3769 * testsuite/26_numerics/bit/bitops.rot/rotr.cc: New.
3770 * testsuite/26_numerics/bit/bitops.count/countl_one.cc: New.
3771 * testsuite/26_numerics/bit/bitops.count/countl_zero.cc: New.
3772 * testsuite/26_numerics/bit/bitops.count/countr_one.cc: New.
3773 * testsuite/26_numerics/bit/bitops.count/countr_zero.cc: New.
3774
3775 * include/bits/alloc_traits.h: Remove redundant preprocessor
3776 condition.
3777
3778 2018-07-03 François Dumont <fdumont@gcc.gnu.org>
3779
3780 * include/bits/stl_algobase.h (__niter_wrap): New.
3781 (__copy_move_a2(_II, _II, _OI)): Use latter.
3782 (__copy_move_backward_a2(_BI1, _BI1, _BI2)): Likewise.
3783 (fill_n(_OI, _Size, const _Tp&)): Likewise.
3784 (equal(_II1, _II1, _II2)): Use __glibcxx_requires_can_increment.
3785 * include/debug/stl_iterator.h
3786 (std::__niter_base(const __gnu_cxx::_Safe_iterator<
3787 __gnu_cxx::__normal_iterator<>, _Sequence>&)): New declaration.
3788 * include/debug/vector (__niter_base(const __gnu_cxx::_Safe_iterator<
3789 __gnu_cxx::__normal_iterator<>, _Sequence>&)): New.
3790
3791 2018-07-02 Jonathan Wakely <jwakely@redhat.com>
3792
3793 P0758R1 Implicit conversion traits
3794 * include/std/type_traits [__cplusplus > 201703]
3795 (__is_convertible_helper::__is_nothrow_type): Define new member.
3796 (__is_convertible_helper<_From, _To, false>::__test_aux1): Add
3797 noexcept.
3798 (__is_convertible_helper<_From, _To, false>::__test_nothrow)
3799 (__is_convertible_helper<_From, _To, false>::__is_nothrow_type): Add
3800 new members.
3801 (is_nothrow_convertible, is_nothrow_convertible_v): Define for C++2a.
3802 * testsuite/20_util/is_nothrow_convertible/value.cc: New.
3803 * testsuite/20_util/is_nothrow_convertible/requirements/
3804 explicit_instantiation.cc: New.
3805 * testsuite/20_util/is_nothrow_convertible/requirements/typedefs.cc:
3806 New.
3807
3808 P0887R1 The identity metafunction
3809 * include/std/type_traits (type_identity, type_identity_t): Define
3810 for C++2a.
3811 * testsuite/20_util/type_identity/requirements/alias_decl.cc: New.
3812 * testsuite/20_util/type_identity/requirements/
3813 explicit_instantiation.cc:New.
3814 * testsuite/20_util/type_identity/requirements/typedefs.cc: New.
3815
3816 * include/bits/regex.h (sub_match::operator string_type): Call str().
3817 (sub_match::compare): Use _M_str() instead of str().
3818 (sub_match::_M_compare): New public function.
3819 (sub_match::__string_view): New helper type.
3820 (sub_match::_M_str): New overloaded functions to avoid creating a
3821 string_type object when not needed.
3822 (operator==, operator!=, operator<, operator>, operator<=, operator>=):
3823 Use sub_match::_M_compare instead of creating string_type objects.
3824 Fix Doxygen comments.
3825 * include/bits/regex_compiler.h (__has_contiguous_iter): Remove.
3826 (__is_contiguous_normal_iter): Rename to __is_contiguous_iter and
3827 simplify.
3828 (__enable_if_contiguous_iter, __disable_if_contiguous_iter): Use
3829 __enable_if_t.
3830 * include/std/type_traits (__enable_if_t): Define for C++11.
3831 * testsuite/28_regex/sub_match/compare.cc: New.
3832 * testsuite/util/testsuite_iterators.h (remove_cv): Add transformation
3833 trait.
3834 (input_iterator_wrapper): Use remove_cv for value_type argument of
3835 std::iterator base class.
3836
3837 2018-06-29 Jonathan Wakely <jwakely@redhat.com>
3838
3839 * testsuite/20_util/add_rvalue_reference/requirements/alias_decl.cc:
3840 Add whitespace to dejagnu directive.
3841 * testsuite/23_containers/array/element_access/at_neg.cc: Likewise.
3842
3843 2018-06-27 François Dumont <fdumont@gcc.gnu.org>
3844
3845 * include/bits/stl_vector.h
3846 (struct _Vector_base<>::_Vector_impl_data): New.
3847 (struct _Vector_base<>::_Vector_impl): Inherit from latter.
3848 (_Vector_base<>::_Vector_impl::_M_swap_data): Move...
3849 (_Vector_base<>::_Vector_impl_data::_M_swap_data): ...here.
3850 (_Vector_base<>::_Vector_impl()): Add noexcept qualification.
3851 (_Vector_base<>::_Vector_impl(_Vector_impl&&)): New.
3852 (_Vector_base<>::_Vector_impl(_Tp_alloc_type&&, _Vector_impl&&)): New.
3853 (_Vector_base(const allocator_type&, _Vector_base&&)): New, use latter.
3854 (_Vector_base()): Default.
3855 (_Vector_base(_Vector_base&&)): Default.
3856 (_Vector_base(size_t)) [_GLIBCXX_INLINE_VERSION]: Delete.
3857 (_Vector_base(_Tp_alloc_type&&)) [_GLIBCXX_INLINE_VERSION]: Delete.
3858 (_Vector_base::_M_create_storage(size_t)): Make protected.
3859 (vector()): Default.
3860 (vector(vector&&)): Default.
3861 (vector(vector&&, const allocator_type&, true_type)): New.
3862 (vector(vector&&, const allocator_type&, false_type)): New.
3863 (vector(vector&&, const allocator_type&)): Use latters.
3864 (vector(_InputIte, _InputIte, const allocator_type&)): Call
3865 _M_range_initialize directly.
3866 * include/debug/vector
3867 (vector(vector&&, const allocator_type&)): Add noexcept qualification.
3868 * testsuite/23_containers/vector/allocator/default_init.cc: New.
3869 * testsuite/23_containers/vector/cons/noexcept_move_construct.cc: Add
3870 static assertions.
3871
3872 2018-06-27 Jonathan Wakely <jwakely@redhat.com>
3873
3874 * include/bits/cpp_type_traits.h [__cplusplus >= 201703]
3875 (__is_byte<byte>): Define specialization for std::byte.
3876
3877 PR libstdc++/86138
3878 * include/bits/basic_string.tcc: [_GLIBCXX_EXTERN_TEMPLATE < 0]
3879 Declare explicit instantiations of COW empty reps and I/O functions.
3880
3881 2018-06-26 David Edelsohn <dje.gcc@gmail.com>
3882
3883 * testsuite/experimental/algorithm/sample-2.cc: Add TLS DejaGNU
3884 directives.
3885 * testsuite/experimental/algorithm/shuffle.cc: Likewise.
3886
3887 2018-06-26 Jonathan Wakely <jwakely@redhat.com>
3888
3889 * include/bits/regex.tcc (regex_iterator::operator==): Add missing
3890 noexcept.
3891
3892 2018-06-25 Jonathan Wakely <jwakely@redhat.com>
3893
3894 PR libstdc++/86112
3895 * python/libstdcxx/v6/printers.py (add_one_template_type_printer):
3896 Replace dict comprehension.
3897
3898 PR libstdc++/81092
3899 * config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt: Update.
3900
3901 PR libstdc++/86292
3902 * include/bits/stl_vector.h (vector::_M_range_initialize<InputIter>):
3903 Add try-catch block.
3904 * testsuite/23_containers/vector/cons/86292.cc: New.
3905
3906 * doc/xml/manual/status_cxx2017.xml: Document N4531 status.
3907
3908 * include/experimental/algorithm (sample, shuffle): Add new overloads
3909 using per-thread random number engine.
3910 * testsuite/experimental/algorithm/sample.cc: Simpify and reduce
3911 dependencies by using __gnu_test::test_container.
3912 * testsuite/experimental/algorithm/sample-2.cc: New.
3913 * testsuite/experimental/algorithm/shuffle.cc: New.
3914
3915 2018-06-22 Jonathan Wakely <jwakely@redhat.com>
3916
3917 * config/abi/pre/gnu.ver: Fix __cxx11::basic_string patterns for
3918 different size_t mangling on 32-bit targets.
3919
3920 PR libstdc++/86280
3921 * include/experimental/memory_resource
3922 (__resource_adaptor_common::_AlignMgr::_M_token_size): Use type large
3923 enough for result of left shift.
3924
3925 PR libstdc++/86138
3926 * include/bits/basic_string.tcc:
3927 [__cplusplus > 201402 && !_GLIBCXX_USE_CXX11_ABI]
3928 (basic_string<char>::_Rep::_S_empty_rep_storage)
3929 (basic_string<wchar_t>::_Rep::_S_empty_rep_storage): Add explicit
3930 instantiation declarations.
3931 [__cplusplus > 201402] (operator>>, operator<<, getline): Re-enable
3932 explicit instantiation declarations.
3933 * testsuite/21_strings/basic_string/cons/char/86138.cc: New.
3934 * testsuite/21_strings/basic_string/cons/wchar_t/86138.cc: New.
3935
3936 2018-06-21 Jonathan Wakely <jwakely@redhat.com>
3937
3938 PR libstdc++/83328
3939 * acinclude.m4 (libtool_VERSION): Bump to 6:26:0.
3940 * config/abi/pre/gnu.ver: Add GLIBCXX_3.4.26 and export new symbol.
3941 * configure: Regenerate.
3942 * include/bits/basic_string.h [_GLIBCXX_USE_CXX11_ABI]
3943 (basic_string::insert(const_iterator, initializer_list<C>)): Add.
3944 [_GLIBCXX_USE_CXX11_ABI && !_GLIBCXX_DEFINING_STRING_INSTANTIATIONS]
3945 (basic_string::insert(iterator, initializer_list<C>)): Suppress
3946 definition.
3947 * include/debug/string (basic_string::insert(iterator, C)): Change
3948 first parameter to const_iterator.
3949 (basic_string::insert(iterator, size_type, C)): Likewise. Change
3950 return type to iterator.
3951 (basic_string::insert(iterator, InputIterator, InputIterator)):
3952 Likewise.
3953 (basic_string::insert(iterator, initializer_list<C>)): Change first
3954 parameter to const_iterator and return type to iterator.
3955 * src/c++11/string-inst.cc: Extend comment.
3956 * testsuite/21_strings/basic_string/modifiers/insert/char/83328.cc:
3957 New.
3958 * testsuite/21_strings/basic_string/modifiers/insert/wchar_t/83328.cc:
3959 New.
3960 * testsuite/util/testsuite_abi.cc: Add new symbol version.
3961
3962 * config/abi/post/x86_64-linux-gnu/baseline_symbols.txt: Update.
3963
3964 PR libstdc++/70940
3965 * include/experimental/memory_resource
3966 (__resource_adaptor_imp::do_deallocate): Add missing return.
3967 * testsuite/experimental/memory_resource/new_delete_resource.cc: New.
3968 * testsuite/experimental/memory_resource/resource_adaptor.cc: Test
3969 resource_adaptor with std::allocator, __gnu_cxx::new_allocator and
3970 __gnu_cxx::malloc_allocator.
3971
3972 PR libstdc++/70940
3973 * include/experimental/memory_resource (__resource_adaptor_common):
3974 New base class.
3975 (__resource_adaptor_common::_AlignMgr): Helper for obtaining aligned
3976 pointer from unaligned, and vice versa.
3977 (__resource_adaptor_imp::do_allocate): Use _AlignMgr to adjust
3978 allocated pointer to meet alignment request.
3979 (__resource_adaptor_imp::do_deallocate): Use _AlignMgr to retrieve
3980 original pointer for deallocation.
3981 (__resource_adaptor_imp::do_is_equal): Reformat.
3982 (__resource_adaptor_imp::_S_aligned_size): Remove.
3983 (__resource_adaptor_imp::_S_supported): Remove.
3984 (new_delete_resource): Use __gnu_cxx::new_allocator.
3985 * testsuite/experimental/memory_resource/resource_adaptor.cc: Test
3986 extended alignments and use debug_allocator to check for matching
3987 allocate/deallocate pairs.
3988
3989 2018-06-21 François Dumont <fdumont@gcc.gnu.org>
3990
3991 * include/debug/safe_iterator.h
3992 (_Safe_iterator<>(const _Safe_iterator<_MutableIterator,>& __x)):
3993 Compare __x base iterator with a value-initialized iterator of the
3994 same type.
3995
3996 2018-06-20 Jonathan Wakely <jwakely@redhat.com>
3997
3998 PR libstdc++/70966
3999 * include/experimental/memory_resource (__resource_adaptor_imp): Add
4000 static assertions to enforce requirements on pointer types.
4001 (__resource_adaptor_imp::get_allocator()): Add noexcept.
4002 (new_delete_resource, null_memory_resource): Return address of an
4003 object with dynamic storage duration.
4004 (__null_memory_resource): Remove.
4005 * testsuite/experimental/memory_resource/70966.cc: New.
4006
4007 * testsuite/20_util/duration/arithmetic/dr3050.cc: Add new test
4008 missed from recent commit.
4009
4010 2018-06-19 Jonathan Wakely <jwakely@redhat.com>
4011
4012 * include/std/utility: Remove unused <exception> header.
4013
4014 2018-06-18 Jonathan Wakely <jwakely@redhat.com>
4015
4016 LWG 2975 ensure construct(pair<T,U>*, ...) used to construct pairs
4017 * include/std/scoped_allocator (__not_pair): Define SFINAE helper.
4018 (construct(_Tp*, _Args&&...)): Remove from overload set when _Tp is
4019 a specialization of std::pair.
4020 * testsuite/20_util/scoped_allocator/construct_pair.cc: Ensure
4021 pair elements are constructed correctly.
4022
4023 LWG 2989 hide path iostream operators from normal lookup
4024 * include/bits/fs_path.h (operator<<, operator>>): Define inline as
4025 friends.
4026 * testsuite/27_io/filesystem/path/io/dr2989.cc: New.
4027
4028 LWG 3050 Fix cv-qualification of convertibility constraints
4029 * include/std/chrono (duration, operator*, operator/, operator%): Use
4030 const-qualified type as source type in is_convertible constraints.
4031 * testsuite/20_util/duration/arithmetic/dr3050.cc: New.
4032 * testsuite/20_util/duration/cons/dr3050.cc: New.
4033 * testsuite/20_util/duration/literals/range.cc: Rename to...
4034 * testsuite/20_util/duration/literals/range_neg.cc: Here. Adjust
4035 dg-error lineno.
4036
4037 2018-06-18 Maya Rashish <coypu@sdf.org>
4038
4039 * crossconfig.m4: Handle OpenBSD just like NetBSD.
4040 * configure: Rebuilt.
4041
4042 2018-06-18 Jonathan Wakely <jwakely@redhat.com>
4043
4044 P0754R2 <version> header
4045 * include/Makefile.am: Add new header.
4046 * include/Makefile.in: Regenerate.
4047 * include/bits/c++config: Change doxygen comment to suggest <version>
4048 instead of <iosfwd>.
4049 * include/precompiled/stdc++.h: Include <cwchar> and <cwctype>
4050 unconditionally. Add C++17 and C++20 headers.
4051 * include/std/version: New header.
4052 * testsuite/17_intro/headers/c++2017/all_attributes.cc: New.
4053 * testsuite/17_intro/headers/c++2017/all_no_exceptions.cc: New.
4054 * testsuite/17_intro/headers/c++2017/all_no_rtti.cc: New.
4055 * testsuite/17_intro/headers/c++2017/all_pedantic_errors.cc: New.
4056 * testsuite/17_intro/headers/c++2017/operator_names.cc: New.
4057 * testsuite/17_intro/headers/c++2017/stdc++.cc: New.
4058 * testsuite/17_intro/headers/c++2017/stdc++_multiple_inclusion.cc:
4059 New.
4060 * testsuite/17_intro/headers/c++2020/all_attributes.cc: New.
4061 * testsuite/17_intro/headers/c++2020/all_no_exceptions.cc: New.
4062 * testsuite/17_intro/headers/c++2020/all_no_rtti.cc: New.
4063 * testsuite/17_intro/headers/c++2020/all_pedantic_errors.cc: New.
4064 * testsuite/17_intro/headers/c++2020/operator_names.cc: New.
4065 * testsuite/17_intro/headers/c++2020/stdc++.cc: New.
4066 * testsuite/17_intro/headers/c++2020/stdc++_multiple_inclusion.cc:
4067 New.
4068 * testsuite/18_support/headers/version/macros.cc: New.
4069 * testsuite/18_support/headers/version/macros.cc: New.
4070
4071 * acinclude.m4 (GLIBCXX_CHECK_FILESYSTEM_DEPS): Only check when
4072 enable_libstdcxx_filesystem_ts = yes. Check for link, readlink and
4073 symlink.
4074 * config.h.in: Regenerate.
4075 * configure: Regenerate.
4076 * configure.ac: Remove AC_CHECK_FUNCS for link, readlink and symlink.
4077
4078 LWG 3035. std::allocator's constructors should be constexpr
4079 * include/bits/allocator.h (allocator): Add constexpr to constructors
4080 for C++2a. Replace dynamic exception specifications with NOTHROW
4081 macro.
4082 (allocator, operator==, operator!=): Replace USE_NOEXCEPT macro with
4083 NOTHROW.
4084 * include/bits/c++config (_GLIBCXX20_CONSTEXPR): Define.
4085 * include/ext/malloc_allocator.h (malloc_allocator): Add constexpr
4086 to constructors for C++2a.
4087 * include/ext/new_allocator.h (new_allocator): Likewise.
4088
4089 2018-06-16 Jonathan Wakely <jwakely@redhat.com>
4090
4091 LWG 3076 basic_string CTAD ambiguity
4092 * doc/xml/manual/intro.xml: Document LWG 3076 change.
4093 * include/bits/basic_string.h
4094 [__cpp_deduction_guides && !_GLIBCXX_DEFINING_STRING_INSTANTIATIONS]
4095 (basic_string(const _CharT*, const _Alloc&)): Turn into a function
4096 template constrained by _RequireAllocator.
4097 (basic_string(size_type, _CharT, const _Alloc&)): Likewise.
4098 * src/c++11/string-inst.cc (_GLIBCXX_DEFINING_STRING_INSTANTIATIONS):
4099 Define.
4100 * testsuite/21_strings/basic_string/cons/char/deduction.cc: Test
4101 deduction
4102 * testsuite/21_strings/basic_string/cons/wchar_t/deduction.cc:
4103 Likewise.
4104
4105 2018-06-15 Jonathan Wakely <jwakely@redhat.com>
4106
4107 PR libstdc++/86169
4108 * include/bits/basic_string.h [!_GLIBCXX_USE_CXX11_ABI]
4109 (basic_string::data()): Unshare string.
4110 * testsuite/21_strings/basic_string/operations/data/char/86169.cc:
4111 New.
4112
4113 * include/std/string_view (basic_string_view(const CharT*)): Remove
4114 check for null pointer and add nonnull attribute.
4115 (compare(const CharT*), compare(size_type, size_type, const CharT*))
4116 (find(const CharT*, size_type), rfind(const CharT*, size_type))
4117 (find_first_of(const CharT*, size_type))
4118 (find_last_of(const CharT*, size_type))
4119 (find_first_not_of(const CharT*, size_type))
4120 (find_last_not_of(const CharT*, size_type)): Add nonnull attribute.
4121 * testsuite/21_strings/basic_string_view/cons/char/nonnull.cc: New.
4122 * testsuite/21_strings/basic_string_view/operations/compare/char/
4123 nonnull.cc: New.
4124 * testsuite/21_strings/basic_string_view/operations/find/char/
4125 nonnull.cc: New.
4126 * testsuite/21_strings/basic_string_view/operations/rfind/char/
4127 nonnull.cc: New.
4128
4129 PR libstdc++/86168
4130 * include/bits/random.h (random_device(const string&)): Remove
4131 default argument.
4132
4133 * include/bits/char_traits.h (__cpp_lib_constexpr_char_traits): Only
4134 define for C++17 and above.
4135
4136 LWG 2993 reference_wrapper<T> conversion from T&&
4137 * doc/xml/manual/intro.xml: Document LWG 2993 change.
4138 * include/bits/refwrap.h (reference_wrapper(_Tp&)): Remove.
4139 (reference_wrapper(_Tp&&)): Remove.
4140 (reference_wrapper<_Up>(_Up&&)): Define new constructor as constrained
4141 template.
4142 (reference_wrapper): Add deduction guide.
4143 * testsuite/20_util/reference_wrapper/deduction.cc: New.
4144 * testsuite/20_util/reference_wrapper/lwg2993.cc: New.
4145
4146 LWG 3039 Unnecessary decay in thread and packaged_task
4147 * include/std/future (__constrain_pkgdtask): Replace with ...
4148 (packaged_task::__not_same): New alias template, using
4149 __remove_cvref_t instead of decay.
4150 * include/std/thread (thread::__not_same): Add comment.
4151
4152 2018-06-14 Jonathan Wakely <jwakely@redhat.com>
4153
4154 LWG 3075 basic_string needs deduction guides from basic_string_view
4155 * testsuite/21_strings/basic_string/cons/char/deduction.cc: Test
4156 deduction from string views.
4157 * testsuite/21_strings/basic_string/cons/wchar_t/deduction.cc:
4158 Likewise.
4159
4160 LWG 3074 make scalar types non-deduced in valarray non-member functions
4161 * include/bits/valarray_after.h (_DEFINE_EXPR_BINARY_FUNCTION): Change
4162 scalar parameters to be a non-deduced context.
4163 * include/std/valarray (_DEFINE_BINARY_OPERATOR): Likewise. Adjust
4164 whitespace.
4165 * testsuite/26_numerics/valarray/operators.cc: Test scalar operands.
4166 * testsuite/26_numerics/valarray/transcend.cc: New.
4167
4168 * include/std/tuple (__cpp_lib_tuple_element_t, tuple_element_t):
4169 Move back to <utility>.
4170 * include/std/utility (__cpp_lib_tuple_element_t. tuple_element_t):
4171 Restore to here.
4172
4173 P0935R0 Eradicating unnecessarily explicit default constructors
4174 * include/backward/strstream (strstreambuf): Add non-explicit default
4175 constructor.
4176 * include/bits/locale_conv.h (wbuffer_convert, wstring_convert):
4177 Likewise.
4178 * include/bits/regex.h (match_results): Likewise.
4179 * testsuite/22_locale/conversions/buffer/1.cc: Test for non-explicit
4180 default constructor.
4181 * testsuite/22_locale/conversions/string/1.cc: Likewise.
4182 * testsuite/28_regex/match_results/ctors/char/default.cc: Likewise.
4183 * testsuite/28_regex/match_results/ctors/wchar_t/default.cc: Likewise.
4184
4185 * include/std/tuple (__cpp_lib_tuple_element_t): Move feature test
4186 macro from <utility> and change type to long.
4187 * include/std/utility (__cpp_lib_tuple_element_t): Remove.
4188 * testsuite/20_util/tuple/tuple_element_t.cc: Check for feature test
4189 macro.
4190
4191 P0935R0 Eradicating unnecessarily explicit default constructors
4192 * include/bits/random.h (uniform_real_distribution::param_type)
4193 (normal_distribution::param_type, lognormal_distribution::param_type)
4194 (gamma_distribution::param_type, chi_squared_distribution::param_type)
4195 (cauchy_distribution::param_type, fisher_f_distribution::param_type)
4196 (student_t_distribution::param_type)
4197 (bernoulli_distribution::param_type)
4198 (binomial_distribution::param_type)
4199 (geometric_distribution::param_type)
4200 (negative_binomial_distribution::param_type)
4201 (poisson_distribution::param_type)
4202 (exponential_distribution::param_type)
4203 (weibull_distribution::param_type)
4204 (extreme_value_distribution::param_type): Add non-explicit default
4205 constructors. Remove default argument for first parameter of explicit
4206 constructors.
4207 * include/bits/uniform_int_dist.h
4208 (uniform_int_distribution::param_type): Likewise.
4209 * include/ext/random
4210 (beta_distribution::param_type, rice_distribution::param_type)
4211 (nakagami_distribution::param_type, pareto_distribution::param_type)
4212 (k_distribution::param_type, arcsine_distribution::param_type)
4213 (hoyt_distribution::param_type, triangular_distribution::param_type)
4214 (von_mises_distribution::param_type)
4215 (hypergeometric_distribution::param_type)
4216 (logistic_distribution::param_type)
4217 (uniform_inside_sphere_distribution::param_type): Likewise.
4218 (uniform_on_sphere_distribution::param_type): Make default constructor
4219 non-explicit.
4220 * testsuite/26_numerics/random/bernoulli_distribution/cons/default.cc:
4221 Test param_type for non-explicit default constructor.
4222 * testsuite/26_numerics/random/binomial_distribution/cons/default.cc:
4223 Likewise.
4224 * testsuite/26_numerics/random/cauchy_distribution/cons/default.cc:
4225 Likewise.
4226 * testsuite/26_numerics/random/chi_squared_distribution/cons/default.cc:
4227 Likewise.
4228 * testsuite/26_numerics/random/discrete_distribution/cons/default.cc:
4229 Likewise.
4230 * testsuite/26_numerics/random/exponential_distribution/cons/default.cc:
4231 Likewise.
4232 * testsuite/26_numerics/random/extreme_value_distribution/cons/default.cc:
4233 Likewise.
4234 * testsuite/26_numerics/random/fisher_f_distribution/cons/default.cc:
4235 Likewise.
4236 * testsuite/26_numerics/random/gamma_distribution/cons/default.cc:
4237 Likewise.
4238 * testsuite/26_numerics/random/geometric_distribution/cons/default.cc:
4239 Likewise.
4240 * testsuite/26_numerics/random/lognormal_distribution/cons/default.cc:
4241 Likewise.
4242 * testsuite/26_numerics/random/negative_binomial_distribution/cons/default.cc:
4243 Likewise.
4244 * testsuite/26_numerics/random/normal_distribution/cons/default.cc:
4245 Likewise.
4246 * testsuite/26_numerics/random/piecewise_constant_distribution/cons/default.cc:
4247 Likewise.
4248 * testsuite/26_numerics/random/piecewise_linear_distribution/cons/default.cc:
4249 Likewise.
4250 * testsuite/26_numerics/random/poisson_distribution/cons/default.cc:
4251 Likewise.
4252 * testsuite/26_numerics/random/student_t_distribution/cons/default.cc:
4253 Likewise.
4254 * testsuite/26_numerics/random/uniform_int_distribution/cons/default.cc:
4255 Likewise.
4256 * testsuite/26_numerics/random/uniform_real_distribution/cons/default.cc:
4257 Likewise.
4258 * testsuite/26_numerics/random/weibull_distribution/cons/default.cc:
4259 Likewise.
4260 * testsuite/ext/random/arcsine_distribution/cons/default.cc: Likewise.
4261 * testsuite/ext/random/beta_distribution/cons/default.cc: Likewise.
4262 * testsuite/ext/random/hoyt_distribution/cons/default.cc: Likewise.
4263 * testsuite/ext/random/hypergeometric_distribution/cons/default.cc:
4264 Likewise.
4265 * testsuite/ext/random/k_distribution/cons/default.cc: Likewise.
4266 * testsuite/ext/random/logistic_distribution/cons/default.cc: Likewise.
4267 * testsuite/ext/random/nakagami_distribution/cons/default.cc: Likewise.
4268 * testsuite/ext/random/normal_mv_distribution/cons/default.cc:
4269 Likewise.
4270 * testsuite/ext/random/pareto_distribution/cons/default.cc: Likewise.
4271 * testsuite/ext/random/rice_distribution/cons/default.cc: Likewise.
4272 * testsuite/ext/random/triangular_distribution/cons/default.cc:
4273 Likewise.
4274 * testsuite/ext/random/uniform_inside_sphere_distribution/cons/default.cc:
4275 Likewise.
4276 * testsuite/ext/random/uniform_on_sphere_distribution/cons/default.cc:
4277 Likewise.
4278 * testsuite/ext/random/von_mises_distribution/cons/default.cc:
4279 Likewise.
4280
4281 2018-06-14 Daniel Trebbien <dtrebbien@gmail.com>
4282 Jonathan Wakely <jwakely@redhat.com>
4283
4284 PR libstdc++/83982
4285 * include/bits/vector.tcc (vector::_M_default_append(size_type)):
4286 Default-construct new elements before moving existing ones.
4287 * testsuite/23_containers/vector/capacity/resize/strong_guarantee.cc:
4288 New.
4289
4290 2018-06-13 Jonathan Wakely <jwakely@redhat.com>
4291
4292 PR libstdc++/86127
4293 * include/bits/forward_list.h (_Fwd_list_base::_Tp_alloc_type): Remove
4294 unused typedef.
4295 (_Fwd_list_base::_M_create_node, _Fwd_list_base::_M_erase_after):
4296 Use node allocator to create and destroy elements.
4297 (forward_list::_Tp_alloc_type): Remove unused typedef.
4298 (forward_list::_Alloc_traits): Use allocator_traits instead of
4299 __gnu_cxx::__alloc_traits.
4300
4301 2018-06-13 François Dumont <fdumont@gcc.gnu.org>
4302
4303 * include/debug/helper_functions.h
4304 (__gnu_debug::_Safe_iterator<>): Add declaration.
4305 (__can_advance(_Ite, _Size)): New.
4306 (__can_advance(const _Safe_iterator<>&, _Size)): Overload declaration.
4307 * include/debug/functions.h
4308 (__gnu_debug::_Safe_iterator<>): Remove declaration.
4309 * include/debug/stl_iterator.h
4310 (__can_advance(const _Safe_iterator<>&)): New definition.
4311 * include/debug/stl_iterator.h
4312 (__can_advance(const std::reverse_iterator<>&, _Size)): New.
4313 (__can_advance(const std::move_iterator<>&, _Size)): New.
4314 * include/debug/macros.h (__glibcxx_check_can_increment): New.
4315 * include/debug/debug.h (__glibcxx_requires_can_increment): New.
4316 * include/bits/stl_algobase.h (fill_n): Use latter.
4317 * testsuite/25_algorithms/fill_n/2.cc: New.
4318 * testsuite/25_algorithms/fill_n/debug/1_neg.cc: New.
4319 * testsuite/25_algorithms/fill_n/debug/2_neg.cc: New.
4320 * testsuite/25_algorithms/fill_n/debug/3_neg.cc: New.
4321 * testsuite/25_algorithms/fill_n/debug/4_neg.cc: New.
4322
4323 * include/debug/debug.h (__glibcxx_requires_can_increment_range): New.
4324 (__glibcxx_requires_can_decrement_range): New.
4325
4326 2018-06-12 François Dumont <fdumont@gcc.gnu.org>
4327
4328 * include/debug/macros.h (__glibcxx_check_can_increment_range): New.
4329 (__glibcxx_check_can_decrement_range): New.
4330 * include/bits/stl_algobase.h (std::copy(_II, _II, _OI)): Use
4331 __glibcxx_requires_can_increment_range.
4332 (std::move(_II, _II, _OI)): Likewise.
4333 (std::copy_backward(_BI, _BI, _BI2)): Use
4334 __glibcxx_requires_can_decrement_range.
4335 (std::move_backward(_BI, _BI, _BI2)): Likewise.
4336 * testsuite/25_algorithms/copy_backward/debug/1_neg.cc: New.
4337 * testsuite/25_algorithms/copy_backward/debug/2_neg.cc: New.
4338 * testsuite/25_algorithms/copy_backward/debug/3_neg.cc: New.
4339 * testsuite/25_algorithms/equal/debug/1_neg.cc: New.
4340 * testsuite/25_algorithms/equal/debug/2_neg.cc: New.
4341 * testsuite/25_algorithms/equal/debug/3_neg.cc: New.
4342
4343 2018-06-12 Jonathan Wakely <jwakely@redhat.com>
4344
4345 P0935R0 Eradicating unnecessarily explicit default constructors
4346 * include/bits/random.h (linear_congruential_engine)
4347 (mersenne_twister_engine, subtract_with_carry_engine, random_device)
4348 (uniform_real_distribution, normal_distribution)
4349 (lognormal_distribution, gamma_distribution, chi_squared_distribution)
4350 (cauchy_distribution, fisher_f_distribution, student_t_distribution)
4351 (bernoulli_distribution, binomial_distribution,geometric_distribution)
4352 (negative_binomial_distribution, exponential_distribution)
4353 (weibull_distribution, extreme_value_distribution): Add non-explicit
4354 default constructors. Remove default argument for first parameter of
4355 explicit constructors.
4356 (piecewise_constant_distribution, piecewise_linear_distribution):
4357 Make default constructor non-explicit.
4358 * include/bits/uniform_int_dist.h (uniform_int_distribution): Add
4359 non-explicit default constructors. Remove default argument for first
4360 parameter of explicit constructor.
4361 * include/ext/random
4362 (simd_fast_mersenne_twister_engine, beta_distribution)
4363 (rice_distribution, nakagami_distribution, pareto_distribution)
4364 (k_distribution, arcsine_distribution, hoyt_distribution)
4365 (triangular_distribution, von_mises_distribution)
4366 (hypergeometric_distribution, logistic_distribution)
4367 (uniform_inside_sphere_distribution): Likewise.
4368 (uniform_on_sphere_distribution): Make default constructor
4369 non-explicit.
4370 * testsuite/26_numerics/random/bernoulli_distribution/cons/default.cc:
4371 Test for non-explicit default constructor. Fix references to standard.
4372 * testsuite/26_numerics/random/binomial_distribution/cons/default.cc:
4373 Likewise.
4374 * testsuite/26_numerics/random/cauchy_distribution/cons/default.cc:
4375 Likewise.
4376 * testsuite/26_numerics/random/chi_squared_distribution/cons/default.cc:
4377 Likewise.
4378 * testsuite/26_numerics/random/discrete_distribution/cons/default.cc:
4379 Likewise.
4380 * testsuite/26_numerics/random/exponential_distribution/cons/default.cc:
4381 Likewise.
4382 * testsuite/26_numerics/random/extreme_value_distribution/cons/default.cc:
4383 Likewise.
4384 * testsuite/26_numerics/random/fisher_f_distribution/cons/default.cc:
4385 Likewise.
4386 * testsuite/26_numerics/random/gamma_distribution/cons/default.cc:
4387 Likewise.
4388 * testsuite/26_numerics/random/geometric_distribution/cons/default.cc:
4389 Likewise.
4390 * testsuite/26_numerics/random/lognormal_distribution/cons/default.cc:
4391 Likewise.
4392 * testsuite/26_numerics/random/negative_binomial_distribution/cons/default.cc:
4393 Likewise.
4394 * testsuite/26_numerics/random/normal_distribution/cons/default.cc:
4395 Likewise.
4396 * testsuite/26_numerics/random/piecewise_constant_distribution/cons/default.cc:
4397 Likewise.
4398 * testsuite/26_numerics/random/piecewise_linear_distribution/cons/default.cc:
4399 Likewise.
4400 * testsuite/26_numerics/random/poisson_distribution/cons/default.cc:
4401 Likewise.
4402 * testsuite/26_numerics/random/student_t_distribution/cons/default.cc:
4403 Likewise.
4404 * testsuite/26_numerics/random/uniform_int_distribution/cons/default.cc:
4405 Likewise.
4406 * testsuite/26_numerics/random/uniform_real_distribution/cons/default.cc:
4407 Likewise.
4408 * testsuite/26_numerics/random/weibull_distribution/cons/default.cc:
4409 Likewise.
4410 * testsuite/ext/random/arcsine_distribution/cons/default.cc: Likewise.
4411 * testsuite/ext/random/beta_distribution/cons/default.cc: Likewise.
4412 * testsuite/ext/random/hoyt_distribution/cons/default.cc: Likewise.
4413 * testsuite/ext/random/hypergeometric_distribution/cons/default.cc:
4414 Likewise.
4415 * testsuite/ext/random/k_distribution/cons/default.cc: Likewise.
4416 * testsuite/ext/random/logistic_distribution/cons/default.cc: Likewise.
4417 * testsuite/ext/random/nakagami_distribution/cons/default.cc: Likewise.
4418 * testsuite/ext/random/normal_mv_distribution/cons/default.cc:
4419 Likewise.
4420 * testsuite/ext/random/pareto_distribution/cons/default.cc: Likewise.
4421 * testsuite/ext/random/rice_distribution/cons/default.cc: Likewise.
4422 * testsuite/ext/random/triangular_distribution/cons/default.cc:
4423 Likewise.
4424 * testsuite/ext/random/uniform_inside_sphere_distribution/cons/default.cc:
4425 Likewise.
4426 * testsuite/ext/random/uniform_on_sphere_distribution/cons/default.cc:
4427 Likewise.
4428 * testsuite/ext/random/von_mises_distribution/cons/default.cc:
4429 Likewise.
4430 * testsuite/util/testsuite_common_types.h
4431 (implicitly_default_constructible): New helper.
4432
4433 2018-06-08 Jonathan Wakely <jwakely@redhat.com>
4434
4435 * include/bits/ios_base.h (ios::Init::Init(const Init&))
4436 (ios::Init::operator=): Define as defaulted.
4437 * include/bits/stl_bvector.h (_Bit_reference(const _Bit_reference&)):
4438 Likewise.
4439 * include/bits/stream_iterator.h (istream_iterator::operator=)
4440 (ostream_iterator::operator=): Likewise.
4441 * include/bits/streambuf_iterator.h (istreambuf_iterator::operator=)
4442 Likewise.
4443 * include/std/bitset (bitset::reference::reference(const reference&)):
4444 Likewise.
4445 * include/std/complex (complex<float>::complex(const complex&))
4446 (complex<double>::complex(const complex&))
4447 (complex<long double>::complex(const complex&)): Likewise.
4448
4449 2018-06-07 Jonathan Wakely <jwakely@redhat.com>
4450
4451 * include/bits/regex.h (sub_match): Add noexcept to default
4452 constructor and length observer.
4453 (match_results): Add noexcept to default constructor and observers
4454 with no preconditions. Define destructor as defaulted.
4455 (operator==, operator!=, swap): Add noexcept.
4456 (regex_iterator): Add default member initializers and define default
4457 constructor and destructor as defaulted. Add noexcept to equality
4458 and dereference operators.
4459
4460 2018-06-07 François Dumont <fdumont@gcc.gnu.org>
4461
4462 * src/c++11/debug.cc
4463 (_Safe_iterator_base::_M_detach()): Reset state only if needed.
4464 (_Safe_iterator_base::_M_detach_single()): Likewise.
4465 (_Safe_local_iterator_base::_M_detach()): Reset state only if needed.
4466 (_Safe_local_iterator_base::_M_detach_single()): Likewise.
4467
4468 2018-06-06 Jonathan Wakely <jwakely@redhat.com>
4469
4470 * include/bits/shared_ptr_base.h (__shared_count): Remove redundant
4471 move of const value.
4472
4473 2018-06-06 Jakub Jelinek <jakub@redhat.com>
4474
4475 PR c++/86068
4476 * include/bits/c++config: Check __cpp_transactional_memory >= 201500L
4477 rather than __cpp_transactional_memory >= 201505L.
4478
4479 2018-06-06 Jonathan Wakely <jwakely@redhat.com>
4480
4481 PR libstdc++/86008
4482 * include/bits/quoted_string.h (_Quoted_string<basic_string_view, C>):
4483 Define new partial specialization.
4484 * include/std/iomanip (quoted(basic_string_view<C,T>, C, C)): Define
4485 new overload.
4486 (operator<<(basic_ostream<C,T>&, const _Quoted_string<S,C>&)): Use
4487 value not reference for iteration.
4488 * testsuite/27_io/manipulators/standard/char/quoted.cc: Adjust
4489 comment.
4490 * testsuite/27_io/manipulators/standard/char/quoted_sv.cc: New test.
4491 * testsuite/27_io/manipulators/standard/wchar_t/quoted.cc: Adjust
4492 comment.
4493
4494 2018-06-05 Jonathan Wakely <jwakely@redhat.com>
4495
4496 * include/std/type_traits: Fix comment typos.
4497
4498 * testsuite/27_io/filesystem/operations/read_symlink.cc: XFAIL for
4499 mingw* targets.
4500 * testsuite/27_io/filesystem/operations/symlink_status.cc: Likewise.
4501 * testsuite/experimental/filesystem/operations/read_symlink.cc:
4502 Likewise.
4503
4504 2018-06-05 François Dumont <fdumont@gcc.gnu.org>
4505
4506 * include/bits/stl_tempbuf.h
4507 (_Temporary_buffer(_FwdIte, _FwdIte)): Delete, replaced by...
4508 (_Temporary_buffer(_FwdIte, size_type)): ...this, new.
4509 * include/ext/memory (temporary_buffer<>(_FwdIte, _FwdIte)): Adapt.
4510 * include/bits/stl_algo.h (__stable_partition): Adapt.
4511 (__inplace_merge): Adapt.
4512 (__stable_sort): Adapt.
4513
4514 2018-06-04 Jonathan Wakely <jwakely@redhat.com>
4515
4516 PR libstdc++/85930
4517 * include/bits/shared_ptr_base.h [!__cpp_rtti]: Include <typeinfo>
4518 unconditionally. Remove redundant declaration.
4519 [!__cpp_rtti] (_Sp_make_shared_tag::_S_ti): Fix location of
4520 alignment-specifier.
4521
4522 * include/bits/postypes.h (fpos): Define special members as defaulted.
4523
4524 PR libstdc++/85930
4525 * include/bits/shared_ptr_base.h (_Sp_make_shared_tag::_S_ti): Align
4526 the static variable correctly.
4527
4528 2018-05-24 Jonathan Wakely <jwakely@redhat.com>
4529
4530 PR libstdc++/78870 support std::filesystem on Windows
4531 * config.h.in: Regenerate.
4532 * configure: Regenerate.
4533 * configure.ac: Check for link, readlink and symlink.
4534 * include/bits/fs_path.h (path::operator/=(const path&)): Move
4535 definition out of class body.
4536 (path::is_absolute(), path::_M_append(path)): Likewise.
4537 (operator<<(basic_ostream, const path&)): Use std::quoted directly.
4538 (operator>>(basic_istream, path&)): Likewise.
4539 (u8path): Reorder definitions and fix Windows implementation.
4540 (path::is_absolute()): Define inline and fix for Windows.
4541 [!_GLIBCXX_FILESYSTEM_IS_WINDOWS] (path::operator/=(const path&)):
4542 Define POSIX version inline.
4543 (path::_M_append(path)): Define inline.
4544 * include/experimental/bits/fs_path.h (path::is_absolute()): Move
4545 definition out of class body.
4546 (operator<<(basic_ostream, const path&)): Fix type of delimiter and
4547 escape characters.
4548 (operator>>(basic_istream, path&)): Likewise.
4549 (path::is_absolute()): Define inline and fix for Windows.
4550 * src/filesystem/dir-common.h (__gnu_posix): New namespace.
4551 (__gnu_posix::char_type, __gnu_posix::DIR, __gnu_posix::dirent)
4552 (__gnu_posix::opendir, __gnu_posix::readdir, __gnu_posix::closedir):
4553 Define as adaptors for Windows functions/types or as
4554 using-declarations for POSIX functions/types.
4555 (_Dir_base, get_file_type): Qualify names to use declarations from
4556 __gnu_posix namespace.
4557 (_Dir_base::is_dor_or_dotdot): New helper functions.
4558 * src/filesystem/dir.cc (_Dir, recursive_directory_iterator): Qualify
4559 names to use declarations from __gnu_posix namespace.
4560 * src/filesystem/ops-common.h (__gnu_posix): New nested namespace.
4561 (__gnu_posix::open, __gnu_posix::close, __gnu_posix::stat_type)
4562 (__gnu_posix::stat, __gnu_posix::lstat, __gnu_posix::mode_t)
4563 (__gnu_posix::chmod, __gnu_posix::mkdir, __gnu_posix::getcwd)
4564 (__gnu_posix::chdir, __gnu_posix::utimbuf, __gnu_posix::utime)
4565 (__gnu_posix::rename, __gnu_posix::truncate, __gnu_posix::char_type):
4566 Define as adaptors for Windows functions/types or as
4567 using-declarations for POSIX functions/types.
4568 (stat_type, do_copy_file): Qualify names to use declarations from
4569 __gnu_posix namespace.
4570 (do_space): Declare new function.
4571 (make_file_type): Only use S_ISLNK if defined.
4572 * src/filesystem/ops.cc (char_ptr, filesystem::canonical): Use
4573 path::value_type not char.
4574 (filesystem::copy, create_dir, filesystem::create_directory): Qualify
4575 names to use declarations from __gnu_posix namespace.
4576 (filesystem::create_hard_link): Check HAVE_LINK autoconf macro and
4577 add implementation for Windows.
4578 (filesystem::create_symlink): Check HAVE_SYMLINK autoconf macro.
4579 (filesystem::current_path(error_code&)): Use __gnu_posix::getcwd.
4580 [!_PC_PATH_MAX]: Don't use pathconf.
4581 [PATH_MAX]: Use if defined.
4582 (filesystem::current_path(const path&, error_code&))
4583 (filesystem::equivalent, do_stat, filesystem::hard_link_count)
4584 (filesystem::last_write_time, filesystem::permissions): Use names
4585 from __gnu_posix.
4586 (filesystem::read_symlink): Check HAVE_READLINK autoconf macro.
4587 (filesystem::remove) [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Add
4588 implementation for Windows.
4589 (filesystem::rename, filesystem::resize_file): Use names from
4590 __gnu_posix.
4591 (filesystem::space): Use do_space.
4592 [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Get absolute path to directory.
4593 (filesystem::status, filesystem::symlink_status): Use names from
4594 __gnu_posix.
4595 (filesystem::temp_directory_path): Add implementation for Windows.
4596 * src/filesystem/path.cc (dot): Define constant.
4597 (path::replace_extension): Use dot.
4598 (path::_M_find_extension): Likewise. Use path::string_type not
4599 std::string.
4600 (path::_M_split_cmpts): Use dot.
4601 (filesystem_error::_M_get_what): Use u8string() not native().
4602 * src/filesystem/std-dir.cc (_Dir, recursive_directory_iterator):
4603 Qualify names to use declarations from __gnu_posix namespace.
4604 * src/filesystem/std-ops.cc (filesystem::absolute(const path&)): Use
4605 correct error_code.
4606 (filesystem::absolute(const path&, error_code&)): Add implementation
4607 for Windows.
4608 (char_ptr, filesystem::canonical): Use path::value_type not char.
4609 (do_copy_file): Use names from __gnu_posix.
4610 [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Do not use fchmod, fchmodat or
4611 sendfile.
4612 (filesystem::copy, create_dir, filesystem::create_directory): Qualify
4613 names to use declarations from __gnu_posix namespace.
4614 (filesystem::create_hard_link): Check HAVE_LINK autoconf macro and
4615 add implementation for Windows.
4616 (filesystem::create_symlink): Check HAVE_SYMLINK autoconf macro.
4617 (filesystem::current_path(error_code&)): Use __gnu_posix::getcwd.
4618 [!_PC_PATH_MAX]: Don't use pathconf.
4619 [PATH_MAX]: Use if defined.
4620 (filesystem::current_path(const path&, error_code&))
4621 (filesystem::equivalent, do_stat, filesystem::hard_link_count)
4622 (filesystem::last_write_time, filesystem::permissions): Use names
4623 from __gnu_posix.
4624 (filesystem::read_symlink): Check HAVE_READLINK autoconf macro.
4625 (filesystem::remove) [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Add
4626 implementation for Windows.
4627 (filesystem::rename, filesystem::resize_file): Use names from
4628 __gnu_posix.
4629 (do_space): Define.
4630 (filesystem::space): Use do_space.
4631 (filesystem::status, filesystem::symlink_status): Use names from
4632 __gnu_posix.
4633 (filesystem::temp_directory_path): Add implementation for Windows.
4634 * src/filesystem/std-path.cc
4635 [_GLIBCXX_FILESYSTEM_IS_WINDOWS] (path::operator/=(const path&)):
4636 Define for Windows.
4637 (dot): Define constant.
4638 (path::replace_extension, is_dot): Use dot.
4639 (path::lexically_normal): Check _M_type instead of calling
4640 non-existent function.
4641 (path::_M_find_extension): Use dot. Use path::string_type not
4642 std::string.
4643 (path::_M_split_cmpts): Use dot.
4644 (filesystem_error::_M_get_what): Use u8string() not native().
4645 * testsuite/27_io/filesystem/iterators/directory_iterator.cc: Do not
4646 use symlinks.
4647 * testsuite/27_io/filesystem/iterators/recursive_directory_iterator.cc:
4648 Likewise.
4649 * testsuite/27_io/filesystem/operations/absolute.cc: Use
4650 __gnu_test::root_path() instead of "/" and add Windows-specific tests.
4651 * testsuite/27_io/filesystem/operations/canonical.cc: Use
4652 path::string() to get narrow string, not path::native().
4653 * testsuite/27_io/filesystem/operations/copy.cc: Construct fstreams
4654 with std::filesystem::path not std::basic_string.
4655 * testsuite/27_io/filesystem/operations/copy_file.cc: Likewise.
4656 * testsuite/27_io/filesystem/operations/exists.cc: Use
4657 __gnu_test::root_path() instead of "/".
4658 * testsuite/27_io/filesystem/operations/is_empty.cc: Construct
4659 fstreams with std::filesystem::path not std::basic_string.
4660 * testsuite/27_io/filesystem/operations/last_write_time.cc: Use
4661 path::string() to get narrow string.
4662 * testsuite/27_io/filesystem/operations/space.cc: Check results for
4663 errors, expect sensible values otherwise.
4664 * testsuite/27_io/filesystem/operations/temp_directory_path.cc: Add
4665 helpers for adjusting the environment on Windows.
4666 * testsuite/27_io/filesystem/path/append/path.cc: Test
4667 Windows-specific behaviour.
4668 * testsuite/27_io/filesystem/path/construct/format.cc: Fix creation
4669 of path::string_type objects.
4670 * testsuite/27_io/filesystem/path/construct/locale.cc: Compare native
4671 string to wide string on Windows.
4672 * testsuite/27_io/filesystem/path/decompose/root_directory.cc: Allow
4673 for backslash as root-directory.
4674 * testsuite/27_io/filesystem/path/decompose/stem.cc: Use
4675 path::string() to get narrow string.
4676 * testsuite/27_io/filesystem/path/itr/traversal.cc: Test Windows-style
4677 paths.
4678 * testsuite/27_io/filesystem/path/native/string.cc: Use string_type
4679 not std::string.
4680 * testsuite/27_io/filesystem/path/query/is_absolute.cc: Adjust for
4681 different definintion of absolute paths on Windows.
4682 * testsuite/experimental/filesystem/iterators/directory_iterator.cc:
4683 Do not use symlinks.
4684 * testsuite/experimental/filesystem/operations/absolute.cc: Test
4685 Windows behaviour.
4686 * testsuite/experimental/filesystem/operations/copy.cc: Construct
4687 fstreams with NTCTS not std::basic_string.
4688 * testsuite/experimental/filesystem/operations/copy_file.cc: Likewise.
4689 * testsuite/experimental/filesystem/operations/exists.cc: Use
4690 __gnu_test::root_path() instead of "/".
4691 * testsuite/experimental/filesystem/operations/is_empty.cc: Construct
4692 fstreams with NTCTS not std::basic_string.
4693 * testsuite/experimental/filesystem/operations/last_write_time.cc:
4694 Use path::string() to get narrow string.
4695 * testsuite/experimental/filesystem/operations/space.cc: Use
4696 __gnu_test::root_path() instead of "/".
4697 * testsuite/experimental/filesystem/operations/temp_directory_path.cc:
4698 Add helpers for adjusting the environment on Windows.
4699 * testsuite/experimental/filesystem/path/append/path.cc: Use
4700 path::string() to get narrow strings for comparisons.
4701 * testsuite/experimental/filesystem/path/concat/path.cc: Likewise.
4702 * testsuite/experimental/filesystem/path/decompose/root_directory.cc:
4703 Likewise.
4704 * testsuite/experimental/filesystem/path/decompose/stem.cc: Likewise.
4705 * testsuite/experimental/filesystem/path/native/string.cc: Use
4706 string_type not std::string.
4707 * testsuite/experimental/filesystem/path/query/is_absolute.cc:
4708 Adjust for different definintion of absolute paths on Windows.
4709 * testsuite/util/testsuite_fs.h (__gnu_test::root_path()): New
4710 function.
4711 (__gnu_test::scoped_file): Construct fstreams with NTCTS not
4712 std::basic_string.
4713
4714 2018-05-31 Jonathan Wakely <jwakely@redhat.com>
4715
4716 PR libstdc++/85951
4717 * include/std/type_traits [_GLIBCXX_USE_C99_STDINT_TR1]: Do not define
4718 uint_least16_t and uint_least32_t.
4719 (__make_unsigned<wchar_t>): Define unconditionally.
4720 (__make_unsigned_selector<_Tp, true, false>): Remove intermediate
4721 typedefs.
4722 (__make_unsigned_selector_base): New type to provide helper templates.
4723 (__make_unsigned_selector<_Tp, false, true>): Reimplement using
4724 __make_unsigned_selector_base helpers.
4725 (__make_unsigned<char16_t>, __make_unsigned<char32_t>): Define.
4726 (__make_signed_selector<_Tp, true, false>): Remove intermediate
4727 typedefs.
4728 (__make_signed<wchar_t>, __make_signed<char16_t>)
4729 (__make_signed<char32_t>)): Define unconditionally.
4730 * testsuite/20_util/make_signed/requirements/typedefs-3.cc: Check
4731 wchar_t, char16_t and char32_t are transformed correctly.
4732 * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust
4733 dg-error lineno.
4734 * testsuite/20_util/make_unsigned/requirements/typedefs-3.cc: Check
4735 wchar_t, char16_t and char32_t are transformed correctly.
4736 * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Adjust
4737 dg-error lineno.
4738
4739 2018-05-29 Jonathan Wakely <jwakely@redhat.com>
4740
4741 * include/std/variant (__erased_dtor): Qualify call to __get.
4742
4743 2018-05-27 François Dumont <fdumont@gcc.gnu.org>
4744
4745 * include/bits/stl_tree.h (_Rb_tree_impl(_Node_allocator&&)): New.
4746 (_Rb_tree(const allocator_type&)): Use latter.
4747 * include/bits/stl_map.h (map(const allocator_type&)): Likewise.
4748 (map(initializer_list<value_type>, const allocator_type&)): Likewise.
4749 (map(_InputIterator, _InputIterator, const allocator_type&)): Likewise.
4750 * include/bits/stl_multimap.h
4751 (multimap(const allocator_type&)): Likewise.
4752 (multimap(initializer_list<value_type>, const allocator_type&)):
4753 Likewise.
4754 (multimap(_InputIterator, _InputIterator, const allocator_type&)):
4755 Likewise.
4756 * include/bits/stl_set.h (set(const allocator_type&)): Likewise.
4757 (set(initializer_list<value_type>, const allocator_type&)): Likewise.
4758 (set(_InputIterator, _InputIterator, const allocator_type&)): Likewise.
4759 * include/bits/stl_multiset.h
4760 (multiset(const allocator_type&)): Likewise.
4761 (multiset(initializer_list<value_type>, const allocator_type&)):
4762 Likewise.
4763 (multiset(_InputIterator, _InputIterator, const allocator_type&)):
4764 Likewise.
4765
4766 2018-05-25 François Dumont <fdumont@gcc.gnu.org>
4767
4768 PR libstdc++/85768
4769 * src/c++11/debug.cc: Remove backtrace usage.
4770
4771 2018-05-24 Maya Rashish <coypu@sdf.org>
4772
4773 PR target/85904
4774 * crossconfig.m4: Test for aligned_alloc on netbsd.
4775 * configure: Regenerate.
4776
4777 2018-05-24 Jonathan Wakely <jwakely@redhat.com>
4778
4779 PR libstdc++/69769
4780 PR libstdc++/85886
4781 * include/bits/atomic_base.h (__atomic_base::value_type)
4782 (__atomic_base::difference_type): Add new typedefs.
4783 * include/std/atomic (atomic<bool>::value_type, atomic<T>::value_type)
4784 (atomic<T*>::value_type, atomic<T*>::difference_type): Likewise.
4785 (atomic<T*>::operator++, atomic<T*>::operator--)
4786 (atomic<T*>::operator+=, atomic<T*>::operator-=)
4787 (atomic<T*>::fetch_add, atomic<T*>::fetch_sub): Add static assertion
4788 to enforce C++17 requirement on pointer arithmetic.
4789 (__atomic_val_t, __atomic_diff_t): New alias templates.
4790 (atomic_init, atomic_store_explicit, atomic_exchange_explicit)
4791 (atomic_compare_exchange_weak_explicit)
4792 (atomic_compare_exchange_strong_explicit, atomic_store)
4793 (atomic_exchange, atomic_compare_exchange_weak)
4794 (atomic_compare_exchange_strong): Use __atomic_val_t to make
4795 scalar parameters be non-deduced contexts.
4796 (atomic_fetch_add_explicit, atomic_fetch_sub_explicit)
4797 (atomic_fetch_add, atomic_fetch_sub): Change first parameter to be
4798 atomic instead of __atomic_base, and use __atomic_diff_t for scalar
4799 parameters.
4800 (atomic_fetch_and_explicit, atomic_fetch_or_explicit)
4801 (atomic_fetch_xor_explicit, atomic_fetch_and, atomic_fetch_or)
4802 (atomic_fetch_xor): Use __atomic_val_t for scalar parameters.
4803 (atomic_fetch_add_explicit, atomic_fetch_sub_explicit)
4804 (atomic_fetch_add, atomic_fetch_sub): Remove overloads for atomic
4805 address types.
4806 * testsuite/29_atomics/atomic/60695.cc: Adjust dg-error lineno.
4807 * testsuite/29_atomics/atomic/69769.cc: New test.
4808 * testsuite/29_atomics/atomic/nonmembers.cc: New test.
4809 * testsuite/29_atomics/atomic/operators/pointer_partial_void.cc:
4810 Disable test for C++17 and later.
4811 * testsuite/29_atomics/atomic/requirements/typedefs.cc: New test.
4812 * testsuite/29_atomics/atomic_integral/nonmembers.cc: New test.
4813 * testsuite/29_atomics/atomic_integral/requirements/typedefs.cc: New
4814 test.
4815
4816 2018-05-23 Jonathan Wakely <jwakely@redhat.com>
4817
4818 * include/bits/fs_path.h (path::__is_encoded_char): Change from class
4819 template to alias template.
4820 (path::__value_type_is_char): Use remove_const_t.
4821 (path:_S_string_from_iter): New helper function.
4822 (path::_S_convert(InputIter, __null_terminated))
4823 (path::_S_convert_loc(InputIter, __null_terminated, const locale&)):
4824 Use _S_string_from_iter.
4825 (path::string<_CharT, _Allocator>(const _Allocator&)): Allow sharing
4826 rep for COW strings.
4827 * include/experimental/bits/fs_path.h (path::__is_encoded_char):
4828 Change from class template to alias template.
4829 (path::__value_type_is_char): Use remove_const.
4830 (path:_S_string_from_iter): New helper function.
4831 (path::_S_convert(InputIter, __null_terminated))
4832 (path::_S_convert_loc(InputIter, __null_terminated, const locale&)):
4833 Use _S_string_from_iter.
4834 * testsuite/27_io/filesystem/path/append/source.cc: Test appending
4835 wide strings.
4836 * testsuite/27_io/filesystem/path/concat/strings.cc: Check for exact
4837 string equality, not path equivalence.
4838 * testsuite/27_io/filesystem/path/construct/format.cc: Check
4839 construction from std::string and std::wstring and input iterators.
4840 * testsuite/27_io/filesystem/path/construct/locale.cc: Check
4841 construction from iterators.
4842 * testsuite/experimental/filesystem/path/concat/strings.cc: Check for
4843 exact string equality, not path equivalence.
4844 * testsuite/experimental/filesystem/path/construct/locale.cc: Check
4845 construction from iterators.
4846
4847 * include/bits/fs_path.h (path::_M_type): Change default member
4848 initializer to _Filename.
4849 (path::begin): Create past-the-end iterator for empty path.
4850 * src/filesystem/std-path.cc (path::remove_filename()): Remove
4851 debugging check.
4852 (path::has_relative_path()): Return false for empty filenames.
4853 (path::_M_split_cmpts): Set _M_type to _Filename for empty paths.
4854 Fix offset of empty final component.
4855 * testsuite/27_io/filesystem/path/itr/components.cc: New.
4856 * testsuite/27_io/filesystem/path/itr/traversal.cc: Add new inputs.
4857
4858 2018-05-21 Jonathan Wakely <jwakely@redhat.com>
4859
4860 Add support for opening file streams from wide character strings.
4861 * config/io/basic_file_stdio.cc [_GLIBCXX_HAVE__WFOPEN]
4862 (__basic_file<char>::open(const wchar_t*, ios_base::openmode)):
4863 Define new overload.
4864 * config/io/basic_file_stdio.h [_GLIBCXX_HAVE__WFOPEN]
4865 (__basic_file<char>::open(const wchar_t*, ios_base::openmode)):
4866 Declare new overload.
4867 * configure.ac: Check for _wfopen.
4868 * crossconfig.m4: Likewise.
4869 * configure: Regenerate.
4870 * config.h.in: Regenerate.
4871 * include/bits/fstream.tcc [_GLIBCXX_HAVE__WFOPEN]
4872 (basic_filebuf<C,T>::open(const wchar_t*, ios_base::openmode)):
4873 Define new overload.
4874 * include/std/fstream [_GLIBCXX_HAVE__WFOPEN]
4875 (basic_filebuf<C,T>::open(const wchar_t*, ios_base::openmode)):
4876 Declare new overload.
4877 [_GLIBCXX_HAVE__WFOPEN]
4878 (basic_ifstream<C,T>::basic_ifstream(const wchar_t*, openmode))
4879 (basic_ifstream<C,T>::basic_open(const wchar_t*, openmode))
4880 (basic_ofstream<C,T>::basic_ifstream(const wchar_t*, openmode))
4881 (basic_ofstream<C,T>::basic_open(const wchar_t*, openmode))
4882 (basic_fstream<C,T>::basic_ifstream(const wchar_t*, openmode))
4883 (basic_fstream<C,T>::basic_open(const wchar_t*, openmode)): Define
4884 new overloads.
4885 * testsuite/27_io/basic_filebuf/open/wchar_t/1.cc: New.
4886 * testsuite/27_io/basic_ifstream/cons/wchar_t/1.cc: New.
4887 * testsuite/27_io/basic_ifstream/open/wchar_t/1.cc: New.
4888 * testsuite/27_io/basic_ofstream/cons/wchar_t/1.cc: New.
4889 * testsuite/27_io/basic_ofstream/open/wchar_t/1.cc: New.
4890 * testsuite/27_io/basic_fstream/cons/wchar_t/1.cc: New.
4891 * testsuite/27_io/basic_fstream/open/wchar_t/1.cc: New.
4892
4893 2018-05-21 François Dumont <fdumont@gcc.gnu.org>
4894
4895 PR libstdc++/85845
4896 * include/bits/stl_tree.h
4897 (_Rb_tree_impl(_Rb_tree_impl&&, _Node_allocator&&)): Fix noexcept
4898 qualification.
4899
4900 2018-05-21 Jonathan Wakely <jwakely@redhat.com>
4901
4902 * src/filesystem/std-ops.cc (absolute): Report an error for empty
4903 paths.
4904 (weakly_canonical(const path&)): Do not call canonical on empty path.
4905 (weakly_canonical(const path&, error_code&)): Likewise.
4906 * testsuite/27_io/filesystem/operations/absolute.cc: Check for errors.
4907
4908 PR libstdc++/85818
4909 * testsuite/experimental/filesystem/path/preferred_separator.cc: Add
4910 dg-require-filesystem-ts.
4911
4912 PR libstdc++/85843
4913 * src/c++11/cow-stdexcept.cc (logic_error, runtime_error): Explicitly
4914 initialize base class to avoid warnings.
4915
4916 2018-05-19 Jonathan Wakely <jwakely@redhat.com>
4917
4918 * src/c++11/codecvt.cc (__codecvt_utf8_base<wchar_t>::do_in)
4919 [__SIZEOF_WCHAR_T__==2 && __BYTE_ORDER__!=__ORDER_BIG_ENDIAN__]: Set
4920 little_endian element in bitmask.
4921 * testsuite/22_locale/codecvt/codecvt_utf8/69703.cc: Run all tests.
4922 * testsuite/22_locale/codecvt/codecvt_utf8/wchar_t/1.cc: New.
4923
4924 2018-05-18 François Dumont <fdumont@gcc.gnu.org>
4925
4926 * include/bits/stl_tree.h
4927 (_Rb_tree_impl(_Rb_tree_impl&&, _Node_allocator&&)): New.
4928 (_Rb_tree(_Rb_tree&&, _Node_allocator&&, true_type)): New, use latter.
4929 (_Rb_tree(_Rb_tree&&, _Node_allocator&&, false_type)): New.
4930 (_Rb_tree(_Rb_tree&&, _Node_allocator&&)): Adapt, use latters.
4931 * include/debug/map.h
4932 (map(map&&, const_allocator_type&)): Add noexcept qualitication.
4933 * include/debug/multimap.h
4934 (multimap(multimap&&, const_allocator_type&)): Likewise.
4935 * include/debug/set.h
4936 (set(set&&, const_allocator_type&)): Likewise.
4937 * include/debug/multiset.h
4938 (multiset(multiset&&, const_allocator_type&)): Likewise.
4939 * testsuite/23_containers/map/cons/noexcept_default_construct.cc:
4940 Add checks.
4941 * testsuite/23_containers/map/cons/noexcept_move_construct.cc:
4942 Add checks.
4943 * testsuite/23_containers/multimap/cons/noexcept_default_construct.cc:
4944 Add checks.
4945 * testsuite/23_containers/multimap/cons/noexcept_move_construct.cc:
4946 Add checks.
4947 * testsuite/23_containers/multiset/cons/noexcept_default_construct.cc:
4948 Add checks.
4949 * testsuite/23_containers/multiset/cons/noexcept_move_construct.cc:
4950 Add checks.
4951 * testsuite/23_containers/set/cons/noexcept_default_construct.cc:
4952 Add checks.
4953 * testsuite/23_containers/set/cons/noexcept_move_construct.cc:
4954 Add checks.
4955
4956 2018-05-18 Jason Merrill <jason@redhat.com>
4957
4958 * include/bits/stl_deque.h (_Deque_iterator): Constrain constructor
4959 for conversion to const_iterator. Add defaulted copy ops.
4960 * libsupc++/new (bad_alloc): Add defaulted copy ops.
4961 * libsupc++/exception.h (exception): Add defaulted copy ops.
4962 * include/std/system_error (system_error): Add defaulted copy ops.
4963 * include/std/stdexcept (domain_error, invalid_argument)
4964 (length_error, out_of_range, range_error, overflow_error)
4965 (underflow_error): Add defaulted copy ops.
4966 * include/bits/stl_iterator.h (reverse_iterator): Add defaulted
4967 copy assignment.
4968 * include/bits/allocator.h (allocator): Add defaulted copy assignment.
4969 * include/ext/throw_allocator.h (condition_base): Add defaulted
4970 default and copy ctor and copy assignment.
4971
4972 2018-05-18 Jonathan Wakely <jwakely@redhat.com>
4973
4974 PR libstdc++/85098
4975 * include/bits/regex.h [__cplusplus < 201703L] (basic_regex::icase)
4976 (basic_regex::nosubs, basic_regex::optimize, basic_regex::collate)
4977 (basic_regex::ECMAScript, basic_regex::basic, basic_regex::extended)
4978 (basic_regex::awk, basic_regex::grep, basic_regex::egrep): Add
4979 definitions.
4980 * include/bits/regex_automaton.h (_NFA::_M_insert_state): Adjust
4981 whitespace.
4982 * include/bits/regex_compiler.tcc (__INSERT_REGEX_MATCHER): Add
4983 braces around body of do-while.
4984 * testsuite/28_regex/basic_regex/85098.cc: New
4985
4986 2018-05-17 Jonathan Wakely <jwakely@redhat.com>
4987
4988 PR libstdc++/85818
4989 * src/filesystem/path.cc (path::preferred_separator): Add used
4990 attribute.
4991 * testsuite/experimental/filesystem/path/preferred_separator.cc: New.
4992
4993 PR libstdc++/85812
4994 * libsupc++/cxxabi_init_exception.h (__cxa_free_exception): Declare.
4995 * libsupc++/exception_ptr.h (make_exception_ptr) [__cpp_exceptions]:
4996 Refactor to separate non-throwing and throwing implementations.
4997 [__cpp_rtti && !_GLIBCXX_HAVE_CDTOR_CALLABI]: Deallocate the memory
4998 if constructing the object throws.
4999
5000 2018-05-15 Jonathan Wakely <jwakely@redhat.com>
5001
5002 PR libstdc++/85749
5003 * include/bits/random.h (__detail::__is_seed_seq): New SFINAE helper.
5004 (linear_congruential_engine, mersenne_twister_engine)
5005 (subtract_with_carry_engine, discard_block_engine)
5006 (independent_bits_engine, shuffle_order_engine): Use __is_seed_seq to
5007 constrain function templates taking seed sequences.
5008 * include/bits/random.tcc (linear_congruential_engine::seed(_Sseq&))
5009 (mersenne_twister_engine::seed(_Sseq&))
5010 (subtract_with_carry_engine::seed(_Sseq&)): Change return types to
5011 match declarations.
5012 * include/ext/random (simd_fast_mersenne_twister_engine): Use
5013 __is_seed_seq to constrain function templates taking seed sequences.
5014 * include/ext/random.tcc (simd_fast_mersenne_twister_engine::seed):
5015 Change return type to match declaration.
5016 * testsuite/26_numerics/random/discard_block_engine/cons/seed_seq2.cc:
5017 New.
5018 * testsuite/26_numerics/random/independent_bits_engine/cons/
5019 seed_seq2.cc: New.
5020 * testsuite/26_numerics/random/linear_congruential_engine/cons/
5021 seed_seq2.cc: New.
5022 * testsuite/26_numerics/random/mersenne_twister_engine/cons/
5023 seed_seq2.cc: New.
5024 * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error lineno.
5025 * testsuite/26_numerics/random/shuffle_order_engine/cons/seed_seq2.cc:
5026 New.
5027 * testsuite/26_numerics/random/subtract_with_carry_engine/cons/
5028 seed_seq2.cc: New.
5029 * testsuite/ext/random/simd_fast_mersenne_twister_engine/cons/
5030 seed_seq2.cc: New.
5031
5032 PR libstdc++/83891
5033 * include/bits/fs_path.h (path::is_absolute()): Use same definition
5034 for all operating systems.
5035 * include/experimental/bits/fs_path.h (path::is_absolute()): Likewise.
5036 * testsuite/27_io/filesystem/path/query/is_absolute.cc: New.
5037 * testsuite/27_io/filesystem/path/query/is_relative.cc: Fix comment.
5038 * testsuite/experimental/filesystem/path/query/is_absolute.cc: New.
5039
5040 * testsuite/27_io/filesystem/path/decompose/extension.cc: Remove
5041 unused <vector> header.
5042 * testsuite/27_io/filesystem/path/query/empty.cc: Likewise.
5043 * testsuite/27_io/filesystem/path/query/has_extension.cc: Likewise.
5044 * testsuite/27_io/filesystem/path/query/has_filename.cc: Likewise.
5045 * testsuite/27_io/filesystem/path/query/has_parent_path.cc: Likewise.
5046 * testsuite/27_io/filesystem/path/query/has_relative_path.cc:
5047 Likewise.
5048 * testsuite/27_io/filesystem/path/query/has_root_directory.cc:
5049 Likewise.
5050 * testsuite/27_io/filesystem/path/query/has_root_name.cc: Likewise.
5051 * testsuite/27_io/filesystem/path/query/has_root_path.cc: Likewise.
5052 * testsuite/27_io/filesystem/path/query/has_stem.cc: Likewise.
5053 * testsuite/27_io/filesystem/path/query/is_relative.cc: Likewise.
5054 * testsuite/experimental/filesystem/path/decompose/extension.cc:
5055 Likewise.
5056 * testsuite/experimental/filesystem/path/query/empty.cc: Likewise.
5057 * testsuite/experimental/filesystem/path/query/has_extension.cc:
5058 Likewise.
5059 * testsuite/experimental/filesystem/path/query/has_filename.cc:
5060 Likewise.
5061 * testsuite/experimental/filesystem/path/query/has_parent_path.cc:
5062 Likewise.
5063 * testsuite/experimental/filesystem/path/query/has_relative_path.cc:
5064 Likewise.
5065 * testsuite/experimental/filesystem/path/query/has_root_directory.cc:
5066 Likewise.
5067 * testsuite/experimental/filesystem/path/query/has_root_name.cc:
5068 Likewise.
5069 * testsuite/experimental/filesystem/path/query/has_root_path.cc:
5070 Likewise.
5071 * testsuite/experimental/filesystem/path/query/has_stem.cc: Likewise.
5072 * testsuite/experimental/filesystem/path/query/is_relative.cc:
5073 Likewise.
5074
5075 PR libstdc++/84159
5076 * include/bits/fs_path.h (path::operator/=, path::append): Construct
5077 temporary path before calling _M_append.
5078 (path::_M_append): Change parameter to path and implement C++17
5079 semantics.
5080 * testsuite/27_io/filesystem/path/append/path.cc: Add helper function
5081 and more examples from the standard.
5082 * testsuite/27_io/filesystem/path/append/source.cc: New.
5083 * testsuite/27_io/filesystem/path/decompose/filename.cc: Add comment.
5084 * testsuite/27_io/filesystem/path/nonmember/append.cc: New.
5085
5086 * include/std/variant (__gen_vtable_impl::__visit_invoke): Qualify
5087 __invoke to prevent ADL.
5088
5089 2018-05-14 Jonathan Wakely <jwakely@redhat.com>
5090
5091 PR libstdc++/81256
5092 * include/bits/fstream.tcc (basic_filebuf::close): Do not swallow
5093 exceptions from _M_terminate_output().
5094 * include/std/fstream (basic_filebuf::~basic_filebuf): Swallow any
5095 exceptions from close().
5096 * testsuite/27_io/basic_filebuf/close/81256.cc: New.
5097
5098 * include/bits/valarray_array.h (__valarray_get_memory): Remove.
5099 (__valarray_get_storage): Call operator new directly. Remove ignored
5100 top-level restrict qualifier and add malloc attribute instead.
5101 (_Array<_Tp>::_Array(size_t)): Remove unused constructor.
5102
5103 PR libstdc++/67554
5104 * include/bits/valarray_array.h (_Array_copy_ctor<_Tp, true>)
5105 (_Array_copier<_Tp, true>): Do not pass null pointers to memcpy.
5106
5107 PR libstdc++/82966
5108 * include/bits/node_handle.h (_Node_handle_common::_M_swap): Use value
5109 instead of type.
5110 * testsuite/23_containers/set/modifiers/node_swap.cc: New.
5111
5112 2018-05-13 Ville Voutilainen <ville.voutilainen@gmail.com>
5113
5114 PR libstdc++/80165
5115 * testsuite/20_util/variant/80165.cc: New.
5116
5117 2018-05-10 Jonathan Wakely <jwakely@redhat.com>
5118
5119 * doc/xml/faq.xml: Link to C++17 status. Add note to outdated answer.
5120 * doc/xml/manual/debug_mode.xml: Add array and forward_list to list
5121 of C++11 containers with Debug Mode support.
5122 * doc/xml/manual/using.xml: Document Dual ABI for ios_base::failure.
5123 * doc/html/*: Regenerate.
5124
5125 2018-05-10 Jason Merrill <jason@redhat.com>
5126
5127 * include/bits/regex_compiler.h (_S_cache_size): Change from
5128 function to variable.
5129
5130 2018-05-10 Edward Smith-Rowland <3dw4rd@verizon.net>
5131
5132 PR libstdc++/83140 - assoc_legendre returns negated value when m is odd
5133 * include/tr1/legendre_function.tcc (__assoc_legendre_p): Add __phase
5134 argument defaulted to +1. Doxy comments on same.
5135 * testsuite/special_functions/02_assoc_legendre/
5136 check_value.cc: Regen.
5137 * testsuite/tr1/5_numerical_facilities/special_functions/
5138 02_assoc_legendre/check_value.cc: Regen.
5139
5140 2018-05-10 Jonathan Wakely <jwakely@redhat.com>
5141
5142 PR libstdc++/85729
5143 * include/bits/c++config.h (__replacement_assert): Add linkage
5144 specification.
5145 * include/bits/std_abs.h: Add comment to closing brace of block.
5146 * include/c_global/cstddef: Add linkage specification.
5147 * include/c_global/cstring: Likewise.
5148 * include/c_global/cwchar: Likewise.
5149
5150 2018-05-09 François Dumont <fdumont@gcc.gnu.org>
5151
5152 * include/debug/safe_iterator.h (_Safe_iterator<>::_M_constant()):
5153 Rename in...
5154 (_Safe_iterator<>::_S_constant()): ...that.
5155 * include/debug/safe_local_iterator.h
5156 (_Safe_local_iterator<>::_M_constant()): Rename in...
5157 (_Safe_local_iterator<>::_S_constant()): ...that.
5158 * include/debug/formatter.h: Remove bits/cpp_type_traits.h include.
5159 (_Iterator_state::__rbegin): New.
5160 (_Iterator_state::__rmiddle): New.
5161 (_Iterator_state::__rend): New.
5162 (_Parameter::_Parameter(const _Safe_iterator<>&, const char*,
5163 _Is_iterator)): Use _Safe_iterator<>::_S_constant. Grab normal underlying
5164 iterator type.
5165 (_Parameter::_Parameter(const _Safe_local_iterator<>&, const char*,
5166 _Is_iterator)): Likewise.
5167 (_Parameter::_S_reverse_state(_Iterator_state)): New.
5168 (_Parameter(__gnu_cxx::__normal_iterator<> const&, const char*,
5169 _Is_iterator)): New.
5170 (_Parameter(std::reverse_iterator<> const&, const char*,
5171 _Is_iterator)): New.
5172 (_Parameter(std::reverse_iterator<_Safe_iterator<>> const&,
5173 const char*, _Is_iterator)): New.
5174 (_Parameter(std::move_iterator<> const&, const char*, _Is_iterator):
5175 New.
5176 (_Parameter(std::move_iterator<_Safe_iterator<>> const&, const char*,
5177 _Is_iterator)): New.
5178 * testsuite/24_iterators/move_iterator/debug_neg.cc: New.
5179 * testsuite/24_iterators/normal_iterator/debug_neg.cc: New.
5180 * testsuite/24_iterators/reverse_iterator/debug_neg.cc: New.
5181
5182 2018-05-09 Jonathan Wakely <jwakely@redhat.com>
5183
5184 * include/bits/std_function.h (_Base_manager::_M_get_pointer):
5185 Use constexpr if in C++17 mode.
5186 (_Base_manager::_M_clone(_Any_data&, const _Any_data&, true_type)):
5187 Copy from const object.
5188 * testsuite/20_util/function/cons/non_copyconstructible.cc: New.
5189
5190 2018-05-08 François Dumont <fdumont@gcc.gnu.org>
5191
5192 * src/c++11/debug.cc [_GLIBCXX_HAVE_EXECINFO_H]: Include execinfo.h.
5193 [_GLIBCXX_HAVE_EXECINFO_H](_Error_formatter::_M_error): Render
5194 backtrace.
5195
5196 * include/debug/macros.h (__glibcxx_check_valid_range_at): New.
5197 * include/debug/functions.h (__check_valid_range): Use latter.
5198 * include/debug/macros.h (__glibcxx_check_valid_constructor_range): New,
5199 use latter.
5200 * include/debug/deque
5201 (deque::deque<_Iter>(_Iter, _Iter, const _Alloc&)): Use latter.
5202 * include/debug/forward_list
5203 (forward_list::forward_list<_Iter>(_Iter, _Iter, const _Alloc&)):
5204 Likewise.
5205 * include/debug/list
5206 (list::list<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
5207 * include/debug/list
5208 (list::list<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
5209 * include/debug/map.h
5210 (map::map<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
5211 (map::map<_Iter>(_Iter, _Iter, const _Compare&, const _Alloc&)):
5212 Likewise.
5213 * include/debug/multimap.h
5214 (multimap::multimap<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
5215 (multimap::multimap<_Iter>(_Iter, _Iter, const _Compare&,
5216 const _Alloc&)): Likewise.
5217 * include/debug/set.h
5218 (set::set<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
5219 (set::set<_Iter>(_Iter, _Iter, const _Compare&, const _Alloc&)):
5220 Likewise.
5221 * include/debug/multiset.h
5222 (multiset::multiset<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
5223 (multiset::multiset<_Iter>(_Iter, _Iter, const _Compare&,
5224 const _Alloc&)): Likewise.
5225 * include/debug/string
5226 (basic_string::basic_string<_Iter>(_Iter, _Iter, const _Alloc&)):
5227 Likewise.
5228 * include/debug/unordered_map
5229 (unordered_map::unordered_map<_Iter>(_Iter, _Iter, const _Alloc&)):
5230 Likewise.
5231 (unordered_multimap::unordered_multimap<_Iter>(_Iter, _Iter,
5232 const _Alloc&)): Likewise.
5233 * include/debug/unordered_set
5234 (unordered_set::unordered_set<_Iter>(_Iter, _Iter, const _Alloc&)):
5235 Likewise.
5236 (unordered_multiset::unordered_multiset<_Iter>(_Iter, _Iter,
5237 const _Alloc&)): Likewise.
5238 * include/debug/vector
5239 (vector::vector<_Iter>(_Iter, _Iter, const _Alloc&)): Use latter.
5240
5241 * include/debug/formatter.h (_Error_formatter::_M_function): New.
5242 (_Error_formatter(const char*, unsigned int)): Adapt.
5243 (_Error_formatter::_M_at): Rename in...
5244 (_Error_formatter::_S_at): ...that and adapt.
5245 * include/debug/macros.h (_GLIBCXX_DEBUG_VERIFY_AT_F): New.
5246 (_GLIBCXX_DEBUG_VERIFY_AT, _GLIBCXX_DEBUG_VERIFY): Adapt.
5247 * src/c++11/debug.cc (_Error_formatter::_M_error): Render _M_function
5248 when available.
5249
5250 2018-05-08 Jonathan Wakely <jwakely@redhat.com>
5251
5252 * include/bits/regex_automaton.h (_NFA_base::_M_paren_stack, _NFA):
5253 Use normal std::vector even in Debug Mode.
5254
5255 PR libstdc++/85672
5256 * include/Makefile.am [!ENABLE_FLOAT128]: Change c++config.h entry
5257 to #undef _GLIBCXX_USE_FLOAT128 instead of defining it to zero.
5258 * include/Makefile.in: Regenerate.
5259 * include/bits/c++config (_GLIBCXX_USE_FLOAT128): Move definition
5260 within conditional block.
5261
5262 2018-05-07 Jonathan Wakely <jwakely@redhat.com>
5263
5264 * doc/xml/manual/using.xml (table.cmd_options): Document that the
5265 C++17 Filesystem implementation also needs -lstdc++fs.
5266
5267 PR libstdc++/85671
5268 * include/bits/fs_path.h (operator/): Permit copy elision.
5269 * include/experimental/bits/fs_path.h (operator/): Likewise.
5270
5271 2018-05-07 Edward Smith-Rowland <3dw4rd@verizon.net>
5272
5273 Moar PR libstdc++/80506
5274 * include/bits/random.tcc (gamma_distribution::__generate_impl()):
5275 Fix magic number used in loop condition.
5276
5277 2018-05-04 Jonathan Wakely <jwakely@redhat.com>
5278
5279 PR libstdc++/85642 fix is_nothrow_default_constructible<optional<T>>
5280 * include/std/optional (_Optional_payload): Add noexcept to default
5281 constructor. Re-indent.
5282 (_Optional_payload<_Tp, true, true, true>): Likewise. Add noexcept to
5283 constructor for copying disengaged payloads.
5284 (_Optional_payload<_Tp, true, false, true>): Likewise.
5285 (_Optional_payload<_Tp, true, true, false>): Likewise.
5286 (_Optional_payload<_Tp, true, false, false>): Likewise.
5287 * testsuite/20_util/optional/cons/85642.cc: New.
5288 * testsuite/20_util/optional/cons/value_neg.cc: Adjust dg-error lines.
5289
5290 2018-05-03 Jonathan Wakely <jwakely@redhat.com>
5291
5292 PR libstdc++/82644
5293 * include/tr1/cmath [__STRICT_ANSI__] (hypergf, hypergl, hyperg): Use
5294 inline definitions instead of using-declarations.
5295 [__STRICT_ANSI__] (conf_hypergf, conf_hypergl, conf_hyperg): Likewise.
5296 * testsuite/tr1/5_numerical_facilities/special_functions/
5297 07_conf_hyperg/compile_cxx17.cc: New.
5298 * testsuite/tr1/5_numerical_facilities/special_functions/
5299 17_hyperg/compile_cxx17.cc: New.
5300
5301 PR libstdc++/84769
5302 * include/std/variant (visit): Qualify std::get call.
5303
5304 PR libstdc++/85632 use uintmax_t for arithmetic
5305 * src/filesystem/ops.cc (experimental::filesystem::space): Perform
5306 arithmetic in result type.
5307 * src/filesystem/std-ops.cc (filesystem::space): Likewise.
5308 * testsuite/27_io/filesystem/operations/space.cc: Check total capacity
5309 is greater than free space.
5310 * testsuite/experimental/filesystem/operations/space.cc: New.
5311
5312 * testsuite/20_util/remove_cvref/requirements/alias_decl.cc: New.
5313 * testsuite/20_util/remove_cvref/requirements/explicit_instantiation.cc:
5314 New.
5315 * testsuite/20_util/remove_cvref/value.cc: New.
5316 * testsuite/20_util/remove_cvref/value_ext.cc: New.
5317
5318 PR libstdc++/84087 LWG DR 2268 basic_string default arguments
5319 * include/bits/basic_string.h [_GLIBCXX_USE_CXX11_ABI=1]
5320 (append(const basic_string&, size_type, size_type)
5321 (assign(const basic_string&, size_type, size_type)
5322 (insert(size_type, const basic_string&, size_type, size_type)
5323 (replace(size_type,size_type,const basic_string&,size_type,size_type)
5324 (compare(size_type,size_type,constbasic_string&,size_type,size_type)):
5325 Add default arguments (LWG 2268).
5326 [_GLIBCXX_USE_CXX11_ABI=0]
5327 (append(const basic_string&, size_type, size_type)
5328 (assign(const basic_string&, size_type, size_type)
5329 (insert(size_type, const basic_string&, size_type, size_type)
5330 (replace(size_type,size_type,const basic_string&,size_type,size_type)
5331 (compare(size_type,size_type,constbasic_string&,size_type,size_type)):
5332 Likewise.
5333 * testsuite/21_strings/basic_string/dr2268.cc: New test.
5334
5335 PR libstdc++/84535
5336 * include/std/thread (thread::__not_same): New SFINAE helper.
5337 (thread::thread(_Callable&&, _Args&&...)): Add SFINAE constraint that
5338 first argument is not a std::thread. Add static assertion to check
5339 INVOKE expression is valid.
5340 (thread::thread(thread&), thread::thread(const thread&&)): Remove.
5341 (thread::_Invoke::_M_invoke, thread::_Invoke::operator()): Use
5342 __invoke_result for return types and remove exception specifications.
5343 * testsuite/30_threads/thread/cons/84535.cc: New.
5344
5345 * include/std/future (__async_result_of): Use __invoke_result instead
5346 of result_of.
5347
5348 * include/std/any (any_cast): Use __remove_cvref_t.
5349 * include/std/tuple (__make_tuple): Likewise.
5350 * include/std/type_traits (__remove_cvref_t): Define.
5351 (__result_of_memobj, __result_of_memfun): Use __remove_cvref_t.
5352 [__cplusplus > 201703L] (remove_cvref, remove_cvref_t): Define.
5353 * include/std/variant (__erased_hash): Use __remove_cvref_t.
5354
5355 2018-05-02 François Dumont <fdumont@gcc.gnu.org>
5356
5357 * include/bits/deque.tcc (deque<>::_M_assign_aux): Cast to void to
5358 ensure overloaded comma not used.
5359 * include/bits/list.tcc (list<>::_M_assign_dispatch): Likewise.
5360 * include/bits/vector.tcc (vector<>::_M_assign_aux): Likewise.
5361 * include/bits/stl_bvector.h (vector<bool>::_M_assign_aux): Likewise.
5362 * testsuite/23_containers/deque/modifiers/assign/1.cc: New.
5363 * testsuite/23_containers/list/modifiers/assign/1.cc: New.
5364 * testsuite/23_containers/vector/bool/modifiers/assign/1.cc: New.
5365 * testsuite/23_containers/vector/modifiers/assign/1.cc: New.
5366
5367 2018-05-02 Jonathan Wakely <jwakely@redhat.com>
5368
5369 PR libstdc++/68197
5370 * include/bits/ios_base.h (ios_base::iword, ios_base::pword): Cast
5371 indices to unsigned.
5372 * src/c++11/ios.cc (ios_base::_M_grow_words): Treat negative indices
5373 as failure. Refactor error handling.
5374 * testsuite/27_io/ios_base/storage/68197.cc: New.
5375
5376 PR libstdc++/57997
5377 PR libstdc++/83860
5378 * include/bits/gslice_array.h (gslice_array): Define default
5379 constructor as deleted, as per C++11 standard.
5380 * include/bits/mask_array.h (mask_array): Likewise.
5381 * include/bits/slice_array.h (slice_array): Likewise.
5382 * include/bits/valarray_after.h (_GBase, _GClos, _IBase, _IClos): Move
5383 to namespace __detail.
5384 (_GBase::_M_expr, _IBase::_M_expr): Use _ValArrayRef for type of data
5385 members.
5386 * include/bits/valarray_before.h (_ValArrayRef): New helper for type
5387 of data members in closure objects.
5388 (_FunBase, _ValFunClos, _RefFunClos, _UnBase, _UnClos, _BinBase)
5389 (_BinBase2, _BinBase1, _BinClos, _SBase, _SClos): Move to namespace
5390 __detail.
5391 (_FunBase::_M_expr, _UnBase::_M_expr, _BinBase::_M_expr1)
5392 (_BinBase::_M_expr2, _BinBase2::_M_expr1, _BinBase1::_M_expr2)
5393 (_SBase::_M_expr): Use _ValArrayRef for type of data members.
5394 * include/std/valarray (_UnClos, _BinClos, _SClos, _GClos, _IClos)
5395 (_ValFunClos, _RefFunClos): Move to namespace __detail and add
5396 using-declarations to namespace std.
5397 * testsuite/26_numerics/valarray/83860.cc: New.
5398
5399 * testsuite/backward/strstream_move.cc: Remove duplicate function
5400 call.
5401
5402 PR libstdc++/69608
5403 * include/backward/strstream (strstreambuf): Define move constructor
5404 and move assignment operator.
5405 (istrstream, ostrstream, strstream): Likewise.
5406 * testsuite/backward/strstream_move.cc: New.
5407
5408 2018-05-01 Tulio Magno Quites Machado Filho <tuliom@linux.vnet.ibm.com>
5409
5410 PR libstdc++/84654
5411 * acinclude.m4: Set ENABLE_FLOAT128 instead of _GLIBCXX_USE_FLOAT128.
5412 * config.h.in: Remove references to _GLIBCXX_USE_FLOAT128.
5413 * configure: Regenerate.
5414 * include/Makefile.am: Replace the value of _GLIBCXX_USE_FLOAT128
5415 based on ENABLE_FLOAT128.
5416 * include/Makefile.in: Regenerate.
5417 * include/bits/c++config: Define _GLIBCXX_USE_FLOAT128.
5418 [!defined(__FLOAT128__) && !defined(__SIZEOF_FLOAT128__)]: Undefine
5419 _GLIBCXX_USE_FLOAT128.
5420
5421 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
5422
5423 * configure: Regenerated.
5424
5425 2018-04-19 Jakub Jelinek <jakub@redhat.com>
5426
5427 * configure: Regenerated.
5428
5429 2018-04-18 Jonathan Wakely <jwakely@redhat.com>
5430 Jakub Jelinek <jakub@redhat.com>
5431
5432 PR libstdc++/85442
5433 * src/c++11/Makefile.am: Don't generate debuginfo again for
5434 cxx11-ios_failure-lt.s and cxx11-ios_failure.s files.
5435 * src/c++11/Makefile.in: Regenerate.
5436
5437 2018-04-18 Jonathan Wakely <jwakely@redhat.com>
5438
5439 PR libstdc++/84442
5440 * testsuite/30_threads/thread/cons/terminate.cc
5441 [!_GLIBCXX_USE_C99_STDLIB] : Use _exit or std::exit instead of _Exit.
5442
5443 2018-04-18 David Malcolm <dmalcolm@redhat.com>
5444
5445 PR jit/85384
5446 * configure: Regenerate.
5447
5448 2018-04-16 Jonathan Wakely <jwakely@redhat.com>
5449
5450 * testsuite/experimental/filesystem/file_status/1.cc: Add
5451 -DUSE_FILESYSTEM_TS to dg-options.
5452 * testsuite/experimental/filesystem/iterators/directory_iterator.cc:
5453 Likewise.
5454 * testsuite/experimental/filesystem/iterators/pop.cc: Likewise.
5455 * testsuite/experimental/filesystem/iterators/
5456 recursive_directory_iterator.cc: Likewise.
5457 * testsuite/experimental/filesystem/operations/absolute.cc: Likewise.
5458 * testsuite/experimental/filesystem/operations/canonical.cc: Likewise.
5459 * testsuite/experimental/filesystem/operations/copy.cc: Likewise.
5460 * testsuite/experimental/filesystem/operations/copy_file.cc: Likewise.
5461 * testsuite/experimental/filesystem/operations/create_directories.cc:
5462 Likewise.
5463 * testsuite/experimental/filesystem/operations/create_directory.cc:
5464 Likewise.
5465 * testsuite/experimental/filesystem/operations/create_symlink.cc:
5466 Likewise.
5467 * testsuite/experimental/filesystem/operations/current_path.cc:
5468 Likewise.
5469 * testsuite/experimental/filesystem/operations/equivalent.cc: Likewise.
5470 * testsuite/experimental/filesystem/operations/exists.cc: Likewise.
5471 * testsuite/experimental/filesystem/operations/file_size.cc: Likewise.
5472 * testsuite/experimental/filesystem/operations/is_empty.cc: Likewise.
5473 * testsuite/experimental/filesystem/operations/last_write_time.cc:
5474 Likewise.
5475 * testsuite/experimental/filesystem/operations/permissions.cc:
5476 Likewise.
5477 * testsuite/experimental/filesystem/operations/read_symlink.cc:
5478 Likewise.
5479 * testsuite/experimental/filesystem/operations/remove.cc: Likewise.
5480 * testsuite/experimental/filesystem/operations/remove_all.cc: Likewise.
5481 * testsuite/experimental/filesystem/operations/status.cc: Likewise.
5482 * testsuite/experimental/filesystem/operations/temp_directory_path.cc:
5483 Likewise.
5484 * testsuite/experimental/filesystem/path/append/path.cc: Likewise.
5485 * testsuite/experimental/filesystem/path/assign/assign.cc: Likewise.
5486 * testsuite/experimental/filesystem/path/assign/copy.cc: Likewise.
5487 * testsuite/experimental/filesystem/path/compare/compare.cc: Likewise.
5488 * testsuite/experimental/filesystem/path/compare/path.cc: Likewise.
5489 * testsuite/experimental/filesystem/path/compare/strings.cc: Likewise.
5490 * testsuite/experimental/filesystem/path/concat/path.cc: Likewise.
5491 * testsuite/experimental/filesystem/path/concat/strings.cc: Likewise.
5492 * testsuite/experimental/filesystem/path/construct/copy.cc: Likewise.
5493 * testsuite/experimental/filesystem/path/construct/default.cc:
5494 Likewise.
5495 * testsuite/experimental/filesystem/path/construct/locale.cc: Likewise.
5496 * testsuite/experimental/filesystem/path/construct/range.cc: Likewise.
5497 * testsuite/experimental/filesystem/path/construct/string_view.cc:
5498 Likewise.
5499 * testsuite/experimental/filesystem/path/decompose/extension.cc:
5500 Likewise.
5501 * testsuite/experimental/filesystem/path/decompose/filename.cc:
5502 Likewise.
5503 * testsuite/experimental/filesystem/path/decompose/parent_path.cc:
5504 Likewise.
5505 * testsuite/experimental/filesystem/path/decompose/relative_path.cc:
5506 Likewise.
5507 * testsuite/experimental/filesystem/path/decompose/root_directory.cc:
5508 Likewise.
5509 * testsuite/experimental/filesystem/path/decompose/root_name.cc:
5510 Likewise.
5511 * testsuite/experimental/filesystem/path/decompose/root_path.cc:
5512 Likewise.
5513 * testsuite/experimental/filesystem/path/decompose/stem.cc: Likewise.
5514 * testsuite/experimental/filesystem/path/generic/generic_string.cc:
5515 Likewise.
5516 * testsuite/experimental/filesystem/path/itr/traversal.cc: Likewise.
5517 * testsuite/experimental/filesystem/path/modifiers/clear.cc: Likewise.
5518 * testsuite/experimental/filesystem/path/modifiers/make_preferred.cc:
5519 Likewise.
5520 * testsuite/experimental/filesystem/path/modifiers/remove_filename.cc:
5521 Likewise.
5522 * testsuite/experimental/filesystem/path/modifiers/replace_extension.cc:
5523 Likewise.
5524 * testsuite/experimental/filesystem/path/modifiers/replace_filename.cc:
5525 Likewise.
5526 * testsuite/experimental/filesystem/path/modifiers/swap.cc: Likewise.
5527 * testsuite/experimental/filesystem/path/native/string.cc: Likewise.
5528 * testsuite/experimental/filesystem/path/nonmember/hash_value.cc:
5529 Likewise.
5530 * testsuite/experimental/filesystem/path/query/empty.cc: Likewise.
5531 * testsuite/experimental/filesystem/path/query/has_extension.cc:
5532 Likewise.
5533 * testsuite/experimental/filesystem/path/query/has_filename.cc:
5534 Likewise.
5535 * testsuite/experimental/filesystem/path/query/has_parent_path.cc:
5536 Likewise.
5537 * testsuite/experimental/filesystem/path/query/has_relative_path.cc:
5538 Likewise.
5539 * testsuite/experimental/filesystem/path/query/has_root_directory.cc:
5540 Likewise.
5541 * testsuite/experimental/filesystem/path/query/has_root_name.cc:
5542 Likewise.
5543 * testsuite/experimental/filesystem/path/query/has_root_path.cc:
5544 Likewise.
5545 * testsuite/experimental/filesystem/path/query/has_stem.cc: Likewise.
5546 * testsuite/experimental/filesystem/path/query/is_relative.cc:
5547 Likewise.
5548
5549 2018-04-13 Jonathan Wakely <jwakely@redhat.com>
5550
5551 * src/c++11/Makefile.am: Fix sed command.
5552 * src/c++11/Makefile.in: Regenerate.
5553
5554 * src/c++11/Makefile.am: Rewrite sed rule to be less fragile and to
5555 handle mangled names starting with double underscores on darwin.
5556 * src/c++11/Makefile.in: Regenerate.
5557
5558 2018-04-12 Jonathan Wakely <jwakely@redhat.com>
5559
5560 * src/c++11/Makefile.am: Fix comment.
5561 * src/c++11/Makefile.in: Regenerate.
5562 * src/c++11/cxx11-ios_failure.cc: Fix comment.
5563 * src/c++98/ios_failure.cc: Likewise.
5564
5565 * src/c++11/ios.cc: Remove redundant macro definition.
5566
5567 2018-04-11 Jonathan Wakely <jwakely@redhat.com>
5568
5569 * doc/xml/manual/abi.xml: Document header locations in recent
5570 releases.
5571 * doc/xml/manual/evolution.xml: Add API changes since GCC 5.
5572 * doc/xml/manual/spine.xml: Update copyright years.
5573 * doc/xml/manual/strings.xml: Adjust tolower example to avoid
5574 undefined behaviour.
5575 * doc/xml/manual/test.xml: Update outdated notes on VERIFY in tests.
5576 * doc/html/*: Regenerate.
5577
5578 2018-04-10 Jonathan Wakely <jwakely@redhat.com>
5579
5580 * doc/xml/faq.xml: Update links to archived copy of SGI STL docs.
5581 * doc/xml/manual/backwards_compatibility.xml: Likewise.
5582 * doc/xml/manual/containers.xml: Likewise.
5583 * doc/xml/manual/debug_mode.xml: Likewise.
5584 * doc/xml/manual/extensions.xml: Likewise.
5585 * doc/xml/manual/policy_data_structures_biblio.xml: Likewise.
5586 * doc/xml/manual/using.xml: Likewise.
5587 * doc/xml/manual/utilities.xml: Likewise.
5588
5589 PR libstdc++/85222
5590 * src/c++11/Makefile.am [ENABLE_DUAL_ABI]: Add special rules for
5591 cxx11-ios_failure.cc to rewrite type info for __ios_failure.
5592 * src/c++11/Makefile.in: Regenerate.
5593 * src/c++11/cxx11-ios_failure.cc (__ios_failure, __iosfail_type_info):
5594 New types.
5595 [_GLIBCXX_USE_DUAL_ABI] (__throw_ios_failure): Define here.
5596 * src/c++11/ios.cc (__throw_ios_failure): Remove definition.
5597 * src/c++98/ios_failure.cc (__construct_ios_failure)
5598 (__destroy_ios_failure, is_ios_failure_handler): New functions.
5599 [!_GLIBCXX_USE_DUAL_ABI] (__throw_ios_failure): Define here.
5600 * testsuite/27_io/ios_base/failure/dual_abi.cc: New.
5601 * testsuite/27_io/basic_ios/copyfmt/char/1.cc: Revert changes to
5602 handler types, to always catch std::ios_base::failure.
5603 * testsuite/27_io/basic_ios/exceptions/char/1.cc: Likewise.
5604 * testsuite/27_io/basic_istream/extractors_arithmetic/char/
5605 exceptions_failbit.cc: Likewise.
5606 * testsuite/27_io/basic_istream/extractors_arithmetic/wchar_t/
5607 exceptions_failbit.cc: Likewise.
5608 * testsuite/27_io/basic_istream/extractors_other/char/
5609 exceptions_null.cc: Likewise.
5610 * testsuite/27_io/basic_istream/extractors_other/wchar_t/
5611 exceptions_null.cc: Likewise.
5612 * testsuite/27_io/basic_istream/sentry/char/12297.cc: Likewise.
5613 * testsuite/27_io/basic_istream/sentry/wchar_t/12297.cc: Likewise.
5614 * testsuite/27_io/basic_ostream/inserters_other/char/
5615 exceptions_null.cc: Likewise.
5616 * testsuite/27_io/basic_ostream/inserters_other/wchar_t/
5617 exceptions_null.cc: Likewise.
5618 * testsuite/27_io/ios_base/storage/2.cc: Likewise.
5619
5620 2018-04-05 Jonathan Wakely <jwakely@redhat.com>
5621
5622 * include/std/variant (_VARIANT_RELATION_FUNCTION_TEMPLATE): Qualify
5623 __get calls to avoid ADL and avoid ambiguity due to Clang bug.
5624
5625 2018-04-03 Jonathan Wakely <jwakely@redhat.com>
5626
5627 PR libstdc++/85183
5628 * include/std/variant (_Move_assign_base::operator=): Fix incorrect
5629 value categories.
5630 * testsuite/20_util/variant/85183.cc: New.
5631
5632 2018-03-26 Jonathan Wakely <jwakely@redhat.com>
5633
5634 * include/std/variant (__get): Qualify calls to avoid ADL.
5635 (__select_index): Adjust whitespace.
5636 (variant): Add using-declaration to workaround Clang bug.
5637
5638 2018-03-22 Jonathan Wakely <jwakely@redhat.com>
5639
5640 PR libstdc++/85040
5641 * include/bits/stl_function.h (greater::__not_overloaded)
5642 (less::__not_overloaded, greater_equal::__not_overloaded)
5643 (less_equal::__not_overloaded): Fix ambiguous specializations.
5644 * testsuite/20_util/function_objects/comparisons_pointer.cc: Add
5645 tests for type with overloaded operators.
5646
5647 2018-03-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5648
5649 PR libstdc++/77691
5650 * testsuite/experimental/memory_resource/resource_adaptor.cc:
5651 xfail execution on 32-bit Solaris/x86.
5652
5653 2018-03-21 Jonathan Wakely <jwakely@redhat.com>
5654
5655 * testsuite/20_util/function_objects/comparisons_pointer.cc: Use
5656 VERIFY instead of assert.
5657 * testsuite/20_util/hash/84998.cc: New test.
5658 * testsuite/23_containers/vector/cons/destructible_debug_neg.cc: New
5659 copy of test adjusted for Debug Mode.
5660 * testsuite/23_containers/vector/cons/destructible_neg.cc: Do not run
5661 test in Debug Mode.
5662
5663 2018-03-20 François Dumont <fdumont@gcc.gnu.org>
5664
5665 PR libstdc++/84998
5666 * include/bits/stl_bvector.h: Fix std::hash friend declaration.
5667 * include/std/bitset: Likewise.
5668 * include/bits/stl_map.h (std::map<>): Fix _Rb_tree_merge_helper friend
5669 declaration.
5670 * include/bits/stl_multimap.h (std::multimap<>): Likewise.
5671 * include/bits/stl_multiset.h (std::multiset<>): Likewise.
5672 * include/bits/stl_set.h (std::set<>): Likewise.
5673 * include/bits/unordered_map.h (std::unordered_map<>): Fix
5674 _Hash_merge_helper friend declaration.
5675 (std::unordered_multimap<>): Likewise.
5676 * include/bits/unordered_set.h (std::unordered_set<>): Likewise.
5677 (std::unordered_multiset<>): Likewise.
5678
5679 2018-03-19 Gerald Pfeifer <gerald@pfeifer.com>
5680
5681 * doc/xml/api.xml: www.fsf.org has moved to https. Also omit
5682 trailing slash for domain level link.
5683 * doc/xml/faq.xml: Ditto.
5684 * doc/xml/manual/appendix_free.xml (software): Ditto.
5685 * doc/xml/manual/intro.xml: Ditto.
5686 * doc/xml/manual/spine.xml: Ditto.
5687 * doc/xml/spine.xml: Ditto.
5688
5689 2018-03-19 Gerald Pfeifer <gerald@pfeifer.com>
5690
5691 * doc/xml/manual/documentation_hacking.xml: Adjust link to
5692 docbook.org.
5693
5694 2018-03-17 Jonathan Wakely <jwakely@redhat.com>
5695
5696 * testsuite/20_util/function_objects/comparisons_pointer.cc: Adjust
5697 to compile as C++98.
5698
5699 2018-03-14 Jonathan Wakely <jwakely@redhat.com>
5700
5701 PR libstdc++/78420
5702 * include/bits/stl_function.h (greater<_Tp*>, less<_Tp*>)
5703 (greater_equal<_Tp*>, less_equal<_Tp>*): Add partial specializations
5704 to ensure total order for pointers.
5705 (greater<void>, less<void>, greater_equal<void>, less_equal<void>):
5706 Add operator() overloads for pointer arguments and make generic
5707 overloads dispatch to new _S_cmp functions when comparisons would
5708 use built-in operators for pointers.
5709 * testsuite/20_util/function_objects/comparisons_pointer.cc: New.
5710
5711 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
5712
5713 PR libstdc++/84773
5714 PR libstdc++/83662
5715 * crossconfig.m4: Check for aligned_alloc etc. on freebsd and mingw32.
5716 * configure: Regenerate.
5717 * include/c_global/cstdlib [_GLIBCXX_HAVE_ALIGNED_ALLOC]
5718 (aligned_alloc): Add using-declaration.
5719 * testsuite/18_support/aligned_alloc/aligned_alloc.cc: New test.
5720
5721 2018-03-09 François Dumont <fdumont@gcc.gnu.org>
5722
5723 * python/libstdcxx/v6/printers.py (build_libstdcxx_dictionary):
5724 Fix std::_Fwd_list_iterator and std::_Fwd_list_const_iterator printers
5725 registration.
5726
5727 2018-03-09 Jonathan Wakely <jwakely@redhat.com>
5728
5729 PR libstdc++/84769
5730 * include/std/variant (get<_Tp, _Types...>, get_if<_Tp, _Types...>):
5731 Qualify calls to get<_Np, Types...> and get_if<_Np, _Types...>.
5732
5733 src/filesystem/ops.cc (create_dir): Pass error_code to is_directory.
5734 src/filesystem/std-ops.cc (create_dir): Likewise.
5735
5736 2018-03-08 François Dumont <fdumont@gcc.gnu.org>
5737
5738 * python/libstdcxx/v6/printers.py (NodeIteratorPrinter): New.
5739 (StdListIteratorPrinter): Inherit from latter.
5740 (StdFwdListIteratorPrinter): New, inherit from latter.
5741 (StdDebugIteratorPrinter.to_string): Use non-debug iterator printer
5742 when iterator has no associated container.
5743 (build_libstdcxx_dictionary): Add __gnu_cxx::_Fwd_list_iterator and
5744 __gnu_cxx::_Fwd_list_const_iterator printers. Remove __norm namespace
5745 registrations.
5746 * testsuite/libstdc++-prettyprinters/debug.cc: Adapt.
5747 * testsuite/libstdc++-prettyprinters/debug_cxx11.cc: Adapt.
5748
5749 2018-03-06 Ville Voutilainen <ville.voutilainen@gmail.com>
5750
5751 PR libstdc++/84601
5752 * include/std/optional (_Optional_payload): Split into multiple
5753 specializations that can handle different cases of trivial or
5754 non-trivial assignment operators.
5755 * testsuite/20_util/optional/84601.cc: New.
5756 * testsuite/20_util/optional/cons/value_neg.cc: Adjust.
5757
5758 2018-03-02 Jonathan Wakely <jwakely@redhat.com>
5759
5760 PR libstdc++/84671
5761 * include/bits/parse_numbers.h (_Number_help): Add partial
5762 specialization to handle digit separators. Adjust partial
5763 specialization for recursion temrination to require _Pow == 1ULL.
5764 * testsuite/20_util/duration/literals/84671.cc: New
5765
5766 2018-02-27 Ville Voutilainen <ville.voutilainen@gmail.com>
5767
5768 Implement the missing bits of LWG 2769
5769 * include/std/any (any_cast(const any&)): Add static_assert.
5770 (any_cast(any&)): Likewise.
5771 (any_cast(any&&)): Likewise, and remove the handling
5772 for copyable-but-not-movable type.
5773 * testsuite/20_util/any/misc/any_cast.cc: Adjust.
5774 * testsuite/20_util/any/misc/any_cast_neg.cc: Likewise, and
5775 add new tests.
5776
5777 2018-02-23 Jonathan Wakely <jwakely@redhat.com>
5778
5779 PR libstdc++/84532
5780 * include/std/thread (thread::__make_invoker): Construct tuple
5781 directly instead of using make_tuple.
5782 * testsuite/30_threads/async/84532.cc: New.
5783 * testsuite/30_threads/thread/84532.cc: New.
5784
5785 2018-02-20 François Dumont <fdumont@gcc.gnu.org>
5786
5787 * include/ext/aligned_buffer.h [_GLIBCXX_INLINE_VERSION]
5788 (template<> __aligned_buffer): Define as __aligned_membuf alias.
5789
5790 2018-02-19 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
5791
5792 PR target/84148
5793 * configure: Regenerate.
5794
5795 2018-02-15 Jonathan Wakely <jwakely@redhat.com>
5796
5797 PR libstdc++/81797
5798 * configure.ac (INCLUDE_DIR_NOTPARALLEL): Define.
5799 * configure: Regenerate.
5800 * include/Makefile.am (INCLUDE_DIR_NOTPARALLEL): Add .NOTPARALLEL when
5801 defined.
5802 * include/Makefile.in: Regenerate.
5803
5804 2018-01-29 Jonathan Wakely <jwakely@redhat.com>
5805
5806 PR libstdc++/83833
5807 * testsuite/26_numerics/random/chi_squared_distribution/83833.cc:
5808 Add -ffloat-store to options for m68k and ia32.
5809
5810 * doc/xml/faq.xml: Update copyright years.
5811 * doc/html/*: Regenerate.
5812
5813 PR libstdc++/83658
5814 * include/std/any (any::__do_emplace): Only set _M_manager after
5815 constructing the contained object.
5816 * testsuite/20_util/any/misc/any_cast_neg.cc: Adjust dg-error line.
5817 * testsuite/20_util/any/modifiers/83658.cc: New test.
5818
5819 2018-01-25 Jonathan Wakely <jwakely@redhat.com>
5820
5821 PR libstdc++/81076
5822 * include/c_global/cstddef (__byte_operand): Define primary template.
5823 * testsuite/18_support/byte/81076.cc: New test.
5824
5825 2018-01-19 Christophe Lyon <christophe.lyon@linaro.org>
5826
5827 * testsuite/ext/special_functions/airy_ai/check_nan.cc: Fix
5828 dg-options and dg-add-options order.
5829 * testsuite/ext/special_functions/airy_bi/check_nan.cc: Likewise.
5830 * testsuite/ext/special_functions/conf_hyperg/check_nan.cc:
5831 Likewise.
5832 * testsuite/ext/special_functions/hyperg/check_nan.cc: Likewise.
5833 * testsuite/special_functions/01_assoc_laguerre/check_nan.cc:
5834 Likewise.
5835 * testsuite/special_functions/02_assoc_legendre/check_nan.cc:
5836 Likewise.
5837 * testsuite/special_functions/03_beta/check_nan.cc: Likewise.
5838 * testsuite/special_functions/04_comp_ellint_1/check_nan.cc:
5839 Likewise.
5840 * testsuite/special_functions/05_comp_ellint_2/check_nan.cc:
5841 Likewise.
5842 * testsuite/special_functions/06_comp_ellint_3/check_nan.cc:
5843 Likewise.
5844 * testsuite/special_functions/06_comp_ellint_3/pr66689.cc:
5845 Likewise.
5846 * testsuite/special_functions/07_cyl_bessel_i/check_nan.cc:
5847 Likewise.
5848 * testsuite/special_functions/08_cyl_bessel_j/check_nan.cc:
5849 Likewise.
5850 * testsuite/special_functions/09_cyl_bessel_k/check_nan.cc:
5851 Likewise.
5852 * testsuite/special_functions/10_cyl_neumann/check_nan.cc:
5853 Likewise.
5854 * testsuite/special_functions/11_ellint_1/check_nan.cc: Likewise.
5855 * testsuite/special_functions/12_ellint_2/check_nan.cc: Likewise.
5856 * testsuite/special_functions/13_ellint_3/check_nan.cc: Likewise.
5857 * testsuite/special_functions/13_ellint_3/pr66689.cc: Likewise.
5858 * testsuite/special_functions/14_expint/check_nan.cc: Likewise.
5859 * testsuite/special_functions/15_hermite/check_nan.cc: Likewise.
5860 * testsuite/special_functions/16_laguerre/check_nan.cc: Likewise.
5861 * testsuite/special_functions/17_legendre/check_nan.cc: Likewise.
5862 * testsuite/special_functions/18_riemann_zeta/check_nan.cc:
5863 Likewise.
5864 * testsuite/special_functions/19_sph_bessel/check_nan.cc:
5865 Likewise.
5866 * testsuite/special_functions/20_sph_legendre/check_nan.cc:
5867 Likewise.
5868 * testsuite/special_functions/21_sph_neumann/check_nan.cc:
5869 Likewise.
5870
5871 2018-01-18 Uros Bizjak <ubizjak@gmail.com>
5872
5873 * configure.ac (AC_CHECK_HEADERS): Add linux/types.h. Conditionally
5874 include linux/types.h when checking linux/random.h header.
5875 * config.h.in: Regenerate.
5876 * configure: Ditto.
5877 * src/c++11/random.cc: Conditionally include linux/types.h.
5878
5879 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
5880
5881 * testsuite/17_intro/names.cc: Undefine 'y' on SPARC/Linux.
5882
5883 2018-01-16 Jonathan Wakely <jwakely@redhat.com>
5884
5885 PR libstdc++/83834
5886 * config/abi/pre/gnu.ver (GLIBCXX_3.4): Replace std::c[a-g]* wildcard
5887 pattern with exact match for std::cerr.
5888
5889 2018-01-15 Jonathan Wakely <jwakely@redhat.com>
5890
5891 PR libstdc++/83833
5892 * include/bits/random.h (chi_squared_distribution::param): Update
5893 gamma distribution parameter.
5894 * testsuite/26_numerics/random/chi_squared_distribution/83833.cc: New
5895 test.
5896
5897 PR libstdc++/83830
5898 * include/std/type_traits (has_unique_object_representations_v): Add
5899 variable template.
5900 * testsuite/20_util/has_unique_object_representations/value.cc: Check
5901 variable template.
5902
5903 2018-01-15 Ville Voutilainen <ville.voutilainen@gmail.com>
5904
5905 Make optional conditionally
5906 trivially_{copy,move}_{constructible,assignable}
5907 * include/std/optional (_Optional_payload): Fix the comment in
5908 the class head and turn into a primary and one specialization.
5909 (_Optional_payload::_M_engaged): Strike the NSDMI.
5910 (_Optional_payload<_Tp, false>::operator=(const _Optional_payload&)):
5911 New.
5912 (_Optional_payload<_Tp, false>::operator=(_Optional_payload&&)):
5913 Likewise.
5914 (_Optional_payload<_Tp, false>::_M_get): Likewise.
5915 (_Optional_payload<_Tp, false>::_M_reset): Likewise.
5916 (_Optional_base_impl): Likewise.
5917 (_Optional_base): Turn into a primary and three specializations.
5918 (optional(nullopt)): Change the base init.
5919 * testsuite/20_util/optional/assignment/8.cc: New.
5920 * testsuite/20_util/optional/cons/trivial.cc: Likewise.
5921 * testsuite/20_util/optional/cons/value_neg.cc: Adjust.
5922
5923 2018-01-15 Jonathan Wakely <jwakely@redhat.com>
5924
5925 PR libstdc++/80276
5926 * python/libstdcxx/v6/printers.py (strip_inline_namespaces): New.
5927 (get_template_arg_list): New.
5928 (StdVariantPrinter._template_args): Remove, use get_template_arg_list
5929 instead.
5930 (TemplateTypePrinter): Rewrite to work with gdb.Type objects instead
5931 of strings and regular expressions.
5932 (add_one_template_type_printer): Adapt to new TemplateTypePrinter.
5933 (FilteringTypePrinter): Add docstring. Match using startswith. Use
5934 strip_inline_namespaces instead of strip_versioned_namespace.
5935 (add_one_type_printer): Prepend namespace to match argument.
5936 (register_type_printers): Add type printers for char16_t and char32_t
5937 string types and for types using cxx11 ABI. Update calls to
5938 add_one_template_type_printer to provide default argument dicts.
5939 * testsuite/libstdc++-prettyprinters/80276.cc: New test.
5940 * testsuite/libstdc++-prettyprinters/whatis.cc: Remove tests for
5941 basic_string<unsigned char> and basic_string<signed char>.
5942 * testsuite/libstdc++-prettyprinters/whatis2.cc: Duplicate whatis.cc
5943 to test local variables, without overriding _GLIBCXX_USE_CXX11_ABI.
5944
5945 2018-01-14 Andreas Schwab <schwab@linux-m68k.org>
5946
5947 PR libstdc++/81092
5948 * config/abi/post/ia64-linux-gnu/baseline_symbols.txt: Update.
5949
5950 2018-01-13 Tim Shen <timshen@google.com>
5951
5952 PR libstdc++/83601
5953 * include/bits/regex.tcc (regex_replace): Fix escaping in sed.
5954 * testsuite/28_regex/algorithms/regex_replace/char/pr83601.cc: Tests.
5955 * testsuite/28_regex/algorithms/regex_replace/wchar_t/pr83601.cc: Tests.
5956
5957 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5958
5959 PR libstdc++/64054
5960 * testsuite/27_io/basic_ostream/inserters_arithmetic/char/hexfloat.cc:
5961 Remove dg-xfail-run-if.
5962
5963 2018-01-10 François Dumont <fdumont@gcc.gnu.org>
5964
5965 * include/bits/forward_list.h
5966 (_Fwd_list_node_base(_Fwd_list_node_base&&)): New.
5967 (_Fwd_list_node_base& operator=(_Fwd_list_node_base&&)): New.
5968 (_Fwd_list_node_base(const _Fwd_list_node_base&)): Explicit delete.
5969 (_Fwd_list_node_base& operator=(const _Fwd_list_node_base&)): Likewise.
5970 (_Fwd_list_impl()): Add noexcept qualification.
5971 (_Fwd_list_impl(const _Node_alloc_type&)): Delete.
5972 (_Fwd_list_impl(_Fwd_list_impl&&)): New, default.
5973 (_Fwd_list_impl(_Fwd_list_impl&&, _Node_alloc_type&&)): New.
5974 (_Fwd_list_base()): Default.
5975 (_Fwd_list_base(_Fwd_list_base&&, _Node_alloc_type&&, true_type)): New.
5976 (_Fwd_list_base(_Fwd_list_base&&)): Default.
5977 (forward_list<>()): Default.
5978 (forward_list<>(forward_list&&)): Default.
5979 (forward_list(forward_list&&, _Node_alloc_type&&, false_type)): New.
5980 (forward_list(forward_list&&, _Node_alloc_type&&, true_type)): New.
5981 (forward_list(forward_list&&, const _Alloc&)): Adapt to use latters.
5982 * include/bits/forward_list.tcc
5983 (_Fwd_list_base(_Fwd_list_base&&, _Node_alloc_type&&)): Adapt to use
5984 _M_impl._M_head move assignment.
5985 (forward_list<>::merge(forward_list<>&&, _Comp)): Likewise.
5986 * testsuite/23_containers/forward_list/allocator/default_init.cc: New.
5987
5988 2018-01-09 Jonathan Wakely <jwakely@redhat.com>
5989
5990 PR libstdc++/80276
5991 * python/libstdcxx/v6/printers.py (SharedPointerPrinter)
5992 (UniquePointerPrinter): Print correct template argument, not type of
5993 the pointer.
5994 (TemplateTypePrinter._recognizer.recognize): Handle failure to lookup
5995 a type.
5996 * testsuite/libstdc++-prettyprinters/cxx11.cc: Test unique_ptr of
5997 array type.
5998 * testsuite/libstdc++-prettyprinters/cxx17.cc: Test shared_ptr and
5999 weak_ptr of array types.
6000
6001 2018-01-09 François Dumont <fdumont@gcc.gnu.org>
6002
6003 PR libstdc++/83709
6004 * include/bits/hashtable_policy.h
6005 (__distance_fwd(_Iterator, _Iterator, input_iterator_tag)): Return 1 if
6006 __first != __last.
6007 (_Insert_base::_M_insert_range(_Ite, _Ite, _NodeGetter, true_type)): New.
6008 (_Insert_base::_M_insert_range(_Ite, _Ite, _NodeGetter, false_type)):
6009 Add false_type parameter.
6010 (_Insert_base::insert): Adapt.
6011 * include/bits/hashtable.h (_Hashtable::operator=(initializzr_list<>)):
6012 Adapt.
6013 (_Hashtable::_M_insert(_Arg&&, const _NodeGen&, true_type, size_t)):
6014 Add __n_elt parameter, defaulted to 1.
6015 (_Hashtable::_M_insert_unique_node): Likewise. Use it to call rehash
6016 policy _M_need_rehash.
6017 (_Hashtable::_M_merge_unique): Pass target number of elements to add to
6018 produce only 1 rehash if necessary.
6019 * testsuite/23_containers/unordered_map/insert/83709.cc: New.
6020 * testsuite/23_containers/unordered_set/insert/83709.cc: New.
6021
6022 2018-01-09 Juraj Oršulić <juraj.orsulic@fer.hr>
6023 Jonathan Wakely <jwakely@redhat.com>
6024
6025 PR libstdc++/59253 (partial)
6026 * python/libstdcxx/v6/printers.py (SmartPtrIterator): Common iterator
6027 type for pointer stored by shared_ptr, weak_ptr and unique_ptr.
6028 (SharedPointerPrinter, UniquePointerPrinter): Treat stored values as
6029 children.
6030 * testsuite/libstdc++-prettyprinters/cxx11.cc: Update expected output
6031 of unique_ptr printer.
6032 * testsuite/libstdc++-prettyprinters/shared_ptr.cc: Update expected
6033 output of shared_ptr printer.
6034
6035 2018-01-05 Jonathan Wakely <jwakely@redhat.com>
6036
6037 PR libstdc++/83626
6038 * src/filesystem/ops.cc (remove(const path&, error_code&)): Remove
6039 unnecessary symlink_status call.
6040 (remove_all(const path&, error_code&)): Use filesystem::remove.
6041 * src/filesystem/std-ops.cc: Likewise.
6042
6043 PR libstdc++/83279
6044 * src/filesystem/std-ops.cc (do_copy_file): Use non-null offset with
6045 sendfile.
6046
6047 PR libstdc++/83626
6048 * src/filesystem/ops.cc (remove(const path&, error_code&)): Do not
6049 report an error for ENOENT.
6050 (remove_all(const path&)): Fix type of result variable.
6051 (remove_all(const path&, error_code&)): Use non-throwing increment
6052 for directory iterator. Call POSIX remove directly to avoid redundant
6053 calls to symlink_status. Do not report errors for ENOENT.
6054 * src/filesystem/std-ops.cc: Likewise.
6055 * testsuite/27_io/filesystem/operations/remove_all.cc: Test throwing
6056 overload.
6057 * testsuite/experimental/filesystem/operations/remove_all.cc:
6058 Likewise.
6059
6060 2018-01-04 Jonathan Wakely <jwakely@redhat.com>
6061
6062 PR libstdc++/83626
6063 * src/filesystem/ops.cc (remove(const path&, error_code&))): Remove
6064 redundant call to ec.clear().
6065 (remove_all(const path&, error_code&))): Do not return an error for
6066 non-existent paths.
6067 * src/filesystem/std-ops.cc: Likewise.
6068 * testsuite/27_io/filesystem/operations/remove.cc: New test.
6069 * testsuite/27_io/filesystem/operations/remove_all.cc: Fix expected
6070 results for non-existent paths.
6071 * testsuite/experimental/filesystem/operations/remove.cc: New test.
6072 * testsuite/experimental/filesystem/operations/remove_all.cc: Fix
6073 expected results for non-existent paths.
6074
6075 * include/bits/fs_ops.h (exists(const path&, error_code&))): Only
6076 check status_known once.
6077 * include/experimental/bits/fs_ops.h: Likewise.
6078
6079 PR libstdc++/83607
6080 * include/std/functional (__is_byte_like): New trait.
6081 (__is_std_equal_to): Remove.
6082 (__boyer_moore_base_t): Use __is_byte_like instead of
6083 __is_std_equal_to.
6084 * include/experimental/functional (__is_std_equal_to): Remove.
6085 (__boyer_moore_base_t): Use __is_byte_like instead of
6086 __is_std_equal_to.
6087 * testsuite/20_util/function_objects/83607.cc: New test.
6088
6089 2018-01-03 Ville Voutilainen <ville.voutilainen@gmail.com>
6090
6091 Protect optional's deduction guide with the feature macro
6092 * include/std/optional: Use the feature macro.
6093
6094 2018-01-03 Jakub Jelinek <jakub@redhat.com>
6095
6096 Update copyright years.
6097 \f
6098 Copyright (C) 2018 Free Software Foundation, Inc.
6099
6100 Copying and distribution of this file, with or without modification,
6101 are permitted in any medium without royalty provided the copyright
6102 notice and this notice are preserved.