32 #pragma GCC system_header 34 #if __cplusplus >= 201103L 42 namespace __gnu_cxx _GLIBCXX_VISIBILITY(default)
44 _GLIBCXX_BEGIN_NAMESPACE_VERSION
54 template<
typename _CharT,
typename _Traits,
typename _Alloc,
55 template <
typename,
typename,
typename>
class _Base>
57 :
private _Base<_CharT, _Traits, _Alloc>
59 typedef _Base<_CharT, _Traits, _Alloc> __vstring_base;
60 typedef typename __vstring_base::_CharT_alloc_type _CharT_alloc_type;
64 typedef _Traits traits_type;
65 typedef typename _Traits::char_type value_type;
66 typedef _Alloc allocator_type;
67 typedef typename _CharT_alloc_type::size_type size_type;
68 typedef typename _CharT_alloc_type::difference_type difference_type;
69 typedef value_type& reference;
70 typedef const value_type& const_reference;
71 typedef typename _CharT_alloc_type::pointer pointer;
72 typedef typename _CharT_alloc_type::const_pointer const_pointer;
73 typedef __gnu_cxx::__normal_iterator<pointer, __versa_string> iterator;
74 typedef __gnu_cxx::__normal_iterator<const_pointer, __versa_string>
81 static const size_type
npos = static_cast<size_type>(-1);
85 _M_check(size_type __pos,
const char* __s)
const 87 if (__pos > this->
size())
88 std::__throw_out_of_range_fmt(__N(
"%s: __pos (which is %zu) > " 89 "this->size() (which is %zu)"),
90 __s, __pos, this->
size());
95 _M_check_length(size_type __n1, size_type __n2,
const char* __s)
const 98 std::__throw_length_error(__N(__s));
103 _M_limit(size_type __pos, size_type __off)
const _GLIBCXX_NOEXCEPT
105 const bool __testoff = __off < this->
size() - __pos;
106 return __testoff ? __off : this->
size() - __pos;
111 _M_disjunct(
const _CharT* __s)
const _GLIBCXX_NOEXCEPT
115 + this->
size(), __s));
121 _M_ibegin() const _GLIBCXX_NOEXCEPT
122 {
return iterator(this->_M_data()); }
125 _M_iend() const _GLIBCXX_NOEXCEPT
126 {
return iterator(this->_M_data() + this->_M_length()); }
138 : __vstring_base(__a) { }
146 : __vstring_base(__str) { }
148 #if __cplusplus >= 201103L 158 : __vstring_base(std::move(__str)) { }
166 const _Alloc& __a = _Alloc())
167 : __vstring_base(__l.
begin(), __l.
end(), __a) { }
177 size_type __n =
npos)
178 : __vstring_base(__str._M_data()
179 + __str._M_check(__pos,
180 "__versa_string::__versa_string"),
181 __str._M_data() + __str._M_limit(__pos, __n)
182 + __pos, _Alloc()) { }
192 size_type __n,
const _Alloc& __a)
193 : __vstring_base(__str._M_data()
194 + __str._M_check(__pos,
195 "__versa_string::__versa_string"),
196 __str._M_data() + __str._M_limit(__pos, __n)
209 const _Alloc& __a = _Alloc())
210 : __vstring_base(__s, __s + __n, __a) { }
218 : __vstring_base(__s, __s ? __s + traits_type::
length(__s) :
228 : __vstring_base(__n, __c, __a) { }
236 #if __cplusplus >= 201103L 237 template<
class _InputIterator,
238 typename = std::_RequireInputIter<_InputIterator>>
240 template<
class _InputIterator>
243 const _Alloc& __a = _Alloc())
244 : __vstring_base(__beg, __end, __a) { }
257 {
return this->
assign(__str); }
259 #if __cplusplus >= 201103L 282 this->
assign(__l.begin(), __l.end());
293 {
return this->
assign(__s); }
318 return iterator(this->_M_data());
327 {
return const_iterator(this->_M_data()); }
337 return iterator(this->_M_data() + this->
size());
345 end() const _GLIBCXX_NOEXCEPT
346 {
return const_iterator(this->_M_data() + this->
size()); }
362 const_reverse_iterator
380 const_reverse_iterator
384 #if __cplusplus >= 201103L 391 {
return const_iterator(this->_M_data()); }
399 {
return const_iterator(this->_M_data() + this->
size()); }
406 const_reverse_iterator
415 const_reverse_iterator
426 {
return this->_M_length(); }
432 {
return this->_M_length(); }
437 {
return this->_M_max_size(); }
450 resize(size_type __n, _CharT __c);
464 { this->
resize(__n, _CharT()); }
466 #if __cplusplus >= 201103L 487 {
return this->_M_capacity(); }
508 { this->_M_reserve(__res_arg); }
515 { this->_M_clear(); }
523 {
return this->
size() == 0; }
539 __glibcxx_assert(__pos <= this->
size());
540 return this->_M_data()[__pos];
558 __glibcxx_assert(__pos <= this->
size());
560 _GLIBCXX_DEBUG_PEDASSERT(__cplusplus >= 201103L
561 || __pos < this->
size());
563 return this->_M_data()[__pos];
577 at(size_type __n)
const 579 if (__n >= this->
size())
580 std::__throw_out_of_range_fmt(__N(
"__versa_string::at: __n " 581 "(which is %zu) >= this->size() " 584 return this->_M_data()[__n];
601 if (__n >= this->
size())
602 std::__throw_out_of_range_fmt(__N(
"__versa_string::at: __n " 603 "(which is %zu) >= this->size() " 607 return this->_M_data()[__n];
610 #if __cplusplus >= 201103L 652 {
return this->
append(__str); }
661 {
return this->
append(__s); }
675 #if __cplusplus >= 201103L 683 {
return this->
append(__l.begin(), __l.end()); }
693 {
return _M_append(__str._M_data(), __str.
size()); }
710 {
return _M_append(__str._M_data()
711 + __str._M_check(__pos,
"__versa_string::append"),
712 __str._M_limit(__pos, __n)); }
723 __glibcxx_requires_string_len(__s, __n);
724 _M_check_length(size_type(0), __n,
"__versa_string::append");
725 return _M_append(__s, __n);
736 __glibcxx_requires_string(__s);
737 const size_type __n = traits_type::length(__s);
738 _M_check_length(size_type(0), __n,
"__versa_string::append");
739 return _M_append(__s, __n);
752 {
return _M_replace_aux(this->
size(), size_type(0), __n, __c); }
754 #if __cplusplus >= 201103L 762 {
return this->
append(__l.begin(), __l.end()); }
773 #if __cplusplus >= 201103L 774 template<
class _InputIterator,
775 typename = std::_RequireInputIter<_InputIterator>>
777 template<
class _InputIterator>
780 append(_InputIterator __first, _InputIterator __last)
781 {
return this->
replace(_M_iend(), _M_iend(), __first, __last); }
790 const size_type __size = this->
size();
791 if (__size + 1 > this->
capacity() || this->_M_is_shared())
792 this->_M_mutate(__size, size_type(0), 0, size_type(1));
793 traits_type::assign(this->_M_data()[__size], __c);
794 this->_M_set_length(__size + 1);
805 this->_M_assign(__str);
809 #if __cplusplus >= 201103L 841 {
return _M_replace(size_type(0), this->
size(), __str._M_data()
842 + __str._M_check(__pos,
"__versa_string::assign"),
843 __str._M_limit(__pos, __n)); }
859 __glibcxx_requires_string_len(__s, __n);
860 return _M_replace(size_type(0), this->
size(), __s, __n);
875 __glibcxx_requires_string(__s);
876 return _M_replace(size_type(0), this->
size(), __s,
877 traits_type::length(__s));
891 {
return _M_replace_aux(size_type(0), this->
size(), __n, __c); }
902 #if __cplusplus >= 201103L 903 template<
class _InputIterator,
904 typename = std::_RequireInputIter<_InputIterator>>
906 template<
class _InputIterator>
909 assign(_InputIterator __first, _InputIterator __last)
910 {
return this->
replace(_M_ibegin(), _M_iend(), __first, __last); }
912 #if __cplusplus >= 201103L 920 {
return this->
assign(__l.begin(), __l.end()); }
923 #if __cplusplus >= 201103L 940 insert(const_iterator __p, size_type __n, _CharT __c)
942 _GLIBCXX_DEBUG_PEDASSERT(__p >= _M_ibegin() && __p <= _M_iend());
943 const size_type __pos = __p - _M_ibegin();
944 this->
replace(__p, __p, __n, __c);
945 return iterator(this->_M_data() + __pos);
963 { this->
replace(__p, __p, __n, __c); }
966 #if __cplusplus >= 201103L 981 template<
class _InputIterator,
982 typename = std::_RequireInputIter<_InputIterator>>
984 insert(const_iterator __p, _InputIterator __beg, _InputIterator __end)
986 _GLIBCXX_DEBUG_PEDASSERT(__p >= _M_ibegin() && __p <= _M_iend());
987 const size_type __pos = __p - _M_ibegin();
988 this->
replace(__p, __p, __beg, __end);
989 return iterator(this->_M_data() + __pos);
1004 template<
class _InputIterator>
1007 { this->
replace(__p, __p, __beg, __end); }
1010 #if __cplusplus >= 201103L 1021 {
return this->
insert(__p, __l.begin(), __l.end()); }
1038 {
return this->
replace(__pos1, size_type(0),
1039 __str._M_data(), __str.
size()); }
1061 size_type __pos2, size_type __n)
1062 {
return this->
replace(__pos1, size_type(0), __str._M_data()
1063 + __str._M_check(__pos2,
"__versa_string::insert"),
1064 __str._M_limit(__pos2, __n)); }
1083 insert(size_type __pos,
const _CharT* __s, size_type __n)
1084 {
return this->
replace(__pos, size_type(0), __s, __n); }
1104 __glibcxx_requires_string(__s);
1105 return this->
replace(__pos, size_type(0), __s,
1106 traits_type::length(__s));
1126 insert(size_type __pos, size_type __n, _CharT __c)
1127 {
return _M_replace_aux(_M_check(__pos,
"__versa_string::insert"),
1128 size_type(0), __n, __c); }
1144 #if __cplusplus >= 201103L 1147 insert(iterator __p, _CharT __c)
1150 _GLIBCXX_DEBUG_PEDASSERT(__p >= _M_ibegin() && __p <= _M_iend());
1151 const size_type __pos = __p - _M_ibegin();
1152 _M_replace_aux(__pos, size_type(0), size_type(1), __c);
1153 this->_M_set_leaked();
1154 return iterator(this->_M_data() + __pos);
1175 this->_M_erase(_M_check(__pos,
"__versa_string::erase"),
1176 _M_limit(__pos, __n));
1189 #if __cplusplus >= 201103L 1192 erase(iterator __position)
1195 _GLIBCXX_DEBUG_PEDASSERT(__position >= _M_ibegin()
1196 && __position < _M_iend());
1197 const size_type __pos = __position - _M_ibegin();
1198 this->_M_erase(__pos, size_type(1));
1199 this->_M_set_leaked();
1200 return iterator(this->_M_data() + __pos);
1214 #if __cplusplus >= 201103L 1215 erase(const_iterator __first, const_iterator __last)
1217 erase(iterator __first, iterator __last)
1220 _GLIBCXX_DEBUG_PEDASSERT(__first >= _M_ibegin() && __first <= __last
1221 && __last <= _M_iend());
1222 const size_type __pos = __first - _M_ibegin();
1223 this->_M_erase(__pos, __last - __first);
1224 this->_M_set_leaked();
1225 return iterator(this->_M_data() + __pos);
1228 #if __cplusplus >= 201103L 1236 { this->_M_erase(
size()-1, 1); }
1258 {
return this->
replace(__pos, __n, __str._M_data(), __str.
size()); }
1281 size_type __pos2, size_type __n2)
1283 return this->
replace(__pos1, __n1, __str._M_data()
1284 + __str._M_check(__pos2,
1285 "__versa_string::replace"),
1286 __str._M_limit(__pos2, __n2));
1308 replace(size_type __pos, size_type __n1,
const _CharT* __s,
1311 __glibcxx_requires_string_len(__s, __n2);
1312 return _M_replace(_M_check(__pos,
"__versa_string::replace"),
1313 _M_limit(__pos, __n1), __s, __n2);
1332 replace(size_type __pos, size_type __n1,
const _CharT* __s)
1334 __glibcxx_requires_string(__s);
1335 return this->
replace(__pos, __n1, __s, traits_type::length(__s));
1356 replace(size_type __pos, size_type __n1, size_type __n2, _CharT __c)
1357 {
return _M_replace_aux(_M_check(__pos,
"__versa_string::replace"),
1358 _M_limit(__pos, __n1), __n2, __c); }
1374 #if __cplusplus >= 201103L 1380 {
return this->
replace(__i1, __i2, __str._M_data(), __str.
size()); }
1397 #if __cplusplus >= 201103L 1399 const _CharT* __s, size_type __n)
1401 replace(iterator __i1, iterator __i2,
const _CharT* __s, size_type __n)
1404 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1405 && __i2 <= _M_iend());
1406 return this->
replace(__i1 - _M_ibegin(), __i2 - __i1, __s, __n);
1423 #if __cplusplus >= 201103L 1424 replace(const_iterator __i1, const_iterator __i2,
const _CharT* __s)
1426 replace(iterator __i1, iterator __i2,
const _CharT* __s)
1429 __glibcxx_requires_string(__s);
1430 return this->
replace(__i1, __i2, __s, traits_type::length(__s));
1448 #if __cplusplus >= 201103L 1449 replace(const_iterator __i1, const_iterator __i2, size_type __n,
1452 replace(iterator __i1, iterator __i2, size_type __n, _CharT __c)
1455 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1456 && __i2 <= _M_iend());
1457 return _M_replace_aux(__i1 - _M_ibegin(), __i2 - __i1, __n, __c);
1474 #if __cplusplus >= 201103L 1475 template<
class _InputIterator,
1476 typename = std::_RequireInputIter<_InputIterator>>
1479 _InputIterator __k1, _InputIterator __k2)
1481 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1482 && __i2 <= _M_iend());
1483 __glibcxx_requires_valid_range(__k1, __k2);
1484 return this->_M_replace_dispatch(__i1, __i2, __k1, __k2,
1485 std::__false_type());
1488 template<
class _InputIterator>
1491 _InputIterator __k1, _InputIterator __k2)
1493 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1494 && __i2 <= _M_iend());
1495 __glibcxx_requires_valid_range(__k1, __k2);
1496 typedef typename std::__is_integer<_InputIterator>::__type _Integral;
1497 return this->_M_replace_dispatch(__i1, __i2, __k1, __k2, _Integral());
1504 #if __cplusplus >= 201103L 1505 replace(const_iterator __i1, const_iterator __i2,
1506 _CharT* __k1, _CharT* __k2)
1508 replace(iterator __i1, iterator __i2,
1509 _CharT* __k1, _CharT* __k2)
1512 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1513 && __i2 <= _M_iend());
1514 __glibcxx_requires_valid_range(__k1, __k2);
1515 return this->
replace(__i1 - _M_ibegin(), __i2 - __i1,
1520 #if __cplusplus >= 201103L 1521 replace(const_iterator __i1, const_iterator __i2,
1522 const _CharT* __k1,
const _CharT* __k2)
1524 replace(iterator __i1, iterator __i2,
1525 const _CharT* __k1,
const _CharT* __k2)
1528 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1529 && __i2 <= _M_iend());
1530 __glibcxx_requires_valid_range(__k1, __k2);
1531 return this->
replace(__i1 - _M_ibegin(), __i2 - __i1,
1536 #if __cplusplus >= 201103L 1537 replace(const_iterator __i1, const_iterator __i2,
1538 iterator __k1, iterator __k2)
1540 replace(iterator __i1, iterator __i2,
1541 iterator __k1, iterator __k2)
1544 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1545 && __i2 <= _M_iend());
1546 __glibcxx_requires_valid_range(__k1, __k2);
1547 return this->
replace(__i1 - _M_ibegin(), __i2 - __i1,
1548 __k1.base(), __k2 - __k1);
1552 #if __cplusplus >= 201103L 1553 replace(const_iterator __i1, const_iterator __i2,
1554 const_iterator __k1, const_iterator __k2)
1556 replace(iterator __i1, iterator __i2,
1557 const_iterator __k1, const_iterator __k2)
1560 _GLIBCXX_DEBUG_PEDASSERT(_M_ibegin() <= __i1 && __i1 <= __i2
1561 && __i2 <= _M_iend());
1562 __glibcxx_requires_valid_range(__k1, __k2);
1563 return this->
replace(__i1 - _M_ibegin(), __i2 - __i1,
1564 __k1.base(), __k2 - __k1);
1567 #if __cplusplus >= 201103L 1584 {
return this->
replace(__i1, __i2, __l.begin(), __l.end()); }
1588 template<
class _Integer>
1590 _M_replace_dispatch(const_iterator __i1, const_iterator __i2,
1591 _Integer __n, _Integer __val, std::__true_type)
1592 {
return _M_replace_aux(__i1 - _M_ibegin(), __i2 - __i1, __n, __val); }
1594 template<
class _InputIterator>
1596 _M_replace_dispatch(const_iterator __i1, const_iterator __i2,
1597 _InputIterator __k1, _InputIterator __k2,
1601 _M_replace_aux(size_type __pos1, size_type __n1, size_type __n2,
1605 _M_replace(size_type __pos, size_type __len1,
const _CharT* __s,
1606 const size_type __len2);
1609 _M_append(
const _CharT* __s, size_type __n);
1626 copy(_CharT* __s, size_type __n, size_type __pos = 0)
const;
1637 { this->_M_swap(__s); }
1648 {
return this->_M_data(); }
1658 {
return this->_M_data(); }
1665 {
return allocator_type(this->_M_get_allocator()); }
1680 find(
const _CharT* __s, size_type __pos, size_type __n)
const;
1695 {
return this->
find(__str.
data(), __pos, __str.
size()); }
1708 find(
const _CharT* __s, size_type __pos = 0)
const 1710 __glibcxx_requires_string(__s);
1711 return this->
find(__s, __pos, traits_type::length(__s));
1725 find(_CharT __c, size_type __pos = 0) const _GLIBCXX_NOEXCEPT;
1740 {
return this->
rfind(__str.data(), __pos, __str.size()); }
1755 rfind(
const _CharT* __s, size_type __pos, size_type __n)
const;
1770 __glibcxx_requires_string(__s);
1771 return this->
rfind(__s, __pos, traits_type::length(__s));
1785 rfind(_CharT __c, size_type __pos =
npos)
const _GLIBCXX_NOEXCEPT;
1815 find_first_of(
const _CharT* __s, size_type __pos, size_type __n)
const;
1830 __glibcxx_requires_string(__s);
1831 return this->
find_first_of(__s, __pos, traits_type::length(__s));
1848 {
return this->
find(__c, __pos); }
1879 find_last_of(
const _CharT* __s, size_type __pos, size_type __n)
const;
1894 __glibcxx_requires_string(__s);
1895 return this->
find_last_of(__s, __pos, traits_type::length(__s));
1912 {
return this->
rfind(__c, __pos); }
1943 size_type __n)
const;
1958 __glibcxx_requires_string(__s);
1989 size_type __pos =
npos) const _GLIBCXX_NOEXCEPT
2006 size_type __n)
const;
2021 __glibcxx_requires_string(__s);
2054 return __versa_string(*
this, _M_check(__pos,
"__versa_string::substr"),
2075 if (this->_M_compare(__str))
2078 const size_type __size = this->
size();
2079 const size_type __osize = __str.
size();
2080 const size_type __len =
std::min(__size, __osize);
2082 int __r = traits_type::compare(this->_M_data(), __str.
data(), __len);
2084 __r = this->_S_compare(__size, __osize);
2108 compare(size_type __pos, size_type __n,
2136 size_type __pos2, size_type __n2)
const;
2154 compare(
const _CharT* __s)
const;
2178 compare(size_type __pos, size_type __n1,
const _CharT* __s)
const;
2205 compare(size_type __pos, size_type __n1,
const _CharT* __s,
2206 size_type __n2)
const;
2216 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2217 template <
typename,
typename,
typename>
class _Base>
2218 __versa_string<_CharT, _Traits, _Alloc, _Base>
2219 operator+(
const __versa_string<_CharT, _Traits, _Alloc, _Base>& __lhs,
2220 const __versa_string<_CharT, _Traits, _Alloc, _Base>& __rhs);
2228 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2229 template <
typename,
typename,
typename>
class _Base>
2230 __versa_string<_CharT, _Traits, _Alloc, _Base>
2231 operator+(
const _CharT* __lhs,
2232 const __versa_string<_CharT, _Traits, _Alloc, _Base>& __rhs);
2240 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2241 template <
typename,
typename,
typename>
class _Base>
2242 __versa_string<_CharT, _Traits, _Alloc, _Base>
2243 operator+(_CharT __lhs,
2244 const __versa_string<_CharT, _Traits, _Alloc, _Base>& __rhs);
2252 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2253 template <
typename,
typename,
typename>
class _Base>
2254 __versa_string<_CharT, _Traits, _Alloc, _Base>
2255 operator+(
const __versa_string<_CharT, _Traits, _Alloc, _Base>& __lhs,
2256 const _CharT* __rhs);
2264 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2265 template <
typename,
typename,
typename>
class _Base>
2266 __versa_string<_CharT, _Traits, _Alloc, _Base>
2267 operator+(
const __versa_string<_CharT, _Traits, _Alloc, _Base>& __lhs,
2270 #if __cplusplus >= 201103L 2271 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2272 template <
typename,
typename,
typename>
class _Base>
2273 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2274 operator+(__versa_string<_CharT, _Traits, _Alloc, _Base>&& __lhs,
2275 const __versa_string<_CharT, _Traits, _Alloc, _Base>& __rhs)
2276 {
return std::move(__lhs.append(__rhs)); }
2278 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2279 template <
typename,
typename,
typename>
class _Base>
2280 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2281 operator+(
const __versa_string<_CharT, _Traits, _Alloc, _Base>& __lhs,
2282 __versa_string<_CharT, _Traits, _Alloc, _Base>&& __rhs)
2283 {
return std::move(__rhs.insert(0, __lhs)); }
2285 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2286 template <
typename,
typename,
typename>
class _Base>
2287 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2288 operator+(__versa_string<_CharT, _Traits, _Alloc, _Base>&& __lhs,
2289 __versa_string<_CharT, _Traits, _Alloc, _Base>&& __rhs)
2291 const auto __size = __lhs.size() + __rhs.size();
2292 const bool __cond = (__size > __lhs.capacity()
2293 && __size <= __rhs.capacity());
2294 return __cond ? std::move(__rhs.insert(0, __lhs))
2295 : std::move(__lhs.append(__rhs));
2298 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2299 template <
typename,
typename,
typename>
class _Base>
2300 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2301 operator+(
const _CharT* __lhs,
2302 __versa_string<_CharT, _Traits, _Alloc, _Base>&& __rhs)
2303 {
return std::move(__rhs.insert(0, __lhs)); }
2305 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2306 template <
typename,
typename,
typename>
class _Base>
2307 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2308 operator+(_CharT __lhs,
2309 __versa_string<_CharT, _Traits, _Alloc, _Base>&& __rhs)
2310 {
return std::move(__rhs.insert(0, 1, __lhs)); }
2312 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2313 template <
typename,
typename,
typename>
class _Base>
2314 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2315 operator+(__versa_string<_CharT, _Traits, _Alloc, _Base>&& __lhs,
2316 const _CharT* __rhs)
2317 {
return std::move(__lhs.append(__rhs)); }
2319 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2320 template <
typename,
typename,
typename>
class _Base>
2321 inline __versa_string<_CharT, _Traits, _Alloc, _Base>
2322 operator+(__versa_string<_CharT, _Traits, _Alloc, _Base>&& __lhs,
2324 {
return std::move(__lhs.append(1, __rhs)); }
2334 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2335 template <
typename,
typename,
typename>
class _Base>
2339 {
return __lhs.
compare(__rhs) == 0; }
2341 template<
typename _CharT,
2342 template <
typename,
typename,
typename>
class _Base>
2343 inline typename __enable_if<std::__is_char<_CharT>::__value,
bool>::__type
2348 {
return (__lhs.size() == __rhs.size()
2358 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2359 template <
typename,
typename,
typename>
class _Base>
2361 operator==(
const _CharT* __lhs,
2363 {
return __rhs.
compare(__lhs) == 0; }
2371 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2372 template <
typename,
typename,
typename>
class _Base>
2375 const _CharT* __rhs)
2376 {
return __lhs.
compare(__rhs) == 0; }
2385 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2386 template <
typename,
typename,
typename>
class _Base>
2390 {
return !(__lhs == __rhs); }
2398 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2399 template <
typename,
typename,
typename>
class _Base>
2401 operator!=(
const _CharT* __lhs,
2403 {
return !(__lhs == __rhs); }
2411 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2412 template <
typename,
typename,
typename>
class _Base>
2415 const _CharT* __rhs)
2416 {
return !(__lhs == __rhs); }
2425 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2426 template <
typename,
typename,
typename>
class _Base>
2430 {
return __lhs.
compare(__rhs) < 0; }
2438 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2439 template <
typename,
typename,
typename>
class _Base>
2442 const _CharT* __rhs)
2443 {
return __lhs.
compare(__rhs) < 0; }
2451 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2452 template <
typename,
typename,
typename>
class _Base>
2454 operator<(
const _CharT* __lhs,
2456 {
return __rhs.
compare(__lhs) > 0; }
2465 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2466 template <
typename,
typename,
typename>
class _Base>
2470 {
return __lhs.
compare(__rhs) > 0; }
2478 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2479 template <
typename,
typename,
typename>
class _Base>
2482 const _CharT* __rhs)
2483 {
return __lhs.
compare(__rhs) > 0; }
2491 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2492 template <
typename,
typename,
typename>
class _Base>
2494 operator>(
const _CharT* __lhs,
2496 {
return __rhs.
compare(__lhs) < 0; }
2505 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2506 template <
typename,
typename,
typename>
class _Base>
2510 {
return __lhs.
compare(__rhs) <= 0; }
2518 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2519 template <
typename,
typename,
typename>
class _Base>
2522 const _CharT* __rhs)
2523 {
return __lhs.
compare(__rhs) <= 0; }
2531 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2532 template <
typename,
typename,
typename>
class _Base>
2534 operator<=(
const _CharT* __lhs,
2536 {
return __rhs.
compare(__lhs) >= 0; }
2545 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2546 template <
typename,
typename,
typename>
class _Base>
2550 {
return __lhs.
compare(__rhs) >= 0; }
2558 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2559 template <
typename,
typename,
typename>
class _Base>
2562 const _CharT* __rhs)
2563 {
return __lhs.
compare(__rhs) >= 0; }
2571 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2572 template <
typename,
typename,
typename>
class _Base>
2574 operator>=(
const _CharT* __lhs,
2576 {
return __rhs.
compare(__lhs) <= 0; }
2585 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2586 template <
typename,
typename,
typename>
class _Base>
2590 { __lhs.
swap(__rhs); }
2592 _GLIBCXX_END_NAMESPACE_VERSION
2595 namespace std _GLIBCXX_VISIBILITY(default)
2597 _GLIBCXX_BEGIN_NAMESPACE_VERSION
2611 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2612 template <
typename,
typename,
typename>
class _Base>
2613 basic_istream<_CharT, _Traits>&
2614 operator>>(basic_istream<_CharT, _Traits>& __is,
2616 _Alloc, _Base>& __str);
2627 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2628 template <
typename,
typename,
typename>
class _Base>
2629 inline basic_ostream<_CharT, _Traits>&
2636 return __ostream_insert(__os, __str.
data(), __str.
size());
2653 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2654 template <
typename,
typename,
typename>
class _Base>
2655 basic_istream<_CharT, _Traits>&
2656 getline(basic_istream<_CharT, _Traits>& __is,
2673 template<
typename _CharT,
typename _Traits,
typename _Alloc,
2674 template <
typename,
typename,
typename>
class _Base>
2675 inline basic_istream<_CharT, _Traits>&
2680 _GLIBCXX_END_NAMESPACE_VERSION
2683 #if __cplusplus >= 201103L 2687 namespace __gnu_cxx _GLIBCXX_VISIBILITY(default)
2689 _GLIBCXX_BEGIN_NAMESPACE_VERSION
2691 #if _GLIBCXX_USE_C99_STDLIB 2694 stoi(
const __vstring& __str, std::size_t* __idx = 0,
int __base = 10)
2695 {
return __gnu_cxx::__stoa<long, int>(&std::strtol,
"stoi", __str.c_str(),
2699 stol(
const __vstring& __str, std::size_t* __idx = 0,
int __base = 10)
2700 {
return __gnu_cxx::__stoa(&std::strtol,
"stol", __str.c_str(),
2703 inline unsigned long 2704 stoul(
const __vstring& __str, std::size_t* __idx = 0,
int __base = 10)
2705 {
return __gnu_cxx::__stoa(&std::strtoul,
"stoul", __str.c_str(),
2709 stoll(
const __vstring& __str, std::size_t* __idx = 0,
int __base = 10)
2710 {
return __gnu_cxx::__stoa(&std::strtoll,
"stoll", __str.c_str(),
2713 inline unsigned long long 2714 stoull(
const __vstring& __str, std::size_t* __idx,
int __base = 10)
2715 {
return __gnu_cxx::__stoa(&std::strtoull,
"stoull", __str.c_str(),
2720 stof(
const __vstring& __str, std::size_t* __idx = 0)
2721 {
return __gnu_cxx::__stoa(&std::strtof,
"stof", __str.c_str(), __idx); }
2724 stod(
const __vstring& __str, std::size_t* __idx = 0)
2725 {
return __gnu_cxx::__stoa(&std::strtod,
"stod", __str.c_str(), __idx); }
2728 stold(
const __vstring& __str, std::size_t* __idx = 0)
2729 {
return __gnu_cxx::__stoa(&std::strtold,
"stold", __str.c_str(), __idx); }
2730 #endif // _GLIBCXX_USE_C99_STDLIB 2732 #if _GLIBCXX_USE_C99_STDIO 2737 to_string(
int __val)
2738 {
return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf, 4 *
sizeof(
int),
2742 to_string(
unsigned __val)
2743 {
return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf,
2744 4 *
sizeof(
unsigned),
2748 to_string(
long __val)
2749 {
return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf,
2754 to_string(
unsigned long __val)
2755 {
return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf,
2756 4 *
sizeof(
unsigned long),
2761 to_string(
long long __val)
2762 {
return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf,
2763 4 *
sizeof(
long long),
2767 to_string(
unsigned long long __val)
2768 {
return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf,
2769 4 *
sizeof(
unsigned long long),
2773 to_string(
float __val)
2775 const int __n = __numeric_traits<float>::__max_exponent10 + 20;
2776 return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf, __n,
2781 to_string(
double __val)
2783 const int __n = __numeric_traits<double>::__max_exponent10 + 20;
2784 return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf, __n,
2789 to_string(
long double __val)
2791 const int __n = __numeric_traits<long double>::__max_exponent10 + 20;
2792 return __gnu_cxx::__to_xstring<__vstring>(&std::vsnprintf, __n,
2795 #endif // _GLIBCXX_USE_C99_STDIO 2797 #if defined(_GLIBCXX_USE_WCHAR_T) && _GLIBCXX_USE_C99_WCHAR 2799 stoi(
const __wvstring& __str, std::size_t* __idx = 0,
int __base = 10)
2800 {
return __gnu_cxx::__stoa<long, int>(&std::wcstol,
"stoi", __str.c_str(),
2804 stol(
const __wvstring& __str, std::size_t* __idx = 0,
int __base = 10)
2805 {
return __gnu_cxx::__stoa(&std::wcstol,
"stol", __str.c_str(),
2808 inline unsigned long 2809 stoul(
const __wvstring& __str, std::size_t* __idx = 0,
int __base = 10)
2810 {
return __gnu_cxx::__stoa(&std::wcstoul,
"stoul", __str.c_str(),
2814 stoll(
const __wvstring& __str, std::size_t* __idx = 0,
int __base = 10)
2815 {
return __gnu_cxx::__stoa(&std::wcstoll,
"stoll", __str.c_str(),
2818 inline unsigned long long 2819 stoull(
const __wvstring& __str, std::size_t* __idx = 0,
int __base = 10)
2820 {
return __gnu_cxx::__stoa(&std::wcstoull,
"stoull", __str.c_str(),
2825 stof(
const __wvstring& __str, std::size_t* __idx = 0)
2826 {
return __gnu_cxx::__stoa(&std::wcstof,
"stof", __str.c_str(), __idx); }
2829 stod(
const __wvstring& __str, std::size_t* __idx = 0)
2830 {
return __gnu_cxx::__stoa(&std::wcstod,
"stod", __str.c_str(), __idx); }
2833 stold(
const __wvstring& __str, std::size_t* __idx = 0)
2834 {
return __gnu_cxx::__stoa(&std::wcstold,
"stold", __str.c_str(), __idx); }
2836 #ifndef _GLIBCXX_HAVE_BROKEN_VSWPRINTF 2839 to_wstring(
int __val)
2840 {
return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf,
2845 to_wstring(
unsigned __val)
2846 {
return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf,
2847 4 *
sizeof(
unsigned),
2851 to_wstring(
long __val)
2852 {
return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf,
2857 to_wstring(
unsigned long __val)
2858 {
return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf,
2859 4 *
sizeof(
unsigned long),
2863 to_wstring(
long long __val)
2864 {
return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf,
2865 4 *
sizeof(
long long),
2869 to_wstring(
unsigned long long __val)
2870 {
return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf,
2871 4 *
sizeof(
unsigned long long),
2875 to_wstring(
float __val)
2877 const int __n = __numeric_traits<float>::__max_exponent10 + 20;
2878 return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf, __n,
2883 to_wstring(
double __val)
2885 const int __n = __numeric_traits<double>::__max_exponent10 + 20;
2886 return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf, __n,
2891 to_wstring(
long double __val)
2893 const int __n = __numeric_traits<long double>::__max_exponent10 + 20;
2894 return __gnu_cxx::__to_xstring<__wvstring>(&std::vswprintf, __n,
2897 #endif // _GLIBCXX_HAVE_BROKEN_VSWPRINTF 2898 #endif // _GLIBCXX_USE_WCHAR_T && _GLIBCXX_USE_C99_WCHAR 2900 _GLIBCXX_END_NAMESPACE_VERSION
2905 #if __cplusplus >= 201103L 2909 namespace std _GLIBCXX_VISIBILITY(default)
2911 _GLIBCXX_BEGIN_NAMESPACE_VERSION
2916 :
public __hash_base<size_t, __gnu_cxx::__vstring>
2920 {
return std::_Hash_impl::hash(__s.
data(), __s.
length()); }
2923 #ifdef _GLIBCXX_USE_WCHAR_T 2927 :
public __hash_base<size_t, __gnu_cxx::__wvstring>
2931 {
return std::_Hash_impl::hash(__s.
data(),
2932 __s.
length() *
sizeof(wchar_t)); }
2936 #ifdef _GLIBCXX_USE_C99_STDINT_TR1 2940 :
public __hash_base<size_t, __gnu_cxx::__u16vstring>
2944 {
return std::_Hash_impl::hash(__s.
data(),
2945 __s.
length() *
sizeof(char16_t)); }
2951 :
public __hash_base<size_t, __gnu_cxx::__u32vstring>
2955 {
return std::_Hash_impl::hash(__s.
data(),
2956 __s.
length() *
sizeof(char32_t)); }
2960 _GLIBCXX_END_NAMESPACE_VERSION
allocator_type get_allocator() const noexcept
Return copy of allocator used to construct this string.
__versa_string(_InputIterator __beg, _InputIterator __end, const _Alloc &__a=_Alloc())
Construct string as copy of a range.
std::basic_istream< _CharT, _Traits > & operator>>(std::basic_istream< _CharT, _Traits > &__is, bitset< _Nb > &__x)
Global I/O operators for bitsets.
One of the comparison functors.
__versa_string & assign(std::initializer_list< _CharT > __l)
Set value to an initializer_list of characters.
const_iterator end() const noexcept
reverse_iterator rbegin() noexcept
__versa_string & replace(const_iterator __i1, const_iterator __i2, const _CharT *__s)
Replace range of characters with C string.
__versa_string & assign(const __versa_string &__str)
Set value to contents of another string.
__versa_string & insert(size_type __pos1, const __versa_string &__str, size_type __pos2, size_type __n)
Insert a substring.
__versa_string & assign(size_type __n, _CharT __c)
Set value to multiple characters.
Template class __versa_string.Data structure managing sequences of characters and character-like obje...
reference front() noexcept
The standard allocator, as per [20.4].
const_iterator begin() const noexcept
bool empty() const noexcept
__versa_string & replace(size_type __pos, size_type __n1, const _CharT *__s)
Replace characters with value of a C string.
__versa_string & append(size_type __n, _CharT __c)
Append multiple characters.
__versa_string & append(_InputIterator __first, _InputIterator __last)
Append a range of characters.
size_type find_last_of(_CharT __c, size_type __pos=npos) const noexcept
Find last position of a character.
iterator insert(const_iterator __p, std::initializer_list< _CharT > __l)
Insert an initializer_list of characters.
reference back() noexcept
const _CharT * c_str() const noexcept
Return const pointer to null-terminated contents.
__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, size_type __pos, size_type __n, const _Alloc &__a)
Construct string as copy of a substring.
__versa_string & operator+=(_CharT __c)
Append a character.
size_type rfind(const __versa_string &__str, size_type __pos=npos) const noexcept
Find last position of a string.
__versa_string & replace(size_type __pos, size_type __n1, size_type __n2, _CharT __c)
Replace characters with multiple characters.
__versa_string & append(const _CharT *__s, size_type __n)
Append a C substring.
size_type size() const noexcept
Returns the number of characters in the string, not including any null-termination.
size_type find_first_of(_CharT __c, size_type __pos=0) const noexcept
Find position of a character.
iterator erase(const_iterator __first, const_iterator __last)
Remove a range of characters.
Primary class template hash.
__versa_string & replace(const_iterator __i1, const_iterator __i2, _InputIterator __k1, _InputIterator __k2)
Replace range of characters with range.
size_type find(const __versa_string &__str, size_type __pos=0) const noexcept
Find position 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.
reference operator[](size_type __pos) noexcept
Subscript access to the data contained in the string.
__versa_string & operator=(_CharT __c)
Set value to string of length 1.
__versa_string & insert(size_type __pos, size_type __n, _CharT __c)
Insert multiple characters.
__versa_string(const _CharT *__s, const _Alloc &__a=_Alloc())
Construct string as copy of a C string.
__versa_string & replace(const_iterator __i1, const_iterator __i2, const _CharT *__s, size_type __n)
Replace range of characters with C substring.
char_type widen(char __c) const
Widens characters.
const_iterator cbegin() const noexcept
size_type find_first_of(const _CharT *__s, size_type __pos=0) const
Find position of a character of C string.
__versa_string & operator+=(const __versa_string &__str)
Append a string to this string.
size_type capacity() const noexcept
Template class basic_istream.
GNU extensions for public use.
~__versa_string() noexcept
Destroy the string instance.
size_type find(const _CharT *__s, size_type __pos=0) const
Find position of a C string.
__versa_string(__versa_string &&__str) noexcept
String move constructor.
size_type find_last_not_of(const _CharT *__s, size_type __pos=npos) const
Find last position of a character not in C string.
iterator begin() noexcept
__versa_string & erase(size_type __pos=0, size_type __n=npos)
Remove characters.
const_reference back() const noexcept
__versa_string & replace(size_type __pos, size_type __n1, const _CharT *__s, size_type __n2)
Replace characters with value of a C substring.
__versa_string & append(const _CharT *__s)
Append a C string.
const_reverse_iterator crbegin() const noexcept
__versa_string & operator=(const _CharT *__s)
Copy contents of __s into this string.
__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.
size_type copy(_CharT *__s, size_type __n, size_type __pos=0) const
Copy substring into C string.
const_reverse_iterator rbegin() const noexcept
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.
ISO C++ entities toplevel namespace is std.
void resize(size_type __n)
Resizes the string to the specified number of characters.
_GLIBCXX14_CONSTEXPR const _Tp & min(const _Tp &, const _Tp &)
This does what you think it does.
size_type length() const noexcept
Returns the number of characters in the string, not including any null-termination.
reverse_iterator rend() noexcept
__versa_string & operator=(__versa_string &&__str) noexcept
String move assignment operator.
__versa_string & operator+=(const _CharT *__s)
Append a C string.
void shrink_to_fit() noexcept
A non-binding request to reduce capacity() to size().
Basis for explicit traits specializations.
size_type rfind(const _CharT *__s, size_type __pos=npos) const
Find last position of a C string.
size_type find(const _CharT *__s, size_type __pos, size_type __n) const
Find position of a C substring.
__versa_string & operator=(std::initializer_list< _CharT > __l)
Set value to string constructed from initializer list.
iterator erase(const_iterator __position)
Remove one character.
const_reference at(size_type __n) const
Provides access to the data contained in the string.
__versa_string & assign(const __versa_string &__str, size_type __pos, size_type __n)
Set value to a substring of a string.
iterator insert(const_iterator __p, _InputIterator __beg, _InputIterator __end)
Insert a range of characters.
Template class basic_ostream.
std::basic_ostream< _CharT, _Traits > & operator<<(std::basic_ostream< _CharT, _Traits > &__os, const bitset< _Nb > &__x)
Global I/O operators for bitsets.
void pop_back()
Remove the last character.
const_reference operator[](size_type __pos) const noexcept
Subscript access to the data contained in the string.
__versa_string & assign(__versa_string &&__str) noexcept
Set value to contents of another string.
size_type find_first_of(const __versa_string &__str, size_type __pos=0) const noexcept
Find position of a character of string.
iterator insert(const_iterator __p, _CharT __c)
Insert one character.
const_iterator cend() const noexcept
__versa_string(size_type __n, _CharT __c, const _Alloc &__a=_Alloc())
Construct string as multiple characters.
__versa_string(const __versa_string &__str)
Construct string with copy of value of __str.
void swap(__versa_string &__s) noexcept
Swap contents with another string.
__versa_string & append(const __versa_string &__str, size_type __pos, size_type __n)
Append a substring.
const_reverse_iterator rend() const noexcept
__versa_string & insert(size_type __pos, const _CharT *__s, size_type __n)
Insert a C substring.
reference at(size_type __n)
Provides 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, size_type __n, const _Alloc &__a=_Alloc())
Construct string initialized by a character array.
__versa_string(std::initializer_list< _CharT > __l, const _Alloc &__a=_Alloc())
Construct string from an initializer list.
size_type find_first_not_of(const _CharT *__s, size_type __pos=0) const
Find position of a character not in C string.
__versa_string & replace(const_iterator __i1, const_iterator __i2, size_type __n, _CharT __c)
Replace range of characters with multiple characters.
__versa_string & operator=(const __versa_string &__str)
Assign the value of str to this string.
const_reference front() const noexcept
__versa_string & assign(const _CharT *__s, size_type __n)
Set value to a C substring.
iterator insert(const_iterator __p, size_type __n, _CharT __c)
Insert multiple characters.
__versa_string & operator+=(std::initializer_list< _CharT > __l)
Append an initializer_list of characters.
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.
__versa_string & insert(size_type __pos1, const __versa_string &__str)
Insert value of a string.
__versa_string(const __versa_string &__str, size_type __pos, size_type __n=npos)
Construct string as copy of a substring.
static const size_type npos
Value returned by various member functions when they fail.
__versa_string & assign(const _CharT *__s)
Set value to contents of a C string.
size_type max_size() const noexcept
Returns the size() of the largest possible string.
__versa_string(const _Alloc &__a=_Alloc()) noexcept
Construct an empty string using allocator a.
int compare(const __versa_string &__str) const
Compare to a string.
const_reverse_iterator crend() const noexcept
void resize(size_type __n, _CharT __c)
Resizes the string to the specified number of characters.
__versa_string & assign(_InputIterator __first, _InputIterator __last)
Set value to a range of characters.
void reserve(size_type __res_arg=0)
Attempt to preallocate enough memory for specified number of characters.
__versa_string & append(std::initializer_list< _CharT > __l)
Append an initializer_list of characters.
__versa_string & replace(const_iterator __i1, const_iterator __i2, std::initializer_list< _CharT > __l)
Replace range of characters with initializer_list.
__versa_string & insert(size_type __pos, const _CharT *__s)
Insert a C string.
void push_back(_CharT __c)
Append a single 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 & append(const __versa_string &__str)
Append a string to this string.
size_type find_first_not_of(const __versa_string &__str, size_type __pos=0) const noexcept
Find position of a character not in string.
const _CharT * data() const noexcept
Return const pointer to contents.
__versa_string & replace(const_iterator __i1, const_iterator __i2, const __versa_string &__str)
Replace range of characters with string.