30 #ifndef _GLIBCXX_EXPERIMENTAL_FS_PATH_H 31 #define _GLIBCXX_EXPERIMENTAL_FS_PATH_H 1 33 #if __cplusplus < 201103L 47 #if __cplusplus == 201402L 51 #if defined(_WIN32) && !defined(__CYGWIN__) 52 # define _GLIBCXX_FILESYSTEM_IS_WINDOWS 1 56 namespace std _GLIBCXX_VISIBILITY(default)
58 _GLIBCXX_BEGIN_NAMESPACE_VERSION
60 namespace experimental
66 _GLIBCXX_BEGIN_NAMESPACE_CXX11
68 #if __cplusplus == 201402L 69 using std::experimental::basic_string_view;
70 #elif __cplusplus > 201402L 71 using std::basic_string_view;
82 template<
typename _CharT>
85 template<
typename _Iter,
86 typename _Iter_traits = std::iterator_traits<_Iter>>
87 using __is_path_iter_src
88 = __and_<__is_encoded_char<typename _Iter_traits::value_type>,
90 typename _Iter_traits::iterator_category>>;
92 template<
typename _Iter>
93 static __is_path_iter_src<_Iter>
94 __is_path_src(_Iter,
int);
96 template<
typename _CharT,
typename _Traits,
typename _Alloc>
97 static __is_encoded_char<_CharT>
100 #if __cplusplus >= 201402L 101 template<
typename _CharT,
typename _Traits>
102 static __is_encoded_char<_CharT>
103 __is_path_src(
const basic_string_view<_CharT, _Traits>&,
int);
106 template<
typename _Unknown>
108 __is_path_src(
const _Unknown&, ...);
110 template<
typename _Tp1,
typename _Tp2>
111 struct __constructible_from;
113 template<
typename _Iter>
114 struct __constructible_from<_Iter, _Iter>
115 : __is_path_iter_src<_Iter>
118 template<
typename _Source>
119 struct __constructible_from<_Source, void>
120 : decltype(__is_path_src(std::declval<_Source>(), 0))
123 template<
typename _Tp1,
typename _Tp2 =
void>
124 using _Path =
typename 126 __constructible_from<_Tp1, _Tp2>>::value,
129 template<
typename _Source>
131 _S_range_begin(_Source __begin) {
return __begin; }
133 struct __null_terminated { };
135 template<
typename _Source>
136 static __null_terminated
137 _S_range_end(_Source) {
return {}; }
139 template<
typename _CharT,
typename _Traits,
typename _Alloc>
142 {
return __str.
data(); }
144 template<
typename _CharT,
typename _Traits,
typename _Alloc>
147 {
return __str.
data() + __str.
size(); }
149 #if __cplusplus >= 201402L 150 template<
typename _CharT,
typename _Traits>
152 _S_range_begin(
const basic_string_view<_CharT, _Traits>& __str)
153 {
return __str.data(); }
155 template<
typename _CharT,
typename _Traits>
157 _S_range_end(
const basic_string_view<_CharT, _Traits>& __str)
158 {
return __str.data() + __str.size(); }
161 template<
typename _Tp,
162 typename _Iter = decltype(_S_range_begin(std::declval<_Tp>())),
163 typename _Val =
typename std::iterator_traits<_Iter>::value_type>
164 using __value_type_is_char
168 #ifdef _GLIBCXX_FILESYSTEM_IS_WINDOWS 169 typedef wchar_t value_type;
170 static constexpr value_type preferred_separator = L
'\\';
172 typedef char value_type;
173 static constexpr value_type preferred_separator =
'/';
184 : _M_pathname(std::move(__p._M_pathname)), _M_type(__p._M_type)
191 : _M_pathname(std::move(__source))
192 { _M_split_cmpts(); }
194 template<
typename _Source,
195 typename _Require = _Path<_Source>>
196 path(_Source
const& __source)
197 : _M_pathname(_S_convert(_S_range_begin(__source),
198 _S_range_end(__source)))
199 { _M_split_cmpts(); }
201 template<
typename _InputIterator,
202 typename _Require = _Path<_InputIterator, _InputIterator>>
203 path(_InputIterator __first, _InputIterator __last)
204 : _M_pathname(_S_convert(__first, __last))
205 { _M_split_cmpts(); }
207 template<
typename _Source,
208 typename _Require = _Path<_Source>,
209 typename _Require2 = __value_type_is_char<_Source>>
210 path(_Source
const& __source,
const locale& __loc)
211 : _M_pathname(_S_convert_loc(_S_range_begin(__source),
212 _S_range_end(__source), __loc))
213 { _M_split_cmpts(); }
215 template<
typename _InputIterator,
216 typename _Require = _Path<_InputIterator, _InputIterator>,
217 typename _Require2 = __value_type_is_char<_InputIterator>>
218 path(_InputIterator __first, _InputIterator __last,
const locale& __loc)
219 : _M_pathname(_S_convert_loc(__first, __last, __loc))
220 { _M_split_cmpts(); }
226 path& operator=(
const path& __p) =
default;
227 path& operator=(
path&& __p) noexcept;
231 template<
typename _Source>
233 operator=(_Source
const& __source)
234 {
return *
this =
path(__source); }
236 template<
typename _Source>
238 assign(_Source
const& __source)
239 {
return *
this =
path(__source); }
241 template<
typename _InputIterator>
242 _Path<_InputIterator, _InputIterator>&
243 assign(_InputIterator __first, _InputIterator __last)
244 {
return *
this =
path(__first, __last); }
248 path& operator/=(
const path& __p) {
return _M_append(__p._M_pathname); }
250 template <
class _Source>
252 operator/=(_Source
const& __source)
253 {
return append(__source); }
255 template<
typename _Source>
257 append(_Source
const& __source)
259 return _M_append(_S_convert(_S_range_begin(__source),
260 _S_range_end(__source)));
263 template<
typename _InputIterator>
264 _Path<_InputIterator, _InputIterator>&
265 append(_InputIterator __first, _InputIterator __last)
266 {
return _M_append(_S_convert(__first, __last)); }
272 path& operator+=(
const value_type* __x);
273 path& operator+=(value_type __x);
274 #if __cplusplus >= 201402L 275 path& operator+=(basic_string_view<value_type> __x);
278 template<
typename _Source>
280 operator+=(_Source
const& __x) {
return concat(__x); }
282 template<
typename _CharT>
283 _Path<_CharT*, _CharT*>&
284 operator+=(_CharT __x);
286 template<
typename _Source>
288 concat(_Source
const& __x)
289 {
return *
this += _S_convert(_S_range_begin(__x), _S_range_end(__x)); }
291 template<
typename _InputIterator>
292 _Path<_InputIterator, _InputIterator>&
293 concat(_InputIterator __first, _InputIterator __last)
294 {
return *
this += _S_convert(__first, __last); }
298 void clear() noexcept { _M_pathname.
clear(); _M_split_cmpts(); }
300 path& make_preferred();
301 path& remove_filename();
302 path& replace_filename(
const path& __replacement);
303 path& replace_extension(
const path& __replacement =
path());
305 void swap(
path& __rhs) noexcept;
309 const string_type& native()
const noexcept {
return _M_pathname; }
310 const value_type* c_str()
const noexcept {
return _M_pathname.
c_str(); }
311 operator string_type()
const {
return _M_pathname; }
313 template<
typename _CharT,
typename _Traits = std::
char_traits<_CharT>,
314 typename _Allocator = std::allocator<_CharT>>
316 string(
const _Allocator& __a = _Allocator())
const;
319 #if _GLIBCXX_USE_WCHAR_T 327 template<
typename _CharT,
typename _Traits = std::
char_traits<_CharT>,
328 typename _Allocator = std::allocator<_CharT>>
330 generic_string(
const _Allocator& __a = _Allocator())
const;
333 #if _GLIBCXX_USE_WCHAR_T 342 int compare(
const path& __p)
const noexcept;
344 int compare(
const value_type* __s)
const;
345 #if __cplusplus >= 201402L 346 int compare(
const basic_string_view<value_type> __s)
const;
351 path root_name()
const;
352 path root_directory()
const;
353 path root_path()
const;
354 path relative_path()
const;
355 path parent_path()
const;
356 path filename()
const;
358 path extension()
const;
362 bool empty()
const noexcept {
return _M_pathname.
empty(); }
363 bool has_root_name()
const;
364 bool has_root_directory()
const;
365 bool has_root_path()
const;
366 bool has_relative_path()
const;
367 bool has_parent_path()
const;
368 bool has_filename()
const;
369 bool has_stem()
const;
370 bool has_extension()
const;
371 bool is_absolute()
const;
372 bool is_relative()
const {
return !is_absolute(); }
382 enum class _Type : unsigned char {
383 _Multi, _Root_name, _Root_dir, _Filename
386 path(
string_type __str, _Type __type) : _M_pathname(__str), _M_type(__type)
388 __glibcxx_assert(!empty());
389 __glibcxx_assert(_M_type != _Type::_Multi);
392 enum class _Split { _Stem, _Extension };
396 if (!_M_pathname.
empty() && !_S_is_dir_sep(_M_pathname.
back())
397 && !__str.
empty() && !_S_is_dir_sep(__str.
front()))
398 _M_pathname += preferred_separator;
399 _M_pathname += __str;
406 template<
typename _CharT>
410 _S_convert(value_type* __src, __null_terminated)
414 _S_convert(
const value_type* __src, __null_terminated)
417 template<
typename _Iter>
419 _S_convert(_Iter __first, _Iter __last)
421 using __value_type =
typename std::iterator_traits<_Iter>::value_type;
422 return _Cvt<typename remove_cv<__value_type>::type>::
423 _S_convert(__first, __last);
426 template<
typename _InputIterator>
428 _S_convert(_InputIterator __src, __null_terminated)
430 using _Tp =
typename std::iterator_traits<_InputIterator>::value_type;
432 for (; *__src != _Tp{}; ++__src)
438 _S_convert_loc(
const char* __first,
const char* __last,
441 template<
typename _Iter>
443 _S_convert_loc(_Iter __first, _Iter __last,
const std::locale& __loc)
446 return _S_convert_loc(__str.
data(), __str.
data()+__str.
size(), __loc);
449 template<
typename _InputIterator>
451 _S_convert_loc(_InputIterator __src, __null_terminated,
455 while (*__src !=
'\0')
457 return _S_convert_loc(__tmp.
data(), __tmp.
data()+__tmp.
size(), __loc);
460 bool _S_is_dir_sep(value_type __ch)
462 #ifdef _GLIBCXX_FILESYSTEM_IS_WINDOWS 463 return __ch == L
'/' || __ch == preferred_separator;
469 void _M_split_cmpts();
471 void _M_add_root_name(
size_t __n);
472 void _M_add_root_dir(
size_t __pos);
473 void _M_add_filename(
size_t __pos,
size_t __n);
478 using _List = _GLIBCXX_STD_C::vector<_Cmpt>;
480 _Type _M_type = _Type::_Multi;
483 inline void swap(
path& __lhs,
path& __rhs) noexcept { __lhs.swap(__rhs); }
485 size_t hash_value(
const path& __p) noexcept;
488 inline bool operator<(
const path& __lhs,
const path& __rhs) noexcept
489 {
return __lhs.compare(__rhs) < 0; }
492 inline bool operator<=(
const path& __lhs,
const path& __rhs) noexcept
493 {
return !(__rhs < __lhs); }
496 inline bool operator>(
const path& __lhs,
const path& __rhs) noexcept
497 {
return __rhs < __lhs; }
500 inline bool operator>=(
const path& __lhs,
const path& __rhs) noexcept
501 {
return !(__lhs < __rhs); }
504 inline bool operator==(
const path& __lhs,
const path& __rhs) noexcept
505 {
return __lhs.compare(__rhs) == 0; }
508 inline bool operator!=(
const path& __lhs,
const path& __rhs) noexcept
509 {
return !(__lhs == __rhs); }
513 {
return path(__lhs) /= __rhs; }
516 template<
typename _CharT,
typename _Traits>
518 operator<<(basic_ostream<_CharT, _Traits>& __os,
const path& __p)
520 auto __tmp = __p.string<_CharT, _Traits>();
521 using __quoted_string
523 __os << __quoted_string{__tmp,
'"',
'\\'};
528 template<
typename _CharT,
typename _Traits>
533 using __quoted_string
535 if (__is >> __quoted_string{ __tmp,
'"',
'\\' })
536 __p = std::move(__tmp);
541 template<
typename _Source>
545 #ifdef _GLIBCXX_FILESYSTEM_IS_WINDOWS 548 return path{ __source };
553 template<
typename _InputIterator>
555 u8path(_InputIterator __first, _InputIterator __last)
557 #ifdef _GLIBCXX_FILESYSTEM_IS_WINDOWS 560 return path{ __first, __last };
567 filesystem_error(
const string& __what_arg,
error_code __ec)
570 filesystem_error(
const string& __what_arg,
const path& __p1,
574 filesystem_error(
const string& __what_arg,
const path& __p1,
576 :
system_error(__ec, __what_arg), _M_path1(__p1), _M_path2(__p2)
581 const path& path1() const noexcept {
return _M_path1; }
582 const path& path2() const noexcept {
return _M_path2; }
583 const char* what() const noexcept {
return _M_what.c_str(); }
595 {
using value_type = char; };
599 {
using value_type = wchar_t; };
603 {
using value_type = char16_t; };
607 {
using value_type = char32_t; };
609 template<
typename _Tp>
610 struct path::__is_encoded_char<const _Tp> : __is_encoded_char<_Tp> { };
612 struct path::_Cmpt : path
614 _Cmpt(string_type __s, _Type __t,
size_t __pos)
615 : path(
std::move(__s), __t), _M_pos(__pos) { }
617 _Cmpt() : _M_pos(-1) { }
624 struct path::_Cvt<path::value_type>
626 template<
typename _Iter>
628 _S_convert(_Iter __first, _Iter __last)
629 {
return string_type{__first, __last}; }
632 template<
typename _CharT>
635 #ifdef _GLIBCXX_FILESYSTEM_IS_WINDOWS 637 _S_wconvert(
const char* __f,
const char* __l,
true_type)
640 const auto& __cvt = std::use_facet<_Cvt>(
std::locale{});
642 if (__str_codecvt_in(__f, __l, __wstr, __cvt))
644 _GLIBCXX_THROW_OR_ABORT(filesystem_error(
645 "Cannot convert character sequence",
646 std::make_error_code(errc::illegal_byte_sequence)));
650 _S_wconvert(
const _CharT* __f,
const _CharT* __l,
false_type)
652 std::codecvt_utf8<_CharT> __cvt;
654 if (__str_codecvt_out(__f, __l, __str, __cvt))
656 const char* __f2 = __str.
data();
657 const char* __l2 = __f2 + __str.
size();
658 std::codecvt_utf8<wchar_t> __wcvt;
660 if (__str_codecvt_in(__f2, __l2, __wstr, __wcvt))
663 _GLIBCXX_THROW_OR_ABORT(filesystem_error(
664 "Cannot convert character sequence",
665 std::make_error_code(errc::illegal_byte_sequence)));
669 _S_convert(
const _CharT* __f,
const _CharT* __l)
671 return _S_wconvert(__f, __l, is_same<_CharT, char>{});
675 _S_convert(
const _CharT* __f,
const _CharT* __l)
677 std::codecvt_utf8<_CharT> __cvt;
679 if (__str_codecvt_out(__f, __l, __str, __cvt))
681 _GLIBCXX_THROW_OR_ABORT(filesystem_error(
682 "Cannot convert character sequence",
683 std::make_error_code(errc::illegal_byte_sequence)));
688 _S_convert(_CharT* __f, _CharT* __l)
690 return _S_convert(const_cast<const _CharT*>(__f),
691 const_cast<const _CharT*>(__l));
694 template<
typename _Iter>
696 _S_convert(_Iter __first, _Iter __last)
699 return _S_convert(__str.
data(), __str.
data() + __str.
size());
702 template<
typename _Iter,
typename _Cont>
704 _S_convert(__gnu_cxx::__normal_iterator<_Iter, _Cont> __first,
705 __gnu_cxx::__normal_iterator<_Iter, _Cont> __last)
706 {
return _S_convert(__first.base(), __last.base()); }
713 using difference_type = std::ptrdiff_t;
719 iterator() : _M_path(
nullptr), _M_cur(), _M_at_end() { }
728 iterator operator++(
int) {
auto __tmp = *
this; ++*
this;
return __tmp; }
731 iterator operator--(
int) {
auto __tmp = *
this; --*
this;
return __tmp; }
734 {
return __lhs._M_equals(__rhs); }
737 {
return !__lhs._M_equals(__rhs); }
742 iterator(
const path* __path, path::_List::const_iterator __iter)
743 : _M_path(__path), _M_cur(__iter), _M_at_end()
747 : _M_path(__path), _M_cur(), _M_at_end(__at_end)
753 path::_List::const_iterator _M_cur;
759 path::operator=(
path&& __p) noexcept
761 _M_pathname = std::move(__p._M_pathname);
762 _M_cmpts = std::move(__p._M_cmpts);
763 _M_type = __p._M_type;
769 path::operator=(string_type&& __source)
770 {
return *
this =
path(std::move(__source)); }
773 path::assign(string_type&& __source)
774 {
return *
this = path(std::move(__source)); }
777 path::operator+=(
const path& __p)
779 return operator+=(__p.native());
783 path::operator+=(
const string_type& __x)
791 path::operator+=(
const value_type* __x)
799 path::operator+=(value_type __x)
806 #if __cplusplus >= 201402L 808 path::operator+=(basic_string_view<value_type> __x)
810 _M_pathname.
append(__x.data(), __x.size());
816 template<
typename _CharT>
817 inline path::_Path<_CharT*, _CharT*>&
818 path::operator+=(_CharT __x)
821 return concat(__addr, __addr + 1);
825 path::make_preferred()
827 #ifdef _GLIBCXX_FILESYSTEM_IS_WINDOWS 829 preferred_separator);
834 inline void path::swap(path& __rhs) noexcept
836 _M_pathname.swap(__rhs._M_pathname);
837 _M_cmpts.swap(__rhs._M_cmpts);
838 std::swap(_M_type, __rhs._M_type);
841 template<
typename _CharT,
typename _Traits,
typename _Allocator>
845 if (is_same<_CharT, value_type>::value)
846 return { _M_pathname.
begin(), _M_pathname.
end(), __a };
848 const value_type* __first = _M_pathname.
data();
849 const value_type* __last = __first + _M_pathname.
size();
851 #ifdef _GLIBCXX_FILESYSTEM_IS_WINDOWS 852 using _CharAlloc = __alloc_rebind<_Allocator, char>;
853 using _String = basic_string<char, char_traits<char>, _CharAlloc>;
854 using _WString = basic_string<_CharT, _Traits, _Allocator>;
857 codecvt_utf8<value_type> __cvt;
858 _String __u8str{_CharAlloc{__a}};
859 if (__str_codecvt_out(__first, __last, __u8str, __cvt))
864 operator()(
const _String& __from, _String&,
true_type)
868 operator()(
const _String& __from, _WString& __to,
false_type)
871 codecvt_utf8<_CharT> __cvt;
872 const char* __f = __from.data();
873 const char* __l = __f + __from.size();
874 if (__str_codecvt_in(__f, __l, __to, __cvt))
880 if (
auto* __p = __dispatch(__u8str, __wstr, is_same<_CharT, char>{}))
884 codecvt_utf8<_CharT> __cvt;
885 basic_string<_CharT, _Traits, _Allocator> __wstr{__a};
886 if (__str_codecvt_in(__first, __last, __wstr, __cvt))
889 _GLIBCXX_THROW_OR_ABORT(filesystem_error(
890 "Cannot convert character sequence",
891 std::make_error_code(errc::illegal_byte_sequence)));
897 #if _GLIBCXX_USE_WCHAR_T 903 path::u8string()
const 905 #ifdef _GLIBCXX_FILESYSTEM_IS_WINDOWS 908 codecvt_utf8<value_type> __cvt;
909 const value_type* __first = _M_pathname.
data();
910 const value_type* __last = __first + _M_pathname.
size();
911 if (__str_codecvt_out(__first, __last, __str, __cvt))
913 _GLIBCXX_THROW_OR_ABORT(filesystem_error(
914 "Cannot convert character sequence",
915 std::make_error_code(errc::illegal_byte_sequence)));
927 #ifndef _GLIBCXX_FILESYSTEM_IS_WINDOWS 928 template<
typename _CharT,
typename _Traits,
typename _Allocator>
930 path::generic_string(
const _Allocator& __a)
const 931 {
return string<_CharT, _Traits, _Allocator>(__a); }
934 path::generic_string()
const {
return string(); }
936 #if _GLIBCXX_USE_WCHAR_T 938 path::generic_wstring()
const {
return wstring(); }
942 path::generic_u8string()
const {
return u8string(); }
945 path::generic_u16string()
const {
return u16string(); }
948 path::generic_u32string()
const {
return u32string(); }
952 path::compare(
const string_type& __s)
const {
return compare(path(__s)); }
955 path::compare(
const value_type* __s)
const {
return compare(path(__s)); }
957 #if __cplusplus >= 201402L 959 path::compare(basic_string_view<value_type> __s)
const 960 {
return compare(path(__s)); }
964 path::filename()
const {
return empty() ? path() : *--
end(); }
969 auto ext = _M_find_extension();
970 if (ext.first && ext.second != 0)
971 return path{ext.first->substr(0, ext.second)};
976 path::extension()
const 978 auto ext = _M_find_extension();
980 return path{ext.first->substr(ext.second)};
985 path::has_stem()
const 987 auto ext = _M_find_extension();
988 return ext.first && ext.second != 0;
992 path::has_extension()
const 994 auto ext = _M_find_extension();
999 path::is_absolute()
const 1001 #ifdef _GLIBCXX_FILESYSTEM_IS_WINDOWS 1002 return has_root_name();
1004 return has_root_directory();
1008 inline path::iterator
1011 if (_M_type == _Type::_Multi)
1012 return iterator(
this, _M_cmpts.
begin());
1013 return iterator(
this,
false);
1016 inline path::iterator
1019 if (_M_type == _Type::_Multi)
1020 return iterator(
this, _M_cmpts.
end());
1021 return iterator(
this,
true);
1024 inline path::iterator&
1025 path::iterator::operator++()
1027 __glibcxx_assert(_M_path !=
nullptr);
1028 if (_M_path->_M_type == _Type::_Multi)
1030 __glibcxx_assert(_M_cur != _M_path->_M_cmpts.
end());
1035 __glibcxx_assert(!_M_at_end);
1041 inline path::iterator&
1042 path::iterator::operator--()
1044 __glibcxx_assert(_M_path !=
nullptr);
1045 if (_M_path->_M_type == _Type::_Multi)
1047 __glibcxx_assert(_M_cur != _M_path->_M_cmpts.begin());
1052 __glibcxx_assert(_M_at_end);
1058 inline path::iterator::reference
1059 path::iterator::operator*()
const 1061 __glibcxx_assert(_M_path !=
nullptr);
1062 if (_M_path->_M_type == _Type::_Multi)
1064 __glibcxx_assert(_M_cur != _M_path->_M_cmpts.end());
1071 path::iterator::_M_equals(iterator __rhs)
const 1073 if (_M_path != __rhs._M_path)
1075 if (_M_path ==
nullptr)
1077 if (_M_path->_M_type == path::_Type::_Multi)
1078 return _M_cur == __rhs._M_cur;
1079 return _M_at_end == __rhs._M_at_end;
1083 _GLIBCXX_END_NAMESPACE_CXX11
1088 _GLIBCXX_END_NAMESPACE_VERSION
1093 #endif // _GLIBCXX_EXPERIMENTAL_FS_PATH_H
basic_string & append(const basic_string &__str)
Append a string to this string.
An iterator for the components of a path.
iterator begin() noexcept
size_type size() const noexcept
Returns the number of characters in the string, not including any null-termination.
basic_string< char32_t > u32string
A string of char32_t.
Define a member typedef type only if a boolean constant is true.
Thrown to indicate error code of underlying system.
constexpr const _Tp * end(initializer_list< _Tp > __ils) noexcept
Return an iterator pointing to one past the last element of the initializer_list. ...
basic_string< char > string
A string of char.
integral_constant< bool, false > false_type
The type used as a compile-time boolean with false value.
constexpr const _Tp * begin(initializer_list< _Tp > __ils) noexcept
Return an iterator pointing to the first element of the initializer_list.
Template class basic_istream.
void replace(_ForwardIterator __first, _ForwardIterator __last, const _Tp &__old_value, const _Tp &__new_value)
Replace each occurrence of one value in a sequence with another value.
Managing sequences of characters and character-like objects.
void push_back(_CharT __c)
Append a single character.
const _CharT * data() const noexcept
Return const pointer to contents.
constexpr _Tp * __addressof(_Tp &__r) noexcept
Same as C++11 std::addressof.
basic_string< char16_t > u16string
A string of char16_t.
Class codecvt<wchar_t, char, mbstate_t> specialization.
integral_constant< bool, true > true_type
The type used as a compile-time boolean with true value.
ISO C++ entities toplevel namespace is std.
Bidirectional iterators support a superset of forward iterator operations.
path u8path(const _Source &__source)
Compare paths.
std::basic_istream< _CharT, _Traits > & operator>>(std::basic_istream< _CharT, _Traits > &__is, bitset< _Nb > &__x)
Global I/O operators for bitsets.
Struct for delimited strings.
complex< _Tp > operator/(const complex< _Tp > &__x, const complex< _Tp > &__y)
Return new complex value x divided by y.
basic_string< wchar_t > wstring
A string of wchar_t.
Container class for localization functionality.The locale class is first a class wrapper for C librar...
Struct holding two objects of arbitrary type.
const _CharT * c_str() const noexcept
Return const pointer to null-terminated contents.
bool empty() const noexcept
static const size_type npos
Value returned by various member functions when they fail.
Template class basic_ostream.