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