1 2018-06-08 Jonathan Wakely <jwakely@redhat.com>
3 * include/bits/ios_base.h (ios::Init::Init(const Init&))
4 (ios::Init::operator=): Define as defaulted.
5 * include/bits/stl_bvector.h (_Bit_reference(const _Bit_reference&)):
7 * include/bits/stream_iterator.h (istream_iterator::operator=)
8 (ostream_iterator::operator=): Likewise.
9 * include/bits/streambuf_iterator.h (istreambuf_iterator::operator=)
11 * include/std/bitset (bitset::reference::reference(const reference&)):
13 * include/std/complex (complex<float>::complex(const complex&))
14 (complex<double>::complex(const complex&))
15 (complex<long double>::complex(const complex&)): Likewise.
17 2018-06-07 Jonathan Wakely <jwakely@redhat.com>
19 * include/bits/regex.h (sub_match): Add noexcept to default
20 constructor and length observer.
21 (match_results): Add noexcept to default constructor and observers
22 with no preconditions. Define destructor as defaulted.
23 (operator==, operator!=, swap): Add noexcept.
24 (regex_iterator): Add default member initializers and define default
25 constructor and destructor as defaulted. Add noexcept to equality
26 and dereference operators.
28 2018-06-07 François Dumont <fdumont@gcc.gnu.org>
31 (_Safe_iterator_base::_M_detach()): Reset state only if needed.
32 (_Safe_iterator_base::_M_detach_single()): Likewise.
33 (_Safe_local_iterator_base::_M_detach()): Reset state only if needed.
34 (_Safe_local_iterator_base::_M_detach_single()): Likewise.
36 2018-06-06 Jonathan Wakely <jwakely@redhat.com>
38 * include/bits/shared_ptr_base.h (__shared_count): Remove redundant
41 2018-06-06 Jakub Jelinek <jakub@redhat.com>
44 * include/bits/c++config: Check __cpp_transactional_memory >= 201500L
45 rather than __cpp_transactional_memory >= 201505L.
47 2018-06-06 Jonathan Wakely <jwakely@redhat.com>
50 * include/bits/quoted_string.h (_Quoted_string<basic_string_view, C>):
51 Define new partial specialization.
52 * include/std/iomanip (quoted(basic_string_view<C,T>, C, C)): Define
54 (operator<<(basic_ostream<C,T>&, const _Quoted_string<S,C>&)): Use
55 value not reference for iteration.
56 * testsuite/27_io/manipulators/standard/char/quoted.cc: Adjust
58 * testsuite/27_io/manipulators/standard/char/quoted_sv.cc: New test.
59 * testsuite/27_io/manipulators/standard/wchar_t/quoted.cc: Adjust
62 2018-06-05 Jonathan Wakely <jwakely@redhat.com>
64 * include/std/type_traits: Fix comment typos.
66 * testsuite/27_io/filesystem/operations/read_symlink.cc: XFAIL for
68 * testsuite/27_io/filesystem/operations/symlink_status.cc: Likewise.
69 * testsuite/experimental/filesystem/operations/read_symlink.cc:
72 2018-06-05 François Dumont <fdumont@gcc.gnu.org>
74 * include/bits/stl_tempbuf.h
75 (_Temporary_buffer(_FwdIte, _FwdIte)): Delete, replaced by...
76 (_Temporary_buffer(_FwdIte, size_type)): ...this, new.
77 * include/ext/memory (temporary_buffer<>(_FwdIte, _FwdIte)): Adapt.
78 * include/bits/stl_algo.h (__stable_partition): Adapt.
79 (__inplace_merge): Adapt.
80 (__stable_sort): Adapt.
82 2018-06-04 Jonathan Wakely <jwakely@redhat.com>
85 * include/bits/shared_ptr_base.h [!__cpp_rtti]: Include <typeinfo>
86 unconditionally. Remove redundant declaration.
87 [!__cpp_rtti] (_Sp_make_shared_tag::_S_ti): Fix location of
90 * include/bits/postypes.h (fpos): Define special members as defaulted.
93 * include/bits/shared_ptr_base.h (_Sp_make_shared_tag::_S_ti): Align
94 the static variable correctly.
96 2018-05-24 Jonathan Wakely <jwakely@redhat.com>
98 PR libstdc++/78870 support std::filesystem on Windows
99 * config.h.in: Regenerate.
100 * configure: Regenerate.
101 * configure.ac: Check for link, readlink and symlink.
102 * include/bits/fs_path.h (path::operator/=(const path&)): Move
103 definition out of class body.
104 (path::is_absolute(), path::_M_append(path)): Likewise.
105 (operator<<(basic_ostream, const path&)): Use std::quoted directly.
106 (operator>>(basic_istream, path&)): Likewise.
107 (u8path): Reorder definitions and fix Windows implementation.
108 (path::is_absolute()): Define inline and fix for Windows.
109 [!_GLIBCXX_FILESYSTEM_IS_WINDOWS] (path::operator/=(const path&)):
110 Define POSIX version inline.
111 (path::_M_append(path)): Define inline.
112 * include/experimental/bits/fs_path.h (path::is_absolute()): Move
113 definition out of class body.
114 (operator<<(basic_ostream, const path&)): Fix type of delimiter and
116 (operator>>(basic_istream, path&)): Likewise.
117 (path::is_absolute()): Define inline and fix for Windows.
118 * src/filesystem/dir-common.h (__gnu_posix): New namespace.
119 (__gnu_posix::char_type, __gnu_posix::DIR, __gnu_posix::dirent)
120 (__gnu_posix::opendir, __gnu_posix::readdir, __gnu_posix::closedir):
121 Define as adaptors for Windows functions/types or as
122 using-declarations for POSIX functions/types.
123 (_Dir_base, get_file_type): Qualify names to use declarations from
124 __gnu_posix namespace.
125 (_Dir_base::is_dor_or_dotdot): New helper functions.
126 * src/filesystem/dir.cc (_Dir, recursive_directory_iterator): Qualify
127 names to use declarations from __gnu_posix namespace.
128 * src/filesystem/ops-common.h (__gnu_posix): New nested namespace.
129 (__gnu_posix::open, __gnu_posix::close, __gnu_posix::stat_type)
130 (__gnu_posix::stat, __gnu_posix::lstat, __gnu_posix::mode_t)
131 (__gnu_posix::chmod, __gnu_posix::mkdir, __gnu_posix::getcwd)
132 (__gnu_posix::chdir, __gnu_posix::utimbuf, __gnu_posix::utime)
133 (__gnu_posix::rename, __gnu_posix::truncate, __gnu_posix::char_type):
134 Define as adaptors for Windows functions/types or as
135 using-declarations for POSIX functions/types.
136 (stat_type, do_copy_file): Qualify names to use declarations from
137 __gnu_posix namespace.
138 (do_space): Declare new function.
139 (make_file_type): Only use S_ISLNK if defined.
140 * src/filesystem/ops.cc (char_ptr, filesystem::canonical): Use
141 path::value_type not char.
142 (filesystem::copy, create_dir, filesystem::create_directory): Qualify
143 names to use declarations from __gnu_posix namespace.
144 (filesystem::create_hard_link): Check HAVE_LINK autoconf macro and
145 add implementation for Windows.
146 (filesystem::create_symlink): Check HAVE_SYMLINK autoconf macro.
147 (filesystem::current_path(error_code&)): Use __gnu_posix::getcwd.
148 [!_PC_PATH_MAX]: Don't use pathconf.
149 [PATH_MAX]: Use if defined.
150 (filesystem::current_path(const path&, error_code&))
151 (filesystem::equivalent, do_stat, filesystem::hard_link_count)
152 (filesystem::last_write_time, filesystem::permissions): Use names
154 (filesystem::read_symlink): Check HAVE_READLINK autoconf macro.
155 (filesystem::remove) [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Add
156 implementation for Windows.
157 (filesystem::rename, filesystem::resize_file): Use names from
159 (filesystem::space): Use do_space.
160 [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Get absolute path to directory.
161 (filesystem::status, filesystem::symlink_status): Use names from
163 (filesystem::temp_directory_path): Add implementation for Windows.
164 * src/filesystem/path.cc (dot): Define constant.
165 (path::replace_extension): Use dot.
166 (path::_M_find_extension): Likewise. Use path::string_type not
168 (path::_M_split_cmpts): Use dot.
169 (filesystem_error::_M_get_what): Use u8string() not native().
170 * src/filesystem/std-dir.cc (_Dir, recursive_directory_iterator):
171 Qualify names to use declarations from __gnu_posix namespace.
172 * src/filesystem/std-ops.cc (filesystem::absolute(const path&)): Use
174 (filesystem::absolute(const path&, error_code&)): Add implementation
176 (char_ptr, filesystem::canonical): Use path::value_type not char.
177 (do_copy_file): Use names from __gnu_posix.
178 [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Do not use fchmod, fchmodat or
180 (filesystem::copy, create_dir, filesystem::create_directory): Qualify
181 names to use declarations from __gnu_posix namespace.
182 (filesystem::create_hard_link): Check HAVE_LINK autoconf macro and
183 add implementation for Windows.
184 (filesystem::create_symlink): Check HAVE_SYMLINK autoconf macro.
185 (filesystem::current_path(error_code&)): Use __gnu_posix::getcwd.
186 [!_PC_PATH_MAX]: Don't use pathconf.
187 [PATH_MAX]: Use if defined.
188 (filesystem::current_path(const path&, error_code&))
189 (filesystem::equivalent, do_stat, filesystem::hard_link_count)
190 (filesystem::last_write_time, filesystem::permissions): Use names
192 (filesystem::read_symlink): Check HAVE_READLINK autoconf macro.
193 (filesystem::remove) [_GLIBCXX_FILESYSTEM_IS_WINDOWS]: Add
194 implementation for Windows.
195 (filesystem::rename, filesystem::resize_file): Use names from
198 (filesystem::space): Use do_space.
199 (filesystem::status, filesystem::symlink_status): Use names from
201 (filesystem::temp_directory_path): Add implementation for Windows.
202 * src/filesystem/std-path.cc
203 [_GLIBCXX_FILESYSTEM_IS_WINDOWS] (path::operator/=(const path&)):
205 (dot): Define constant.
206 (path::replace_extension, is_dot): Use dot.
207 (path::lexically_normal): Check _M_type instead of calling
208 non-existent function.
209 (path::_M_find_extension): Use dot. Use path::string_type not
211 (path::_M_split_cmpts): Use dot.
212 (filesystem_error::_M_get_what): Use u8string() not native().
213 * testsuite/27_io/filesystem/iterators/directory_iterator.cc: Do not
215 * testsuite/27_io/filesystem/iterators/recursive_directory_iterator.cc:
217 * testsuite/27_io/filesystem/operations/absolute.cc: Use
218 __gnu_test::root_path() instead of "/" and add Windows-specific tests.
219 * testsuite/27_io/filesystem/operations/canonical.cc: Use
220 path::string() to get narrow string, not path::native().
221 * testsuite/27_io/filesystem/operations/copy.cc: Construct fstreams
222 with std::filesystem::path not std::basic_string.
223 * testsuite/27_io/filesystem/operations/copy_file.cc: Likewise.
224 * testsuite/27_io/filesystem/operations/exists.cc: Use
225 __gnu_test::root_path() instead of "/".
226 * testsuite/27_io/filesystem/operations/is_empty.cc: Construct
227 fstreams with std::filesystem::path not std::basic_string.
228 * testsuite/27_io/filesystem/operations/last_write_time.cc: Use
229 path::string() to get narrow string.
230 * testsuite/27_io/filesystem/operations/space.cc: Check results for
231 errors, expect sensible values otherwise.
232 * testsuite/27_io/filesystem/operations/temp_directory_path.cc: Add
233 helpers for adjusting the environment on Windows.
234 * testsuite/27_io/filesystem/path/append/path.cc: Test
235 Windows-specific behaviour.
236 * testsuite/27_io/filesystem/path/construct/format.cc: Fix creation
237 of path::string_type objects.
238 * testsuite/27_io/filesystem/path/construct/locale.cc: Compare native
239 string to wide string on Windows.
240 * testsuite/27_io/filesystem/path/decompose/root_directory.cc: Allow
241 for backslash as root-directory.
242 * testsuite/27_io/filesystem/path/decompose/stem.cc: Use
243 path::string() to get narrow string.
244 * testsuite/27_io/filesystem/path/itr/traversal.cc: Test Windows-style
246 * testsuite/27_io/filesystem/path/native/string.cc: Use string_type
248 * testsuite/27_io/filesystem/path/query/is_absolute.cc: Adjust for
249 different definintion of absolute paths on Windows.
250 * testsuite/experimental/filesystem/iterators/directory_iterator.cc:
252 * testsuite/experimental/filesystem/operations/absolute.cc: Test
254 * testsuite/experimental/filesystem/operations/copy.cc: Construct
255 fstreams with NTCTS not std::basic_string.
256 * testsuite/experimental/filesystem/operations/copy_file.cc: Likewise.
257 * testsuite/experimental/filesystem/operations/exists.cc: Use
258 __gnu_test::root_path() instead of "/".
259 * testsuite/experimental/filesystem/operations/is_empty.cc: Construct
260 fstreams with NTCTS not std::basic_string.
261 * testsuite/experimental/filesystem/operations/last_write_time.cc:
262 Use path::string() to get narrow string.
263 * testsuite/experimental/filesystem/operations/space.cc: Use
264 __gnu_test::root_path() instead of "/".
265 * testsuite/experimental/filesystem/operations/temp_directory_path.cc:
266 Add helpers for adjusting the environment on Windows.
267 * testsuite/experimental/filesystem/path/append/path.cc: Use
268 path::string() to get narrow strings for comparisons.
269 * testsuite/experimental/filesystem/path/concat/path.cc: Likewise.
270 * testsuite/experimental/filesystem/path/decompose/root_directory.cc:
272 * testsuite/experimental/filesystem/path/decompose/stem.cc: Likewise.
273 * testsuite/experimental/filesystem/path/native/string.cc: Use
274 string_type not std::string.
275 * testsuite/experimental/filesystem/path/query/is_absolute.cc:
276 Adjust for different definintion of absolute paths on Windows.
277 * testsuite/util/testsuite_fs.h (__gnu_test::root_path()): New
279 (__gnu_test::scoped_file): Construct fstreams with NTCTS not
282 2018-05-31 Jonathan Wakely <jwakely@redhat.com>
285 * include/std/type_traits [_GLIBCXX_USE_C99_STDINT_TR1]: Do not define
286 uint_least16_t and uint_least32_t.
287 (__make_unsigned<wchar_t>): Define unconditionally.
288 (__make_unsigned_selector<_Tp, true, false>): Remove intermediate
290 (__make_unsigned_selector_base): New type to provide helper templates.
291 (__make_unsigned_selector<_Tp, false, true>): Reimplement using
292 __make_unsigned_selector_base helpers.
293 (__make_unsigned<char16_t>, __make_unsigned<char32_t>): Define.
294 (__make_signed_selector<_Tp, true, false>): Remove intermediate
296 (__make_signed<wchar_t>, __make_signed<char16_t>)
297 (__make_signed<char32_t>)): Define unconditionally.
298 * testsuite/20_util/make_signed/requirements/typedefs-3.cc: Check
299 wchar_t, char16_t and char32_t are transformed correctly.
300 * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust
302 * testsuite/20_util/make_unsigned/requirements/typedefs-3.cc: Check
303 wchar_t, char16_t and char32_t are transformed correctly.
304 * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Adjust
307 2018-05-29 Jonathan Wakely <jwakely@redhat.com>
309 * include/std/variant (__erased_dtor): Qualify call to __get.
311 2018-05-27 François Dumont <fdumont@gcc.gnu.org>
313 * include/bits/stl_tree.h (_Rb_tree_impl(_Node_allocator&&)): New.
314 (_Rb_tree(const allocator_type&)): Use latter.
315 * include/bits/stl_map.h (map(const allocator_type&)): Likewise.
316 (map(initializer_list<value_type>, const allocator_type&)): Likewise.
317 (map(_InputIterator, _InputIterator, const allocator_type&)): Likewise.
318 * include/bits/stl_multimap.h
319 (multimap(const allocator_type&)): Likewise.
320 (multimap(initializer_list<value_type>, const allocator_type&)):
322 (multimap(_InputIterator, _InputIterator, const allocator_type&)):
324 * include/bits/stl_set.h (set(const allocator_type&)): Likewise.
325 (set(initializer_list<value_type>, const allocator_type&)): Likewise.
326 (set(_InputIterator, _InputIterator, const allocator_type&)): Likewise.
327 * include/bits/stl_multiset.h
328 (multiset(const allocator_type&)): Likewise.
329 (multiset(initializer_list<value_type>, const allocator_type&)):
331 (multiset(_InputIterator, _InputIterator, const allocator_type&)):
334 2018-05-25 François Dumont <fdumont@gcc.gnu.org>
337 * src/c++11/debug.cc: Remove backtrace usage.
339 2018-05-24 Maya Rashish <coypu@sdf.org>
342 * crossconfig.m4: Test for aligned_alloc on netbsd.
343 * configure: Regenerate.
345 2018-05-24 Jonathan Wakely <jwakely@redhat.com>
349 * include/bits/atomic_base.h (__atomic_base::value_type)
350 (__atomic_base::difference_type): Add new typedefs.
351 * include/std/atomic (atomic<bool>::value_type, atomic<T>::value_type)
352 (atomic<T*>::value_type, atomic<T*>::difference_type): Likewise.
353 (atomic<T*>::operator++, atomic<T*>::operator--)
354 (atomic<T*>::operator+=, atomic<T*>::operator-=)
355 (atomic<T*>::fetch_add, atomic<T*>::fetch_sub): Add static assertion
356 to enforce C++17 requirement on pointer arithmetic.
357 (__atomic_val_t, __atomic_diff_t): New alias templates.
358 (atomic_init, atomic_store_explicit, atomic_exchange_explicit)
359 (atomic_compare_exchange_weak_explicit)
360 (atomic_compare_exchange_strong_explicit, atomic_store)
361 (atomic_exchange, atomic_compare_exchange_weak)
362 (atomic_compare_exchange_strong): Use __atomic_val_t to make
363 scalar parameters be non-deduced contexts.
364 (atomic_fetch_add_explicit, atomic_fetch_sub_explicit)
365 (atomic_fetch_add, atomic_fetch_sub): Change first parameter to be
366 atomic instead of __atomic_base, and use __atomic_diff_t for scalar
368 (atomic_fetch_and_explicit, atomic_fetch_or_explicit)
369 (atomic_fetch_xor_explicit, atomic_fetch_and, atomic_fetch_or)
370 (atomic_fetch_xor): Use __atomic_val_t for scalar parameters.
371 (atomic_fetch_add_explicit, atomic_fetch_sub_explicit)
372 (atomic_fetch_add, atomic_fetch_sub): Remove overloads for atomic
374 * testsuite/29_atomics/atomic/60695.cc: Adjust dg-error lineno.
375 * testsuite/29_atomics/atomic/69769.cc: New test.
376 * testsuite/29_atomics/atomic/nonmembers.cc: New test.
377 * testsuite/29_atomics/atomic/operators/pointer_partial_void.cc:
378 Disable test for C++17 and later.
379 * testsuite/29_atomics/atomic/requirements/typedefs.cc: New test.
380 * testsuite/29_atomics/atomic_integral/nonmembers.cc: New test.
381 * testsuite/29_atomics/atomic_integral/requirements/typedefs.cc: New
384 2018-05-23 Jonathan Wakely <jwakely@redhat.com>
386 * include/bits/fs_path.h (path::__is_encoded_char): Change from class
387 template to alias template.
388 (path::__value_type_is_char): Use remove_const_t.
389 (path:_S_string_from_iter): New helper function.
390 (path::_S_convert(InputIter, __null_terminated))
391 (path::_S_convert_loc(InputIter, __null_terminated, const locale&)):
392 Use _S_string_from_iter.
393 (path::string<_CharT, _Allocator>(const _Allocator&)): Allow sharing
395 * include/experimental/bits/fs_path.h (path::__is_encoded_char):
396 Change from class template to alias template.
397 (path::__value_type_is_char): Use remove_const.
398 (path:_S_string_from_iter): New helper function.
399 (path::_S_convert(InputIter, __null_terminated))
400 (path::_S_convert_loc(InputIter, __null_terminated, const locale&)):
401 Use _S_string_from_iter.
402 * testsuite/27_io/filesystem/path/append/source.cc: Test appending
404 * testsuite/27_io/filesystem/path/concat/strings.cc: Check for exact
405 string equality, not path equivalence.
406 * testsuite/27_io/filesystem/path/construct/format.cc: Check
407 construction from std::string and std::wstring and input iterators.
408 * testsuite/27_io/filesystem/path/construct/locale.cc: Check
409 construction from iterators.
410 * testsuite/experimental/filesystem/path/concat/strings.cc: Check for
411 exact string equality, not path equivalence.
412 * testsuite/experimental/filesystem/path/construct/locale.cc: Check
413 construction from iterators.
415 * include/bits/fs_path.h (path::_M_type): Change default member
416 initializer to _Filename.
417 (path::begin): Create past-the-end iterator for empty path.
418 * src/filesystem/std-path.cc (path::remove_filename()): Remove
420 (path::has_relative_path()): Return false for empty filenames.
421 (path::_M_split_cmpts): Set _M_type to _Filename for empty paths.
422 Fix offset of empty final component.
423 * testsuite/27_io/filesystem/path/itr/components.cc: New.
424 * testsuite/27_io/filesystem/path/itr/traversal.cc: Add new inputs.
426 2018-05-21 Jonathan Wakely <jwakely@redhat.com>
428 Add support for opening file streams from wide character strings.
429 * config/io/basic_file_stdio.cc [_GLIBCXX_HAVE__WFOPEN]
430 (__basic_file<char>::open(const wchar_t*, ios_base::openmode)):
432 * config/io/basic_file_stdio.h [_GLIBCXX_HAVE__WFOPEN]
433 (__basic_file<char>::open(const wchar_t*, ios_base::openmode)):
434 Declare new overload.
435 * configure.ac: Check for _wfopen.
436 * crossconfig.m4: Likewise.
437 * configure: Regenerate.
438 * config.h.in: Regenerate.
439 * include/bits/fstream.tcc [_GLIBCXX_HAVE__WFOPEN]
440 (basic_filebuf<C,T>::open(const wchar_t*, ios_base::openmode)):
442 * include/std/fstream [_GLIBCXX_HAVE__WFOPEN]
443 (basic_filebuf<C,T>::open(const wchar_t*, ios_base::openmode)):
444 Declare new overload.
445 [_GLIBCXX_HAVE__WFOPEN]
446 (basic_ifstream<C,T>::basic_ifstream(const wchar_t*, openmode))
447 (basic_ifstream<C,T>::basic_open(const wchar_t*, openmode))
448 (basic_ofstream<C,T>::basic_ifstream(const wchar_t*, openmode))
449 (basic_ofstream<C,T>::basic_open(const wchar_t*, openmode))
450 (basic_fstream<C,T>::basic_ifstream(const wchar_t*, openmode))
451 (basic_fstream<C,T>::basic_open(const wchar_t*, openmode)): Define
453 * testsuite/27_io/basic_filebuf/open/wchar_t/1.cc: New.
454 * testsuite/27_io/basic_ifstream/cons/wchar_t/1.cc: New.
455 * testsuite/27_io/basic_ifstream/open/wchar_t/1.cc: New.
456 * testsuite/27_io/basic_ofstream/cons/wchar_t/1.cc: New.
457 * testsuite/27_io/basic_ofstream/open/wchar_t/1.cc: New.
458 * testsuite/27_io/basic_fstream/cons/wchar_t/1.cc: New.
459 * testsuite/27_io/basic_fstream/open/wchar_t/1.cc: New.
461 2018-05-21 François Dumont <fdumont@gcc.gnu.org>
464 * include/bits/stl_tree.h
465 (_Rb_tree_impl(_Rb_tree_impl&&, _Node_allocator&&)): Fix noexcept
468 2018-05-21 Jonathan Wakely <jwakely@redhat.com>
470 * src/filesystem/std-ops.cc (absolute): Report an error for empty
472 (weakly_canonical(const path&)): Do not call canonical on empty path.
473 (weakly_canonical(const path&, error_code&)): Likewise.
474 * testsuite/27_io/filesystem/operations/absolute.cc: Check for errors.
477 * testsuite/experimental/filesystem/path/preferred_separator.cc: Add
478 dg-require-filesystem-ts.
481 * src/c++11/cow-stdexcept.cc (logic_error, runtime_error): Explicitly
482 initialize base class to avoid warnings.
484 2018-05-19 Jonathan Wakely <jwakely@redhat.com>
486 * src/c++11/codecvt.cc (__codecvt_utf8_base<wchar_t>::do_in)
487 [__SIZEOF_WCHAR_T__==2 && __BYTE_ORDER__!=__ORDER_BIG_ENDIAN__]: Set
488 little_endian element in bitmask.
489 * testsuite/22_locale/codecvt/codecvt_utf8/69703.cc: Run all tests.
490 * testsuite/22_locale/codecvt/codecvt_utf8/wchar_t/1.cc: New.
492 2018-05-18 François Dumont <fdumont@gcc.gnu.org>
494 * include/bits/stl_tree.h
495 (_Rb_tree_impl(_Rb_tree_impl&&, _Node_allocator&&)): New.
496 (_Rb_tree(_Rb_tree&&, _Node_allocator&&, true_type)): New, use latter.
497 (_Rb_tree(_Rb_tree&&, _Node_allocator&&, false_type)): New.
498 (_Rb_tree(_Rb_tree&&, _Node_allocator&&)): Adapt, use latters.
499 * include/debug/map.h
500 (map(map&&, const_allocator_type&)): Add noexcept qualitication.
501 * include/debug/multimap.h
502 (multimap(multimap&&, const_allocator_type&)): Likewise.
503 * include/debug/set.h
504 (set(set&&, const_allocator_type&)): Likewise.
505 * include/debug/multiset.h
506 (multiset(multiset&&, const_allocator_type&)): Likewise.
507 * testsuite/23_containers/map/cons/noexcept_default_construct.cc:
509 * testsuite/23_containers/map/cons/noexcept_move_construct.cc:
511 * testsuite/23_containers/multimap/cons/noexcept_default_construct.cc:
513 * testsuite/23_containers/multimap/cons/noexcept_move_construct.cc:
515 * testsuite/23_containers/multiset/cons/noexcept_default_construct.cc:
517 * testsuite/23_containers/multiset/cons/noexcept_move_construct.cc:
519 * testsuite/23_containers/set/cons/noexcept_default_construct.cc:
521 * testsuite/23_containers/set/cons/noexcept_move_construct.cc:
524 2018-05-18 Jason Merrill <jason@redhat.com>
526 * include/bits/stl_deque.h (_Deque_iterator): Constrain constructor
527 for conversion to const_iterator. Add defaulted copy ops.
528 * libsupc++/new (bad_alloc): Add defaulted copy ops.
529 * libsupc++/exception.h (exception): Add defaulted copy ops.
530 * include/std/system_error (system_error): Add defaulted copy ops.
531 * include/std/stdexcept (domain_error, invalid_argument)
532 (length_error, out_of_range, range_error, overflow_error)
533 (underflow_error): Add defaulted copy ops.
534 * include/bits/stl_iterator.h (reverse_iterator): Add defaulted
536 * include/bits/allocator.h (allocator): Add defaulted copy assignment.
537 * include/ext/throw_allocator.h (condition_base): Add defaulted
538 default and copy ctor and copy assignment.
540 2018-05-18 Jonathan Wakely <jwakely@redhat.com>
543 * include/bits/regex.h [__cplusplus < 201703L] (basic_regex::icase)
544 (basic_regex::nosubs, basic_regex::optimize, basic_regex::collate)
545 (basic_regex::ECMAScript, basic_regex::basic, basic_regex::extended)
546 (basic_regex::awk, basic_regex::grep, basic_regex::egrep): Add
548 * include/bits/regex_automaton.h (_NFA::_M_insert_state): Adjust
550 * include/bits/regex_compiler.tcc (__INSERT_REGEX_MATCHER): Add
551 braces around body of do-while.
552 * testsuite/28_regex/basic_regex/85098.cc: New
554 2018-05-17 Jonathan Wakely <jwakely@redhat.com>
557 * src/filesystem/path.cc (path::preferred_separator): Add used
559 * testsuite/experimental/filesystem/path/preferred_separator.cc: New.
562 * libsupc++/cxxabi_init_exception.h (__cxa_free_exception): Declare.
563 * libsupc++/exception_ptr.h (make_exception_ptr) [__cpp_exceptions]:
564 Refactor to separate non-throwing and throwing implementations.
565 [__cpp_rtti && !_GLIBCXX_HAVE_CDTOR_CALLABI]: Deallocate the memory
566 if constructing the object throws.
568 2018-05-15 Jonathan Wakely <jwakely@redhat.com>
571 * include/bits/random.h (__detail::__is_seed_seq): New SFINAE helper.
572 (linear_congruential_engine, mersenne_twister_engine)
573 (subtract_with_carry_engine, discard_block_engine)
574 (independent_bits_engine, shuffle_order_engine): Use __is_seed_seq to
575 constrain function templates taking seed sequences.
576 * include/bits/random.tcc (linear_congruential_engine::seed(_Sseq&))
577 (mersenne_twister_engine::seed(_Sseq&))
578 (subtract_with_carry_engine::seed(_Sseq&)): Change return types to
580 * include/ext/random (simd_fast_mersenne_twister_engine): Use
581 __is_seed_seq to constrain function templates taking seed sequences.
582 * include/ext/random.tcc (simd_fast_mersenne_twister_engine::seed):
583 Change return type to match declaration.
584 * testsuite/26_numerics/random/discard_block_engine/cons/seed_seq2.cc:
586 * testsuite/26_numerics/random/independent_bits_engine/cons/
588 * testsuite/26_numerics/random/linear_congruential_engine/cons/
590 * testsuite/26_numerics/random/mersenne_twister_engine/cons/
592 * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error lineno.
593 * testsuite/26_numerics/random/shuffle_order_engine/cons/seed_seq2.cc:
595 * testsuite/26_numerics/random/subtract_with_carry_engine/cons/
597 * testsuite/ext/random/simd_fast_mersenne_twister_engine/cons/
601 * include/bits/fs_path.h (path::is_absolute()): Use same definition
602 for all operating systems.
603 * include/experimental/bits/fs_path.h (path::is_absolute()): Likewise.
604 * testsuite/27_io/filesystem/path/query/is_absolute.cc: New.
605 * testsuite/27_io/filesystem/path/query/is_relative.cc: Fix comment.
606 * testsuite/experimental/filesystem/path/query/is_absolute.cc: New.
608 * testsuite/27_io/filesystem/path/decompose/extension.cc: Remove
609 unused <vector> header.
610 * testsuite/27_io/filesystem/path/query/empty.cc: Likewise.
611 * testsuite/27_io/filesystem/path/query/has_extension.cc: Likewise.
612 * testsuite/27_io/filesystem/path/query/has_filename.cc: Likewise.
613 * testsuite/27_io/filesystem/path/query/has_parent_path.cc: Likewise.
614 * testsuite/27_io/filesystem/path/query/has_relative_path.cc:
616 * testsuite/27_io/filesystem/path/query/has_root_directory.cc:
618 * testsuite/27_io/filesystem/path/query/has_root_name.cc: Likewise.
619 * testsuite/27_io/filesystem/path/query/has_root_path.cc: Likewise.
620 * testsuite/27_io/filesystem/path/query/has_stem.cc: Likewise.
621 * testsuite/27_io/filesystem/path/query/is_relative.cc: Likewise.
622 * testsuite/experimental/filesystem/path/decompose/extension.cc:
624 * testsuite/experimental/filesystem/path/query/empty.cc: Likewise.
625 * testsuite/experimental/filesystem/path/query/has_extension.cc:
627 * testsuite/experimental/filesystem/path/query/has_filename.cc:
629 * testsuite/experimental/filesystem/path/query/has_parent_path.cc:
631 * testsuite/experimental/filesystem/path/query/has_relative_path.cc:
633 * testsuite/experimental/filesystem/path/query/has_root_directory.cc:
635 * testsuite/experimental/filesystem/path/query/has_root_name.cc:
637 * testsuite/experimental/filesystem/path/query/has_root_path.cc:
639 * testsuite/experimental/filesystem/path/query/has_stem.cc: Likewise.
640 * testsuite/experimental/filesystem/path/query/is_relative.cc:
644 * include/bits/fs_path.h (path::operator/=, path::append): Construct
645 temporary path before calling _M_append.
646 (path::_M_append): Change parameter to path and implement C++17
648 * testsuite/27_io/filesystem/path/append/path.cc: Add helper function
649 and more examples from the standard.
650 * testsuite/27_io/filesystem/path/append/source.cc: New.
651 * testsuite/27_io/filesystem/path/decompose/filename.cc: Add comment.
652 * testsuite/27_io/filesystem/path/nonmember/append.cc: New.
654 * include/std/variant (__gen_vtable_impl::__visit_invoke): Qualify
655 __invoke to prevent ADL.
657 2018-05-14 Jonathan Wakely <jwakely@redhat.com>
660 * include/bits/fstream.tcc (basic_filebuf::close): Do not swallow
661 exceptions from _M_terminate_output().
662 * include/std/fstream (basic_filebuf::~basic_filebuf): Swallow any
663 exceptions from close().
664 * testsuite/27_io/basic_filebuf/close/81256.cc: New.
666 * include/bits/valarray_array.h (__valarray_get_memory): Remove.
667 (__valarray_get_storage): Call operator new directly. Remove ignored
668 top-level restrict qualifier and add malloc attribute instead.
669 (_Array<_Tp>::_Array(size_t)): Remove unused constructor.
672 * include/bits/valarray_array.h (_Array_copy_ctor<_Tp, true>)
673 (_Array_copier<_Tp, true>): Do not pass null pointers to memcpy.
676 * include/bits/node_handle.h (_Node_handle_common::_M_swap): Use value
678 * testsuite/23_containers/set/modifiers/node_swap.cc: New.
680 2018-05-13 Ville Voutilainen <ville.voutilainen@gmail.com>
683 * testsuite/20_util/variant/80165.cc: New.
685 2018-05-10 Jonathan Wakely <jwakely@redhat.com>
687 * doc/xml/faq.xml: Link to C++17 status. Add note to outdated answer.
688 * doc/xml/manual/debug_mode.xml: Add array and forward_list to list
689 of C++11 containers with Debug Mode support.
690 * doc/xml/manual/using.xml: Document Dual ABI for ios_base::failure.
691 * doc/html/*: Regenerate.
693 2018-05-10 Jason Merrill <jason@redhat.com>
695 * include/bits/regex_compiler.h (_S_cache_size): Change from
696 function to variable.
698 2018-05-10 Edward Smith-Rowland <3dw4rd@verizon.net>
700 PR libstdc++/83140 - assoc_legendre returns negated value when m is odd
701 * include/tr1/legendre_function.tcc (__assoc_legendre_p): Add __phase
702 argument defaulted to +1. Doxy comments on same.
703 * testsuite/special_functions/02_assoc_legendre/
704 check_value.cc: Regen.
705 * testsuite/tr1/5_numerical_facilities/special_functions/
706 02_assoc_legendre/check_value.cc: Regen.
708 2018-05-10 Jonathan Wakely <jwakely@redhat.com>
711 * include/bits/c++config.h (__replacement_assert): Add linkage
713 * include/bits/std_abs.h: Add comment to closing brace of block.
714 * include/c_global/cstddef: Add linkage specification.
715 * include/c_global/cstring: Likewise.
716 * include/c_global/cwchar: Likewise.
718 2018-05-09 François Dumont <fdumont@gcc.gnu.org>
720 * include/debug/safe_iterator.h (_Safe_iterator<>::_M_constant()):
722 (_Safe_iterator<>::_S_constant()): ...that.
723 * include/debug/safe_local_iterator.h
724 (_Safe_local_iterator<>::_M_constant()): Rename in...
725 (_Safe_local_iterator<>::_S_constant()): ...that.
726 * include/debug/formatter.h: Remove bits/cpp_type_traits.h include.
727 (_Iterator_state::__rbegin): New.
728 (_Iterator_state::__rmiddle): New.
729 (_Iterator_state::__rend): New.
730 (_Parameter::_Parameter(const _Safe_iterator<>&, const char*,
731 _Is_iterator)): Use _Safe_iterator<>::_S_constant. Grab normal underlying
733 (_Parameter::_Parameter(const _Safe_local_iterator<>&, const char*,
734 _Is_iterator)): Likewise.
735 (_Parameter::_S_reverse_state(_Iterator_state)): New.
736 (_Parameter(__gnu_cxx::__normal_iterator<> const&, const char*,
738 (_Parameter(std::reverse_iterator<> const&, const char*,
740 (_Parameter(std::reverse_iterator<_Safe_iterator<>> const&,
741 const char*, _Is_iterator)): New.
742 (_Parameter(std::move_iterator<> const&, const char*, _Is_iterator):
744 (_Parameter(std::move_iterator<_Safe_iterator<>> const&, const char*,
746 * testsuite/24_iterators/move_iterator/debug_neg.cc: New.
747 * testsuite/24_iterators/normal_iterator/debug_neg.cc: New.
748 * testsuite/24_iterators/reverse_iterator/debug_neg.cc: New.
750 2018-05-09 Jonathan Wakely <jwakely@redhat.com>
752 * include/bits/std_function.h (_Base_manager::_M_get_pointer):
753 Use constexpr if in C++17 mode.
754 (_Base_manager::_M_clone(_Any_data&, const _Any_data&, true_type)):
755 Copy from const object.
756 * testsuite/20_util/function/cons/non_copyconstructible.cc: New.
758 2018-05-08 François Dumont <fdumont@gcc.gnu.org>
760 * src/c++11/debug.cc [_GLIBCXX_HAVE_EXECINFO_H]: Include execinfo.h.
761 [_GLIBCXX_HAVE_EXECINFO_H](_Error_formatter::_M_error): Render
764 * include/debug/macros.h (__glibcxx_check_valid_range_at): New.
765 * include/debug/functions.h (__check_valid_range): Use latter.
766 * include/debug/macros.h (__glibcxx_check_valid_constructor_range): New,
768 * include/debug/deque
769 (deque::deque<_Iter>(_Iter, _Iter, const _Alloc&)): Use latter.
770 * include/debug/forward_list
771 (forward_list::forward_list<_Iter>(_Iter, _Iter, const _Alloc&)):
774 (list::list<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
776 (list::list<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
777 * include/debug/map.h
778 (map::map<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
779 (map::map<_Iter>(_Iter, _Iter, const _Compare&, const _Alloc&)):
781 * include/debug/multimap.h
782 (multimap::multimap<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
783 (multimap::multimap<_Iter>(_Iter, _Iter, const _Compare&,
784 const _Alloc&)): Likewise.
785 * include/debug/set.h
786 (set::set<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
787 (set::set<_Iter>(_Iter, _Iter, const _Compare&, const _Alloc&)):
789 * include/debug/multiset.h
790 (multiset::multiset<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
791 (multiset::multiset<_Iter>(_Iter, _Iter, const _Compare&,
792 const _Alloc&)): Likewise.
793 * include/debug/string
794 (basic_string::basic_string<_Iter>(_Iter, _Iter, const _Alloc&)):
796 * include/debug/unordered_map
797 (unordered_map::unordered_map<_Iter>(_Iter, _Iter, const _Alloc&)):
799 (unordered_multimap::unordered_multimap<_Iter>(_Iter, _Iter,
800 const _Alloc&)): Likewise.
801 * include/debug/unordered_set
802 (unordered_set::unordered_set<_Iter>(_Iter, _Iter, const _Alloc&)):
804 (unordered_multiset::unordered_multiset<_Iter>(_Iter, _Iter,
805 const _Alloc&)): Likewise.
806 * include/debug/vector
807 (vector::vector<_Iter>(_Iter, _Iter, const _Alloc&)): Use latter.
809 * include/debug/formatter.h (_Error_formatter::_M_function): New.
810 (_Error_formatter(const char*, unsigned int)): Adapt.
811 (_Error_formatter::_M_at): Rename in...
812 (_Error_formatter::_S_at): ...that and adapt.
813 * include/debug/macros.h (_GLIBCXX_DEBUG_VERIFY_AT_F): New.
814 (_GLIBCXX_DEBUG_VERIFY_AT, _GLIBCXX_DEBUG_VERIFY): Adapt.
815 * src/c++11/debug.cc (_Error_formatter::_M_error): Render _M_function
818 2018-05-08 Jonathan Wakely <jwakely@redhat.com>
820 * include/bits/regex_automaton.h (_NFA_base::_M_paren_stack, _NFA):
821 Use normal std::vector even in Debug Mode.
824 * include/Makefile.am [!ENABLE_FLOAT128]: Change c++config.h entry
825 to #undef _GLIBCXX_USE_FLOAT128 instead of defining it to zero.
826 * include/Makefile.in: Regenerate.
827 * include/bits/c++config (_GLIBCXX_USE_FLOAT128): Move definition
828 within conditional block.
830 2018-05-07 Jonathan Wakely <jwakely@redhat.com>
832 * doc/xml/manual/using.xml (table.cmd_options): Document that the
833 C++17 Filesystem implementation also needs -lstdc++fs.
836 * include/bits/fs_path.h (operator/): Permit copy elision.
837 * include/experimental/bits/fs_path.h (operator/): Likewise.
839 2018-05-07 Edward Smith-Rowland <3dw4rd@verizon.net>
841 Moar PR libstdc++/80506
842 * include/bits/random.tcc (gamma_distribution::__generate_impl()):
843 Fix magic number used in loop condition.
845 2018-05-04 Jonathan Wakely <jwakely@redhat.com>
847 PR libstdc++/85642 fix is_nothrow_default_constructible<optional<T>>
848 * include/std/optional (_Optional_payload): Add noexcept to default
849 constructor. Re-indent.
850 (_Optional_payload<_Tp, true, true, true>): Likewise. Add noexcept to
851 constructor for copying disengaged payloads.
852 (_Optional_payload<_Tp, true, false, true>): Likewise.
853 (_Optional_payload<_Tp, true, true, false>): Likewise.
854 (_Optional_payload<_Tp, true, false, false>): Likewise.
855 * testsuite/20_util/optional/cons/85642.cc: New.
856 * testsuite/20_util/optional/cons/value_neg.cc: Adjust dg-error lines.
858 2018-05-03 Jonathan Wakely <jwakely@redhat.com>
861 * include/tr1/cmath [__STRICT_ANSI__] (hypergf, hypergl, hyperg): Use
862 inline definitions instead of using-declarations.
863 [__STRICT_ANSI__] (conf_hypergf, conf_hypergl, conf_hyperg): Likewise.
864 * testsuite/tr1/5_numerical_facilities/special_functions/
865 07_conf_hyperg/compile_cxx17.cc: New.
866 * testsuite/tr1/5_numerical_facilities/special_functions/
867 17_hyperg/compile_cxx17.cc: New.
870 * include/std/variant (visit): Qualify std::get call.
872 PR libstdc++/85632 use uintmax_t for arithmetic
873 * src/filesystem/ops.cc (experimental::filesystem::space): Perform
874 arithmetic in result type.
875 * src/filesystem/std-ops.cc (filesystem::space): Likewise.
876 * testsuite/27_io/filesystem/operations/space.cc: Check total capacity
877 is greater than free space.
878 * testsuite/experimental/filesystem/operations/space.cc: New.
880 * testsuite/20_util/remove_cvref/requirements/alias_decl.cc: New.
881 * testsuite/20_util/remove_cvref/requirements/explicit_instantiation.cc:
883 * testsuite/20_util/remove_cvref/value.cc: New.
884 * testsuite/20_util/remove_cvref/value_ext.cc: New.
886 PR libstdc++/84087 LWG DR 2268 basic_string default arguments
887 * include/bits/basic_string.h [_GLIBCXX_USE_CXX11_ABI=1]
888 (append(const basic_string&, size_type, size_type)
889 (assign(const basic_string&, size_type, size_type)
890 (insert(size_type, const basic_string&, size_type, size_type)
891 (replace(size_type,size_type,const basic_string&,size_type,size_type)
892 (compare(size_type,size_type,constbasic_string&,size_type,size_type)):
893 Add default arguments (LWG 2268).
894 [_GLIBCXX_USE_CXX11_ABI=0]
895 (append(const basic_string&, size_type, size_type)
896 (assign(const basic_string&, size_type, size_type)
897 (insert(size_type, const basic_string&, size_type, size_type)
898 (replace(size_type,size_type,const basic_string&,size_type,size_type)
899 (compare(size_type,size_type,constbasic_string&,size_type,size_type)):
901 * testsuite/21_strings/basic_string/dr2268.cc: New test.
904 * include/std/thread (thread::__not_same): New SFINAE helper.
905 (thread::thread(_Callable&&, _Args&&...)): Add SFINAE constraint that
906 first argument is not a std::thread. Add static assertion to check
907 INVOKE expression is valid.
908 (thread::thread(thread&), thread::thread(const thread&&)): Remove.
909 (thread::_Invoke::_M_invoke, thread::_Invoke::operator()): Use
910 __invoke_result for return types and remove exception specifications.
911 * testsuite/30_threads/thread/cons/84535.cc: New.
913 * include/std/future (__async_result_of): Use __invoke_result instead
916 * include/std/any (any_cast): Use __remove_cvref_t.
917 * include/std/tuple (__make_tuple): Likewise.
918 * include/std/type_traits (__remove_cvref_t): Define.
919 (__result_of_memobj, __result_of_memfun): Use __remove_cvref_t.
920 [__cplusplus > 201703L] (remove_cvref, remove_cvref_t): Define.
921 * include/std/variant (__erased_hash): Use __remove_cvref_t.
923 2018-05-02 François Dumont <fdumont@gcc.gnu.org>
925 * include/bits/deque.tcc (deque<>::_M_assign_aux): Cast to void to
926 ensure overloaded comma not used.
927 * include/bits/list.tcc (list<>::_M_assign_dispatch): Likewise.
928 * include/bits/vector.tcc (vector<>::_M_assign_aux): Likewise.
929 * include/bits/stl_bvector.h (vector<bool>::_M_assign_aux): Likewise.
930 * testsuite/23_containers/deque/modifiers/assign/1.cc: New.
931 * testsuite/23_containers/list/modifiers/assign/1.cc: New.
932 * testsuite/23_containers/vector/bool/modifiers/assign/1.cc: New.
933 * testsuite/23_containers/vector/modifiers/assign/1.cc: New.
935 2018-05-02 Jonathan Wakely <jwakely@redhat.com>
938 * include/bits/ios_base.h (ios_base::iword, ios_base::pword): Cast
940 * src/c++11/ios.cc (ios_base::_M_grow_words): Treat negative indices
941 as failure. Refactor error handling.
942 * testsuite/27_io/ios_base/storage/68197.cc: New.
946 * include/bits/gslice_array.h (gslice_array): Define default
947 constructor as deleted, as per C++11 standard.
948 * include/bits/mask_array.h (mask_array): Likewise.
949 * include/bits/slice_array.h (slice_array): Likewise.
950 * include/bits/valarray_after.h (_GBase, _GClos, _IBase, _IClos): Move
951 to namespace __detail.
952 (_GBase::_M_expr, _IBase::_M_expr): Use _ValArrayRef for type of data
954 * include/bits/valarray_before.h (_ValArrayRef): New helper for type
955 of data members in closure objects.
956 (_FunBase, _ValFunClos, _RefFunClos, _UnBase, _UnClos, _BinBase)
957 (_BinBase2, _BinBase1, _BinClos, _SBase, _SClos): Move to namespace
959 (_FunBase::_M_expr, _UnBase::_M_expr, _BinBase::_M_expr1)
960 (_BinBase::_M_expr2, _BinBase2::_M_expr1, _BinBase1::_M_expr2)
961 (_SBase::_M_expr): Use _ValArrayRef for type of data members.
962 * include/std/valarray (_UnClos, _BinClos, _SClos, _GClos, _IClos)
963 (_ValFunClos, _RefFunClos): Move to namespace __detail and add
964 using-declarations to namespace std.
965 * testsuite/26_numerics/valarray/83860.cc: New.
967 * testsuite/backward/strstream_move.cc: Remove duplicate function
971 * include/backward/strstream (strstreambuf): Define move constructor
972 and move assignment operator.
973 (istrstream, ostrstream, strstream): Likewise.
974 * testsuite/backward/strstream_move.cc: New.
976 2018-05-01 Tulio Magno Quites Machado Filho <tuliom@linux.vnet.ibm.com>
979 * acinclude.m4: Set ENABLE_FLOAT128 instead of _GLIBCXX_USE_FLOAT128.
980 * config.h.in: Remove references to _GLIBCXX_USE_FLOAT128.
981 * configure: Regenerate.
982 * include/Makefile.am: Replace the value of _GLIBCXX_USE_FLOAT128
983 based on ENABLE_FLOAT128.
984 * include/Makefile.in: Regenerate.
985 * include/bits/c++config: Define _GLIBCXX_USE_FLOAT128.
986 [!defined(__FLOAT128__) && !defined(__SIZEOF_FLOAT128__)]: Undefine
987 _GLIBCXX_USE_FLOAT128.
989 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
991 * configure: Regenerated.
993 2018-04-19 Jakub Jelinek <jakub@redhat.com>
995 * configure: Regenerated.
997 2018-04-18 Jonathan Wakely <jwakely@redhat.com>
998 Jakub Jelinek <jakub@redhat.com>
1001 * src/c++11/Makefile.am: Don't generate debuginfo again for
1002 cxx11-ios_failure-lt.s and cxx11-ios_failure.s files.
1003 * src/c++11/Makefile.in: Regenerate.
1005 2018-04-18 Jonathan Wakely <jwakely@redhat.com>
1008 * testsuite/30_threads/thread/cons/terminate.cc
1009 [!_GLIBCXX_USE_C99_STDLIB] : Use _exit or std::exit instead of _Exit.
1011 2018-04-18 David Malcolm <dmalcolm@redhat.com>
1014 * configure: Regenerate.
1016 2018-04-16 Jonathan Wakely <jwakely@redhat.com>
1018 * testsuite/experimental/filesystem/file_status/1.cc: Add
1019 -DUSE_FILESYSTEM_TS to dg-options.
1020 * testsuite/experimental/filesystem/iterators/directory_iterator.cc:
1022 * testsuite/experimental/filesystem/iterators/pop.cc: Likewise.
1023 * testsuite/experimental/filesystem/iterators/
1024 recursive_directory_iterator.cc: Likewise.
1025 * testsuite/experimental/filesystem/operations/absolute.cc: Likewise.
1026 * testsuite/experimental/filesystem/operations/canonical.cc: Likewise.
1027 * testsuite/experimental/filesystem/operations/copy.cc: Likewise.
1028 * testsuite/experimental/filesystem/operations/copy_file.cc: Likewise.
1029 * testsuite/experimental/filesystem/operations/create_directories.cc:
1031 * testsuite/experimental/filesystem/operations/create_directory.cc:
1033 * testsuite/experimental/filesystem/operations/create_symlink.cc:
1035 * testsuite/experimental/filesystem/operations/current_path.cc:
1037 * testsuite/experimental/filesystem/operations/equivalent.cc: Likewise.
1038 * testsuite/experimental/filesystem/operations/exists.cc: Likewise.
1039 * testsuite/experimental/filesystem/operations/file_size.cc: Likewise.
1040 * testsuite/experimental/filesystem/operations/is_empty.cc: Likewise.
1041 * testsuite/experimental/filesystem/operations/last_write_time.cc:
1043 * testsuite/experimental/filesystem/operations/permissions.cc:
1045 * testsuite/experimental/filesystem/operations/read_symlink.cc:
1047 * testsuite/experimental/filesystem/operations/remove.cc: Likewise.
1048 * testsuite/experimental/filesystem/operations/remove_all.cc: Likewise.
1049 * testsuite/experimental/filesystem/operations/status.cc: Likewise.
1050 * testsuite/experimental/filesystem/operations/temp_directory_path.cc:
1052 * testsuite/experimental/filesystem/path/append/path.cc: Likewise.
1053 * testsuite/experimental/filesystem/path/assign/assign.cc: Likewise.
1054 * testsuite/experimental/filesystem/path/assign/copy.cc: Likewise.
1055 * testsuite/experimental/filesystem/path/compare/compare.cc: Likewise.
1056 * testsuite/experimental/filesystem/path/compare/path.cc: Likewise.
1057 * testsuite/experimental/filesystem/path/compare/strings.cc: Likewise.
1058 * testsuite/experimental/filesystem/path/concat/path.cc: Likewise.
1059 * testsuite/experimental/filesystem/path/concat/strings.cc: Likewise.
1060 * testsuite/experimental/filesystem/path/construct/copy.cc: Likewise.
1061 * testsuite/experimental/filesystem/path/construct/default.cc:
1063 * testsuite/experimental/filesystem/path/construct/locale.cc: Likewise.
1064 * testsuite/experimental/filesystem/path/construct/range.cc: Likewise.
1065 * testsuite/experimental/filesystem/path/construct/string_view.cc:
1067 * testsuite/experimental/filesystem/path/decompose/extension.cc:
1069 * testsuite/experimental/filesystem/path/decompose/filename.cc:
1071 * testsuite/experimental/filesystem/path/decompose/parent_path.cc:
1073 * testsuite/experimental/filesystem/path/decompose/relative_path.cc:
1075 * testsuite/experimental/filesystem/path/decompose/root_directory.cc:
1077 * testsuite/experimental/filesystem/path/decompose/root_name.cc:
1079 * testsuite/experimental/filesystem/path/decompose/root_path.cc:
1081 * testsuite/experimental/filesystem/path/decompose/stem.cc: Likewise.
1082 * testsuite/experimental/filesystem/path/generic/generic_string.cc:
1084 * testsuite/experimental/filesystem/path/itr/traversal.cc: Likewise.
1085 * testsuite/experimental/filesystem/path/modifiers/clear.cc: Likewise.
1086 * testsuite/experimental/filesystem/path/modifiers/make_preferred.cc:
1088 * testsuite/experimental/filesystem/path/modifiers/remove_filename.cc:
1090 * testsuite/experimental/filesystem/path/modifiers/replace_extension.cc:
1092 * testsuite/experimental/filesystem/path/modifiers/replace_filename.cc:
1094 * testsuite/experimental/filesystem/path/modifiers/swap.cc: Likewise.
1095 * testsuite/experimental/filesystem/path/native/string.cc: Likewise.
1096 * testsuite/experimental/filesystem/path/nonmember/hash_value.cc:
1098 * testsuite/experimental/filesystem/path/query/empty.cc: Likewise.
1099 * testsuite/experimental/filesystem/path/query/has_extension.cc:
1101 * testsuite/experimental/filesystem/path/query/has_filename.cc:
1103 * testsuite/experimental/filesystem/path/query/has_parent_path.cc:
1105 * testsuite/experimental/filesystem/path/query/has_relative_path.cc:
1107 * testsuite/experimental/filesystem/path/query/has_root_directory.cc:
1109 * testsuite/experimental/filesystem/path/query/has_root_name.cc:
1111 * testsuite/experimental/filesystem/path/query/has_root_path.cc:
1113 * testsuite/experimental/filesystem/path/query/has_stem.cc: Likewise.
1114 * testsuite/experimental/filesystem/path/query/is_relative.cc:
1117 2018-04-13 Jonathan Wakely <jwakely@redhat.com>
1119 * src/c++11/Makefile.am: Fix sed command.
1120 * src/c++11/Makefile.in: Regenerate.
1122 * src/c++11/Makefile.am: Rewrite sed rule to be less fragile and to
1123 handle mangled names starting with double underscores on darwin.
1124 * src/c++11/Makefile.in: Regenerate.
1126 2018-04-12 Jonathan Wakely <jwakely@redhat.com>
1128 * src/c++11/Makefile.am: Fix comment.
1129 * src/c++11/Makefile.in: Regenerate.
1130 * src/c++11/cxx11-ios_failure.cc: Fix comment.
1131 * src/c++98/ios_failure.cc: Likewise.
1133 * src/c++11/ios.cc: Remove redundant macro definition.
1135 2018-04-11 Jonathan Wakely <jwakely@redhat.com>
1137 * doc/xml/manual/abi.xml: Document header locations in recent
1139 * doc/xml/manual/evolution.xml: Add API changes since GCC 5.
1140 * doc/xml/manual/spine.xml: Update copyright years.
1141 * doc/xml/manual/strings.xml: Adjust tolower example to avoid
1142 undefined behaviour.
1143 * doc/xml/manual/test.xml: Update outdated notes on VERIFY in tests.
1144 * doc/html/*: Regenerate.
1146 2018-04-10 Jonathan Wakely <jwakely@redhat.com>
1148 * doc/xml/faq.xml: Update links to archived copy of SGI STL docs.
1149 * doc/xml/manual/backwards_compatibility.xml: Likewise.
1150 * doc/xml/manual/containers.xml: Likewise.
1151 * doc/xml/manual/debug_mode.xml: Likewise.
1152 * doc/xml/manual/extensions.xml: Likewise.
1153 * doc/xml/manual/policy_data_structures_biblio.xml: Likewise.
1154 * doc/xml/manual/using.xml: Likewise.
1155 * doc/xml/manual/utilities.xml: Likewise.
1158 * src/c++11/Makefile.am [ENABLE_DUAL_ABI]: Add special rules for
1159 cxx11-ios_failure.cc to rewrite type info for __ios_failure.
1160 * src/c++11/Makefile.in: Regenerate.
1161 * src/c++11/cxx11-ios_failure.cc (__ios_failure, __iosfail_type_info):
1163 [_GLIBCXX_USE_DUAL_ABI] (__throw_ios_failure): Define here.
1164 * src/c++11/ios.cc (__throw_ios_failure): Remove definition.
1165 * src/c++98/ios_failure.cc (__construct_ios_failure)
1166 (__destroy_ios_failure, is_ios_failure_handler): New functions.
1167 [!_GLIBCXX_USE_DUAL_ABI] (__throw_ios_failure): Define here.
1168 * testsuite/27_io/ios_base/failure/dual_abi.cc: New.
1169 * testsuite/27_io/basic_ios/copyfmt/char/1.cc: Revert changes to
1170 handler types, to always catch std::ios_base::failure.
1171 * testsuite/27_io/basic_ios/exceptions/char/1.cc: Likewise.
1172 * testsuite/27_io/basic_istream/extractors_arithmetic/char/
1173 exceptions_failbit.cc: Likewise.
1174 * testsuite/27_io/basic_istream/extractors_arithmetic/wchar_t/
1175 exceptions_failbit.cc: Likewise.
1176 * testsuite/27_io/basic_istream/extractors_other/char/
1177 exceptions_null.cc: Likewise.
1178 * testsuite/27_io/basic_istream/extractors_other/wchar_t/
1179 exceptions_null.cc: Likewise.
1180 * testsuite/27_io/basic_istream/sentry/char/12297.cc: Likewise.
1181 * testsuite/27_io/basic_istream/sentry/wchar_t/12297.cc: Likewise.
1182 * testsuite/27_io/basic_ostream/inserters_other/char/
1183 exceptions_null.cc: Likewise.
1184 * testsuite/27_io/basic_ostream/inserters_other/wchar_t/
1185 exceptions_null.cc: Likewise.
1186 * testsuite/27_io/ios_base/storage/2.cc: Likewise.
1188 2018-04-05 Jonathan Wakely <jwakely@redhat.com>
1190 * include/std/variant (_VARIANT_RELATION_FUNCTION_TEMPLATE): Qualify
1191 __get calls to avoid ADL and avoid ambiguity due to Clang bug.
1193 2018-04-03 Jonathan Wakely <jwakely@redhat.com>
1196 * include/std/variant (_Move_assign_base::operator=): Fix incorrect
1198 * testsuite/20_util/variant/85183.cc: New.
1200 2018-03-26 Jonathan Wakely <jwakely@redhat.com>
1202 * include/std/variant (__get): Qualify calls to avoid ADL.
1203 (__select_index): Adjust whitespace.
1204 (variant): Add using-declaration to workaround Clang bug.
1206 2018-03-22 Jonathan Wakely <jwakely@redhat.com>
1209 * include/bits/stl_function.h (greater::__not_overloaded)
1210 (less::__not_overloaded, greater_equal::__not_overloaded)
1211 (less_equal::__not_overloaded): Fix ambiguous specializations.
1212 * testsuite/20_util/function_objects/comparisons_pointer.cc: Add
1213 tests for type with overloaded operators.
1215 2018-03-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1218 * testsuite/experimental/memory_resource/resource_adaptor.cc:
1219 xfail execution on 32-bit Solaris/x86.
1221 2018-03-21 Jonathan Wakely <jwakely@redhat.com>
1223 * testsuite/20_util/function_objects/comparisons_pointer.cc: Use
1224 VERIFY instead of assert.
1225 * testsuite/20_util/hash/84998.cc: New test.
1226 * testsuite/23_containers/vector/cons/destructible_debug_neg.cc: New
1227 copy of test adjusted for Debug Mode.
1228 * testsuite/23_containers/vector/cons/destructible_neg.cc: Do not run
1231 2018-03-20 François Dumont <fdumont@gcc.gnu.org>
1234 * include/bits/stl_bvector.h: Fix std::hash friend declaration.
1235 * include/std/bitset: Likewise.
1236 * include/bits/stl_map.h (std::map<>): Fix _Rb_tree_merge_helper friend
1238 * include/bits/stl_multimap.h (std::multimap<>): Likewise.
1239 * include/bits/stl_multiset.h (std::multiset<>): Likewise.
1240 * include/bits/stl_set.h (std::set<>): Likewise.
1241 * include/bits/unordered_map.h (std::unordered_map<>): Fix
1242 _Hash_merge_helper friend declaration.
1243 (std::unordered_multimap<>): Likewise.
1244 * include/bits/unordered_set.h (std::unordered_set<>): Likewise.
1245 (std::unordered_multiset<>): Likewise.
1247 2018-03-19 Gerald Pfeifer <gerald@pfeifer.com>
1249 * doc/xml/api.xml: www.fsf.org has moved to https. Also omit
1250 trailing slash for domain level link.
1251 * doc/xml/faq.xml: Ditto.
1252 * doc/xml/manual/appendix_free.xml (software): Ditto.
1253 * doc/xml/manual/intro.xml: Ditto.
1254 * doc/xml/manual/spine.xml: Ditto.
1255 * doc/xml/spine.xml: Ditto.
1257 2018-03-19 Gerald Pfeifer <gerald@pfeifer.com>
1259 * doc/xml/manual/documentation_hacking.xml: Adjust link to
1262 2018-03-17 Jonathan Wakely <jwakely@redhat.com>
1264 * testsuite/20_util/function_objects/comparisons_pointer.cc: Adjust
1265 to compile as C++98.
1267 2018-03-14 Jonathan Wakely <jwakely@redhat.com>
1270 * include/bits/stl_function.h (greater<_Tp*>, less<_Tp*>)
1271 (greater_equal<_Tp*>, less_equal<_Tp>*): Add partial specializations
1272 to ensure total order for pointers.
1273 (greater<void>, less<void>, greater_equal<void>, less_equal<void>):
1274 Add operator() overloads for pointer arguments and make generic
1275 overloads dispatch to new _S_cmp functions when comparisons would
1276 use built-in operators for pointers.
1277 * testsuite/20_util/function_objects/comparisons_pointer.cc: New.
1279 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
1283 * crossconfig.m4: Check for aligned_alloc etc. on freebsd and mingw32.
1284 * configure: Regenerate.
1285 * include/c_global/cstdlib [_GLIBCXX_HAVE_ALIGNED_ALLOC]
1286 (aligned_alloc): Add using-declaration.
1287 * testsuite/18_support/aligned_alloc/aligned_alloc.cc: New test.
1289 2018-03-09 François Dumont <fdumont@gcc.gnu.org>
1291 * python/libstdcxx/v6/printers.py (build_libstdcxx_dictionary):
1292 Fix std::_Fwd_list_iterator and std::_Fwd_list_const_iterator printers
1295 2018-03-09 Jonathan Wakely <jwakely@redhat.com>
1298 * include/std/variant (get<_Tp, _Types...>, get_if<_Tp, _Types...>):
1299 Qualify calls to get<_Np, Types...> and get_if<_Np, _Types...>.
1301 src/filesystem/ops.cc (create_dir): Pass error_code to is_directory.
1302 src/filesystem/std-ops.cc (create_dir): Likewise.
1304 2018-03-08 François Dumont <fdumont@gcc.gnu.org>
1306 * python/libstdcxx/v6/printers.py (NodeIteratorPrinter): New.
1307 (StdListIteratorPrinter): Inherit from latter.
1308 (StdFwdListIteratorPrinter): New, inherit from latter.
1309 (StdDebugIteratorPrinter.to_string): Use non-debug iterator printer
1310 when iterator has no associated container.
1311 (build_libstdcxx_dictionary): Add __gnu_cxx::_Fwd_list_iterator and
1312 __gnu_cxx::_Fwd_list_const_iterator printers. Remove __norm namespace
1314 * testsuite/libstdc++-prettyprinters/debug.cc: Adapt.
1315 * testsuite/libstdc++-prettyprinters/debug_cxx11.cc: Adapt.
1317 2018-03-06 Ville Voutilainen <ville.voutilainen@gmail.com>
1320 * include/std/optional (_Optional_payload): Split into multiple
1321 specializations that can handle different cases of trivial or
1322 non-trivial assignment operators.
1323 * testsuite/20_util/optional/84601.cc: New.
1324 * testsuite/20_util/optional/cons/value_neg.cc: Adjust.
1326 2018-03-02 Jonathan Wakely <jwakely@redhat.com>
1329 * include/bits/parse_numbers.h (_Number_help): Add partial
1330 specialization to handle digit separators. Adjust partial
1331 specialization for recursion temrination to require _Pow == 1ULL.
1332 * testsuite/20_util/duration/literals/84671.cc: New
1334 2018-02-27 Ville Voutilainen <ville.voutilainen@gmail.com>
1336 Implement the missing bits of LWG 2769
1337 * include/std/any (any_cast(const any&)): Add static_assert.
1338 (any_cast(any&)): Likewise.
1339 (any_cast(any&&)): Likewise, and remove the handling
1340 for copyable-but-not-movable type.
1341 * testsuite/20_util/any/misc/any_cast.cc: Adjust.
1342 * testsuite/20_util/any/misc/any_cast_neg.cc: Likewise, and
1345 2018-02-23 Jonathan Wakely <jwakely@redhat.com>
1348 * include/std/thread (thread::__make_invoker): Construct tuple
1349 directly instead of using make_tuple.
1350 * testsuite/30_threads/async/84532.cc: New.
1351 * testsuite/30_threads/thread/84532.cc: New.
1353 2018-02-20 François Dumont <fdumont@gcc.gnu.org>
1355 * include/ext/aligned_buffer.h [_GLIBCXX_INLINE_VERSION]
1356 (template<> __aligned_buffer): Define as __aligned_membuf alias.
1358 2018-02-19 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
1361 * configure: Regenerate.
1363 2018-02-15 Jonathan Wakely <jwakely@redhat.com>
1366 * configure.ac (INCLUDE_DIR_NOTPARALLEL): Define.
1367 * configure: Regenerate.
1368 * include/Makefile.am (INCLUDE_DIR_NOTPARALLEL): Add .NOTPARALLEL when
1370 * include/Makefile.in: Regenerate.
1372 2018-01-29 Jonathan Wakely <jwakely@redhat.com>
1375 * testsuite/26_numerics/random/chi_squared_distribution/83833.cc:
1376 Add -ffloat-store to options for m68k and ia32.
1378 * doc/xml/faq.xml: Update copyright years.
1379 * doc/html/*: Regenerate.
1382 * include/std/any (any::__do_emplace): Only set _M_manager after
1383 constructing the contained object.
1384 * testsuite/20_util/any/misc/any_cast_neg.cc: Adjust dg-error line.
1385 * testsuite/20_util/any/modifiers/83658.cc: New test.
1387 2018-01-25 Jonathan Wakely <jwakely@redhat.com>
1390 * include/c_global/cstddef (__byte_operand): Define primary template.
1391 * testsuite/18_support/byte/81076.cc: New test.
1393 2018-01-19 Christophe Lyon <christophe.lyon@linaro.org>
1395 * testsuite/ext/special_functions/airy_ai/check_nan.cc: Fix
1396 dg-options and dg-add-options order.
1397 * testsuite/ext/special_functions/airy_bi/check_nan.cc: Likewise.
1398 * testsuite/ext/special_functions/conf_hyperg/check_nan.cc:
1400 * testsuite/ext/special_functions/hyperg/check_nan.cc: Likewise.
1401 * testsuite/special_functions/01_assoc_laguerre/check_nan.cc:
1403 * testsuite/special_functions/02_assoc_legendre/check_nan.cc:
1405 * testsuite/special_functions/03_beta/check_nan.cc: Likewise.
1406 * testsuite/special_functions/04_comp_ellint_1/check_nan.cc:
1408 * testsuite/special_functions/05_comp_ellint_2/check_nan.cc:
1410 * testsuite/special_functions/06_comp_ellint_3/check_nan.cc:
1412 * testsuite/special_functions/06_comp_ellint_3/pr66689.cc:
1414 * testsuite/special_functions/07_cyl_bessel_i/check_nan.cc:
1416 * testsuite/special_functions/08_cyl_bessel_j/check_nan.cc:
1418 * testsuite/special_functions/09_cyl_bessel_k/check_nan.cc:
1420 * testsuite/special_functions/10_cyl_neumann/check_nan.cc:
1422 * testsuite/special_functions/11_ellint_1/check_nan.cc: Likewise.
1423 * testsuite/special_functions/12_ellint_2/check_nan.cc: Likewise.
1424 * testsuite/special_functions/13_ellint_3/check_nan.cc: Likewise.
1425 * testsuite/special_functions/13_ellint_3/pr66689.cc: Likewise.
1426 * testsuite/special_functions/14_expint/check_nan.cc: Likewise.
1427 * testsuite/special_functions/15_hermite/check_nan.cc: Likewise.
1428 * testsuite/special_functions/16_laguerre/check_nan.cc: Likewise.
1429 * testsuite/special_functions/17_legendre/check_nan.cc: Likewise.
1430 * testsuite/special_functions/18_riemann_zeta/check_nan.cc:
1432 * testsuite/special_functions/19_sph_bessel/check_nan.cc:
1434 * testsuite/special_functions/20_sph_legendre/check_nan.cc:
1436 * testsuite/special_functions/21_sph_neumann/check_nan.cc:
1439 2018-01-18 Uros Bizjak <ubizjak@gmail.com>
1441 * configure.ac (AC_CHECK_HEADERS): Add linux/types.h. Conditionally
1442 include linux/types.h when checking linux/random.h header.
1443 * config.h.in: Regenerate.
1445 * src/c++11/random.cc: Conditionally include linux/types.h.
1447 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
1449 * testsuite/17_intro/names.cc: Undefine 'y' on SPARC/Linux.
1451 2018-01-16 Jonathan Wakely <jwakely@redhat.com>
1454 * config/abi/pre/gnu.ver (GLIBCXX_3.4): Replace std::c[a-g]* wildcard
1455 pattern with exact match for std::cerr.
1457 2018-01-15 Jonathan Wakely <jwakely@redhat.com>
1460 * include/bits/random.h (chi_squared_distribution::param): Update
1461 gamma distribution parameter.
1462 * testsuite/26_numerics/random/chi_squared_distribution/83833.cc: New
1466 * include/std/type_traits (has_unique_object_representations_v): Add
1468 * testsuite/20_util/has_unique_object_representations/value.cc: Check
1471 2018-01-15 Ville Voutilainen <ville.voutilainen@gmail.com>
1473 Make optional conditionally
1474 trivially_{copy,move}_{constructible,assignable}
1475 * include/std/optional (_Optional_payload): Fix the comment in
1476 the class head and turn into a primary and one specialization.
1477 (_Optional_payload::_M_engaged): Strike the NSDMI.
1478 (_Optional_payload<_Tp, false>::operator=(const _Optional_payload&)):
1480 (_Optional_payload<_Tp, false>::operator=(_Optional_payload&&)):
1482 (_Optional_payload<_Tp, false>::_M_get): Likewise.
1483 (_Optional_payload<_Tp, false>::_M_reset): Likewise.
1484 (_Optional_base_impl): Likewise.
1485 (_Optional_base): Turn into a primary and three specializations.
1486 (optional(nullopt)): Change the base init.
1487 * testsuite/20_util/optional/assignment/8.cc: New.
1488 * testsuite/20_util/optional/cons/trivial.cc: Likewise.
1489 * testsuite/20_util/optional/cons/value_neg.cc: Adjust.
1491 2018-01-15 Jonathan Wakely <jwakely@redhat.com>
1494 * python/libstdcxx/v6/printers.py (strip_inline_namespaces): New.
1495 (get_template_arg_list): New.
1496 (StdVariantPrinter._template_args): Remove, use get_template_arg_list
1498 (TemplateTypePrinter): Rewrite to work with gdb.Type objects instead
1499 of strings and regular expressions.
1500 (add_one_template_type_printer): Adapt to new TemplateTypePrinter.
1501 (FilteringTypePrinter): Add docstring. Match using startswith. Use
1502 strip_inline_namespaces instead of strip_versioned_namespace.
1503 (add_one_type_printer): Prepend namespace to match argument.
1504 (register_type_printers): Add type printers for char16_t and char32_t
1505 string types and for types using cxx11 ABI. Update calls to
1506 add_one_template_type_printer to provide default argument dicts.
1507 * testsuite/libstdc++-prettyprinters/80276.cc: New test.
1508 * testsuite/libstdc++-prettyprinters/whatis.cc: Remove tests for
1509 basic_string<unsigned char> and basic_string<signed char>.
1510 * testsuite/libstdc++-prettyprinters/whatis2.cc: Duplicate whatis.cc
1511 to test local variables, without overriding _GLIBCXX_USE_CXX11_ABI.
1513 2018-01-14 Andreas Schwab <schwab@linux-m68k.org>
1516 * config/abi/post/ia64-linux-gnu/baseline_symbols.txt: Update.
1518 2018-01-13 Tim Shen <timshen@google.com>
1521 * include/bits/regex.tcc (regex_replace): Fix escaping in sed.
1522 * testsuite/28_regex/algorithms/regex_replace/char/pr83601.cc: Tests.
1523 * testsuite/28_regex/algorithms/regex_replace/wchar_t/pr83601.cc: Tests.
1525 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1528 * testsuite/27_io/basic_ostream/inserters_arithmetic/char/hexfloat.cc:
1529 Remove dg-xfail-run-if.
1531 2018-01-10 François Dumont <fdumont@gcc.gnu.org>
1533 * include/bits/forward_list.h
1534 (_Fwd_list_node_base(_Fwd_list_node_base&&)): New.
1535 (_Fwd_list_node_base& operator=(_Fwd_list_node_base&&)): New.
1536 (_Fwd_list_node_base(const _Fwd_list_node_base&)): Explicit delete.
1537 (_Fwd_list_node_base& operator=(const _Fwd_list_node_base&)): Likewise.
1538 (_Fwd_list_impl()): Add noexcept qualification.
1539 (_Fwd_list_impl(const _Node_alloc_type&)): Delete.
1540 (_Fwd_list_impl(_Fwd_list_impl&&)): New, default.
1541 (_Fwd_list_impl(_Fwd_list_impl&&, _Node_alloc_type&&)): New.
1542 (_Fwd_list_base()): Default.
1543 (_Fwd_list_base(_Fwd_list_base&&, _Node_alloc_type&&, true_type)): New.
1544 (_Fwd_list_base(_Fwd_list_base&&)): Default.
1545 (forward_list<>()): Default.
1546 (forward_list<>(forward_list&&)): Default.
1547 (forward_list(forward_list&&, _Node_alloc_type&&, false_type)): New.
1548 (forward_list(forward_list&&, _Node_alloc_type&&, true_type)): New.
1549 (forward_list(forward_list&&, const _Alloc&)): Adapt to use latters.
1550 * include/bits/forward_list.tcc
1551 (_Fwd_list_base(_Fwd_list_base&&, _Node_alloc_type&&)): Adapt to use
1552 _M_impl._M_head move assignment.
1553 (forward_list<>::merge(forward_list<>&&, _Comp)): Likewise.
1554 * testsuite/23_containers/forward_list/allocator/default_init.cc: New.
1556 2018-01-09 Jonathan Wakely <jwakely@redhat.com>
1559 * python/libstdcxx/v6/printers.py (SharedPointerPrinter)
1560 (UniquePointerPrinter): Print correct template argument, not type of
1562 (TemplateTypePrinter._recognizer.recognize): Handle failure to lookup
1564 * testsuite/libstdc++-prettyprinters/cxx11.cc: Test unique_ptr of
1566 * testsuite/libstdc++-prettyprinters/cxx17.cc: Test shared_ptr and
1567 weak_ptr of array types.
1569 2018-01-09 François Dumont <fdumont@gcc.gnu.org>
1572 * include/bits/hashtable_policy.h
1573 (__distance_fwd(_Iterator, _Iterator, input_iterator_tag)): Return 1 if
1575 (_Insert_base::_M_insert_range(_Ite, _Ite, _NodeGetter, true_type)): New.
1576 (_Insert_base::_M_insert_range(_Ite, _Ite, _NodeGetter, false_type)):
1577 Add false_type parameter.
1578 (_Insert_base::insert): Adapt.
1579 * include/bits/hashtable.h (_Hashtable::operator=(initializzr_list<>)):
1581 (_Hashtable::_M_insert(_Arg&&, const _NodeGen&, true_type, size_t)):
1582 Add __n_elt parameter, defaulted to 1.
1583 (_Hashtable::_M_insert_unique_node): Likewise. Use it to call rehash
1584 policy _M_need_rehash.
1585 (_Hashtable::_M_merge_unique): Pass target number of elements to add to
1586 produce only 1 rehash if necessary.
1587 * testsuite/23_containers/unordered_map/insert/83709.cc: New.
1588 * testsuite/23_containers/unordered_set/insert/83709.cc: New.
1590 2018-01-09 Juraj Oršulić <juraj.orsulic@fer.hr>
1591 Jonathan Wakely <jwakely@redhat.com>
1593 PR libstdc++/59253 (partial)
1594 * python/libstdcxx/v6/printers.py (SmartPtrIterator): Common iterator
1595 type for pointer stored by shared_ptr, weak_ptr and unique_ptr.
1596 (SharedPointerPrinter, UniquePointerPrinter): Treat stored values as
1598 * testsuite/libstdc++-prettyprinters/cxx11.cc: Update expected output
1599 of unique_ptr printer.
1600 * testsuite/libstdc++-prettyprinters/shared_ptr.cc: Update expected
1601 output of shared_ptr printer.
1603 2018-01-05 Jonathan Wakely <jwakely@redhat.com>
1606 * src/filesystem/ops.cc (remove(const path&, error_code&)): Remove
1607 unnecessary symlink_status call.
1608 (remove_all(const path&, error_code&)): Use filesystem::remove.
1609 * src/filesystem/std-ops.cc: Likewise.
1612 * src/filesystem/std-ops.cc (do_copy_file): Use non-null offset with
1616 * src/filesystem/ops.cc (remove(const path&, error_code&)): Do not
1617 report an error for ENOENT.
1618 (remove_all(const path&)): Fix type of result variable.
1619 (remove_all(const path&, error_code&)): Use non-throwing increment
1620 for directory iterator. Call POSIX remove directly to avoid redundant
1621 calls to symlink_status. Do not report errors for ENOENT.
1622 * src/filesystem/std-ops.cc: Likewise.
1623 * testsuite/27_io/filesystem/operations/remove_all.cc: Test throwing
1625 * testsuite/experimental/filesystem/operations/remove_all.cc:
1628 2018-01-04 Jonathan Wakely <jwakely@redhat.com>
1631 * src/filesystem/ops.cc (remove(const path&, error_code&))): Remove
1632 redundant call to ec.clear().
1633 (remove_all(const path&, error_code&))): Do not return an error for
1635 * src/filesystem/std-ops.cc: Likewise.
1636 * testsuite/27_io/filesystem/operations/remove.cc: New test.
1637 * testsuite/27_io/filesystem/operations/remove_all.cc: Fix expected
1638 results for non-existent paths.
1639 * testsuite/experimental/filesystem/operations/remove.cc: New test.
1640 * testsuite/experimental/filesystem/operations/remove_all.cc: Fix
1641 expected results for non-existent paths.
1643 * include/bits/fs_ops.h (exists(const path&, error_code&))): Only
1644 check status_known once.
1645 * include/experimental/bits/fs_ops.h: Likewise.
1648 * include/std/functional (__is_byte_like): New trait.
1649 (__is_std_equal_to): Remove.
1650 (__boyer_moore_base_t): Use __is_byte_like instead of
1652 * include/experimental/functional (__is_std_equal_to): Remove.
1653 (__boyer_moore_base_t): Use __is_byte_like instead of
1655 * testsuite/20_util/function_objects/83607.cc: New test.
1657 2018-01-03 Ville Voutilainen <ville.voutilainen@gmail.com>
1659 Protect optional's deduction guide with the feature macro
1660 * include/std/optional: Use the feature macro.
1662 2018-01-03 Jakub Jelinek <jakub@redhat.com>
1664 Update copyright years.
1666 Copyright (C) 2018 Free Software Foundation, Inc.
1668 Copying and distribution of this file, with or without modification,
1669 are permitted in any medium without royalty provided the copyright
1670 notice and this notice are preserved.