32#pragma GCC system_header
36#if __cplusplus >= 201103L
45namespace __gnu_cxx _GLIBCXX_VISIBILITY(default)
47_GLIBCXX_BEGIN_NAMESPACE_VERSION
57 template<
typename _CharT,
typename _Traits,
typename _Alloc,
58 template <
typename,
typename,
typename>
class _Base>
60 :
private _Base<_CharT, _Traits, _Alloc>
62 typedef _Base<_CharT, _Traits, _Alloc> __vstring_base;
63 typedef typename __vstring_base::_CharT_alloc_type _CharT_alloc_type;
68 typedef _Traits traits_type;
69 typedef typename _Traits::char_type value_type;
70 typedef _Alloc allocator_type;
71 typedef typename _CharT_alloc_type::size_type size_type;
72 typedef typename _CharT_alloc_type::difference_type difference_type;
73 typedef value_type& reference;
74 typedef const value_type& const_reference;
75 typedef typename _CharT_alloc_traits::pointer pointer;
76 typedef typename _CharT_alloc_traits::const_pointer const_pointer;
77 typedef __gnu_cxx::__normal_iterator<pointer, __versa_string> iterator;
78 typedef __gnu_cxx::__normal_iterator<const_pointer, __versa_string>
85 static const size_type
npos =
static_cast<size_type
>(-1);
89 _M_check(size_type __pos,
const char* __s)
const
91 if (__pos > this->
size())
92 std::__throw_out_of_range_fmt(__N(
"%s: __pos (which is %zu) > "
93 "this->size() (which is %zu)"),
94 __s, __pos, this->
size());
99 _M_check_length(size_type __n1, size_type __n2,
const char* __s)
const
102 std::__throw_length_error(__N(__s));
107 _M_limit(size_type __pos, size_type __off)
const _GLIBCXX_NOEXCEPT
109 const bool __testoff = __off < this->
size() - __pos;
110 return __testoff ? __off : this->
size() - __pos;
115 _M_disjunct(
const _CharT* __s)
const _GLIBCXX_NOEXCEPT
119 + this->
size(), __s));
125 _M_ibegin() const _GLIBCXX_NOEXCEPT
126 {
return iterator(this->_M_data()); }
129 _M_iend() const _GLIBCXX_NOEXCEPT
130 {
return iterator(this->_M_data() + this->_M_length()); }
142 : __vstring_base(__a) { }
150 : __vstring_base(__str) { }
152#if __cplusplus >= 201103L
170 const _Alloc& __a = _Alloc())
171 : __vstring_base(__l.
begin(), __l.
end(), __a) { }
181 size_type __n =
npos)
182 : __vstring_base(__str._M_data()
183 + __str._M_check(__pos,
184 "__versa_string::__versa_string"),
185 __str._M_data() + __str._M_limit(__pos, __n)
186 + __pos, _Alloc()) { }
196 size_type __n,
const _Alloc& __a)
197 : __vstring_base(__str._M_data()
198 + __str._M_check(__pos,
199 "__versa_string::__versa_string"),
200 __str._M_data() + __str._M_limit(__pos, __n)
213 const _Alloc& __a = _Alloc())
214 : __vstring_base(__s, __s + __n, __a) { }
222 : __vstring_base(__s, __s ? __s + traits_type::
length(__s) :
232 : __vstring_base(__n, __c, __a) { }
240#if __cplusplus >= 201103L
241 template<
class _InputIterator,
242 typename = std::_RequireInputIter<_InputIterator>>
244 template<
class _InputIterator>
247 const _Alloc& __a = _Alloc())
248 : __vstring_base(__beg, __end, __a) { }
261 {
return this->
assign(__str); }
263#if __cplusplus >= 201103L
286 this->
assign(__l.begin(), __l.end());
297 {
return this->
assign(__s); }
322 return iterator(this->_M_data());
331 {
return const_iterator(this->_M_data()); }
341 return iterator(this->_M_data() + this->
size());
349 end() const _GLIBCXX_NOEXCEPT
350 {
return const_iterator(this->_M_data() + this->
size()); }
366 const_reverse_iterator
384 const_reverse_iterator
388#if __cplusplus >= 201103L
395 {
return const_iterator(this->_M_data()); }
403 {
return const_iterator(this->_M_data() + this->
size()); }
410 const_reverse_iterator
419 const_reverse_iterator
430 {
return this->_M_length(); }
436 {
return this->_M_length(); }
441 {
return this->_M_max_size(); }
454 resize(size_type __n, _CharT __c);
468 { this->
resize(__n, _CharT()); }
470#if __cplusplus >= 201103L
491 {
return this->_M_capacity(); }
512 { this->_M_reserve(__res_arg); }
519 { this->_M_clear(); }
525 _GLIBCXX_NODISCARD
bool
527 {
return this->
size() == 0; }
543 __glibcxx_assert(__pos <= this->
size());
544 return this->_M_data()[__pos];
562 __glibcxx_assert(__pos <= this->
size());
564 _GLIBCXX_DEBUG_PEDASSERT(__cplusplus >= 201103L
565 || __pos < this->
size());
567 return this->_M_data()[__pos];
581 at(size_type __n)
const
583 if (__n >= this->
size())
584 std::__throw_out_of_range_fmt(__N(
"__versa_string::at: __n "
585 "(which is %zu) >= this->size() "
588 return this->_M_data()[__n];
605 if (__n >= this->
size())
606 std::__throw_out_of_range_fmt(__N(
"__versa_string::at: __n "
607 "(which is %zu) >= this->size() "
611 return this->_M_data()[__n];
614#if __cplusplus >= 201103L
656 {
return this->
append(__str); }
665 {
return this->
append(__s); }
679#if __cplusplus >= 201103L
687 {
return this->
append(__l.begin(), __l.end()); }
697 {
return _M_append(__str._M_data(), __str.
size()); }
714 {
return _M_append(__str._M_data()
715 + __str._M_check(__pos,
"__versa_string::append"),
716 __str._M_limit(__pos, __n)); }
727 __glibcxx_requires_string_len(__s, __n);
728 _M_check_length(size_type(0), __n,
"__versa_string::append");
729 return _M_append(__s, __n);
740 __glibcxx_requires_string(__s);
741 const size_type __n = traits_type::length(__s);
742 _M_check_length(size_type(0), __n,
"__versa_string::append");
743 return _M_append(__s, __n);
756 {
return _M_replace_aux(this->
size(), size_type(0), __n, __c); }
758#if __cplusplus >= 201103L
766 {
return this->
append(__l.begin(), __l.end()); }
777#if __cplusplus >= 201103L
778 template<
class _InputIterator,
779 typename = std::_RequireInputIter<_InputIterator>>
781 template<
class _InputIterator>
784 append(_InputIterator __first, _InputIterator __last)
785 {
return this->
replace(_M_iend(), _M_iend(), __first, __last); }
794 const size_type __size = this->
size();
795 if (__size + 1 > this->
capacity() || this->_M_is_shared())
796 this->_M_mutate(__size, size_type(0), 0, size_type(1));
797 traits_type::assign(this->_M_data()[__size], __c);
798 this->_M_set_length(__size + 1);
809 this->_M_assign(__str);
813#if __cplusplus >= 201103L
845 {
return _M_replace(size_type(0), this->
size(), __str._M_data()
846 + __str._M_check(__pos,
"__versa_string::assign"),
847 __str._M_limit(__pos, __n)); }
863 __glibcxx_requires_string_len(__s, __n);
864 return _M_replace(size_type(0), this->
size(), __s, __n);
879 __glibcxx_requires_string(__s);
880 return _M_replace(size_type(0), this->
size(), __s,
881 traits_type::length(__s));
895 {
return _M_replace_aux(size_type(0), this->
size(), __n, __c); }
906#if __cplusplus >= 201103L
907 template<
class _InputIterator,
908 typename = std::_RequireInputIter<_InputIterator>>
910 template<
class _InputIterator>
913 assign(_InputIterator __first, _InputIterator __last)
914 {
return this->
replace(_M_ibegin(), _M_iend(), __first, __last); }
916#if __cplusplus >= 201103L
924 {
return this->
assign(__l.begin(), __l.end()); }
927#if __cplusplus >= 201103L
944 insert(const_iterator __p, size_type __n, _CharT __c)
946 _GLIBCXX_DEBUG_PEDASSERT(__p >= _M_ibegin() && __p <= _M_iend());
947 const size_type __pos = __p - _M_ibegin();
948 this->
replace(__p, __p, __n, __c);
949 return iterator(this->_M_data() + __pos);
966 insert(iterator __p, size_type __n, _CharT __c)
967 { this->
replace(__p, __p, __n, __c); }
970#if __cplusplus >= 201103L
985 template<
class _InputIterator,
986 typename = std::_RequireInputIter<_InputIterator>>
988 insert(const_iterator __p, _InputIterator __beg, _InputIterator __end)
990 _GLIBCXX_DEBUG_PEDASSERT(__p >= _M_ibegin() && __p <= _M_iend());
991 const size_type __pos = __p - _M_ibegin();
992 this->
replace(__p, __p, __beg, __end);
993 return iterator(this->_M_data() + __pos);
1008 template<
class _InputIterator>
1010 insert(iterator __p, _InputIterator __beg, _InputIterator __end)
1011 { this->
replace(__p, __p, __beg, __end); }
1014#if __cplusplus >= 201103L
1025 {
return this->
insert(__p, __l.begin(), __l.end()); }
1042 {
return this->
replace(__pos1, size_type(0),
1043 __str._M_data(), __str.
size()); }
1065 size_type __pos2, size_type __n)
1066 {
return this->
replace(__pos1, size_type(0), __str._M_data()
1067 + __str._M_check(__pos2,
"__versa_string::insert"),
1068 __str._M_limit(__pos2, __n)); }
1087 insert(size_type __pos,
const _CharT* __s, size_type __n)
1088 {
return this->
replace(__pos, size_type(0), __s, __n); }
1108 __glibcxx_requires_string(__s);
1109 return this->
replace(__pos, size_type(0), __s,
1110 traits_type::length(__s));
1130 insert(size_type __pos, size_type __n, _CharT __c)
1131 {
return _M_replace_aux(_M_check(__pos,
"__versa_string::insert"),
1132 size_type(0), __n, __c); }
1148#if __cplusplus >= 201103L
1151 insert(iterator __p, _CharT __c)
1154 _GLIBCXX_DEBUG_PEDASSERT(__p >= _M_ibegin() && __p <= _M_iend());
1155 const size_type __pos = __p - _M_ibegin();
1156 _M_replace_aux(__pos, size_type(0), size_type(1), __c);
1157 this->_M_set_leaked();
1158 return iterator(this->_M_data() + __pos);
1179 this->_M_erase(_M_check(__pos,
"__versa_string::erase"),
1180 _M_limit(__pos, __n));
1193#if __cplusplus >= 201103L
1196 erase(iterator __position)
1199 _GLIBCXX_DEBUG_PEDASSERT(__position >= _M_ibegin()
1200 && __position < _M_iend());
1201 const size_type __pos = __position - _M_ibegin();
1202 this->_M_erase(__pos, size_type(1));
1203 this->_M_set_leaked();
1204 return iterator(this->_M_data() + __pos);
1218#if __cplusplus >= 201103L
1219 erase(const_iterator __first, const_iterator __last)
1221 erase(iterator __first, iterator __last)
1224 _GLIBCXX_DEBUG_PEDASSERT(__first >= _M_ibegin() && __first <= __last
1225 && __last <= _M_iend());
1226 const size_type __pos = __first - _M_ibegin();
1227 this->_M_erase(__pos, __last - __first);
1228 this->_M_set_leaked();
1229 return iterator(this->_M_data() + __pos);
1232#if __cplusplus >= 201103L
1240 { this->_M_erase(
size()-1, 1); }
1262 {
return this->
replace(__pos, __n, __str._M_data(), __str.
size()); }
1285 size_type __pos2, size_type __n2)
1287 return this->
replace(__pos1, __n1, __str._M_data()
1288 + __str._M_check(__pos2,
1289 "__versa_string::replace"),
1290 __str._M_limit(__pos2, __n2));
1312 replace(size_type __pos, size_type __n1,
const _CharT* __s,
1315 __glibcxx_requires_string_len(__s, __n2);
1316 return _M_replace(_M_check(__pos,
"__versa_string::replace"),
1317 _M_limit(__pos, __n1), __s, __n2);
1336 replace(size_type __pos, size_type __n1,
const _CharT* __s)
1338 __glibcxx_requires_string(__s);
1339 return this->
replace(__pos, __n1, __s, traits_type::length(__s));
1360 replace(size_type __pos, size_type __n1, size_type __n2, _CharT __c)
1361 {
return _M_replace_aux(_M_check(__pos,
"__versa_string::replace"),
1362 _M_limit(__pos, __n1), __n2, __c); }
1378#if __cplusplus >= 201103L
1384 {
return this->
replace(__i1, __i2, __str._M_data(), __str.
size()); }
1401#if __cplusplus >= 201103L
1403 const _CharT* __s, size_type __n)
1405 replace(iterator __i1, iterator __i2,
const _CharT* __s, size_type __n)
1408 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1409 && __i2 <= _M_iend());
1410 return this->
replace(__i1 - _M_ibegin(), __i2 - __i1, __s, __n);
1427#if __cplusplus >= 201103L
1428 replace(const_iterator __i1, const_iterator __i2,
const _CharT* __s)
1430 replace(iterator __i1, iterator __i2,
const _CharT* __s)
1433 __glibcxx_requires_string(__s);
1434 return this->
replace(__i1, __i2, __s, traits_type::length(__s));
1452#if __cplusplus >= 201103L
1453 replace(const_iterator __i1, const_iterator __i2, size_type __n,
1456 replace(iterator __i1, iterator __i2, size_type __n, _CharT __c)
1459 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1460 && __i2 <= _M_iend());
1461 return _M_replace_aux(__i1 - _M_ibegin(), __i2 - __i1, __n, __c);
1478#if __cplusplus >= 201103L
1479 template<
class _InputIterator,
1480 typename = std::_RequireInputIter<_InputIterator>>
1483 _InputIterator __k1, _InputIterator __k2)
1485 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1486 && __i2 <= _M_iend());
1487 __glibcxx_requires_valid_range(__k1, __k2);
1488 return this->_M_replace_dispatch(__i1, __i2, __k1, __k2,
1489 std::__false_type());
1492 template<
class _InputIterator>
1494 replace(iterator __i1, iterator __i2,
1495 _InputIterator __k1, _InputIterator __k2)
1497 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1498 && __i2 <= _M_iend());
1499 __glibcxx_requires_valid_range(__k1, __k2);
1500 typedef typename std::__is_integer<_InputIterator>::__type _Integral;
1501 return this->_M_replace_dispatch(__i1, __i2, __k1, __k2, _Integral());
1508#if __cplusplus >= 201103L
1509 replace(const_iterator __i1, const_iterator __i2,
1510 _CharT* __k1, _CharT* __k2)
1512 replace(iterator __i1, iterator __i2,
1513 _CharT* __k1, _CharT* __k2)
1516 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1517 && __i2 <= _M_iend());
1518 __glibcxx_requires_valid_range(__k1, __k2);
1519 return this->
replace(__i1 - _M_ibegin(), __i2 - __i1,
1524#if __cplusplus >= 201103L
1525 replace(const_iterator __i1, const_iterator __i2,
1526 const _CharT* __k1,
const _CharT* __k2)
1528 replace(iterator __i1, iterator __i2,
1529 const _CharT* __k1,
const _CharT* __k2)
1532 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1533 && __i2 <= _M_iend());
1534 __glibcxx_requires_valid_range(__k1, __k2);
1535 return this->
replace(__i1 - _M_ibegin(), __i2 - __i1,
1540#if __cplusplus >= 201103L
1541 replace(const_iterator __i1, const_iterator __i2,
1542 iterator __k1, iterator __k2)
1544 replace(iterator __i1, iterator __i2,
1545 iterator __k1, iterator __k2)
1548 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1549 && __i2 <= _M_iend());
1550 __glibcxx_requires_valid_range(__k1, __k2);
1551 return this->
replace(__i1 - _M_ibegin(), __i2 - __i1,
1552 __k1.base(), __k2 - __k1);
1556#if __cplusplus >= 201103L
1557 replace(const_iterator __i1, const_iterator __i2,
1558 const_iterator __k1, const_iterator __k2)
1560 replace(iterator __i1, iterator __i2,
1561 const_iterator __k1, const_iterator __k2)
1564 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1565 && __i2 <= _M_iend());
1566 __glibcxx_requires_valid_range(__k1, __k2);
1567 return this->
replace(__i1 - _M_ibegin(), __i2 - __i1,
1568 __k1.base(), __k2 - __k1);
1571#if __cplusplus >= 201103L
1588 {
return this->
replace(__i1, __i2, __l.begin(), __l.end()); }
1592 template<
class _Integer>
1594 _M_replace_dispatch(const_iterator __i1, const_iterator __i2,
1595 _Integer __n, _Integer __val, std::__true_type)
1596 {
return _M_replace_aux(__i1 - _M_ibegin(), __i2 - __i1, __n, __val); }
1598 template<
class _InputIterator>
1600 _M_replace_dispatch(const_iterator __i1, const_iterator __i2,
1601 _InputIterator __k1, _InputIterator __k2,
1605 _M_replace_aux(size_type __pos1, size_type __n1, size_type __n2,
1609 _M_replace(size_type __pos, size_type __len1,
const _CharT* __s,
1610 const size_type __len2);
1613 _M_append(
const _CharT* __s, size_type __n);
1630 copy(_CharT* __s, size_type __n, size_type __pos = 0)
const;
1641 { this->_M_swap(__s); }
1652 {
return this->_M_data(); }
1662 {
return this->_M_data(); }
1669 {
return allocator_type(this->_M_get_allocator()); }
1684 find(
const _CharT* __s, size_type __pos, size_type __n)
const;
1699 {
return this->
find(__str.
data(), __pos, __str.
size()); }
1712 find(
const _CharT* __s, size_type __pos = 0)
const
1714 __glibcxx_requires_string(__s);
1715 return this->
find(__s, __pos, traits_type::length(__s));
1729 find(_CharT __c, size_type __pos = 0) const _GLIBCXX_NOEXCEPT;
1744 {
return this->
rfind(__str.data(), __pos, __str.size()); }
1759 rfind(
const _CharT* __s, size_type __pos, size_type __n)
const;
1774 __glibcxx_requires_string(__s);
1775 return this->
rfind(__s, __pos, traits_type::length(__s));
1789 rfind(_CharT __c, size_type __pos =
npos)
const _GLIBCXX_NOEXCEPT;
1819 find_first_of(
const _CharT* __s, size_type __pos, size_type __n)
const;
1834 __glibcxx_requires_string(__s);
1835 return this->
find_first_of(__s, __pos, traits_type::length(__s));
1852 {
return this->
find(__c, __pos); }
1883 find_last_of(
const _CharT* __s, size_type __pos, size_type __n)
const;
1898 __glibcxx_requires_string(__s);
1899 return this->
find_last_of(__s, __pos, traits_type::length(__s));
1916 {
return this->
rfind(__c, __pos); }
1947 size_type __n)
const;
1962 __glibcxx_requires_string(__s);
1993 size_type __pos =
npos) const _GLIBCXX_NOEXCEPT
2010 size_type __n)
const;
2025 __glibcxx_requires_string(__s);
2058 return __versa_string(*
this, _M_check(__pos,
"__versa_string::substr"),
2079 if (this->_M_compare(__str))
2082 const size_type __size = this->
size();
2083 const size_type __osize = __str.
size();
2084 const size_type __len =
std::min(__size, __osize);
2086 int __r = traits_type::compare(this->_M_data(), __str.
data(), __len);
2088 __r = this->_S_compare(__size, __osize);
2112 compare(size_type __pos, size_type __n,
2139 compare(size_type __pos1, size_type __n1,
const __versa_string& __str,
2140 size_type __pos2, size_type __n2)
const;
2158 compare(
const _CharT* __s)
const;
2182 compare(size_type __pos, size_type __n1,
const _CharT* __s)
const;
2209 compare(size_type __pos, size_type __n1,
const _CharT* __s,
2210 size_type __n2)
const;
2220 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2221 template <
typename,
typename,
typename>
class _Base>
2222 __versa_string<_CharT, _Traits, _Alloc, _Base>
2223 operator+(
const __versa_string<_CharT, _Traits, _Alloc, _Base>& __lhs,
2224 const __versa_string<_CharT, _Traits, _Alloc, _Base>& __rhs);
2232 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2233 template <
typename,
typename,
typename>
class _Base>
2234 __versa_string<_CharT, _Traits, _Alloc, _Base>
2235 operator+(
const _CharT* __lhs,
2236 const __versa_string<_CharT, _Traits, _Alloc, _Base>& __rhs);
2244 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2245 template <
typename,
typename,
typename>
class _Base>
2246 __versa_string<_CharT, _Traits, _Alloc, _Base>
2247 operator+(_CharT __lhs,
2248 const __versa_string<_CharT, _Traits, _Alloc, _Base>& __rhs);
2256 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2257 template <
typename,
typename,
typename>
class _Base>
2258 __versa_string<_CharT, _Traits, _Alloc, _Base>
2259 operator+(
const __versa_string<_CharT, _Traits, _Alloc, _Base>& __lhs,
2260 const _CharT* __rhs);
2268 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2269 template <
typename,
typename,
typename>
class _Base>
2270 __versa_string<_CharT, _Traits, _Alloc, _Base>
2271 operator+(
const __versa_string<_CharT, _Traits, _Alloc, _Base>& __lhs,
2274#if __cplusplus >= 201103L
2275 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2276 template <
typename,
typename,
typename>
class _Base>
2277 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2278 operator+(__versa_string<_CharT, _Traits, _Alloc, _Base>&& __lhs,
2279 const __versa_string<_CharT, _Traits, _Alloc, _Base>& __rhs)
2280 {
return std::move(__lhs.append(__rhs)); }
2282 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2283 template <
typename,
typename,
typename>
class _Base>
2284 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2285 operator+(
const __versa_string<_CharT, _Traits, _Alloc, _Base>& __lhs,
2286 __versa_string<_CharT, _Traits, _Alloc, _Base>&& __rhs)
2287 {
return std::move(__rhs.insert(0, __lhs)); }
2289 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2290 template <
typename,
typename,
typename>
class _Base>
2291 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2292 operator+(__versa_string<_CharT, _Traits, _Alloc, _Base>&& __lhs,
2293 __versa_string<_CharT, _Traits, _Alloc, _Base>&& __rhs)
2295 const auto __size = __lhs.size() + __rhs.size();
2296 const bool __cond = (__size > __lhs.capacity()
2297 && __size <= __rhs.capacity());
2298 return __cond ?
std::move(__rhs.insert(0, __lhs))
2299 :
std::move(__lhs.append(__rhs));
2302 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2303 template <
typename,
typename,
typename>
class _Base>
2304 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2306 __versa_string<_CharT, _Traits, _Alloc, _Base>&& __rhs)
2307 {
return std::move(__rhs.insert(0, __lhs)); }
2309 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2310 template <
typename,
typename,
typename>
class _Base>
2311 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2313 __versa_string<_CharT, _Traits, _Alloc, _Base>&& __rhs)
2314 {
return std::move(__rhs.insert(0, 1, __lhs)); }
2316 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2317 template <
typename,
typename,
typename>
class _Base>
2318 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2319 operator+(__versa_string<_CharT, _Traits, _Alloc, _Base>&& __lhs,
2320 const _CharT* __rhs)
2321 {
return std::move(__lhs.append(__rhs)); }
2323 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2324 template <
typename,
typename,
typename>
class _Base>
2325 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2326 operator+(__versa_string<_CharT, _Traits, _Alloc, _Base>&& __lhs,
2328 {
return std::move(__lhs.append(1, __rhs)); }
2338 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2339 template <
typename,
typename,
typename>
class _Base>
2344 return __lhs.
size() == __rhs.
size()
2345 && !_Traits::compare(__lhs.
data(), __rhs.
data(), __lhs.
size());
2354 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2355 template <
typename,
typename,
typename>
class _Base>
2358 const _CharT* __rhs)
2360 return __lhs.
size() == _Traits::length(__rhs)
2361 && !_Traits::compare(__lhs.
data(), __rhs, __lhs.
size());
2370 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2371 template <
typename,
typename,
typename>
class _Base>
2373 operator==(
const _CharT* __lhs,
2375 {
return __rhs == __lhs; }
2384 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2385 template <
typename,
typename,
typename>
class _Base>
2389 {
return !(__lhs == __rhs); }
2397 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2398 template <
typename,
typename,
typename>
class _Base>
2400 operator!=(
const _CharT* __lhs,
2402 {
return !(__rhs == __lhs); }
2410 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2411 template <
typename,
typename,
typename>
class _Base>
2414 const _CharT* __rhs)
2415 {
return !(__lhs == __rhs); }
2424 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2425 template <
typename,
typename,
typename>
class _Base>
2429 {
return __lhs.
compare(__rhs) < 0; }
2437 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2438 template <
typename,
typename,
typename>
class _Base>
2441 const _CharT* __rhs)
2442 {
return __lhs.
compare(__rhs) < 0; }
2450 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2451 template <
typename,
typename,
typename>
class _Base>
2453 operator<(
const _CharT* __lhs,
2455 {
return __rhs.
compare(__lhs) > 0; }
2464 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2465 template <
typename,
typename,
typename>
class _Base>
2469 {
return __lhs.
compare(__rhs) > 0; }
2477 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2478 template <
typename,
typename,
typename>
class _Base>
2481 const _CharT* __rhs)
2482 {
return __lhs.
compare(__rhs) > 0; }
2490 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2491 template <
typename,
typename,
typename>
class _Base>
2493 operator>(
const _CharT* __lhs,
2495 {
return __rhs.
compare(__lhs) < 0; }
2504 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2505 template <
typename,
typename,
typename>
class _Base>
2509 {
return __lhs.
compare(__rhs) <= 0; }
2517 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2518 template <
typename,
typename,
typename>
class _Base>
2521 const _CharT* __rhs)
2522 {
return __lhs.
compare(__rhs) <= 0; }
2530 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2531 template <
typename,
typename,
typename>
class _Base>
2533 operator<=(
const _CharT* __lhs,
2535 {
return __rhs.
compare(__lhs) >= 0; }
2544 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2545 template <
typename,
typename,
typename>
class _Base>
2549 {
return __lhs.
compare(__rhs) >= 0; }
2557 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2558 template <
typename,
typename,
typename>
class _Base>
2561 const _CharT* __rhs)
2562 {
return __lhs.
compare(__rhs) >= 0; }
2570 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2571 template <
typename,
typename,
typename>
class _Base>
2573 operator>=(
const _CharT* __lhs,
2575 {
return __rhs.
compare(__lhs) <= 0; }
2584 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2585 template <
typename,
typename,
typename>
class _Base>
2589 { __lhs.
swap(__rhs); }
2591_GLIBCXX_END_NAMESPACE_VERSION
2594namespace std _GLIBCXX_VISIBILITY(default)
2596_GLIBCXX_BEGIN_NAMESPACE_VERSION
2610 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2611 template <
typename,
typename,
typename>
class _Base>
2612 basic_istream<_CharT, _Traits>&
2615 _Alloc, _Base>& __str);
2626 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2627 template <
typename,
typename,
typename>
class _Base>
2635 return __ostream_insert(__os, __str.
data(), __str.
size());
2652 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2653 template <
typename,
typename,
typename>
class _Base>
2654 basic_istream<_CharT, _Traits>&
2655 getline(basic_istream<_CharT, _Traits>& __is,
2672 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2673 template <
typename,
typename,
typename>
class _Base>
2674 inline basic_istream<_CharT, _Traits>&
2679_GLIBCXX_END_NAMESPACE_VERSION
2682#if __cplusplus >= 201103L
2686namespace __gnu_cxx _GLIBCXX_VISIBILITY(default)
2688_GLIBCXX_BEGIN_NAMESPACE_VERSION
2690#if _GLIBCXX_USE_C99_STDLIB
2693 stoi(
const __vstring& __str, std::size_t* __idx = 0,
int __base = 10)
2694 {
return __gnu_cxx::__stoa<long, int>(&std::strtol,
"stoi", __str.c_str(),
2698 stol(
const __vstring& __str, std::size_t* __idx = 0,
int __base = 10)
2699 {
return __gnu_cxx::__stoa(&std::strtol,
"stol", __str.c_str(),
2702 inline unsigned long
2703 stoul(
const __vstring& __str, std::size_t* __idx = 0,
int __base = 10)
2704 {
return __gnu_cxx::__stoa(&std::strtoul,
"stoul", __str.c_str(),
2708 stoll(
const __vstring& __str, std::size_t* __idx = 0,
int __base = 10)
2709 {
return __gnu_cxx::__stoa(&std::strtoll,
"stoll", __str.c_str(),
2712 inline unsigned long long
2713 stoull(
const __vstring& __str, std::size_t* __idx,
int __base = 10)
2714 {
return __gnu_cxx::__stoa(&std::strtoull,
"stoull", __str.c_str(),
2719 stof(
const __vstring& __str, std::size_t* __idx = 0)
2720 {
return __gnu_cxx::__stoa(&std::strtof,
"stof", __str.c_str(), __idx); }
2723 stod(
const __vstring& __str, std::size_t* __idx = 0)
2724 {
return __gnu_cxx::__stoa(&std::strtod,
"stod", __str.c_str(), __idx); }
2727 stold(
const __vstring& __str, std::size_t* __idx = 0)
2728 {
return __gnu_cxx::__stoa(&std::strtold,
"stold", __str.c_str(), __idx); }
2731#if _GLIBCXX_USE_C99_STDIO
2736 to_string(
int __val)
2737 {
return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf, 4 *
sizeof(
int),
2741 to_string(
unsigned __val)
2742 {
return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf,
2743 4 *
sizeof(
unsigned),
2747 to_string(
long __val)
2748 {
return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf,
2753 to_string(
unsigned long __val)
2754 {
return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf,
2755 4 *
sizeof(
unsigned long),
2760 to_string(
long long __val)
2761 {
return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf,
2762 4 *
sizeof(
long long),
2766 to_string(
unsigned long long __val)
2767 {
return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf,
2768 4 *
sizeof(
unsigned long long),
2772 to_string(
float __val)
2774 const int __n = __numeric_traits<float>::__max_exponent10 + 20;
2775 return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf, __n,
2780 to_string(
double __val)
2782 const int __n = __numeric_traits<double>::__max_exponent10 + 20;
2783 return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf, __n,
2788 to_string(
long double __val)
2790 const int __n = __numeric_traits<long double>::__max_exponent10 + 20;
2791 return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf, __n,
2796#if defined(_GLIBCXX_USE_WCHAR_T) && _GLIBCXX_USE_C99_WCHAR
2798 stoi(
const __wvstring& __str, std::size_t* __idx = 0,
int __base = 10)
2799 {
return __gnu_cxx::__stoa<long, int>(&std::wcstol,
"stoi", __str.c_str(),
2803 stol(
const __wvstring& __str, std::size_t* __idx = 0,
int __base = 10)
2804 {
return __gnu_cxx::__stoa(&std::wcstol,
"stol", __str.c_str(),
2807 inline unsigned long
2808 stoul(
const __wvstring& __str, std::size_t* __idx = 0,
int __base = 10)
2809 {
return __gnu_cxx::__stoa(&std::wcstoul,
"stoul", __str.c_str(),
2813 stoll(
const __wvstring& __str, std::size_t* __idx = 0,
int __base = 10)
2814 {
return __gnu_cxx::__stoa(&std::wcstoll,
"stoll", __str.c_str(),
2817 inline unsigned long long
2818 stoull(
const __wvstring& __str, std::size_t* __idx = 0,
int __base = 10)
2819 {
return __gnu_cxx::__stoa(&std::wcstoull,
"stoull", __str.c_str(),
2824 stof(
const __wvstring& __str, std::size_t* __idx = 0)
2825 {
return __gnu_cxx::__stoa(&std::wcstof,
"stof", __str.c_str(), __idx); }
2828 stod(
const __wvstring& __str, std::size_t* __idx = 0)
2829 {
return __gnu_cxx::__stoa(&std::wcstod,
"stod", __str.c_str(), __idx); }
2832 stold(
const __wvstring& __str, std::size_t* __idx = 0)
2833 {
return __gnu_cxx::__stoa(&std::wcstold,
"stold", __str.c_str(), __idx); }
2835#ifndef _GLIBCXX_HAVE_BROKEN_VSWPRINTF
2838 to_wstring(
int __val)
2839 {
return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf,
2844 to_wstring(
unsigned __val)
2845 {
return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf,
2846 4 *
sizeof(
unsigned),
2850 to_wstring(
long __val)
2851 {
return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf,
2856 to_wstring(
unsigned long __val)
2857 {
return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf,
2858 4 *
sizeof(
unsigned long),
2862 to_wstring(
long long __val)
2863 {
return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf,
2864 4 *
sizeof(
long long),
2868 to_wstring(
unsigned long long __val)
2869 {
return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf,
2870 4 *
sizeof(
unsigned long long),
2874 to_wstring(
float __val)
2876 const int __n = __numeric_traits<float>::__max_exponent10 + 20;
2877 return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf, __n,
2882 to_wstring(
double __val)
2884 const int __n = __numeric_traits<double>::__max_exponent10 + 20;
2885 return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf, __n,
2890 to_wstring(
long double __val)
2892 const int __n = __numeric_traits<long double>::__max_exponent10 + 20;
2893 return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf, __n,
2899_GLIBCXX_END_NAMESPACE_VERSION
2904#if __cplusplus >= 201103L
2908namespace std _GLIBCXX_VISIBILITY(default)
2910_GLIBCXX_BEGIN_NAMESPACE_VERSION
2915 :
public __hash_base<size_t, __gnu_cxx::__vstring>
2919 {
return std::_Hash_impl::hash(__s.
data(), __s.
length()); }
2925 :
public __hash_base<size_t, __gnu_cxx::__wvstring>
2929 {
return std::_Hash_impl::hash(__s.
data(),
2930 __s.
length() *
sizeof(
wchar_t)); }
2936 :
public __hash_base<size_t, __gnu_cxx::__u16vstring>
2940 {
return std::_Hash_impl::hash(__s.
data(),
2941 __s.
length() *
sizeof(
char16_t)); }
2947 :
public __hash_base<size_t, __gnu_cxx::__u32vstring>
2951 {
return std::_Hash_impl::hash(__s.
data(),
2952 __s.
length() *
sizeof(
char32_t)); }
2955_GLIBCXX_END_NAMESPACE_VERSION
constexpr complex< _Tp > operator+(const complex< _Tp > &__x, const complex< _Tp > &__y)
Return new complex value x plus y.
constexpr std::remove_reference< _Tp >::type && move(_Tp &&__t) noexcept
Convert a value to an rvalue.
constexpr const _Tp & min(const _Tp &, const _Tp &)
This does what you think it does.
ISO C++ entities toplevel namespace is std.
basic_istream< _CharT, _Traits > & getline(basic_istream< _CharT, _Traits > &__is, basic_string< _CharT, _Traits, _Alloc > &__str, _CharT __delim)
Read a line from stream into a string.
std::basic_istream< _CharT, _Traits > & operator>>(std::basic_istream< _CharT, _Traits > &__is, bitset< _Nb > &__x)
Global I/O operators for bitsets.
std::basic_ostream< _CharT, _Traits > & operator<<(std::basic_ostream< _CharT, _Traits > &__os, const bitset< _Nb > &__x)
Global I/O operators for bitsets.
GNU extensions for public use.
char_type widen(char __c) const
Widens characters.
Template class basic_istream.
Template class basic_ostream.
Primary class template hash.
One of the comparison functors.
Uniform interface to C++98 and C++11 allocators.
Template class __versa_string.
__versa_string & assign(const _CharT *__s)
Set value to contents of a C string.
void swap(__versa_string &__s) noexcept
Swap contents with another string.
reverse_iterator rend() noexcept
iterator begin() noexcept
__versa_string & replace(size_type __pos, size_type __n1, const _CharT *__s)
Replace characters with value of a C string.
iterator insert(const_iterator __p, _CharT __c)
Insert one character.
size_type find_last_of(const _CharT *__s, size_type __pos=npos) const
Find last position of a character of C string.
__versa_string & insert(size_type __pos1, const __versa_string &__str)
Insert value of a string.
size_type find_last_of(const __versa_string &__str, size_type __pos=npos) const noexcept
Find last position of a character of string.
__versa_string & replace(size_type __pos, size_type __n1, const _CharT *__s, size_type __n2)
Replace characters with value of a C substring.
size_type find_first_not_of(const __versa_string &__str, size_type __pos=0) const noexcept
Find position of a character not in string.
size_type find(const _CharT *__s, size_type __pos, size_type __n) const
Find position of a C substring.
__versa_string & insert(size_type __pos, size_type __n, _CharT __c)
Insert multiple characters.
const_reference at(size_type __n) const
Provides access to the data contained in the string.
__versa_string & replace(const_iterator __i1, const_iterator __i2, const _CharT *__s)
Replace range of characters with C string.
__versa_string & operator=(_CharT __c)
Set value to string of length 1.
size_type find_first_of(_CharT __c, size_type __pos=0) const noexcept
Find position of a character.
const_reference front() const noexcept
__versa_string & replace(size_type __pos1, size_type __n1, const __versa_string &__str, size_type __pos2, size_type __n2)
Replace characters with value from another string.
__versa_string & operator+=(const _CharT *__s)
Append a C string.
__versa_string & append(std::initializer_list< _CharT > __l)
Append an initializer_list of characters.
__versa_string & append(_InputIterator __first, _InputIterator __last)
Append a range of characters.
__versa_string & operator=(const __versa_string &__str)
Assign the value of str to this string.
size_type find_last_not_of(const __versa_string &__str, size_type __pos=npos) const noexcept
Find last position of a character not in string.
const_iterator cend() const noexcept
__versa_string & operator+=(const __versa_string &__str)
Append a string to this string.
__versa_string & insert(size_type __pos, const _CharT *__s, size_type __n)
Insert a C substring.
size_type find_first_of(const __versa_string &__str, size_type __pos=0) const noexcept
Find position of a character of string.
__versa_string(_InputIterator __beg, _InputIterator __end, const _Alloc &__a=_Alloc())
Construct string as copy of a range.
__versa_string & replace(const_iterator __i1, const_iterator __i2, size_type __n, _CharT __c)
Replace range of characters with multiple characters.
__versa_string & append(const _CharT *__s, size_type __n)
Append a C substring.
__versa_string & append(const __versa_string &__str, size_type __pos, size_type __n)
Append a substring.
__versa_string(const _Alloc &__a=_Alloc()) noexcept
Construct an empty string using allocator a.
__versa_string & append(const __versa_string &__str)
Append a string to this string.
size_type find(const __versa_string &__str, size_type __pos=0) const noexcept
Find position of a string.
const_reverse_iterator rbegin() const noexcept
size_type find_last_not_of(const _CharT *__s, size_type __pos=npos) const
Find last position of a character not in C string.
__versa_string(std::initializer_list< _CharT > __l, const _Alloc &__a=_Alloc())
Construct string from an initializer list.
__versa_string & operator+=(_CharT __c)
Append a character.
void resize(size_type __n, _CharT __c)
Resizes the string to the specified number of characters.
__versa_string & assign(const __versa_string &__str)
Set value to contents of another string.
__versa_string & operator=(const _CharT *__s)
Copy contents of __s into this string.
allocator_type get_allocator() const noexcept
Return copy of allocator used to construct this string.
__versa_string & assign(__versa_string &&__str) noexcept
Set value to contents of another string.
iterator erase(const_iterator __position)
Remove one character.
size_type capacity() const noexcept
__versa_string & assign(const __versa_string &__str, size_type __pos, size_type __n)
Set value to a substring of a string.
__versa_string & operator=(std::initializer_list< _CharT > __l)
Set value to string constructed from initializer list.
iterator insert(const_iterator __p, std::initializer_list< _CharT > __l)
Insert an initializer_list of characters.
__versa_string & replace(const_iterator __i1, const_iterator __i2, const _CharT *__s, size_type __n)
Replace range of characters with C substring.
~__versa_string() noexcept
Destroy the string instance.
static const size_type npos
Value returned by various member functions when they fail.
reference back() noexcept
size_type find_first_not_of(const _CharT *__s, size_type __pos=0) const
Find position of a character not in C string.
reference at(size_type __n)
Provides access to the data contained in the string.
iterator erase(const_iterator __first, const_iterator __last)
Remove a range of characters.
__versa_string(__versa_string &&__str) noexcept
String move constructor.
size_type length() const noexcept
Returns the number of characters in the string, not including any null-termination.
size_type size() const noexcept
Returns the number of characters in the string, not including any null-termination.
const _CharT * c_str() const noexcept
Return const pointer to null-terminated contents.
const _CharT * data() const noexcept
Return const pointer to contents.
int compare(const __versa_string &__str) const
Compare to a string.
void shrink_to_fit() noexcept
A non-binding request to reduce capacity() to size().
__versa_string(size_type __n, _CharT __c, const _Alloc &__a=_Alloc())
Construct string as multiple characters.
bool empty() const noexcept
reference operator[](size_type __pos) noexcept
Subscript access to the data contained in the string.
__versa_string(const _CharT *__s, size_type __n, const _Alloc &__a=_Alloc())
Construct string initialized by a character array.
iterator insert(const_iterator __p, _InputIterator __beg, _InputIterator __end)
Insert a range of characters.
__versa_string & insert(size_type __pos1, const __versa_string &__str, size_type __pos2, size_type __n)
Insert a substring.
const_reference back() const noexcept
__versa_string & insert(size_type __pos, const _CharT *__s)
Insert a C string.
void resize(size_type __n)
Resizes the string to the specified number of characters.
const_reverse_iterator crbegin() const noexcept
const_iterator begin() const noexcept
const_reverse_iterator rend() const noexcept
const_reference operator[](size_type __pos) const noexcept
Subscript access to the data contained in the string.
__versa_string substr(size_type __pos=0, size_type __n=npos) const
Get a substring.
__versa_string(const _CharT *__s, const _Alloc &__a=_Alloc())
Construct string as copy of a C string.
__versa_string & assign(size_type __n, _CharT __c)
Set value to multiple characters.
__versa_string(const __versa_string &__str, size_type __pos, size_type __n=npos)
Construct string as copy of a substring.
__versa_string(const __versa_string &__str, size_type __pos, size_type __n, const _Alloc &__a)
Construct string as copy of a substring.
__versa_string & replace(size_type __pos, size_type __n1, size_type __n2, _CharT __c)
Replace characters with multiple characters.
__versa_string & erase(size_type __pos=0, size_type __n=npos)
Remove characters.
__versa_string & append(size_type __n, _CharT __c)
Append multiple characters.
__versa_string & append(const _CharT *__s)
Append a C string.
size_type max_size() const noexcept
Returns the size() of the largest possible string.
const_iterator end() const noexcept
__versa_string & assign(_InputIterator __first, _InputIterator __last)
Set value to a range of characters.
const_iterator cbegin() const noexcept
__versa_string & assign(std::initializer_list< _CharT > __l)
Set value to an initializer_list of characters.
__versa_string & replace(const_iterator __i1, const_iterator __i2, const __versa_string &__str)
Replace range of characters with string.
__versa_string & replace(const_iterator __i1, const_iterator __i2, std::initializer_list< _CharT > __l)
Replace range of characters with initializer_list.
size_type rfind(const _CharT *__s, size_type __pos=npos) const
Find last position of a C string.
size_type copy(_CharT *__s, size_type __n, size_type __pos=0) const
Copy substring into C string.
__versa_string & operator=(__versa_string &&__str) noexcept
String move assignment operator.
size_type find_first_of(const _CharT *__s, size_type __pos=0) const
Find position of a character of C string.
iterator insert(const_iterator __p, size_type __n, _CharT __c)
Insert multiple characters.
void push_back(_CharT __c)
Append a single character.
__versa_string & operator+=(std::initializer_list< _CharT > __l)
Append an initializer_list of characters.
size_type find_last_of(_CharT __c, size_type __pos=npos) const noexcept
Find last position of a character.
reference front() noexcept
__versa_string & replace(size_type __pos, size_type __n, const __versa_string &__str)
Replace characters with value from another string.
__versa_string(const __versa_string &__str)
Construct string with copy of value of __str.
void reserve(size_type __res_arg=0)
Attempt to preallocate enough memory for specified number of characters.
__versa_string & assign(const _CharT *__s, size_type __n)
Set value to a C substring.
size_type rfind(const __versa_string &__str, size_type __pos=npos) const noexcept
Find last position of a string.
const_reverse_iterator crend() const noexcept
void pop_back()
Remove the last character.
__versa_string & replace(const_iterator __i1, const_iterator __i2, _InputIterator __k1, _InputIterator __k2)
Replace range of characters with range.
reverse_iterator rbegin() noexcept
size_type find(const _CharT *__s, size_type __pos=0) const
Find position of a C string.