Qualify another call in <variant>
[gcc.git] / libstdc++-v3 / ChangeLog
1 2018-05-29 Jonathan Wakely <jwakely@redhat.com>
2
3 * include/std/variant (__erased_dtor): Qualify call to __get.
4
5 2018-05-27 François Dumont <fdumont@gcc.gnu.org>
6
7 * include/bits/stl_tree.h (_Rb_tree_impl(_Node_allocator&&)): New.
8 (_Rb_tree(const allocator_type&)): Use latter.
9 * include/bits/stl_map.h (map(const allocator_type&)): Likewise.
10 (map(initializer_list<value_type>, const allocator_type&)): Likewise.
11 (map(_InputIterator, _InputIterator, const allocator_type&)): Likewise.
12 * include/bits/stl_multimap.h
13 (multimap(const allocator_type&)): Likewise.
14 (multimap(initializer_list<value_type>, const allocator_type&)):
15 Likewise.
16 (multimap(_InputIterator, _InputIterator, const allocator_type&)):
17 Likewise.
18 * include/bits/stl_set.h (set(const allocator_type&)): Likewise.
19 (set(initializer_list<value_type>, const allocator_type&)): Likewise.
20 (set(_InputIterator, _InputIterator, const allocator_type&)): Likewise.
21 * include/bits/stl_multiset.h
22 (multiset(const allocator_type&)): Likewise.
23 (multiset(initializer_list<value_type>, const allocator_type&)):
24 Likewise.
25 (multiset(_InputIterator, _InputIterator, const allocator_type&)):
26 Likewise.
27
28 2018-05-25 François Dumont <fdumont@gcc.gnu.org>
29
30 PR libstdc++/85768
31 * src/c++11/debug.cc: Remove backtrace usage.
32
33 2018-05-24 Maya Rashish <coypu@sdf.org>
34
35 PR target/85904
36 * crossconfig.m4: Test for aligned_alloc on netbsd.
37 * configure: Regenerate.
38
39 2018-05-24 Jonathan Wakely <jwakely@redhat.com>
40
41 PR libstdc++/69769
42 PR libstdc++/85886
43 * include/bits/atomic_base.h (__atomic_base::value_type)
44 (__atomic_base::difference_type): Add new typedefs.
45 * include/std/atomic (atomic<bool>::value_type, atomic<T>::value_type)
46 (atomic<T*>::value_type, atomic<T*>::difference_type): Likewise.
47 (atomic<T*>::operator++, atomic<T*>::operator--)
48 (atomic<T*>::operator+=, atomic<T*>::operator-=)
49 (atomic<T*>::fetch_add, atomic<T*>::fetch_sub): Add static assertion
50 to enforce C++17 requirement on pointer arithmetic.
51 (__atomic_val_t, __atomic_diff_t): New alias templates.
52 (atomic_init, atomic_store_explicit, atomic_exchange_explicit)
53 (atomic_compare_exchange_weak_explicit)
54 (atomic_compare_exchange_strong_explicit, atomic_store)
55 (atomic_exchange, atomic_compare_exchange_weak)
56 (atomic_compare_exchange_strong): Use __atomic_val_t to make
57 scalar parameters be non-deduced contexts.
58 (atomic_fetch_add_explicit, atomic_fetch_sub_explicit)
59 (atomic_fetch_add, atomic_fetch_sub): Change first parameter to be
60 atomic instead of __atomic_base, and use __atomic_diff_t for scalar
61 parameters.
62 (atomic_fetch_and_explicit, atomic_fetch_or_explicit)
63 (atomic_fetch_xor_explicit, atomic_fetch_and, atomic_fetch_or)
64 (atomic_fetch_xor): Use __atomic_val_t for scalar parameters.
65 (atomic_fetch_add_explicit, atomic_fetch_sub_explicit)
66 (atomic_fetch_add, atomic_fetch_sub): Remove overloads for atomic
67 address types.
68 * testsuite/29_atomics/atomic/60695.cc: Adjust dg-error lineno.
69 * testsuite/29_atomics/atomic/69769.cc: New test.
70 * testsuite/29_atomics/atomic/nonmembers.cc: New test.
71 * testsuite/29_atomics/atomic/operators/pointer_partial_void.cc:
72 Disable test for C++17 and later.
73 * testsuite/29_atomics/atomic/requirements/typedefs.cc: New test.
74 * testsuite/29_atomics/atomic_integral/nonmembers.cc: New test.
75 * testsuite/29_atomics/atomic_integral/requirements/typedefs.cc: New
76 test.
77
78 2018-05-23 Jonathan Wakely <jwakely@redhat.com>
79
80 * include/bits/fs_path.h (path::__is_encoded_char): Change from class
81 template to alias template.
82 (path::__value_type_is_char): Use remove_const_t.
83 (path:_S_string_from_iter): New helper function.
84 (path::_S_convert(InputIter, __null_terminated))
85 (path::_S_convert_loc(InputIter, __null_terminated, const locale&)):
86 Use _S_string_from_iter.
87 (path::string<_CharT, _Allocator>(const _Allocator&)): Allow sharing
88 rep for COW strings.
89 * include/experimental/bits/fs_path.h (path::__is_encoded_char):
90 Change from class template to alias template.
91 (path::__value_type_is_char): Use remove_const.
92 (path:_S_string_from_iter): New helper function.
93 (path::_S_convert(InputIter, __null_terminated))
94 (path::_S_convert_loc(InputIter, __null_terminated, const locale&)):
95 Use _S_string_from_iter.
96 * testsuite/27_io/filesystem/path/append/source.cc: Test appending
97 wide strings.
98 * testsuite/27_io/filesystem/path/concat/strings.cc: Check for exact
99 string equality, not path equivalence.
100 * testsuite/27_io/filesystem/path/construct/format.cc: Check
101 construction from std::string and std::wstring and input iterators.
102 * testsuite/27_io/filesystem/path/construct/locale.cc: Check
103 construction from iterators.
104 * testsuite/experimental/filesystem/path/concat/strings.cc: Check for
105 exact string equality, not path equivalence.
106 * testsuite/experimental/filesystem/path/construct/locale.cc: Check
107 construction from iterators.
108
109 * include/bits/fs_path.h (path::_M_type): Change default member
110 initializer to _Filename.
111 (path::begin): Create past-the-end iterator for empty path.
112 * src/filesystem/std-path.cc (path::remove_filename()): Remove
113 debugging check.
114 (path::has_relative_path()): Return false for empty filenames.
115 (path::_M_split_cmpts): Set _M_type to _Filename for empty paths.
116 Fix offset of empty final component.
117 * testsuite/27_io/filesystem/path/itr/components.cc: New.
118 * testsuite/27_io/filesystem/path/itr/traversal.cc: Add new inputs.
119
120 2018-05-21 Jonathan Wakely <jwakely@redhat.com>
121
122 Add support for opening file streams from wide character strings.
123 * config/io/basic_file_stdio.cc [_GLIBCXX_HAVE__WFOPEN]
124 (__basic_file<char>::open(const wchar_t*, ios_base::openmode)):
125 Define new overload.
126 * config/io/basic_file_stdio.h [_GLIBCXX_HAVE__WFOPEN]
127 (__basic_file<char>::open(const wchar_t*, ios_base::openmode)):
128 Declare new overload.
129 * configure.ac: Check for _wfopen.
130 * crossconfig.m4: Likewise.
131 * configure: Regenerate.
132 * config.h.in: Regenerate.
133 * include/bits/fstream.tcc [_GLIBCXX_HAVE__WFOPEN]
134 (basic_filebuf<C,T>::open(const wchar_t*, ios_base::openmode)):
135 Define new overload.
136 * include/std/fstream [_GLIBCXX_HAVE__WFOPEN]
137 (basic_filebuf<C,T>::open(const wchar_t*, ios_base::openmode)):
138 Declare new overload.
139 [_GLIBCXX_HAVE__WFOPEN]
140 (basic_ifstream<C,T>::basic_ifstream(const wchar_t*, openmode))
141 (basic_ifstream<C,T>::basic_open(const wchar_t*, openmode))
142 (basic_ofstream<C,T>::basic_ifstream(const wchar_t*, openmode))
143 (basic_ofstream<C,T>::basic_open(const wchar_t*, openmode))
144 (basic_fstream<C,T>::basic_ifstream(const wchar_t*, openmode))
145 (basic_fstream<C,T>::basic_open(const wchar_t*, openmode)): Define
146 new overloads.
147 * testsuite/27_io/basic_filebuf/open/wchar_t/1.cc: New.
148 * testsuite/27_io/basic_ifstream/cons/wchar_t/1.cc: New.
149 * testsuite/27_io/basic_ifstream/open/wchar_t/1.cc: New.
150 * testsuite/27_io/basic_ofstream/cons/wchar_t/1.cc: New.
151 * testsuite/27_io/basic_ofstream/open/wchar_t/1.cc: New.
152 * testsuite/27_io/basic_fstream/cons/wchar_t/1.cc: New.
153 * testsuite/27_io/basic_fstream/open/wchar_t/1.cc: New.
154
155 2018-05-21 François Dumont <fdumont@gcc.gnu.org>
156
157 PR libstdc++/85845
158 * include/bits/stl_tree.h
159 (_Rb_tree_impl(_Rb_tree_impl&&, _Node_allocator&&)): Fix noexcept
160 qualification.
161
162 2018-05-21 Jonathan Wakely <jwakely@redhat.com>
163
164 * src/filesystem/std-ops.cc (absolute): Report an error for empty
165 paths.
166 (weakly_canonical(const path&)): Do not call canonical on empty path.
167 (weakly_canonical(const path&, error_code&)): Likewise.
168 * testsuite/27_io/filesystem/operations/absolute.cc: Check for errors.
169
170 PR libstdc++/85818
171 * testsuite/experimental/filesystem/path/preferred_separator.cc: Add
172 dg-require-filesystem-ts.
173
174 PR libstdc++/85843
175 * src/c++11/cow-stdexcept.cc (logic_error, runtime_error): Explicitly
176 initialize base class to avoid warnings.
177
178 2018-05-19 Jonathan Wakely <jwakely@redhat.com>
179
180 * src/c++11/codecvt.cc (__codecvt_utf8_base<wchar_t>::do_in)
181 [__SIZEOF_WCHAR_T__==2 && __BYTE_ORDER__!=__ORDER_BIG_ENDIAN__]: Set
182 little_endian element in bitmask.
183 * testsuite/22_locale/codecvt/codecvt_utf8/69703.cc: Run all tests.
184 * testsuite/22_locale/codecvt/codecvt_utf8/wchar_t/1.cc: New.
185
186 2018-05-18 François Dumont <fdumont@gcc.gnu.org>
187
188 * include/bits/stl_tree.h
189 (_Rb_tree_impl(_Rb_tree_impl&&, _Node_allocator&&)): New.
190 (_Rb_tree(_Rb_tree&&, _Node_allocator&&, true_type)): New, use latter.
191 (_Rb_tree(_Rb_tree&&, _Node_allocator&&, false_type)): New.
192 (_Rb_tree(_Rb_tree&&, _Node_allocator&&)): Adapt, use latters.
193 * include/debug/map.h
194 (map(map&&, const_allocator_type&)): Add noexcept qualitication.
195 * include/debug/multimap.h
196 (multimap(multimap&&, const_allocator_type&)): Likewise.
197 * include/debug/set.h
198 (set(set&&, const_allocator_type&)): Likewise.
199 * include/debug/multiset.h
200 (multiset(multiset&&, const_allocator_type&)): Likewise.
201 * testsuite/23_containers/map/cons/noexcept_default_construct.cc:
202 Add checks.
203 * testsuite/23_containers/map/cons/noexcept_move_construct.cc:
204 Add checks.
205 * testsuite/23_containers/multimap/cons/noexcept_default_construct.cc:
206 Add checks.
207 * testsuite/23_containers/multimap/cons/noexcept_move_construct.cc:
208 Add checks.
209 * testsuite/23_containers/multiset/cons/noexcept_default_construct.cc:
210 Add checks.
211 * testsuite/23_containers/multiset/cons/noexcept_move_construct.cc:
212 Add checks.
213 * testsuite/23_containers/set/cons/noexcept_default_construct.cc:
214 Add checks.
215 * testsuite/23_containers/set/cons/noexcept_move_construct.cc:
216 Add checks.
217
218 2018-05-18 Jason Merrill <jason@redhat.com>
219
220 * include/bits/stl_deque.h (_Deque_iterator): Constrain constructor
221 for conversion to const_iterator. Add defaulted copy ops.
222 * libsupc++/new (bad_alloc): Add defaulted copy ops.
223 * libsupc++/exception.h (exception): Add defaulted copy ops.
224 * include/std/system_error (system_error): Add defaulted copy ops.
225 * include/std/stdexcept (domain_error, invalid_argument)
226 (length_error, out_of_range, range_error, overflow_error)
227 (underflow_error): Add defaulted copy ops.
228 * include/bits/stl_iterator.h (reverse_iterator): Add defaulted
229 copy assignment.
230 * include/bits/allocator.h (allocator): Add defaulted copy assignment.
231 * include/ext/throw_allocator.h (condition_base): Add defaulted
232 default and copy ctor and copy assignment.
233
234 2018-05-18 Jonathan Wakely <jwakely@redhat.com>
235
236 PR libstdc++/85098
237 * include/bits/regex.h [__cplusplus < 201703L] (basic_regex::icase)
238 (basic_regex::nosubs, basic_regex::optimize, basic_regex::collate)
239 (basic_regex::ECMAScript, basic_regex::basic, basic_regex::extended)
240 (basic_regex::awk, basic_regex::grep, basic_regex::egrep): Add
241 definitions.
242 * include/bits/regex_automaton.h (_NFA::_M_insert_state): Adjust
243 whitespace.
244 * include/bits/regex_compiler.tcc (__INSERT_REGEX_MATCHER): Add
245 braces around body of do-while.
246 * testsuite/28_regex/basic_regex/85098.cc: New
247
248 2018-05-17 Jonathan Wakely <jwakely@redhat.com>
249
250 PR libstdc++/85818
251 * src/filesystem/path.cc (path::preferred_separator): Add used
252 attribute.
253 * testsuite/experimental/filesystem/path/preferred_separator.cc: New.
254
255 PR libstdc++/85812
256 * libsupc++/cxxabi_init_exception.h (__cxa_free_exception): Declare.
257 * libsupc++/exception_ptr.h (make_exception_ptr) [__cpp_exceptions]:
258 Refactor to separate non-throwing and throwing implementations.
259 [__cpp_rtti && !_GLIBCXX_HAVE_CDTOR_CALLABI]: Deallocate the memory
260 if constructing the object throws.
261
262 2018-05-15 Jonathan Wakely <jwakely@redhat.com>
263
264 PR libstdc++/85749
265 * include/bits/random.h (__detail::__is_seed_seq): New SFINAE helper.
266 (linear_congruential_engine, mersenne_twister_engine)
267 (subtract_with_carry_engine, discard_block_engine)
268 (independent_bits_engine, shuffle_order_engine): Use __is_seed_seq to
269 constrain function templates taking seed sequences.
270 * include/bits/random.tcc (linear_congruential_engine::seed(_Sseq&))
271 (mersenne_twister_engine::seed(_Sseq&))
272 (subtract_with_carry_engine::seed(_Sseq&)): Change return types to
273 match declarations.
274 * include/ext/random (simd_fast_mersenne_twister_engine): Use
275 __is_seed_seq to constrain function templates taking seed sequences.
276 * include/ext/random.tcc (simd_fast_mersenne_twister_engine::seed):
277 Change return type to match declaration.
278 * testsuite/26_numerics/random/discard_block_engine/cons/seed_seq2.cc:
279 New.
280 * testsuite/26_numerics/random/independent_bits_engine/cons/
281 seed_seq2.cc: New.
282 * testsuite/26_numerics/random/linear_congruential_engine/cons/
283 seed_seq2.cc: New.
284 * testsuite/26_numerics/random/mersenne_twister_engine/cons/
285 seed_seq2.cc: New.
286 * testsuite/26_numerics/random/pr60037-neg.cc: Adjust dg-error lineno.
287 * testsuite/26_numerics/random/shuffle_order_engine/cons/seed_seq2.cc:
288 New.
289 * testsuite/26_numerics/random/subtract_with_carry_engine/cons/
290 seed_seq2.cc: New.
291 * testsuite/ext/random/simd_fast_mersenne_twister_engine/cons/
292 seed_seq2.cc: New.
293
294 PR libstdc++/83891
295 * include/bits/fs_path.h (path::is_absolute()): Use same definition
296 for all operating systems.
297 * include/experimental/bits/fs_path.h (path::is_absolute()): Likewise.
298 * testsuite/27_io/filesystem/path/query/is_absolute.cc: New.
299 * testsuite/27_io/filesystem/path/query/is_relative.cc: Fix comment.
300 * testsuite/experimental/filesystem/path/query/is_absolute.cc: New.
301
302 * testsuite/27_io/filesystem/path/decompose/extension.cc: Remove
303 unused <vector> header.
304 * testsuite/27_io/filesystem/path/query/empty.cc: Likewise.
305 * testsuite/27_io/filesystem/path/query/has_extension.cc: Likewise.
306 * testsuite/27_io/filesystem/path/query/has_filename.cc: Likewise.
307 * testsuite/27_io/filesystem/path/query/has_parent_path.cc: Likewise.
308 * testsuite/27_io/filesystem/path/query/has_relative_path.cc:
309 Likewise.
310 * testsuite/27_io/filesystem/path/query/has_root_directory.cc:
311 Likewise.
312 * testsuite/27_io/filesystem/path/query/has_root_name.cc: Likewise.
313 * testsuite/27_io/filesystem/path/query/has_root_path.cc: Likewise.
314 * testsuite/27_io/filesystem/path/query/has_stem.cc: Likewise.
315 * testsuite/27_io/filesystem/path/query/is_relative.cc: Likewise.
316 * testsuite/experimental/filesystem/path/decompose/extension.cc:
317 Likewise.
318 * testsuite/experimental/filesystem/path/query/empty.cc: Likewise.
319 * testsuite/experimental/filesystem/path/query/has_extension.cc:
320 Likewise.
321 * testsuite/experimental/filesystem/path/query/has_filename.cc:
322 Likewise.
323 * testsuite/experimental/filesystem/path/query/has_parent_path.cc:
324 Likewise.
325 * testsuite/experimental/filesystem/path/query/has_relative_path.cc:
326 Likewise.
327 * testsuite/experimental/filesystem/path/query/has_root_directory.cc:
328 Likewise.
329 * testsuite/experimental/filesystem/path/query/has_root_name.cc:
330 Likewise.
331 * testsuite/experimental/filesystem/path/query/has_root_path.cc:
332 Likewise.
333 * testsuite/experimental/filesystem/path/query/has_stem.cc: Likewise.
334 * testsuite/experimental/filesystem/path/query/is_relative.cc:
335 Likewise.
336
337 PR libstdc++/84159
338 * include/bits/fs_path.h (path::operator/=, path::append): Construct
339 temporary path before calling _M_append.
340 (path::_M_append): Change parameter to path and implement C++17
341 semantics.
342 * testsuite/27_io/filesystem/path/append/path.cc: Add helper function
343 and more examples from the standard.
344 * testsuite/27_io/filesystem/path/append/source.cc: New.
345 * testsuite/27_io/filesystem/path/decompose/filename.cc: Add comment.
346 * testsuite/27_io/filesystem/path/nonmember/append.cc: New.
347
348 * include/std/variant (__gen_vtable_impl::__visit_invoke): Qualify
349 __invoke to prevent ADL.
350
351 2018-05-14 Jonathan Wakely <jwakely@redhat.com>
352
353 PR libstdc++/81256
354 * include/bits/fstream.tcc (basic_filebuf::close): Do not swallow
355 exceptions from _M_terminate_output().
356 * include/std/fstream (basic_filebuf::~basic_filebuf): Swallow any
357 exceptions from close().
358 * testsuite/27_io/basic_filebuf/close/81256.cc: New.
359
360 * include/bits/valarray_array.h (__valarray_get_memory): Remove.
361 (__valarray_get_storage): Call operator new directly. Remove ignored
362 top-level restrict qualifier and add malloc attribute instead.
363 (_Array<_Tp>::_Array(size_t)): Remove unused constructor.
364
365 PR libstdc++/67554
366 * include/bits/valarray_array.h (_Array_copy_ctor<_Tp, true>)
367 (_Array_copier<_Tp, true>): Do not pass null pointers to memcpy.
368
369 PR libstdc++/82966
370 * include/bits/node_handle.h (_Node_handle_common::_M_swap): Use value
371 instead of type.
372 * testsuite/23_containers/set/modifiers/node_swap.cc: New.
373
374 2018-05-13 Ville Voutilainen <ville.voutilainen@gmail.com>
375
376 PR libstdc++/80165
377 * testsuite/20_util/variant/80165.cc: New.
378
379 2018-05-10 Jonathan Wakely <jwakely@redhat.com>
380
381 * doc/xml/faq.xml: Link to C++17 status. Add note to outdated answer.
382 * doc/xml/manual/debug_mode.xml: Add array and forward_list to list
383 of C++11 containers with Debug Mode support.
384 * doc/xml/manual/using.xml: Document Dual ABI for ios_base::failure.
385 * doc/html/*: Regenerate.
386
387 2018-05-10 Jason Merrill <jason@redhat.com>
388
389 * include/bits/regex_compiler.h (_S_cache_size): Change from
390 function to variable.
391
392 2018-05-10 Edward Smith-Rowland <3dw4rd@verizon.net>
393
394 PR libstdc++/83140 - assoc_legendre returns negated value when m is odd
395 * include/tr1/legendre_function.tcc (__assoc_legendre_p): Add __phase
396 argument defaulted to +1. Doxy comments on same.
397 * testsuite/special_functions/02_assoc_legendre/
398 check_value.cc: Regen.
399 * testsuite/tr1/5_numerical_facilities/special_functions/
400 02_assoc_legendre/check_value.cc: Regen.
401
402 2018-05-10 Jonathan Wakely <jwakely@redhat.com>
403
404 PR libstdc++/85729
405 * include/bits/c++config.h (__replacement_assert): Add linkage
406 specification.
407 * include/bits/std_abs.h: Add comment to closing brace of block.
408 * include/c_global/cstddef: Add linkage specification.
409 * include/c_global/cstring: Likewise.
410 * include/c_global/cwchar: Likewise.
411
412 2018-05-09 François Dumont <fdumont@gcc.gnu.org>
413
414 * include/debug/safe_iterator.h (_Safe_iterator<>::_M_constant()):
415 Rename in...
416 (_Safe_iterator<>::_S_constant()): ...that.
417 * include/debug/safe_local_iterator.h
418 (_Safe_local_iterator<>::_M_constant()): Rename in...
419 (_Safe_local_iterator<>::_S_constant()): ...that.
420 * include/debug/formatter.h: Remove bits/cpp_type_traits.h include.
421 (_Iterator_state::__rbegin): New.
422 (_Iterator_state::__rmiddle): New.
423 (_Iterator_state::__rend): New.
424 (_Parameter::_Parameter(const _Safe_iterator<>&, const char*,
425 _Is_iterator)): Use _Safe_iterator<>::_S_constant. Grab normal underlying
426 iterator type.
427 (_Parameter::_Parameter(const _Safe_local_iterator<>&, const char*,
428 _Is_iterator)): Likewise.
429 (_Parameter::_S_reverse_state(_Iterator_state)): New.
430 (_Parameter(__gnu_cxx::__normal_iterator<> const&, const char*,
431 _Is_iterator)): New.
432 (_Parameter(std::reverse_iterator<> const&, const char*,
433 _Is_iterator)): New.
434 (_Parameter(std::reverse_iterator<_Safe_iterator<>> const&,
435 const char*, _Is_iterator)): New.
436 (_Parameter(std::move_iterator<> const&, const char*, _Is_iterator):
437 New.
438 (_Parameter(std::move_iterator<_Safe_iterator<>> const&, const char*,
439 _Is_iterator)): New.
440 * testsuite/24_iterators/move_iterator/debug_neg.cc: New.
441 * testsuite/24_iterators/normal_iterator/debug_neg.cc: New.
442 * testsuite/24_iterators/reverse_iterator/debug_neg.cc: New.
443
444 2018-05-09 Jonathan Wakely <jwakely@redhat.com>
445
446 * include/bits/std_function.h (_Base_manager::_M_get_pointer):
447 Use constexpr if in C++17 mode.
448 (_Base_manager::_M_clone(_Any_data&, const _Any_data&, true_type)):
449 Copy from const object.
450 * testsuite/20_util/function/cons/non_copyconstructible.cc: New.
451
452 2018-05-08 François Dumont <fdumont@gcc.gnu.org>
453
454 * src/c++11/debug.cc [_GLIBCXX_HAVE_EXECINFO_H]: Include execinfo.h.
455 [_GLIBCXX_HAVE_EXECINFO_H](_Error_formatter::_M_error): Render
456 backtrace.
457
458 * include/debug/macros.h (__glibcxx_check_valid_range_at): New.
459 * include/debug/functions.h (__check_valid_range): Use latter.
460 * include/debug/macros.h (__glibcxx_check_valid_constructor_range): New,
461 use latter.
462 * include/debug/deque
463 (deque::deque<_Iter>(_Iter, _Iter, const _Alloc&)): Use latter.
464 * include/debug/forward_list
465 (forward_list::forward_list<_Iter>(_Iter, _Iter, const _Alloc&)):
466 Likewise.
467 * include/debug/list
468 (list::list<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
469 * include/debug/list
470 (list::list<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
471 * include/debug/map.h
472 (map::map<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
473 (map::map<_Iter>(_Iter, _Iter, const _Compare&, const _Alloc&)):
474 Likewise.
475 * include/debug/multimap.h
476 (multimap::multimap<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
477 (multimap::multimap<_Iter>(_Iter, _Iter, const _Compare&,
478 const _Alloc&)): Likewise.
479 * include/debug/set.h
480 (set::set<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
481 (set::set<_Iter>(_Iter, _Iter, const _Compare&, const _Alloc&)):
482 Likewise.
483 * include/debug/multiset.h
484 (multiset::multiset<_Iter>(_Iter, _Iter, const _Alloc&)): Likewise.
485 (multiset::multiset<_Iter>(_Iter, _Iter, const _Compare&,
486 const _Alloc&)): Likewise.
487 * include/debug/string
488 (basic_string::basic_string<_Iter>(_Iter, _Iter, const _Alloc&)):
489 Likewise.
490 * include/debug/unordered_map
491 (unordered_map::unordered_map<_Iter>(_Iter, _Iter, const _Alloc&)):
492 Likewise.
493 (unordered_multimap::unordered_multimap<_Iter>(_Iter, _Iter,
494 const _Alloc&)): Likewise.
495 * include/debug/unordered_set
496 (unordered_set::unordered_set<_Iter>(_Iter, _Iter, const _Alloc&)):
497 Likewise.
498 (unordered_multiset::unordered_multiset<_Iter>(_Iter, _Iter,
499 const _Alloc&)): Likewise.
500 * include/debug/vector
501 (vector::vector<_Iter>(_Iter, _Iter, const _Alloc&)): Use latter.
502
503 * include/debug/formatter.h (_Error_formatter::_M_function): New.
504 (_Error_formatter(const char*, unsigned int)): Adapt.
505 (_Error_formatter::_M_at): Rename in...
506 (_Error_formatter::_S_at): ...that and adapt.
507 * include/debug/macros.h (_GLIBCXX_DEBUG_VERIFY_AT_F): New.
508 (_GLIBCXX_DEBUG_VERIFY_AT, _GLIBCXX_DEBUG_VERIFY): Adapt.
509 * src/c++11/debug.cc (_Error_formatter::_M_error): Render _M_function
510 when available.
511
512 2018-05-08 Jonathan Wakely <jwakely@redhat.com>
513
514 * include/bits/regex_automaton.h (_NFA_base::_M_paren_stack, _NFA):
515 Use normal std::vector even in Debug Mode.
516
517 PR libstdc++/85672
518 * include/Makefile.am [!ENABLE_FLOAT128]: Change c++config.h entry
519 to #undef _GLIBCXX_USE_FLOAT128 instead of defining it to zero.
520 * include/Makefile.in: Regenerate.
521 * include/bits/c++config (_GLIBCXX_USE_FLOAT128): Move definition
522 within conditional block.
523
524 2018-05-07 Jonathan Wakely <jwakely@redhat.com>
525
526 * doc/xml/manual/using.xml (table.cmd_options): Document that the
527 C++17 Filesystem implementation also needs -lstdc++fs.
528
529 PR libstdc++/85671
530 * include/bits/fs_path.h (operator/): Permit copy elision.
531 * include/experimental/bits/fs_path.h (operator/): Likewise.
532
533 2018-05-07 Edward Smith-Rowland <3dw4rd@verizon.net>
534
535 Moar PR libstdc++/80506
536 * include/bits/random.tcc (gamma_distribution::__generate_impl()):
537 Fix magic number used in loop condition.
538
539 2018-05-04 Jonathan Wakely <jwakely@redhat.com>
540
541 PR libstdc++/85642 fix is_nothrow_default_constructible<optional<T>>
542 * include/std/optional (_Optional_payload): Add noexcept to default
543 constructor. Re-indent.
544 (_Optional_payload<_Tp, true, true, true>): Likewise. Add noexcept to
545 constructor for copying disengaged payloads.
546 (_Optional_payload<_Tp, true, false, true>): Likewise.
547 (_Optional_payload<_Tp, true, true, false>): Likewise.
548 (_Optional_payload<_Tp, true, false, false>): Likewise.
549 * testsuite/20_util/optional/cons/85642.cc: New.
550 * testsuite/20_util/optional/cons/value_neg.cc: Adjust dg-error lines.
551
552 2018-05-03 Jonathan Wakely <jwakely@redhat.com>
553
554 PR libstdc++/82644
555 * include/tr1/cmath [__STRICT_ANSI__] (hypergf, hypergl, hyperg): Use
556 inline definitions instead of using-declarations.
557 [__STRICT_ANSI__] (conf_hypergf, conf_hypergl, conf_hyperg): Likewise.
558 * testsuite/tr1/5_numerical_facilities/special_functions/
559 07_conf_hyperg/compile_cxx17.cc: New.
560 * testsuite/tr1/5_numerical_facilities/special_functions/
561 17_hyperg/compile_cxx17.cc: New.
562
563 PR libstdc++/84769
564 * include/std/variant (visit): Qualify std::get call.
565
566 PR libstdc++/85632 use uintmax_t for arithmetic
567 * src/filesystem/ops.cc (experimental::filesystem::space): Perform
568 arithmetic in result type.
569 * src/filesystem/std-ops.cc (filesystem::space): Likewise.
570 * testsuite/27_io/filesystem/operations/space.cc: Check total capacity
571 is greater than free space.
572 * testsuite/experimental/filesystem/operations/space.cc: New.
573
574 * testsuite/20_util/remove_cvref/requirements/alias_decl.cc: New.
575 * testsuite/20_util/remove_cvref/requirements/explicit_instantiation.cc:
576 New.
577 * testsuite/20_util/remove_cvref/value.cc: New.
578 * testsuite/20_util/remove_cvref/value_ext.cc: New.
579
580 PR libstdc++/84087 LWG DR 2268 basic_string default arguments
581 * include/bits/basic_string.h [_GLIBCXX_USE_CXX11_ABI=1]
582 (append(const basic_string&, size_type, size_type)
583 (assign(const basic_string&, size_type, size_type)
584 (insert(size_type, const basic_string&, size_type, size_type)
585 (replace(size_type,size_type,const basic_string&,size_type,size_type)
586 (compare(size_type,size_type,constbasic_string&,size_type,size_type)):
587 Add default arguments (LWG 2268).
588 [_GLIBCXX_USE_CXX11_ABI=0]
589 (append(const basic_string&, size_type, size_type)
590 (assign(const basic_string&, size_type, size_type)
591 (insert(size_type, const basic_string&, size_type, size_type)
592 (replace(size_type,size_type,const basic_string&,size_type,size_type)
593 (compare(size_type,size_type,constbasic_string&,size_type,size_type)):
594 Likewise.
595 * testsuite/21_strings/basic_string/dr2268.cc: New test.
596
597 PR libstdc++/84535
598 * include/std/thread (thread::__not_same): New SFINAE helper.
599 (thread::thread(_Callable&&, _Args&&...)): Add SFINAE constraint that
600 first argument is not a std::thread. Add static assertion to check
601 INVOKE expression is valid.
602 (thread::thread(thread&), thread::thread(const thread&&)): Remove.
603 (thread::_Invoke::_M_invoke, thread::_Invoke::operator()): Use
604 __invoke_result for return types and remove exception specifications.
605 * testsuite/30_threads/thread/cons/84535.cc: New.
606
607 * include/std/future (__async_result_of): Use __invoke_result instead
608 of result_of.
609
610 * include/std/any (any_cast): Use __remove_cvref_t.
611 * include/std/tuple (__make_tuple): Likewise.
612 * include/std/type_traits (__remove_cvref_t): Define.
613 (__result_of_memobj, __result_of_memfun): Use __remove_cvref_t.
614 [__cplusplus > 201703L] (remove_cvref, remove_cvref_t): Define.
615 * include/std/variant (__erased_hash): Use __remove_cvref_t.
616
617 2018-05-02 François Dumont <fdumont@gcc.gnu.org>
618
619 * include/bits/deque.tcc (deque<>::_M_assign_aux): Cast to void to
620 ensure overloaded comma not used.
621 * include/bits/list.tcc (list<>::_M_assign_dispatch): Likewise.
622 * include/bits/vector.tcc (vector<>::_M_assign_aux): Likewise.
623 * include/bits/stl_bvector.h (vector<bool>::_M_assign_aux): Likewise.
624 * testsuite/23_containers/deque/modifiers/assign/1.cc: New.
625 * testsuite/23_containers/list/modifiers/assign/1.cc: New.
626 * testsuite/23_containers/vector/bool/modifiers/assign/1.cc: New.
627 * testsuite/23_containers/vector/modifiers/assign/1.cc: New.
628
629 2018-05-02 Jonathan Wakely <jwakely@redhat.com>
630
631 PR libstdc++/68197
632 * include/bits/ios_base.h (ios_base::iword, ios_base::pword): Cast
633 indices to unsigned.
634 * src/c++11/ios.cc (ios_base::_M_grow_words): Treat negative indices
635 as failure. Refactor error handling.
636 * testsuite/27_io/ios_base/storage/68197.cc: New.
637
638 PR libstdc++/57997
639 PR libstdc++/83860
640 * include/bits/gslice_array.h (gslice_array): Define default
641 constructor as deleted, as per C++11 standard.
642 * include/bits/mask_array.h (mask_array): Likewise.
643 * include/bits/slice_array.h (slice_array): Likewise.
644 * include/bits/valarray_after.h (_GBase, _GClos, _IBase, _IClos): Move
645 to namespace __detail.
646 (_GBase::_M_expr, _IBase::_M_expr): Use _ValArrayRef for type of data
647 members.
648 * include/bits/valarray_before.h (_ValArrayRef): New helper for type
649 of data members in closure objects.
650 (_FunBase, _ValFunClos, _RefFunClos, _UnBase, _UnClos, _BinBase)
651 (_BinBase2, _BinBase1, _BinClos, _SBase, _SClos): Move to namespace
652 __detail.
653 (_FunBase::_M_expr, _UnBase::_M_expr, _BinBase::_M_expr1)
654 (_BinBase::_M_expr2, _BinBase2::_M_expr1, _BinBase1::_M_expr2)
655 (_SBase::_M_expr): Use _ValArrayRef for type of data members.
656 * include/std/valarray (_UnClos, _BinClos, _SClos, _GClos, _IClos)
657 (_ValFunClos, _RefFunClos): Move to namespace __detail and add
658 using-declarations to namespace std.
659 * testsuite/26_numerics/valarray/83860.cc: New.
660
661 * testsuite/backward/strstream_move.cc: Remove duplicate function
662 call.
663
664 PR libstdc++/69608
665 * include/backward/strstream (strstreambuf): Define move constructor
666 and move assignment operator.
667 (istrstream, ostrstream, strstream): Likewise.
668 * testsuite/backward/strstream_move.cc: New.
669
670 2018-05-01 Tulio Magno Quites Machado Filho <tuliom@linux.vnet.ibm.com>
671
672 PR libstdc++/84654
673 * acinclude.m4: Set ENABLE_FLOAT128 instead of _GLIBCXX_USE_FLOAT128.
674 * config.h.in: Remove references to _GLIBCXX_USE_FLOAT128.
675 * configure: Regenerate.
676 * include/Makefile.am: Replace the value of _GLIBCXX_USE_FLOAT128
677 based on ENABLE_FLOAT128.
678 * include/Makefile.in: Regenerate.
679 * include/bits/c++config: Define _GLIBCXX_USE_FLOAT128.
680 [!defined(__FLOAT128__) && !defined(__SIZEOF_FLOAT128__)]: Undefine
681 _GLIBCXX_USE_FLOAT128.
682
683 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
684
685 * configure: Regenerated.
686
687 2018-04-19 Jakub Jelinek <jakub@redhat.com>
688
689 * configure: Regenerated.
690
691 2018-04-18 Jonathan Wakely <jwakely@redhat.com>
692 Jakub Jelinek <jakub@redhat.com>
693
694 PR libstdc++/85442
695 * src/c++11/Makefile.am: Don't generate debuginfo again for
696 cxx11-ios_failure-lt.s and cxx11-ios_failure.s files.
697 * src/c++11/Makefile.in: Regenerate.
698
699 2018-04-18 Jonathan Wakely <jwakely@redhat.com>
700
701 PR libstdc++/84442
702 * testsuite/30_threads/thread/cons/terminate.cc
703 [!_GLIBCXX_USE_C99_STDLIB] : Use _exit or std::exit instead of _Exit.
704
705 2018-04-18 David Malcolm <dmalcolm@redhat.com>
706
707 PR jit/85384
708 * configure: Regenerate.
709
710 2018-04-16 Jonathan Wakely <jwakely@redhat.com>
711
712 * testsuite/experimental/filesystem/file_status/1.cc: Add
713 -DUSE_FILESYSTEM_TS to dg-options.
714 * testsuite/experimental/filesystem/iterators/directory_iterator.cc:
715 Likewise.
716 * testsuite/experimental/filesystem/iterators/pop.cc: Likewise.
717 * testsuite/experimental/filesystem/iterators/
718 recursive_directory_iterator.cc: Likewise.
719 * testsuite/experimental/filesystem/operations/absolute.cc: Likewise.
720 * testsuite/experimental/filesystem/operations/canonical.cc: Likewise.
721 * testsuite/experimental/filesystem/operations/copy.cc: Likewise.
722 * testsuite/experimental/filesystem/operations/copy_file.cc: Likewise.
723 * testsuite/experimental/filesystem/operations/create_directories.cc:
724 Likewise.
725 * testsuite/experimental/filesystem/operations/create_directory.cc:
726 Likewise.
727 * testsuite/experimental/filesystem/operations/create_symlink.cc:
728 Likewise.
729 * testsuite/experimental/filesystem/operations/current_path.cc:
730 Likewise.
731 * testsuite/experimental/filesystem/operations/equivalent.cc: Likewise.
732 * testsuite/experimental/filesystem/operations/exists.cc: Likewise.
733 * testsuite/experimental/filesystem/operations/file_size.cc: Likewise.
734 * testsuite/experimental/filesystem/operations/is_empty.cc: Likewise.
735 * testsuite/experimental/filesystem/operations/last_write_time.cc:
736 Likewise.
737 * testsuite/experimental/filesystem/operations/permissions.cc:
738 Likewise.
739 * testsuite/experimental/filesystem/operations/read_symlink.cc:
740 Likewise.
741 * testsuite/experimental/filesystem/operations/remove.cc: Likewise.
742 * testsuite/experimental/filesystem/operations/remove_all.cc: Likewise.
743 * testsuite/experimental/filesystem/operations/status.cc: Likewise.
744 * testsuite/experimental/filesystem/operations/temp_directory_path.cc:
745 Likewise.
746 * testsuite/experimental/filesystem/path/append/path.cc: Likewise.
747 * testsuite/experimental/filesystem/path/assign/assign.cc: Likewise.
748 * testsuite/experimental/filesystem/path/assign/copy.cc: Likewise.
749 * testsuite/experimental/filesystem/path/compare/compare.cc: Likewise.
750 * testsuite/experimental/filesystem/path/compare/path.cc: Likewise.
751 * testsuite/experimental/filesystem/path/compare/strings.cc: Likewise.
752 * testsuite/experimental/filesystem/path/concat/path.cc: Likewise.
753 * testsuite/experimental/filesystem/path/concat/strings.cc: Likewise.
754 * testsuite/experimental/filesystem/path/construct/copy.cc: Likewise.
755 * testsuite/experimental/filesystem/path/construct/default.cc:
756 Likewise.
757 * testsuite/experimental/filesystem/path/construct/locale.cc: Likewise.
758 * testsuite/experimental/filesystem/path/construct/range.cc: Likewise.
759 * testsuite/experimental/filesystem/path/construct/string_view.cc:
760 Likewise.
761 * testsuite/experimental/filesystem/path/decompose/extension.cc:
762 Likewise.
763 * testsuite/experimental/filesystem/path/decompose/filename.cc:
764 Likewise.
765 * testsuite/experimental/filesystem/path/decompose/parent_path.cc:
766 Likewise.
767 * testsuite/experimental/filesystem/path/decompose/relative_path.cc:
768 Likewise.
769 * testsuite/experimental/filesystem/path/decompose/root_directory.cc:
770 Likewise.
771 * testsuite/experimental/filesystem/path/decompose/root_name.cc:
772 Likewise.
773 * testsuite/experimental/filesystem/path/decompose/root_path.cc:
774 Likewise.
775 * testsuite/experimental/filesystem/path/decompose/stem.cc: Likewise.
776 * testsuite/experimental/filesystem/path/generic/generic_string.cc:
777 Likewise.
778 * testsuite/experimental/filesystem/path/itr/traversal.cc: Likewise.
779 * testsuite/experimental/filesystem/path/modifiers/clear.cc: Likewise.
780 * testsuite/experimental/filesystem/path/modifiers/make_preferred.cc:
781 Likewise.
782 * testsuite/experimental/filesystem/path/modifiers/remove_filename.cc:
783 Likewise.
784 * testsuite/experimental/filesystem/path/modifiers/replace_extension.cc:
785 Likewise.
786 * testsuite/experimental/filesystem/path/modifiers/replace_filename.cc:
787 Likewise.
788 * testsuite/experimental/filesystem/path/modifiers/swap.cc: Likewise.
789 * testsuite/experimental/filesystem/path/native/string.cc: Likewise.
790 * testsuite/experimental/filesystem/path/nonmember/hash_value.cc:
791 Likewise.
792 * testsuite/experimental/filesystem/path/query/empty.cc: Likewise.
793 * testsuite/experimental/filesystem/path/query/has_extension.cc:
794 Likewise.
795 * testsuite/experimental/filesystem/path/query/has_filename.cc:
796 Likewise.
797 * testsuite/experimental/filesystem/path/query/has_parent_path.cc:
798 Likewise.
799 * testsuite/experimental/filesystem/path/query/has_relative_path.cc:
800 Likewise.
801 * testsuite/experimental/filesystem/path/query/has_root_directory.cc:
802 Likewise.
803 * testsuite/experimental/filesystem/path/query/has_root_name.cc:
804 Likewise.
805 * testsuite/experimental/filesystem/path/query/has_root_path.cc:
806 Likewise.
807 * testsuite/experimental/filesystem/path/query/has_stem.cc: Likewise.
808 * testsuite/experimental/filesystem/path/query/is_relative.cc:
809 Likewise.
810
811 2018-04-13 Jonathan Wakely <jwakely@redhat.com>
812
813 * src/c++11/Makefile.am: Fix sed command.
814 * src/c++11/Makefile.in: Regenerate.
815
816 * src/c++11/Makefile.am: Rewrite sed rule to be less fragile and to
817 handle mangled names starting with double underscores on darwin.
818 * src/c++11/Makefile.in: Regenerate.
819
820 2018-04-12 Jonathan Wakely <jwakely@redhat.com>
821
822 * src/c++11/Makefile.am: Fix comment.
823 * src/c++11/Makefile.in: Regenerate.
824 * src/c++11/cxx11-ios_failure.cc: Fix comment.
825 * src/c++98/ios_failure.cc: Likewise.
826
827 * src/c++11/ios.cc: Remove redundant macro definition.
828
829 2018-04-11 Jonathan Wakely <jwakely@redhat.com>
830
831 * doc/xml/manual/abi.xml: Document header locations in recent
832 releases.
833 * doc/xml/manual/evolution.xml: Add API changes since GCC 5.
834 * doc/xml/manual/spine.xml: Update copyright years.
835 * doc/xml/manual/strings.xml: Adjust tolower example to avoid
836 undefined behaviour.
837 * doc/xml/manual/test.xml: Update outdated notes on VERIFY in tests.
838 * doc/html/*: Regenerate.
839
840 2018-04-10 Jonathan Wakely <jwakely@redhat.com>
841
842 * doc/xml/faq.xml: Update links to archived copy of SGI STL docs.
843 * doc/xml/manual/backwards_compatibility.xml: Likewise.
844 * doc/xml/manual/containers.xml: Likewise.
845 * doc/xml/manual/debug_mode.xml: Likewise.
846 * doc/xml/manual/extensions.xml: Likewise.
847 * doc/xml/manual/policy_data_structures_biblio.xml: Likewise.
848 * doc/xml/manual/using.xml: Likewise.
849 * doc/xml/manual/utilities.xml: Likewise.
850
851 PR libstdc++/85222
852 * src/c++11/Makefile.am [ENABLE_DUAL_ABI]: Add special rules for
853 cxx11-ios_failure.cc to rewrite type info for __ios_failure.
854 * src/c++11/Makefile.in: Regenerate.
855 * src/c++11/cxx11-ios_failure.cc (__ios_failure, __iosfail_type_info):
856 New types.
857 [_GLIBCXX_USE_DUAL_ABI] (__throw_ios_failure): Define here.
858 * src/c++11/ios.cc (__throw_ios_failure): Remove definition.
859 * src/c++98/ios_failure.cc (__construct_ios_failure)
860 (__destroy_ios_failure, is_ios_failure_handler): New functions.
861 [!_GLIBCXX_USE_DUAL_ABI] (__throw_ios_failure): Define here.
862 * testsuite/27_io/ios_base/failure/dual_abi.cc: New.
863 * testsuite/27_io/basic_ios/copyfmt/char/1.cc: Revert changes to
864 handler types, to always catch std::ios_base::failure.
865 * testsuite/27_io/basic_ios/exceptions/char/1.cc: Likewise.
866 * testsuite/27_io/basic_istream/extractors_arithmetic/char/
867 exceptions_failbit.cc: Likewise.
868 * testsuite/27_io/basic_istream/extractors_arithmetic/wchar_t/
869 exceptions_failbit.cc: Likewise.
870 * testsuite/27_io/basic_istream/extractors_other/char/
871 exceptions_null.cc: Likewise.
872 * testsuite/27_io/basic_istream/extractors_other/wchar_t/
873 exceptions_null.cc: Likewise.
874 * testsuite/27_io/basic_istream/sentry/char/12297.cc: Likewise.
875 * testsuite/27_io/basic_istream/sentry/wchar_t/12297.cc: Likewise.
876 * testsuite/27_io/basic_ostream/inserters_other/char/
877 exceptions_null.cc: Likewise.
878 * testsuite/27_io/basic_ostream/inserters_other/wchar_t/
879 exceptions_null.cc: Likewise.
880 * testsuite/27_io/ios_base/storage/2.cc: Likewise.
881
882 2018-04-05 Jonathan Wakely <jwakely@redhat.com>
883
884 * include/std/variant (_VARIANT_RELATION_FUNCTION_TEMPLATE): Qualify
885 __get calls to avoid ADL and avoid ambiguity due to Clang bug.
886
887 2018-04-03 Jonathan Wakely <jwakely@redhat.com>
888
889 PR libstdc++/85183
890 * include/std/variant (_Move_assign_base::operator=): Fix incorrect
891 value categories.
892 * testsuite/20_util/variant/85183.cc: New.
893
894 2018-03-26 Jonathan Wakely <jwakely@redhat.com>
895
896 * include/std/variant (__get): Qualify calls to avoid ADL.
897 (__select_index): Adjust whitespace.
898 (variant): Add using-declaration to workaround Clang bug.
899
900 2018-03-22 Jonathan Wakely <jwakely@redhat.com>
901
902 PR libstdc++/85040
903 * include/bits/stl_function.h (greater::__not_overloaded)
904 (less::__not_overloaded, greater_equal::__not_overloaded)
905 (less_equal::__not_overloaded): Fix ambiguous specializations.
906 * testsuite/20_util/function_objects/comparisons_pointer.cc: Add
907 tests for type with overloaded operators.
908
909 2018-03-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
910
911 PR libstdc++/77691
912 * testsuite/experimental/memory_resource/resource_adaptor.cc:
913 xfail execution on 32-bit Solaris/x86.
914
915 2018-03-21 Jonathan Wakely <jwakely@redhat.com>
916
917 * testsuite/20_util/function_objects/comparisons_pointer.cc: Use
918 VERIFY instead of assert.
919 * testsuite/20_util/hash/84998.cc: New test.
920 * testsuite/23_containers/vector/cons/destructible_debug_neg.cc: New
921 copy of test adjusted for Debug Mode.
922 * testsuite/23_containers/vector/cons/destructible_neg.cc: Do not run
923 test in Debug Mode.
924
925 2018-03-20 François Dumont <fdumont@gcc.gnu.org>
926
927 PR libstdc++/84998
928 * include/bits/stl_bvector.h: Fix std::hash friend declaration.
929 * include/std/bitset: Likewise.
930 * include/bits/stl_map.h (std::map<>): Fix _Rb_tree_merge_helper friend
931 declaration.
932 * include/bits/stl_multimap.h (std::multimap<>): Likewise.
933 * include/bits/stl_multiset.h (std::multiset<>): Likewise.
934 * include/bits/stl_set.h (std::set<>): Likewise.
935 * include/bits/unordered_map.h (std::unordered_map<>): Fix
936 _Hash_merge_helper friend declaration.
937 (std::unordered_multimap<>): Likewise.
938 * include/bits/unordered_set.h (std::unordered_set<>): Likewise.
939 (std::unordered_multiset<>): Likewise.
940
941 2018-03-19 Gerald Pfeifer <gerald@pfeifer.com>
942
943 * doc/xml/api.xml: www.fsf.org has moved to https. Also omit
944 trailing slash for domain level link.
945 * doc/xml/faq.xml: Ditto.
946 * doc/xml/manual/appendix_free.xml (software): Ditto.
947 * doc/xml/manual/intro.xml: Ditto.
948 * doc/xml/manual/spine.xml: Ditto.
949 * doc/xml/spine.xml: Ditto.
950
951 2018-03-19 Gerald Pfeifer <gerald@pfeifer.com>
952
953 * doc/xml/manual/documentation_hacking.xml: Adjust link to
954 docbook.org.
955
956 2018-03-17 Jonathan Wakely <jwakely@redhat.com>
957
958 * testsuite/20_util/function_objects/comparisons_pointer.cc: Adjust
959 to compile as C++98.
960
961 2018-03-14 Jonathan Wakely <jwakely@redhat.com>
962
963 PR libstdc++/78420
964 * include/bits/stl_function.h (greater<_Tp*>, less<_Tp*>)
965 (greater_equal<_Tp*>, less_equal<_Tp>*): Add partial specializations
966 to ensure total order for pointers.
967 (greater<void>, less<void>, greater_equal<void>, less_equal<void>):
968 Add operator() overloads for pointer arguments and make generic
969 overloads dispatch to new _S_cmp functions when comparisons would
970 use built-in operators for pointers.
971 * testsuite/20_util/function_objects/comparisons_pointer.cc: New.
972
973 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
974
975 PR libstdc++/84773
976 PR libstdc++/83662
977 * crossconfig.m4: Check for aligned_alloc etc. on freebsd and mingw32.
978 * configure: Regenerate.
979 * include/c_global/cstdlib [_GLIBCXX_HAVE_ALIGNED_ALLOC]
980 (aligned_alloc): Add using-declaration.
981 * testsuite/18_support/aligned_alloc/aligned_alloc.cc: New test.
982
983 2018-03-09 François Dumont <fdumont@gcc.gnu.org>
984
985 * python/libstdcxx/v6/printers.py (build_libstdcxx_dictionary):
986 Fix std::_Fwd_list_iterator and std::_Fwd_list_const_iterator printers
987 registration.
988
989 2018-03-09 Jonathan Wakely <jwakely@redhat.com>
990
991 PR libstdc++/84769
992 * include/std/variant (get<_Tp, _Types...>, get_if<_Tp, _Types...>):
993 Qualify calls to get<_Np, Types...> and get_if<_Np, _Types...>.
994
995 src/filesystem/ops.cc (create_dir): Pass error_code to is_directory.
996 src/filesystem/std-ops.cc (create_dir): Likewise.
997
998 2018-03-08 François Dumont <fdumont@gcc.gnu.org>
999
1000 * python/libstdcxx/v6/printers.py (NodeIteratorPrinter): New.
1001 (StdListIteratorPrinter): Inherit from latter.
1002 (StdFwdListIteratorPrinter): New, inherit from latter.
1003 (StdDebugIteratorPrinter.to_string): Use non-debug iterator printer
1004 when iterator has no associated container.
1005 (build_libstdcxx_dictionary): Add __gnu_cxx::_Fwd_list_iterator and
1006 __gnu_cxx::_Fwd_list_const_iterator printers. Remove __norm namespace
1007 registrations.
1008 * testsuite/libstdc++-prettyprinters/debug.cc: Adapt.
1009 * testsuite/libstdc++-prettyprinters/debug_cxx11.cc: Adapt.
1010
1011 2018-03-06 Ville Voutilainen <ville.voutilainen@gmail.com>
1012
1013 PR libstdc++/84601
1014 * include/std/optional (_Optional_payload): Split into multiple
1015 specializations that can handle different cases of trivial or
1016 non-trivial assignment operators.
1017 * testsuite/20_util/optional/84601.cc: New.
1018 * testsuite/20_util/optional/cons/value_neg.cc: Adjust.
1019
1020 2018-03-02 Jonathan Wakely <jwakely@redhat.com>
1021
1022 PR libstdc++/84671
1023 * include/bits/parse_numbers.h (_Number_help): Add partial
1024 specialization to handle digit separators. Adjust partial
1025 specialization for recursion temrination to require _Pow == 1ULL.
1026 * testsuite/20_util/duration/literals/84671.cc: New
1027
1028 2018-02-27 Ville Voutilainen <ville.voutilainen@gmail.com>
1029
1030 Implement the missing bits of LWG 2769
1031 * include/std/any (any_cast(const any&)): Add static_assert.
1032 (any_cast(any&)): Likewise.
1033 (any_cast(any&&)): Likewise, and remove the handling
1034 for copyable-but-not-movable type.
1035 * testsuite/20_util/any/misc/any_cast.cc: Adjust.
1036 * testsuite/20_util/any/misc/any_cast_neg.cc: Likewise, and
1037 add new tests.
1038
1039 2018-02-23 Jonathan Wakely <jwakely@redhat.com>
1040
1041 PR libstdc++/84532
1042 * include/std/thread (thread::__make_invoker): Construct tuple
1043 directly instead of using make_tuple.
1044 * testsuite/30_threads/async/84532.cc: New.
1045 * testsuite/30_threads/thread/84532.cc: New.
1046
1047 2018-02-20 François Dumont <fdumont@gcc.gnu.org>
1048
1049 * include/ext/aligned_buffer.h [_GLIBCXX_INLINE_VERSION]
1050 (template<> __aligned_buffer): Define as __aligned_membuf alias.
1051
1052 2018-02-19 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
1053
1054 PR target/84148
1055 * configure: Regenerate.
1056
1057 2018-02-15 Jonathan Wakely <jwakely@redhat.com>
1058
1059 PR libstdc++/81797
1060 * configure.ac (INCLUDE_DIR_NOTPARALLEL): Define.
1061 * configure: Regenerate.
1062 * include/Makefile.am (INCLUDE_DIR_NOTPARALLEL): Add .NOTPARALLEL when
1063 defined.
1064 * include/Makefile.in: Regenerate.
1065
1066 2018-01-29 Jonathan Wakely <jwakely@redhat.com>
1067
1068 PR libstdc++/83833
1069 * testsuite/26_numerics/random/chi_squared_distribution/83833.cc:
1070 Add -ffloat-store to options for m68k and ia32.
1071
1072 * doc/xml/faq.xml: Update copyright years.
1073 * doc/html/*: Regenerate.
1074
1075 PR libstdc++/83658
1076 * include/std/any (any::__do_emplace): Only set _M_manager after
1077 constructing the contained object.
1078 * testsuite/20_util/any/misc/any_cast_neg.cc: Adjust dg-error line.
1079 * testsuite/20_util/any/modifiers/83658.cc: New test.
1080
1081 2018-01-25 Jonathan Wakely <jwakely@redhat.com>
1082
1083 PR libstdc++/81076
1084 * include/c_global/cstddef (__byte_operand): Define primary template.
1085 * testsuite/18_support/byte/81076.cc: New test.
1086
1087 2018-01-19 Christophe Lyon <christophe.lyon@linaro.org>
1088
1089 * testsuite/ext/special_functions/airy_ai/check_nan.cc: Fix
1090 dg-options and dg-add-options order.
1091 * testsuite/ext/special_functions/airy_bi/check_nan.cc: Likewise.
1092 * testsuite/ext/special_functions/conf_hyperg/check_nan.cc:
1093 Likewise.
1094 * testsuite/ext/special_functions/hyperg/check_nan.cc: Likewise.
1095 * testsuite/special_functions/01_assoc_laguerre/check_nan.cc:
1096 Likewise.
1097 * testsuite/special_functions/02_assoc_legendre/check_nan.cc:
1098 Likewise.
1099 * testsuite/special_functions/03_beta/check_nan.cc: Likewise.
1100 * testsuite/special_functions/04_comp_ellint_1/check_nan.cc:
1101 Likewise.
1102 * testsuite/special_functions/05_comp_ellint_2/check_nan.cc:
1103 Likewise.
1104 * testsuite/special_functions/06_comp_ellint_3/check_nan.cc:
1105 Likewise.
1106 * testsuite/special_functions/06_comp_ellint_3/pr66689.cc:
1107 Likewise.
1108 * testsuite/special_functions/07_cyl_bessel_i/check_nan.cc:
1109 Likewise.
1110 * testsuite/special_functions/08_cyl_bessel_j/check_nan.cc:
1111 Likewise.
1112 * testsuite/special_functions/09_cyl_bessel_k/check_nan.cc:
1113 Likewise.
1114 * testsuite/special_functions/10_cyl_neumann/check_nan.cc:
1115 Likewise.
1116 * testsuite/special_functions/11_ellint_1/check_nan.cc: Likewise.
1117 * testsuite/special_functions/12_ellint_2/check_nan.cc: Likewise.
1118 * testsuite/special_functions/13_ellint_3/check_nan.cc: Likewise.
1119 * testsuite/special_functions/13_ellint_3/pr66689.cc: Likewise.
1120 * testsuite/special_functions/14_expint/check_nan.cc: Likewise.
1121 * testsuite/special_functions/15_hermite/check_nan.cc: Likewise.
1122 * testsuite/special_functions/16_laguerre/check_nan.cc: Likewise.
1123 * testsuite/special_functions/17_legendre/check_nan.cc: Likewise.
1124 * testsuite/special_functions/18_riemann_zeta/check_nan.cc:
1125 Likewise.
1126 * testsuite/special_functions/19_sph_bessel/check_nan.cc:
1127 Likewise.
1128 * testsuite/special_functions/20_sph_legendre/check_nan.cc:
1129 Likewise.
1130 * testsuite/special_functions/21_sph_neumann/check_nan.cc:
1131 Likewise.
1132
1133 2018-01-18 Uros Bizjak <ubizjak@gmail.com>
1134
1135 * configure.ac (AC_CHECK_HEADERS): Add linux/types.h. Conditionally
1136 include linux/types.h when checking linux/random.h header.
1137 * config.h.in: Regenerate.
1138 * configure: Ditto.
1139 * src/c++11/random.cc: Conditionally include linux/types.h.
1140
1141 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
1142
1143 * testsuite/17_intro/names.cc: Undefine 'y' on SPARC/Linux.
1144
1145 2018-01-16 Jonathan Wakely <jwakely@redhat.com>
1146
1147 PR libstdc++/83834
1148 * config/abi/pre/gnu.ver (GLIBCXX_3.4): Replace std::c[a-g]* wildcard
1149 pattern with exact match for std::cerr.
1150
1151 2018-01-15 Jonathan Wakely <jwakely@redhat.com>
1152
1153 PR libstdc++/83833
1154 * include/bits/random.h (chi_squared_distribution::param): Update
1155 gamma distribution parameter.
1156 * testsuite/26_numerics/random/chi_squared_distribution/83833.cc: New
1157 test.
1158
1159 PR libstdc++/83830
1160 * include/std/type_traits (has_unique_object_representations_v): Add
1161 variable template.
1162 * testsuite/20_util/has_unique_object_representations/value.cc: Check
1163 variable template.
1164
1165 2018-01-15 Ville Voutilainen <ville.voutilainen@gmail.com>
1166
1167 Make optional conditionally
1168 trivially_{copy,move}_{constructible,assignable}
1169 * include/std/optional (_Optional_payload): Fix the comment in
1170 the class head and turn into a primary and one specialization.
1171 (_Optional_payload::_M_engaged): Strike the NSDMI.
1172 (_Optional_payload<_Tp, false>::operator=(const _Optional_payload&)):
1173 New.
1174 (_Optional_payload<_Tp, false>::operator=(_Optional_payload&&)):
1175 Likewise.
1176 (_Optional_payload<_Tp, false>::_M_get): Likewise.
1177 (_Optional_payload<_Tp, false>::_M_reset): Likewise.
1178 (_Optional_base_impl): Likewise.
1179 (_Optional_base): Turn into a primary and three specializations.
1180 (optional(nullopt)): Change the base init.
1181 * testsuite/20_util/optional/assignment/8.cc: New.
1182 * testsuite/20_util/optional/cons/trivial.cc: Likewise.
1183 * testsuite/20_util/optional/cons/value_neg.cc: Adjust.
1184
1185 2018-01-15 Jonathan Wakely <jwakely@redhat.com>
1186
1187 PR libstdc++/80276
1188 * python/libstdcxx/v6/printers.py (strip_inline_namespaces): New.
1189 (get_template_arg_list): New.
1190 (StdVariantPrinter._template_args): Remove, use get_template_arg_list
1191 instead.
1192 (TemplateTypePrinter): Rewrite to work with gdb.Type objects instead
1193 of strings and regular expressions.
1194 (add_one_template_type_printer): Adapt to new TemplateTypePrinter.
1195 (FilteringTypePrinter): Add docstring. Match using startswith. Use
1196 strip_inline_namespaces instead of strip_versioned_namespace.
1197 (add_one_type_printer): Prepend namespace to match argument.
1198 (register_type_printers): Add type printers for char16_t and char32_t
1199 string types and for types using cxx11 ABI. Update calls to
1200 add_one_template_type_printer to provide default argument dicts.
1201 * testsuite/libstdc++-prettyprinters/80276.cc: New test.
1202 * testsuite/libstdc++-prettyprinters/whatis.cc: Remove tests for
1203 basic_string<unsigned char> and basic_string<signed char>.
1204 * testsuite/libstdc++-prettyprinters/whatis2.cc: Duplicate whatis.cc
1205 to test local variables, without overriding _GLIBCXX_USE_CXX11_ABI.
1206
1207 2018-01-14 Andreas Schwab <schwab@linux-m68k.org>
1208
1209 PR libstdc++/81092
1210 * config/abi/post/ia64-linux-gnu/baseline_symbols.txt: Update.
1211
1212 2018-01-13 Tim Shen <timshen@google.com>
1213
1214 PR libstdc++/83601
1215 * include/bits/regex.tcc (regex_replace): Fix escaping in sed.
1216 * testsuite/28_regex/algorithms/regex_replace/char/pr83601.cc: Tests.
1217 * testsuite/28_regex/algorithms/regex_replace/wchar_t/pr83601.cc: Tests.
1218
1219 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1220
1221 PR libstdc++/64054
1222 * testsuite/27_io/basic_ostream/inserters_arithmetic/char/hexfloat.cc:
1223 Remove dg-xfail-run-if.
1224
1225 2018-01-10 François Dumont <fdumont@gcc.gnu.org>
1226
1227 * include/bits/forward_list.h
1228 (_Fwd_list_node_base(_Fwd_list_node_base&&)): New.
1229 (_Fwd_list_node_base& operator=(_Fwd_list_node_base&&)): New.
1230 (_Fwd_list_node_base(const _Fwd_list_node_base&)): Explicit delete.
1231 (_Fwd_list_node_base& operator=(const _Fwd_list_node_base&)): Likewise.
1232 (_Fwd_list_impl()): Add noexcept qualification.
1233 (_Fwd_list_impl(const _Node_alloc_type&)): Delete.
1234 (_Fwd_list_impl(_Fwd_list_impl&&)): New, default.
1235 (_Fwd_list_impl(_Fwd_list_impl&&, _Node_alloc_type&&)): New.
1236 (_Fwd_list_base()): Default.
1237 (_Fwd_list_base(_Fwd_list_base&&, _Node_alloc_type&&, true_type)): New.
1238 (_Fwd_list_base(_Fwd_list_base&&)): Default.
1239 (forward_list<>()): Default.
1240 (forward_list<>(forward_list&&)): Default.
1241 (forward_list(forward_list&&, _Node_alloc_type&&, false_type)): New.
1242 (forward_list(forward_list&&, _Node_alloc_type&&, true_type)): New.
1243 (forward_list(forward_list&&, const _Alloc&)): Adapt to use latters.
1244 * include/bits/forward_list.tcc
1245 (_Fwd_list_base(_Fwd_list_base&&, _Node_alloc_type&&)): Adapt to use
1246 _M_impl._M_head move assignment.
1247 (forward_list<>::merge(forward_list<>&&, _Comp)): Likewise.
1248 * testsuite/23_containers/forward_list/allocator/default_init.cc: New.
1249
1250 2018-01-09 Jonathan Wakely <jwakely@redhat.com>
1251
1252 PR libstdc++/80276
1253 * python/libstdcxx/v6/printers.py (SharedPointerPrinter)
1254 (UniquePointerPrinter): Print correct template argument, not type of
1255 the pointer.
1256 (TemplateTypePrinter._recognizer.recognize): Handle failure to lookup
1257 a type.
1258 * testsuite/libstdc++-prettyprinters/cxx11.cc: Test unique_ptr of
1259 array type.
1260 * testsuite/libstdc++-prettyprinters/cxx17.cc: Test shared_ptr and
1261 weak_ptr of array types.
1262
1263 2018-01-09 François Dumont <fdumont@gcc.gnu.org>
1264
1265 PR libstdc++/83709
1266 * include/bits/hashtable_policy.h
1267 (__distance_fwd(_Iterator, _Iterator, input_iterator_tag)): Return 1 if
1268 __first != __last.
1269 (_Insert_base::_M_insert_range(_Ite, _Ite, _NodeGetter, true_type)): New.
1270 (_Insert_base::_M_insert_range(_Ite, _Ite, _NodeGetter, false_type)):
1271 Add false_type parameter.
1272 (_Insert_base::insert): Adapt.
1273 * include/bits/hashtable.h (_Hashtable::operator=(initializzr_list<>)):
1274 Adapt.
1275 (_Hashtable::_M_insert(_Arg&&, const _NodeGen&, true_type, size_t)):
1276 Add __n_elt parameter, defaulted to 1.
1277 (_Hashtable::_M_insert_unique_node): Likewise. Use it to call rehash
1278 policy _M_need_rehash.
1279 (_Hashtable::_M_merge_unique): Pass target number of elements to add to
1280 produce only 1 rehash if necessary.
1281 * testsuite/23_containers/unordered_map/insert/83709.cc: New.
1282 * testsuite/23_containers/unordered_set/insert/83709.cc: New.
1283
1284 2018-01-09 Juraj Oršulić <juraj.orsulic@fer.hr>
1285 Jonathan Wakely <jwakely@redhat.com>
1286
1287 PR libstdc++/59253 (partial)
1288 * python/libstdcxx/v6/printers.py (SmartPtrIterator): Common iterator
1289 type for pointer stored by shared_ptr, weak_ptr and unique_ptr.
1290 (SharedPointerPrinter, UniquePointerPrinter): Treat stored values as
1291 children.
1292 * testsuite/libstdc++-prettyprinters/cxx11.cc: Update expected output
1293 of unique_ptr printer.
1294 * testsuite/libstdc++-prettyprinters/shared_ptr.cc: Update expected
1295 output of shared_ptr printer.
1296
1297 2018-01-05 Jonathan Wakely <jwakely@redhat.com>
1298
1299 PR libstdc++/83626
1300 * src/filesystem/ops.cc (remove(const path&, error_code&)): Remove
1301 unnecessary symlink_status call.
1302 (remove_all(const path&, error_code&)): Use filesystem::remove.
1303 * src/filesystem/std-ops.cc: Likewise.
1304
1305 PR libstdc++/83279
1306 * src/filesystem/std-ops.cc (do_copy_file): Use non-null offset with
1307 sendfile.
1308
1309 PR libstdc++/83626
1310 * src/filesystem/ops.cc (remove(const path&, error_code&)): Do not
1311 report an error for ENOENT.
1312 (remove_all(const path&)): Fix type of result variable.
1313 (remove_all(const path&, error_code&)): Use non-throwing increment
1314 for directory iterator. Call POSIX remove directly to avoid redundant
1315 calls to symlink_status. Do not report errors for ENOENT.
1316 * src/filesystem/std-ops.cc: Likewise.
1317 * testsuite/27_io/filesystem/operations/remove_all.cc: Test throwing
1318 overload.
1319 * testsuite/experimental/filesystem/operations/remove_all.cc:
1320 Likewise.
1321
1322 2018-01-04 Jonathan Wakely <jwakely@redhat.com>
1323
1324 PR libstdc++/83626
1325 * src/filesystem/ops.cc (remove(const path&, error_code&))): Remove
1326 redundant call to ec.clear().
1327 (remove_all(const path&, error_code&))): Do not return an error for
1328 non-existent paths.
1329 * src/filesystem/std-ops.cc: Likewise.
1330 * testsuite/27_io/filesystem/operations/remove.cc: New test.
1331 * testsuite/27_io/filesystem/operations/remove_all.cc: Fix expected
1332 results for non-existent paths.
1333 * testsuite/experimental/filesystem/operations/remove.cc: New test.
1334 * testsuite/experimental/filesystem/operations/remove_all.cc: Fix
1335 expected results for non-existent paths.
1336
1337 * include/bits/fs_ops.h (exists(const path&, error_code&))): Only
1338 check status_known once.
1339 * include/experimental/bits/fs_ops.h: Likewise.
1340
1341 PR libstdc++/83607
1342 * include/std/functional (__is_byte_like): New trait.
1343 (__is_std_equal_to): Remove.
1344 (__boyer_moore_base_t): Use __is_byte_like instead of
1345 __is_std_equal_to.
1346 * include/experimental/functional (__is_std_equal_to): Remove.
1347 (__boyer_moore_base_t): Use __is_byte_like instead of
1348 __is_std_equal_to.
1349 * testsuite/20_util/function_objects/83607.cc: New test.
1350
1351 2018-01-03 Ville Voutilainen <ville.voutilainen@gmail.com>
1352
1353 Protect optional's deduction guide with the feature macro
1354 * include/std/optional: Use the feature macro.
1355
1356 2018-01-03 Jakub Jelinek <jakub@redhat.com>
1357
1358 Update copyright years.
1359 \f
1360 Copyright (C) 2018 Free Software Foundation, Inc.
1361
1362 Copying and distribution of this file, with or without modification,
1363 are permitted in any medium without royalty provided the copyright
1364 notice and this notice are preserved.