PR libstdc++/81076 make __byte_operand SFINAE-friendly
[gcc.git] / libstdc++-v3 / ChangeLog
1 2018-01-25 Jonathan Wakely <jwakely@redhat.com>
2
3 PR libstdc++/81076
4 * include/c_global/cstddef (__byte_operand): Define primary template.
5 * testsuite/18_support/byte/81076.cc: New test.
6
7 2018-01-19 Christophe Lyon <christophe.lyon@linaro.org>
8
9 * testsuite/ext/special_functions/airy_ai/check_nan.cc: Fix
10 dg-options and dg-add-options order.
11 * testsuite/ext/special_functions/airy_bi/check_nan.cc: Likewise.
12 * testsuite/ext/special_functions/conf_hyperg/check_nan.cc:
13 Likewise.
14 * testsuite/ext/special_functions/hyperg/check_nan.cc: Likewise.
15 * testsuite/special_functions/01_assoc_laguerre/check_nan.cc:
16 Likewise.
17 * testsuite/special_functions/02_assoc_legendre/check_nan.cc:
18 Likewise.
19 * testsuite/special_functions/03_beta/check_nan.cc: Likewise.
20 * testsuite/special_functions/04_comp_ellint_1/check_nan.cc:
21 Likewise.
22 * testsuite/special_functions/05_comp_ellint_2/check_nan.cc:
23 Likewise.
24 * testsuite/special_functions/06_comp_ellint_3/check_nan.cc:
25 Likewise.
26 * testsuite/special_functions/06_comp_ellint_3/pr66689.cc:
27 Likewise.
28 * testsuite/special_functions/07_cyl_bessel_i/check_nan.cc:
29 Likewise.
30 * testsuite/special_functions/08_cyl_bessel_j/check_nan.cc:
31 Likewise.
32 * testsuite/special_functions/09_cyl_bessel_k/check_nan.cc:
33 Likewise.
34 * testsuite/special_functions/10_cyl_neumann/check_nan.cc:
35 Likewise.
36 * testsuite/special_functions/11_ellint_1/check_nan.cc: Likewise.
37 * testsuite/special_functions/12_ellint_2/check_nan.cc: Likewise.
38 * testsuite/special_functions/13_ellint_3/check_nan.cc: Likewise.
39 * testsuite/special_functions/13_ellint_3/pr66689.cc: Likewise.
40 * testsuite/special_functions/14_expint/check_nan.cc: Likewise.
41 * testsuite/special_functions/15_hermite/check_nan.cc: Likewise.
42 * testsuite/special_functions/16_laguerre/check_nan.cc: Likewise.
43 * testsuite/special_functions/17_legendre/check_nan.cc: Likewise.
44 * testsuite/special_functions/18_riemann_zeta/check_nan.cc:
45 Likewise.
46 * testsuite/special_functions/19_sph_bessel/check_nan.cc:
47 Likewise.
48 * testsuite/special_functions/20_sph_legendre/check_nan.cc:
49 Likewise.
50 * testsuite/special_functions/21_sph_neumann/check_nan.cc:
51 Likewise.
52
53 2018-01-18 Uros Bizjak <ubizjak@gmail.com>
54
55 * configure.ac (AC_CHECK_HEADERS): Add linux/types.h. Conditionally
56 include linux/types.h when checking linux/random.h header.
57 * config.h.in: Regenerate.
58 * configure: Ditto.
59 * src/c++11/random.cc: Conditionally include linux/types.h.
60
61 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
62
63 * testsuite/17_intro/names.cc: Undefine 'y' on SPARC/Linux.
64
65 2018-01-16 Jonathan Wakely <jwakely@redhat.com>
66
67 PR libstdc++/83834
68 * config/abi/pre/gnu.ver (GLIBCXX_3.4): Replace std::c[a-g]* wildcard
69 pattern with exact match for std::cerr.
70
71 2018-01-15 Jonathan Wakely <jwakely@redhat.com>
72
73 PR libstdc++/83833
74 * include/bits/random.h (chi_squared_distribution::param): Update
75 gamma distribution parameter.
76 * testsuite/26_numerics/random/chi_squared_distribution/83833.cc: New
77 test.
78
79 PR libstdc++/83830
80 * include/std/type_traits (has_unique_object_representations_v): Add
81 variable template.
82 * testsuite/20_util/has_unique_object_representations/value.cc: Check
83 variable template.
84
85 2018-01-15 Ville Voutilainen <ville.voutilainen@gmail.com>
86
87 Make optional conditionally
88 trivially_{copy,move}_{constructible,assignable}
89 * include/std/optional (_Optional_payload): Fix the comment in
90 the class head and turn into a primary and one specialization.
91 (_Optional_payload::_M_engaged): Strike the NSDMI.
92 (_Optional_payload<_Tp, false>::operator=(const _Optional_payload&)):
93 New.
94 (_Optional_payload<_Tp, false>::operator=(_Optional_payload&&)):
95 Likewise.
96 (_Optional_payload<_Tp, false>::_M_get): Likewise.
97 (_Optional_payload<_Tp, false>::_M_reset): Likewise.
98 (_Optional_base_impl): Likewise.
99 (_Optional_base): Turn into a primary and three specializations.
100 (optional(nullopt)): Change the base init.
101 * testsuite/20_util/optional/assignment/8.cc: New.
102 * testsuite/20_util/optional/cons/trivial.cc: Likewise.
103 * testsuite/20_util/optional/cons/value_neg.cc: Adjust.
104
105 2018-01-15 Jonathan Wakely <jwakely@redhat.com>
106
107 PR libstdc++/80276
108 * python/libstdcxx/v6/printers.py (strip_inline_namespaces): New.
109 (get_template_arg_list): New.
110 (StdVariantPrinter._template_args): Remove, use get_template_arg_list
111 instead.
112 (TemplateTypePrinter): Rewrite to work with gdb.Type objects instead
113 of strings and regular expressions.
114 (add_one_template_type_printer): Adapt to new TemplateTypePrinter.
115 (FilteringTypePrinter): Add docstring. Match using startswith. Use
116 strip_inline_namespaces instead of strip_versioned_namespace.
117 (add_one_type_printer): Prepend namespace to match argument.
118 (register_type_printers): Add type printers for char16_t and char32_t
119 string types and for types using cxx11 ABI. Update calls to
120 add_one_template_type_printer to provide default argument dicts.
121 * testsuite/libstdc++-prettyprinters/80276.cc: New test.
122 * testsuite/libstdc++-prettyprinters/whatis.cc: Remove tests for
123 basic_string<unsigned char> and basic_string<signed char>.
124 * testsuite/libstdc++-prettyprinters/whatis2.cc: Duplicate whatis.cc
125 to test local variables, without overriding _GLIBCXX_USE_CXX11_ABI.
126
127 2018-01-14 Andreas Schwab <schwab@linux-m68k.org>
128
129 PR libstdc++/81092
130 * config/abi/post/ia64-linux-gnu/baseline_symbols.txt: Update.
131
132 2018-01-13 Tim Shen <timshen@google.com>
133
134 PR libstdc++/83601
135 * include/bits/regex.tcc (regex_replace): Fix escaping in sed.
136 * testsuite/28_regex/algorithms/regex_replace/char/pr83601.cc: Tests.
137 * testsuite/28_regex/algorithms/regex_replace/wchar_t/pr83601.cc: Tests.
138
139 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
140
141 PR libstdc++/64054
142 * testsuite/27_io/basic_ostream/inserters_arithmetic/char/hexfloat.cc:
143 Remove dg-xfail-run-if.
144
145 2018-01-10 François Dumont <fdumont@gcc.gnu.org>
146
147 * include/bits/forward_list.h
148 (_Fwd_list_node_base(_Fwd_list_node_base&&)): New.
149 (_Fwd_list_node_base& operator=(_Fwd_list_node_base&&)): New.
150 (_Fwd_list_node_base(const _Fwd_list_node_base&)): Explicit delete.
151 (_Fwd_list_node_base& operator=(const _Fwd_list_node_base&)): Likewise.
152 (_Fwd_list_impl()): Add noexcept qualification.
153 (_Fwd_list_impl(const _Node_alloc_type&)): Delete.
154 (_Fwd_list_impl(_Fwd_list_impl&&)): New, default.
155 (_Fwd_list_impl(_Fwd_list_impl&&, _Node_alloc_type&&)): New.
156 (_Fwd_list_base()): Default.
157 (_Fwd_list_base(_Fwd_list_base&&, _Node_alloc_type&&, true_type)): New.
158 (_Fwd_list_base(_Fwd_list_base&&)): Default.
159 (forward_list<>()): Default.
160 (forward_list<>(forward_list&&)): Default.
161 (forward_list(forward_list&&, _Node_alloc_type&&, false_type)): New.
162 (forward_list(forward_list&&, _Node_alloc_type&&, true_type)): New.
163 (forward_list(forward_list&&, const _Alloc&)): Adapt to use latters.
164 * include/bits/forward_list.tcc
165 (_Fwd_list_base(_Fwd_list_base&&, _Node_alloc_type&&)): Adapt to use
166 _M_impl._M_head move assignment.
167 (forward_list<>::merge(forward_list<>&&, _Comp)): Likewise.
168 * testsuite/23_containers/forward_list/allocator/default_init.cc: New.
169
170 2018-01-09 Jonathan Wakely <jwakely@redhat.com>
171
172 PR libstdc++/80276
173 * python/libstdcxx/v6/printers.py (SharedPointerPrinter)
174 (UniquePointerPrinter): Print correct template argument, not type of
175 the pointer.
176 (TemplateTypePrinter._recognizer.recognize): Handle failure to lookup
177 a type.
178 * testsuite/libstdc++-prettyprinters/cxx11.cc: Test unique_ptr of
179 array type.
180 * testsuite/libstdc++-prettyprinters/cxx17.cc: Test shared_ptr and
181 weak_ptr of array types.
182
183 2018-01-09 François Dumont <fdumont@gcc.gnu.org>
184
185 PR libstdc++/83709
186 * include/bits/hashtable_policy.h
187 (__distance_fwd(_Iterator, _Iterator, input_iterator_tag)): Return 1 if
188 __first != __last.
189 (_Insert_base::_M_insert_range(_Ite, _Ite, _NodeGetter, true_type)): New.
190 (_Insert_base::_M_insert_range(_Ite, _Ite, _NodeGetter, false_type)):
191 Add false_type parameter.
192 (_Insert_base::insert): Adapt.
193 * include/bits/hashtable.h (_Hashtable::operator=(initializzr_list<>)):
194 Adapt.
195 (_Hashtable::_M_insert(_Arg&&, const _NodeGen&, true_type, size_t)):
196 Add __n_elt parameter, defaulted to 1.
197 (_Hashtable::_M_insert_unique_node): Likewise. Use it to call rehash
198 policy _M_need_rehash.
199 (_Hashtable::_M_merge_unique): Pass target number of elements to add to
200 produce only 1 rehash if necessary.
201 * testsuite/23_containers/unordered_map/insert/83709.cc: New.
202 * testsuite/23_containers/unordered_set/insert/83709.cc: New.
203
204 2018-01-09 Juraj Oršulić <juraj.orsulic@fer.hr>
205 Jonathan Wakely <jwakely@redhat.com>
206
207 PR libstdc++/59253 (partial)
208 * python/libstdcxx/v6/printers.py (SmartPtrIterator): Common iterator
209 type for pointer stored by shared_ptr, weak_ptr and unique_ptr.
210 (SharedPointerPrinter, UniquePointerPrinter): Treat stored values as
211 children.
212 * testsuite/libstdc++-prettyprinters/cxx11.cc: Update expected output
213 of unique_ptr printer.
214 * testsuite/libstdc++-prettyprinters/shared_ptr.cc: Update expected
215 output of shared_ptr printer.
216
217 2018-01-05 Jonathan Wakely <jwakely@redhat.com>
218
219 PR libstdc++/83626
220 * src/filesystem/ops.cc (remove(const path&, error_code&)): Remove
221 unnecessary symlink_status call.
222 (remove_all(const path&, error_code&)): Use filesystem::remove.
223 * src/filesystem/std-ops.cc: Likewise.
224
225 PR libstdc++/83279
226 * src/filesystem/std-ops.cc (do_copy_file): Use non-null offset with
227 sendfile.
228
229 PR libstdc++/83626
230 * src/filesystem/ops.cc (remove(const path&, error_code&)): Do not
231 report an error for ENOENT.
232 (remove_all(const path&)): Fix type of result variable.
233 (remove_all(const path&, error_code&)): Use non-throwing increment
234 for directory iterator. Call POSIX remove directly to avoid redundant
235 calls to symlink_status. Do not report errors for ENOENT.
236 * src/filesystem/std-ops.cc: Likewise.
237 * testsuite/27_io/filesystem/operations/remove_all.cc: Test throwing
238 overload.
239 * testsuite/experimental/filesystem/operations/remove_all.cc:
240 Likewise.
241
242 2018-01-04 Jonathan Wakely <jwakely@redhat.com>
243
244 PR libstdc++/83626
245 * src/filesystem/ops.cc (remove(const path&, error_code&))): Remove
246 redundant call to ec.clear().
247 (remove_all(const path&, error_code&))): Do not return an error for
248 non-existent paths.
249 * src/filesystem/std-ops.cc: Likewise.
250 * testsuite/27_io/filesystem/operations/remove.cc: New test.
251 * testsuite/27_io/filesystem/operations/remove_all.cc: Fix expected
252 results for non-existent paths.
253 * testsuite/experimental/filesystem/operations/remove.cc: New test.
254 * testsuite/experimental/filesystem/operations/remove_all.cc: Fix
255 expected results for non-existent paths.
256
257 * include/bits/fs_ops.h (exists(const path&, error_code&))): Only
258 check status_known once.
259 * include/experimental/bits/fs_ops.h: Likewise.
260
261 PR libstdc++/83607
262 * include/std/functional (__is_byte_like): New trait.
263 (__is_std_equal_to): Remove.
264 (__boyer_moore_base_t): Use __is_byte_like instead of
265 __is_std_equal_to.
266 * include/experimental/functional (__is_std_equal_to): Remove.
267 (__boyer_moore_base_t): Use __is_byte_like instead of
268 __is_std_equal_to.
269 * testsuite/20_util/function_objects/83607.cc: New test.
270
271 2018-01-03 Ville Voutilainen <ville.voutilainen@gmail.com>
272
273 Protect optional's deduction guide with the feature macro
274 * include/std/optional: Use the feature macro.
275
276 2018-01-03 Jakub Jelinek <jakub@redhat.com>
277
278 Update copyright years.
279 \f
280 Copyright (C) 2018 Free Software Foundation, Inc.
281
282 Copying and distribution of this file, with or without modification,
283 are permitted in any medium without royalty provided the copyright
284 notice and this notice are preserved.