]> git.ipfire.org Git - thirdparty/gcc.git/blob - libstdc++-v3/ChangeLog
PR libstdc++/86756 add std::filesystem::path to libstdc++.so
[thirdparty/gcc.git] / libstdc++-v3 / ChangeLog
1 2019-01-06 Jonathan Wakely <jwakely@redhat.com>
2
3 PR libstdc++/86756
4 * config/abi/pre/gnu.ver (GLIBCXX_3.4): Make various patterns for
5 typeinfo and vtables less greedy.
6 (GLIBCXX_3.4.26): Export symbols for std::filesystem::path.
7 * src/c++17/Makefile.am: Add fs_path.cc and cow-fs_path.cc.
8 * src/c++17/Makefile.in: Regenerate.
9 * src/c++17/cow-fs_path.cc: Move src/filesystem/cow-std-path.cc to
10 here, and change name of included file.
11 * src/c++17/fs_path.cc: Move src/filesystem/std-path.cc to here.
12 * src/filesystem/Makefile.am: Remove std-path.cc and cow-std-path.cc
13 from sources.
14 * src/filesystem/Makefile.in: Regenerate.
15 * src/filesystem/cow-std-path.cc: Move to src/c++17/cow-fs_path.cc.
16 * src/filesystem/std-path.cc: Move to src/c++17/fs_path.cc.
17 * testsuite/27_io/filesystem/path/append/path.cc: Remove -lstdc++fs
18 from dg-options and remove dg-require-filesystem-ts.
19 * testsuite/27_io/filesystem/path/append/source.cc: Likewise.
20 * testsuite/27_io/filesystem/path/assign/assign.cc: Likewise.
21 * testsuite/27_io/filesystem/path/assign/copy.cc: Likewise.
22 * testsuite/27_io/filesystem/path/compare/compare.cc: Likewise.
23 * testsuite/27_io/filesystem/path/compare/lwg2936.cc: Likewise.
24 * testsuite/27_io/filesystem/path/compare/path.cc: Likewise.
25 * testsuite/27_io/filesystem/path/compare/strings.cc: Likewise.
26 * testsuite/27_io/filesystem/path/concat/path.cc: Likewise.
27 * testsuite/27_io/filesystem/path/concat/strings.cc: Likewise.
28 * testsuite/27_io/filesystem/path/construct/80762.cc: Likewise.
29 * testsuite/27_io/filesystem/path/construct/copy.cc: Likewise.
30 * testsuite/27_io/filesystem/path/construct/default.cc: Likewise.
31 * testsuite/27_io/filesystem/path/construct/format.cc: Likewise.
32 * testsuite/27_io/filesystem/path/construct/locale.cc: Likewise.
33 * testsuite/27_io/filesystem/path/construct/range.cc: Likewise.
34 * testsuite/27_io/filesystem/path/construct/string_view.cc: Likewise.
35 * testsuite/27_io/filesystem/path/decompose/extension.cc: Likewise.
36 * testsuite/27_io/filesystem/path/decompose/filename.cc: Likewise.
37 * testsuite/27_io/filesystem/path/decompose/parent_path.cc: Likewise.
38 * testsuite/27_io/filesystem/path/decompose/relative_path.cc: Likewise.
39 * testsuite/27_io/filesystem/path/decompose/root_directory.cc:
40 Likewise.
41 * testsuite/27_io/filesystem/path/decompose/root_name.cc: Likewise.
42 * testsuite/27_io/filesystem/path/decompose/root_path.cc: Likewise.
43 * testsuite/27_io/filesystem/path/decompose/stem.cc: Likewise.
44 * testsuite/27_io/filesystem/path/generation/normal.cc: Likewise.
45 * testsuite/27_io/filesystem/path/generation/normal2.cc: Likewise.
46 * testsuite/27_io/filesystem/path/generation/proximate.cc: Likewise.
47 * testsuite/27_io/filesystem/path/generation/relative.cc: Likewise.
48 * testsuite/27_io/filesystem/path/generic/generic_string.cc: Likewise.
49 * testsuite/27_io/filesystem/path/itr/components.cc: Likewise.
50 * testsuite/27_io/filesystem/path/itr/traversal.cc: Likewise.
51 * testsuite/27_io/filesystem/path/modifiers/clear.cc: Likewise.
52 * testsuite/27_io/filesystem/path/modifiers/make_preferred.cc:
53 Likewise.
54 * testsuite/27_io/filesystem/path/modifiers/remove_filename.cc:
55 Likewise.
56 * testsuite/27_io/filesystem/path/modifiers/replace_extension.cc:
57 Likewise.
58 * testsuite/27_io/filesystem/path/modifiers/replace_filename.cc:
59 Likewise.
60 * testsuite/27_io/filesystem/path/modifiers/swap.cc: Likewise.
61 * testsuite/27_io/filesystem/path/native/string.cc: Likewise.
62 * testsuite/27_io/filesystem/path/nonmember/append.cc: Likewise.
63 * testsuite/27_io/filesystem/path/nonmember/hash_value.cc: Likewise.
64 * testsuite/27_io/filesystem/path/query/empty.cc: Likewise.
65 * testsuite/27_io/filesystem/path/query/has_extension.cc: Likewise.
66 * testsuite/27_io/filesystem/path/query/has_filename.cc: Likewise.
67 * testsuite/27_io/filesystem/path/query/has_parent_path.cc: Likewise.
68 * testsuite/27_io/filesystem/path/query/has_relative_path.cc: Likewise.
69 * testsuite/27_io/filesystem/path/query/has_root_directory.cc:
70 Likewise.
71 * testsuite/27_io/filesystem/path/query/has_root_name.cc: Likewise.
72 * testsuite/27_io/filesystem/path/query/has_root_path.cc: Likewise.
73 * testsuite/27_io/filesystem/path/query/has_stem.cc: Likewise.
74 * testsuite/27_io/filesystem/path/query/is_absolute.cc: Likewise.
75 * testsuite/27_io/filesystem/path/query/is_relative.cc: Likewise.
76
77 PR libstdc++/87431
78 * include/std/variant (_Variant_storage<true, _Types...>::_M_valid):
79 Check is_trivially_copyable instead of is_scalar.
80 (variant::emplace<N, Args>(Args&&...)): If construction of the new
81 contained value can throw and its type is trivially copyable then
82 construct into a temporary variant and move from it, to provide the
83 strong exception safety guarantee.
84 (variant::emplace<N, U, Args>(initializer_list<U>, Args&&...)):
85 Likewise.
86 * testsuite/20_util/variant/87431.cc: New test.
87 * testsuite/20_util/variant/run.cc: Adjust test so that throwing
88 conversion causes valueless state.
89
90 PR libstdc++/88607
91 * testsuite/17_intro/headers/c++1998/charset.cc: New test.
92 * testsuite/17_intro/headers/c++2011/charset.cc: New test.
93 * testsuite/17_intro/headers/c++2014/charset.cc: New test.
94 * testsuite/17_intro/headers/c++2017/charset.cc: New test.
95 * testsuite/17_intro/headers/c++2020/charset.cc: New test.
96
97 2019-01-05 Jonathan Wakely <jwakely@redhat.com>
98
99 * include/bits/fs_fwd.h (__file_clock): Define new clock.
100 (file_time_type): Redefine in terms of __file_clock.
101 * src/filesystem/ops-common.h (file_time): Add FIXME comment about
102 overflow.
103 * src/filesystem/std-ops.cc (is_set(perm_options, perm_options)): Give
104 internal linkage.
105 (internal_file_lock): New helper type for accessing __file_clock.
106 (do_copy_file): Use internal_file_lock to convert system time to
107 file_time_type.
108 (last_write_time(const path&, error_code&)): Likewise.
109 (last_write_time(const path&, file_time_type, error_code&)): Likewise.
110
111 2019-01-04 Jonathan Wakely <jwakely@redhat.com>
112
113 * config/abi/pre/gnu.ver (GLIBCXX_3.4.21): Make patterns less greedy
114 for const member functions of std::basic_string.
115 (GLIBCXX_3.4.26): Export member functions of std::basic_string added
116 in C++17.
117 * include/bits/basic_string.h (basic_string(__sv_wrapper, const A&)):
118 Make non-standard constructor private.
119 [!_GLIBCXX_USE_CXX11_ABI] (basic_string(__sv_wrapper, const A&)):
120 Likewise.
121 * include/bits/basic_string.tcc (std::string, std::wstring): Declare
122 explicit instantiations for C++17 as well as earlier dialects.
123 * src/c++17/Makefile.am: Add new source files.
124 * src/c++17/Makefile.in: Regenerate.
125 * src/c++17/cow-string-inst.cc: New file defining explicit
126 instantiations for basic_string member functions added in C++17.
127 * src/c++17/string-inst.cc: Likewise.
128
129 * config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Export allocator-extended
130 copy/move constructors for old std::basic_string.
131 * include/bits/basic_string.h [!_GLIBCXX_USE_CXX11_ABI]
132 (basic_string::reference, basic_string::const_reference): Define
133 as plain references for C++11 and later.
134 (basic_string::basic_string()): Put constructor body outside
135 preprocessor conditional groups.
136 (basic_string::basic_string(basic_string&&)): Move _Alloc_hider
137 instead of copying it.
138 (basic_string::basic_string(const basic_string&, const _Alloc&)):
139 Define.
140 (basic_string::basic_string(basic_string&&, const _Alloc&)):
141 Define.
142 * include/bits/fs_path.h [!_GLIBCXX_USE_CXX11_ABI]: Remove special
143 cases for old basic_string.
144 * testsuite/21_strings/basic_string/cons/char/8.cc: Test
145 allocator-extended constructors unconditionally. Add extra members to
146 allocator type when using old string ABI.
147 * testsuite/21_strings/basic_string/allocator/71964.cc: Enable test
148 for old string ABI.
149 * testsuite/21_strings/basic_string/cons/wchar_t/8.cc: Likewise.
150
151 * testsuite/23_containers/list/61347.cc: Avoid spurious failure when
152 -fno-inline added to test flags.
153
154 * testsuite/21_strings/basic_string/requirements/
155 explicit_instantiation/debug.cc: Remove XFAIL for old ABI.
156
157 * testsuite/27_io/filesystem/filesystem_error/copy.cc: Fix static
158 assertion failures with old std::string ABI.
159
160 * include/bits/fs_path.h (path::_List::erase): Replace both overloads
161 with ...
162 (path::pop_back(), path::_M_erase_from(const_iterator)): New member
163 functions that will only erase elements at the end.
164 * src/filesystem/std-path.cc (path::_List::_Impl::pop_back()): Define.
165 (path::_List::_Impl::_M_erase_from(const_iterator)): Define.
166 (path::_List::operator=(const _List&)): Use _M_erase_from(p) instead
167 of erase(p, end()).
168 (path::_List::pop_back()): Define.
169 (path::_List::_M_erase_from(const_iterator)): Define.
170 (path::operator/=(const path&)): Use pop_back to remove last component
171 and _M_erase_from to remove multiple components.
172 (path::_M_append(basic_string_view<value_type>)): Likewise.
173 (path::operator+=(const path&)): Likewise.
174 (path::_M_concat(basic_string_view<value_type>)): Likewise.
175 (path::remove_filename()): Likewise.
176 (path::lexically_normal()): Use _List::_Impl iterators instead of
177 path::iterator. Use pop_back to remove components from the end. Clear
178 trailing filename, instead of using erase(const_iterator) to remove
179 a non-final component.
180 * testsuite/27_io/filesystem/path/generation/normal.cc: Test
181 additional cases.
182 * testsuite/27_io/filesystem/path/generation/normal2.cc: New test.
183
184 * src/filesystem/std-path.cc (path::operator+=(const path&)): Fix
185 incorrect treatment of empty filename after trailing slash.
186 * testsuite/27_io/filesystem/path/concat/path.cc: Test problem case.
187
188 * testsuite/21_strings/basic_string/modifiers/assign/char/
189 move_assign_optim.cc: Avoid spurious failure when -fno-inline added
190 to test flags.
191 * testsuite/21_strings/basic_string/modifiers/assign/wchar_t/
192 move_assign_optim.cc: Likewise.
193
194 2019-01-03 Jonathan Wakely <jwakely@redhat.com>
195 Jakub Jelinek <jakub@redhat.com>
196
197 PR libstdc++/88607
198 * include/experimental/memory: Replace UTF-8 quote characters.
199 * include/std/future: Replace UTF-8 "em dash" characters.
200
201 2019-01-03 Jonathan Wakely <jwakely@redhat.com>
202
203 PR libstdc++/88607
204 * include/bits/forward_list.h: Replace UTF-8 "ligature fi" character.
205 * include/debug/forward_list: Likewise.
206 * include/experimental/bits/shared_ptr.h: Remove UTF-8 "section sign"
207 character.
208 * include/experimental/chrono: Likewise.
209 * include/experimental/functional: Likewise.
210 * include/experimental/ratio: Likewise.
211 * include/experimental/system_error: Likewise.
212 * include/experimental/tuple: Likewise.
213 * include/experimental/type_traits: Likewise.
214 * include/parallel/workstealing.h: Replace UTF-8 "en dash" character.
215 * include/parallel/multiseq_selection.h: Likewise.
216
217 PR libstdc++/88681
218 * config/abi/pre/gnu.ver: Add missing exports.
219 * testsuite/22_locale/collate_byname/88681.cc: New test.
220 * testsuite/22_locale/time_get/get/char/88681.cc: New test.
221 * testsuite/22_locale/time_get/get/wchar_t/88681.cc: New test.
222
223 2019-01-02 Jonathan Wakely <jwakely@redhat.com>
224
225 * testsuite/23_containers/map/cons/deduction.cc: Test deduction from
226 initializer_list<value_type> and from input iterator ranges.
227 * testsuite/23_containers/multimap/cons/deduction.cc: Likewise.
228
229 * testsuite/experimental/string_view/element_access/char/empty.cc:
230 Fix year range in copyright header.
231
232 2019-01-02 Joel Brobecker <brobecker@adacore.com>
233
234 * testsuite/21_strings/basic_string_view/element_access/char/empty.cc:
235 Fix year range in copyright header.
236
237 2019-01-01 Jakub Jelinek <jakub@redhat.com>
238
239 Update copyright years.
240 \f
241 Copyright (C) 2019 Free Software Foundation, Inc.
242
243 Copying and distribution of this file, with or without modification,
244 are permitted in any medium without royalty provided the copyright
245 notice and this notice are preserved.