Use non-throwing is_directory in filesystem::create_directory
[official-gcc.git] / libstdc++-v3 / ChangeLog
blob8e8fa138bfe6f0d7ceb9a99963d2b9ed92bed302
1 2018-03-09  Jonathan Wakely  <jwakely@redhat.com>
3         src/filesystem/ops.cc (create_dir): Pass error_code to is_directory.
4         src/filesystem/std-ops.cc (create_dir): Likewise.
6 2018-03-08  François Dumont  <fdumont@gcc.gnu.org>
8         * python/libstdcxx/v6/printers.py (NodeIteratorPrinter): New.
9         (StdListIteratorPrinter): Inherit from latter.
10         (StdFwdListIteratorPrinter): New, inherit from latter.
11         (StdDebugIteratorPrinter.to_string): Use non-debug iterator printer
12         when iterator has no associated container.
13         (build_libstdcxx_dictionary): Add __gnu_cxx::_Fwd_list_iterator and
14         __gnu_cxx::_Fwd_list_const_iterator printers. Remove __norm namespace
15         registrations.
16         * testsuite/libstdc++-prettyprinters/debug.cc: Adapt.
17         * testsuite/libstdc++-prettyprinters/debug_cxx11.cc: Adapt.
19 2018-03-06  Ville Voutilainen  <ville.voutilainen@gmail.com>
21         PR libstdc++/84601
22         * include/std/optional (_Optional_payload): Split into multiple
23         specializations that can handle different cases of trivial or
24         non-trivial assignment operators.
25         * testsuite/20_util/optional/84601.cc: New.
26         * testsuite/20_util/optional/cons/value_neg.cc: Adjust.
28 2018-03-02  Jonathan Wakely  <jwakely@redhat.com>
30         PR libstdc++/84671
31         * include/bits/parse_numbers.h (_Number_help): Add partial
32         specialization to handle digit separators. Adjust partial
33         specialization for recursion temrination to require _Pow == 1ULL.
34         * testsuite/20_util/duration/literals/84671.cc: New
36 2018-02-27  Ville Voutilainen  <ville.voutilainen@gmail.com>
38         Implement the missing bits of LWG 2769
39         * include/std/any (any_cast(const any&)): Add static_assert.
40         (any_cast(any&)): Likewise.
41         (any_cast(any&&)): Likewise, and remove the handling
42         for copyable-but-not-movable type.
43         * testsuite/20_util/any/misc/any_cast.cc: Adjust.
44         * testsuite/20_util/any/misc/any_cast_neg.cc: Likewise, and
45         add new tests.
47 2018-02-23  Jonathan Wakely  <jwakely@redhat.com>
49         PR libstdc++/84532
50         * include/std/thread (thread::__make_invoker): Construct tuple
51         directly instead of using make_tuple.
52         * testsuite/30_threads/async/84532.cc: New.
53         * testsuite/30_threads/thread/84532.cc: New.
55 2018-02-20  François Dumont  <fdumont@gcc.gnu.org>
57         * include/ext/aligned_buffer.h [_GLIBCXX_INLINE_VERSION]
58         (template<> __aligned_buffer): Define as __aligned_membuf alias.
60 2018-02-19  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
62         PR target/84148
63         * configure: Regenerate.
65 2018-02-15  Jonathan Wakely  <jwakely@redhat.com>
67         PR libstdc++/81797
68         * configure.ac (INCLUDE_DIR_NOTPARALLEL): Define.
69         * configure: Regenerate.
70         * include/Makefile.am (INCLUDE_DIR_NOTPARALLEL): Add .NOTPARALLEL when
71         defined.
72         * include/Makefile.in: Regenerate.
74 2018-01-29  Jonathan Wakely  <jwakely@redhat.com>
76         PR libstdc++/83833
77         * testsuite/26_numerics/random/chi_squared_distribution/83833.cc:
78         Add -ffloat-store to options for m68k and ia32.
80         * doc/xml/faq.xml: Update copyright years.
81         * doc/html/*: Regenerate.
83         PR libstdc++/83658
84         * include/std/any (any::__do_emplace): Only set _M_manager after
85         constructing the contained object.
86         * testsuite/20_util/any/misc/any_cast_neg.cc: Adjust dg-error line.
87         * testsuite/20_util/any/modifiers/83658.cc: New test.
89 2018-01-25  Jonathan Wakely  <jwakely@redhat.com>
91         PR libstdc++/81076
92         * include/c_global/cstddef (__byte_operand): Define primary template.
93         * testsuite/18_support/byte/81076.cc: New test.
95 2018-01-19  Christophe Lyon  <christophe.lyon@linaro.org>
97         * testsuite/ext/special_functions/airy_ai/check_nan.cc: Fix
98         dg-options and dg-add-options order.
99         * testsuite/ext/special_functions/airy_bi/check_nan.cc: Likewise.
100         * testsuite/ext/special_functions/conf_hyperg/check_nan.cc:
101         Likewise.
102         * testsuite/ext/special_functions/hyperg/check_nan.cc: Likewise.
103         * testsuite/special_functions/01_assoc_laguerre/check_nan.cc:
104         Likewise.
105         * testsuite/special_functions/02_assoc_legendre/check_nan.cc:
106         Likewise.
107         * testsuite/special_functions/03_beta/check_nan.cc: Likewise.
108         * testsuite/special_functions/04_comp_ellint_1/check_nan.cc:
109         Likewise.
110         * testsuite/special_functions/05_comp_ellint_2/check_nan.cc:
111         Likewise.
112         * testsuite/special_functions/06_comp_ellint_3/check_nan.cc:
113         Likewise.
114         * testsuite/special_functions/06_comp_ellint_3/pr66689.cc:
115         Likewise.
116         * testsuite/special_functions/07_cyl_bessel_i/check_nan.cc:
117         Likewise.
118         * testsuite/special_functions/08_cyl_bessel_j/check_nan.cc:
119         Likewise.
120         * testsuite/special_functions/09_cyl_bessel_k/check_nan.cc:
121         Likewise.
122         * testsuite/special_functions/10_cyl_neumann/check_nan.cc:
123         Likewise.
124         * testsuite/special_functions/11_ellint_1/check_nan.cc: Likewise.
125         * testsuite/special_functions/12_ellint_2/check_nan.cc: Likewise.
126         * testsuite/special_functions/13_ellint_3/check_nan.cc: Likewise.
127         * testsuite/special_functions/13_ellint_3/pr66689.cc: Likewise.
128         * testsuite/special_functions/14_expint/check_nan.cc: Likewise.
129         * testsuite/special_functions/15_hermite/check_nan.cc: Likewise.
130         * testsuite/special_functions/16_laguerre/check_nan.cc: Likewise.
131         * testsuite/special_functions/17_legendre/check_nan.cc: Likewise.
132         * testsuite/special_functions/18_riemann_zeta/check_nan.cc:
133         Likewise.
134         * testsuite/special_functions/19_sph_bessel/check_nan.cc:
135         Likewise.
136         * testsuite/special_functions/20_sph_legendre/check_nan.cc:
137         Likewise.
138         * testsuite/special_functions/21_sph_neumann/check_nan.cc:
139         Likewise.
141 2018-01-18  Uros Bizjak  <ubizjak@gmail.com>
143         * configure.ac (AC_CHECK_HEADERS): Add linux/types.h.  Conditionally
144         include linux/types.h when checking linux/random.h header.
145         * config.h.in: Regenerate.
146         * configure: Ditto.
147         * src/c++11/random.cc: Conditionally include linux/types.h.
149 2018-01-16  Eric Botcazou  <ebotcazou@adacore.com>
151         * testsuite/17_intro/names.cc: Undefine 'y' on SPARC/Linux.
153 2018-01-16  Jonathan Wakely  <jwakely@redhat.com>
155         PR libstdc++/83834
156         * config/abi/pre/gnu.ver (GLIBCXX_3.4): Replace std::c[a-g]* wildcard
157         pattern with exact match for std::cerr.
159 2018-01-15  Jonathan Wakely  <jwakely@redhat.com>
161         PR libstdc++/83833
162         * include/bits/random.h (chi_squared_distribution::param): Update
163         gamma distribution parameter.
164         * testsuite/26_numerics/random/chi_squared_distribution/83833.cc: New
165         test.
167         PR libstdc++/83830
168         * include/std/type_traits (has_unique_object_representations_v): Add
169         variable template.
170         * testsuite/20_util/has_unique_object_representations/value.cc: Check
171         variable template.
173 2018-01-15  Ville Voutilainen  <ville.voutilainen@gmail.com>
175         Make optional conditionally
176         trivially_{copy,move}_{constructible,assignable}
177         * include/std/optional (_Optional_payload): Fix the comment in
178         the class head and turn into a primary and one specialization.
179         (_Optional_payload::_M_engaged): Strike the NSDMI.
180         (_Optional_payload<_Tp, false>::operator=(const _Optional_payload&)):
181         New.
182         (_Optional_payload<_Tp, false>::operator=(_Optional_payload&&)):
183         Likewise.
184         (_Optional_payload<_Tp, false>::_M_get): Likewise.
185         (_Optional_payload<_Tp, false>::_M_reset): Likewise.
186         (_Optional_base_impl): Likewise.
187         (_Optional_base): Turn into a primary and three specializations.
188         (optional(nullopt)): Change the base init.
189         * testsuite/20_util/optional/assignment/8.cc: New.
190         * testsuite/20_util/optional/cons/trivial.cc: Likewise.
191         * testsuite/20_util/optional/cons/value_neg.cc: Adjust.
193 2018-01-15  Jonathan Wakely  <jwakely@redhat.com>
195         PR libstdc++/80276
196         * python/libstdcxx/v6/printers.py (strip_inline_namespaces): New.
197         (get_template_arg_list): New.
198         (StdVariantPrinter._template_args): Remove, use get_template_arg_list
199         instead.
200         (TemplateTypePrinter): Rewrite to work with gdb.Type objects instead
201         of strings and regular expressions.
202         (add_one_template_type_printer): Adapt to new TemplateTypePrinter.
203         (FilteringTypePrinter): Add docstring. Match using startswith. Use
204         strip_inline_namespaces instead of strip_versioned_namespace.
205         (add_one_type_printer): Prepend namespace to match argument.
206         (register_type_printers): Add type printers for char16_t and char32_t
207         string types and for types using cxx11 ABI. Update calls to
208         add_one_template_type_printer to provide default argument dicts.
209         * testsuite/libstdc++-prettyprinters/80276.cc: New test.
210         * testsuite/libstdc++-prettyprinters/whatis.cc: Remove tests for
211         basic_string<unsigned char> and basic_string<signed char>.
212         * testsuite/libstdc++-prettyprinters/whatis2.cc: Duplicate whatis.cc
213         to test local variables, without overriding _GLIBCXX_USE_CXX11_ABI.
215 2018-01-14  Andreas Schwab  <schwab@linux-m68k.org>
217         PR libstdc++/81092
218         * config/abi/post/ia64-linux-gnu/baseline_symbols.txt: Update.
220 2018-01-13  Tim Shen  <timshen@google.com>
222         PR libstdc++/83601
223         * include/bits/regex.tcc (regex_replace): Fix escaping in sed.
224         * testsuite/28_regex/algorithms/regex_replace/char/pr83601.cc: Tests.
225         * testsuite/28_regex/algorithms/regex_replace/wchar_t/pr83601.cc: Tests.
227 2018-01-12  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
229         PR libstdc++/64054
230         * testsuite/27_io/basic_ostream/inserters_arithmetic/char/hexfloat.cc:
231         Remove dg-xfail-run-if.
233 2018-01-10  François Dumont  <fdumont@gcc.gnu.org>
235         * include/bits/forward_list.h
236         (_Fwd_list_node_base(_Fwd_list_node_base&&)): New.
237         (_Fwd_list_node_base& operator=(_Fwd_list_node_base&&)): New.
238         (_Fwd_list_node_base(const _Fwd_list_node_base&)): Explicit delete.
239         (_Fwd_list_node_base& operator=(const _Fwd_list_node_base&)): Likewise.
240         (_Fwd_list_impl()): Add noexcept qualification.
241         (_Fwd_list_impl(const _Node_alloc_type&)): Delete.
242         (_Fwd_list_impl(_Fwd_list_impl&&)): New, default.
243         (_Fwd_list_impl(_Fwd_list_impl&&, _Node_alloc_type&&)): New.
244         (_Fwd_list_base()): Default.
245         (_Fwd_list_base(_Fwd_list_base&&, _Node_alloc_type&&, true_type)): New.
246         (_Fwd_list_base(_Fwd_list_base&&)): Default.
247         (forward_list<>()): Default.
248         (forward_list<>(forward_list&&)): Default.
249         (forward_list(forward_list&&, _Node_alloc_type&&, false_type)): New.
250         (forward_list(forward_list&&, _Node_alloc_type&&, true_type)): New.
251         (forward_list(forward_list&&, const _Alloc&)): Adapt to use latters.
252         * include/bits/forward_list.tcc
253         (_Fwd_list_base(_Fwd_list_base&&, _Node_alloc_type&&)): Adapt to use
254         _M_impl._M_head move assignment.
255         (forward_list<>::merge(forward_list<>&&, _Comp)): Likewise.
256         * testsuite/23_containers/forward_list/allocator/default_init.cc: New.
258 2018-01-09  Jonathan Wakely  <jwakely@redhat.com>
260         PR libstdc++/80276
261         * python/libstdcxx/v6/printers.py (SharedPointerPrinter)
262         (UniquePointerPrinter): Print correct template argument, not type of
263         the pointer.
264         (TemplateTypePrinter._recognizer.recognize): Handle failure to lookup
265         a type.
266         * testsuite/libstdc++-prettyprinters/cxx11.cc: Test unique_ptr of
267         array type.
268         * testsuite/libstdc++-prettyprinters/cxx17.cc: Test shared_ptr and
269         weak_ptr of array types.
271 2018-01-09  François Dumont  <fdumont@gcc.gnu.org>
273         PR libstdc++/83709
274         * include/bits/hashtable_policy.h
275         (__distance_fwd(_Iterator, _Iterator, input_iterator_tag)): Return 1 if
276         __first != __last.
277         (_Insert_base::_M_insert_range(_Ite, _Ite, _NodeGetter, true_type)): New.
278         (_Insert_base::_M_insert_range(_Ite, _Ite, _NodeGetter, false_type)):
279         Add false_type parameter.
280         (_Insert_base::insert): Adapt.
281         * include/bits/hashtable.h (_Hashtable::operator=(initializzr_list<>)):
282         Adapt.
283         (_Hashtable::_M_insert(_Arg&&, const _NodeGen&, true_type, size_t)):
284          Add __n_elt parameter, defaulted to 1.
285         (_Hashtable::_M_insert_unique_node): Likewise. Use it to call rehash
286         policy _M_need_rehash.
287         (_Hashtable::_M_merge_unique): Pass target number of elements to add to
288         produce only 1 rehash if necessary.
289         * testsuite/23_containers/unordered_map/insert/83709.cc: New.
290         * testsuite/23_containers/unordered_set/insert/83709.cc: New.
292 2018-01-09  Juraj Oršulić  <juraj.orsulic@fer.hr>
293             Jonathan Wakely  <jwakely@redhat.com>
295         PR libstdc++/59253 (partial)
296         * python/libstdcxx/v6/printers.py (SmartPtrIterator): Common iterator
297         type for pointer stored by shared_ptr, weak_ptr and unique_ptr.
298         (SharedPointerPrinter, UniquePointerPrinter): Treat stored values as
299         children.
300         * testsuite/libstdc++-prettyprinters/cxx11.cc: Update expected output
301         of unique_ptr printer.
302         * testsuite/libstdc++-prettyprinters/shared_ptr.cc: Update expected
303         output of shared_ptr printer.
305 2018-01-05  Jonathan Wakely  <jwakely@redhat.com>
307         PR libstdc++/83626
308         * src/filesystem/ops.cc (remove(const path&, error_code&)): Remove
309         unnecessary symlink_status call.
310         (remove_all(const path&, error_code&)): Use filesystem::remove.
311         * src/filesystem/std-ops.cc: Likewise.
313         PR libstdc++/83279
314         * src/filesystem/std-ops.cc  (do_copy_file): Use non-null offset with
315         sendfile.
317         PR libstdc++/83626
318         * src/filesystem/ops.cc (remove(const path&, error_code&)): Do not
319         report an error for ENOENT.
320         (remove_all(const path&)): Fix type of result variable.
321         (remove_all(const path&, error_code&)): Use non-throwing increment
322         for directory iterator. Call POSIX remove directly to avoid redundant
323         calls to symlink_status. Do not report errors for ENOENT.
324         * src/filesystem/std-ops.cc: Likewise.
325         * testsuite/27_io/filesystem/operations/remove_all.cc: Test throwing
326         overload.
327         * testsuite/experimental/filesystem/operations/remove_all.cc:
328         Likewise.
330 2018-01-04  Jonathan Wakely  <jwakely@redhat.com>
332         PR libstdc++/83626
333         * src/filesystem/ops.cc (remove(const path&, error_code&))): Remove
334         redundant call to ec.clear().
335         (remove_all(const path&, error_code&))): Do not return an error for
336         non-existent paths.
337         * src/filesystem/std-ops.cc: Likewise.
338         * testsuite/27_io/filesystem/operations/remove.cc: New test.
339         * testsuite/27_io/filesystem/operations/remove_all.cc: Fix expected
340         results for non-existent paths.
341         * testsuite/experimental/filesystem/operations/remove.cc: New test.
342         * testsuite/experimental/filesystem/operations/remove_all.cc: Fix
343         expected results for non-existent paths.
345         * include/bits/fs_ops.h (exists(const path&, error_code&))): Only
346         check status_known once.
347         * include/experimental/bits/fs_ops.h: Likewise.
349         PR libstdc++/83607
350         * include/std/functional (__is_byte_like): New trait.
351         (__is_std_equal_to): Remove.
352         (__boyer_moore_base_t): Use __is_byte_like instead of
353         __is_std_equal_to.
354         * include/experimental/functional (__is_std_equal_to): Remove.
355         (__boyer_moore_base_t): Use __is_byte_like instead of
356         __is_std_equal_to.
357         * testsuite/20_util/function_objects/83607.cc: New test.
359 2018-01-03  Ville Voutilainen  <ville.voutilainen@gmail.com>
361         Protect optional's deduction guide with the feature macro
362         * include/std/optional: Use the feature macro.
364 2018-01-03  Jakub Jelinek  <jakub@redhat.com>
366         Update copyright years.
368 Copyright (C) 2018 Free Software Foundation, Inc.
370 Copying and distribution of this file, with or without modification,
371 are permitted in any medium without royalty provided the copyright
372 notice and this notice are preserved.