38 #ifndef LIBPMEMOBJ_CPP_BASIC_STRING_HPP
39 #define LIBPMEMOBJ_CPP_BASIC_STRING_HPP
62 namespace experimental
71 template <
typename CharT,
typename Traits = std::
char_traits<CharT>>
75 using traits_type = Traits;
76 using value_type = CharT;
77 using size_type = std::size_t;
78 using difference_type = std::ptrdiff_t;
79 using reference = value_type &;
80 using const_reference =
const value_type &;
81 using pointer = value_type *;
82 using const_pointer =
const value_type *;
84 using const_iterator = const_pointer;
85 using reverse_iterator = std::reverse_iterator<iterator>;
86 using const_reverse_iterator = std::reverse_iterator<const_iterator>;
89 static constexpr size_type sso_capacity = (32 - 8) /
sizeof(CharT) - 1;
95 size_type count = npos);
96 basic_string(
const std::basic_string<CharT> &other, size_type pos,
97 size_type count = npos);
102 typename Enable =
typename std::enable_if<
126 size_type count = npos);
128 size_type pos, size_type count = npos);
131 template <
typename InputIt,
139 reference
at(size_type n);
140 const_reference
at(size_type n)
const;
141 const_reference
const_at(size_type n)
const;
143 const_reference
operator[](size_type n)
const;
145 const CharT &
front()
const;
146 const CharT &
cfront()
const;
148 const CharT &
back()
const;
149 const CharT &
cback()
const;
151 const CharT *
data()
const noexcept;
152 const CharT *
cdata()
const noexcept;
153 const CharT *
c_str()
const noexcept;
157 const_iterator
begin()
const noexcept;
158 const_iterator
cbegin()
const noexcept;
160 const_iterator
end()
const noexcept;
161 const_iterator
cend()
const noexcept;
162 reverse_iterator
rbegin();
163 const_reverse_iterator
rbegin()
const noexcept;
164 const_reverse_iterator
crbegin()
const noexcept;
165 reverse_iterator
rend();
166 const_reverse_iterator
rend()
const noexcept;
167 const_reverse_iterator
crend()
const noexcept;
170 bool empty()
const noexcept;
171 size_type
size()
const noexcept;
172 size_type
length()
const noexcept;
173 size_type
max_size()
const noexcept;
174 size_type
capacity()
const noexcept;
175 void resize(size_type count, CharT ch);
177 void reserve(size_type new_cap = 0);
186 template <
typename T,
187 typename Enable =
typename std::enable_if<
188 std::is_convertible<T, size_type>::value>::type>
190 template <
typename T,
191 typename Enable =
typename std::enable_if<
192 !std::is_convertible<T, size_type>::value>::type>
198 size_type count = npos);
201 template <
typename InputIt,
208 int compare(
const std::basic_string<CharT> &other)
const;
209 int compare(size_type pos, size_type count,
211 int compare(size_type pos, size_type count,
212 const std::basic_string<CharT> &other)
const;
214 size_type pos2, size_type count2 = npos)
const;
215 int compare(size_type pos1, size_type count1,
216 const std::basic_string<CharT> &other, size_type pos2,
217 size_type count2 = npos)
const;
218 int compare(
const CharT *s)
const;
219 int compare(size_type pos, size_type count,
const CharT *s)
const;
220 int compare(size_type pos, size_type count1,
const CharT *s,
221 size_type count2)
const;
224 static const size_type npos =
static_cast<size_type
>(-1);
268 static constexpr size_type _sso_mask = 1ULL
269 << (std::numeric_limits<size_type>::digits - 1);
272 bool is_sso_used()
const;
276 typename Enable =
typename std::enable_if<
278 size_type
get_size(InputIt first, InputIt last)
const;
279 size_type
get_size(size_type count, value_type ch)
const;
281 template <
typename... Args>
282 pointer
replace(Args &&... args);
283 template <
typename... Args>
288 typename Enable =
typename std::enable_if<
295 typename Enable =
typename std::enable_if<
322 template <
typename CharT,
typename Traits>
329 initialize(0U, value_type(
'\0'));
346 template <
typename CharT,
typename Traits>
353 initialize(count, ch);
373 template <
typename CharT,
typename Traits>
375 size_type pos, size_type count)
380 if (pos > other.
size())
381 throw std::out_of_range(
"Index out of range.");
383 if (count == npos || pos + count > other.
size())
384 count = other.
size() - pos;
386 auto first =
static_cast<difference_type
>(pos);
387 auto last = first +
static_cast<difference_type
>(count);
390 initialize(other.
cbegin() + first, other.
cbegin() + last);
411 template <
typename CharT,
typename Traits>
413 size_type pos, size_type count)
418 if (pos > other.size())
419 throw std::out_of_range(
"Index out of range.");
421 if (count == npos || pos + count > other.size())
422 count = other.size() - pos;
424 auto first =
static_cast<difference_type
>(pos);
425 auto last = first +
static_cast<difference_type
>(count);
428 initialize(other.cbegin() + first, other.cbegin() + last);
446 template <
typename CharT,
typename Traits>
453 initialize(s, s + count);
469 template <
typename CharT,
typename Traits>
475 auto length = traits_type::length(s);
478 initialize(s, s + length);
497 template <
typename CharT,
typename Traits>
498 template <
typename InputIt,
typename Enable>
501 auto len = std::distance(first, last);
507 allocate(
static_cast<size_type
>(len));
508 initialize(first, last);
525 template <
typename CharT,
typename Traits>
531 allocate(other.
size());
550 template <
typename CharT,
typename Traits>
570 template <
typename CharT,
typename Traits>
576 allocate(other.size());
577 initialize(std::move(other));
579 if (other.is_sso_used())
580 other.initialize(0U, value_type(
'\0'));
597 template <
typename CharT,
typename Traits>
603 allocate(ilist.size());
604 initialize(ilist.begin(), ilist.end());
612 template <
typename CharT,
typename Traits>
616 detail::destroy<non_sso_type>(non_sso.data);
628 template <
typename CharT,
typename Traits>
632 return assign(other);
645 template <
typename CharT,
typename Traits>
649 return assign(other);
661 template <
typename CharT,
typename Traits>
665 return assign(std::move(other));
676 template <
typename CharT,
typename Traits>
691 template <
typename CharT,
typename Traits>
695 return assign(1, ch);
707 template <
typename CharT,
typename Traits>
711 return assign(ilist);
724 template <
typename CharT,
typename Traits>
728 auto pop = get_pool();
744 template <
typename CharT,
typename Traits>
751 auto pop = get_pool();
768 template <
typename CharT,
typename Traits>
772 return assign(other.cbegin(), other.cend());
787 template <
typename CharT,
typename Traits>
792 if (pos > other.
size())
793 throw std::out_of_range(
"Index out of range.");
795 if (count == npos || pos + count > other.
size())
796 count = other.
size() - pos;
798 auto pop = get_pool();
799 auto first =
static_cast<difference_type
>(pos);
800 auto last = first +
static_cast<difference_type
>(count);
823 template <
typename CharT,
typename Traits>
826 size_type pos, size_type count)
828 if (pos > other.size())
829 throw std::out_of_range(
"Index out of range.");
831 if (count == npos || pos + count > other.size())
832 count = other.size() - pos;
834 return assign(other.c_str() + pos, count);
847 template <
typename CharT,
typename Traits>
851 auto pop = get_pool();
866 template <
typename CharT,
typename Traits>
870 auto pop = get_pool();
872 auto length = traits_type::length(s);
890 template <
typename CharT,
typename Traits>
891 template <
typename InputIt,
typename Enable>
895 auto pop = get_pool();
911 template <
typename CharT,
typename Traits>
918 auto pop = get_pool();
921 replace(std::move(other));
923 if (other.is_sso_used())
924 other.initialize(0U, value_type(
'\0'));
939 template <
typename CharT,
typename Traits>
943 return assign(ilist.begin(), ilist.end());
951 template <
typename CharT,
typename Traits>
955 return is_sso_used() ?
iterator(&*sso.data.begin())
964 template <
typename CharT,
typename Traits>
965 typename basic_string<CharT, Traits>::const_iterator
976 template <
typename CharT,
typename Traits>
977 typename basic_string<CharT, Traits>::const_iterator
980 return is_sso_used() ? const_iterator(&*sso.data.cbegin())
981 : const_iterator(&*non_sso.data.cbegin());
989 template <
typename CharT,
typename Traits>
993 return begin() +
static_cast<difference_type
>(size());
1002 template <
typename CharT,
typename Traits>
1003 typename basic_string<CharT, Traits>::const_iterator
1006 return cbegin() +
static_cast<difference_type
>(size());
1015 template <
typename CharT,
typename Traits>
1016 typename basic_string<CharT, Traits>::const_iterator
1019 return cbegin() +
static_cast<difference_type
>(size());
1028 template <
typename CharT,
typename Traits>
1029 typename basic_string<CharT, Traits>::reverse_iterator
1032 return reverse_iterator(
end());
1041 template <
typename CharT,
typename Traits>
1042 typename basic_string<CharT, Traits>::const_reverse_iterator
1054 template <
typename CharT,
typename Traits>
1055 typename basic_string<CharT, Traits>::const_reverse_iterator
1058 return const_reverse_iterator(
cend());
1067 template <
typename CharT,
typename Traits>
1068 typename basic_string<CharT, Traits>::reverse_iterator
1071 return reverse_iterator(
begin());
1080 template <
typename CharT,
typename Traits>
1081 typename basic_string<CharT, Traits>::const_reverse_iterator
1093 template <
typename CharT,
typename Traits>
1094 typename basic_string<CharT, Traits>::const_reverse_iterator
1097 return const_reverse_iterator(
cbegin());
1113 template <
typename CharT,
typename Traits>
1114 typename basic_string<CharT, Traits>::reference
1118 throw std::out_of_range(
"string::at");
1120 return is_sso_used() ? sso.data[n] : non_sso.data[n];
1133 template <
typename CharT,
typename Traits>
1134 typename basic_string<CharT, Traits>::const_reference
1153 template <
typename CharT,
typename Traits>
1154 typename basic_string<CharT, Traits>::const_reference
1158 throw std::out_of_range(
"string::const_at");
1160 return is_sso_used()
1161 ?
static_cast<const sso_type &
>(sso.data)[n]
1176 template <
typename CharT,
typename Traits>
1180 return is_sso_used() ? sso.data[n] : non_sso.data[n];
1190 template <
typename CharT,
typename Traits>
1191 typename basic_string<CharT, Traits>::const_reference
1194 return is_sso_used() ? sso.data[n] : non_sso.data[n];
1206 template <
typename CharT,
typename Traits>
1218 template <
typename CharT,
typename Traits>
1233 template <
typename CharT,
typename Traits>
1249 template <
typename CharT,
typename Traits>
1253 return (*
this)[size() - 1];
1261 template <
typename CharT,
typename Traits>
1276 template <
typename CharT,
typename Traits>
1280 return static_cast<const basic_string &
>(*this)[size() - 1];
1286 template <
typename CharT,
typename Traits>
1287 typename basic_string<CharT, Traits>::size_type
1291 return get_sso_size();
1292 else if (non_sso.data.size() == 0)
1295 return non_sso.data.size() - 1;
1304 template <
typename CharT,
typename Traits>
1308 return is_sso_used() ? sso.
data.range(0, get_sso_size() + 1).begin()
1309 : non_sso.data.data();
1330 template <
typename CharT,
typename Traits>
1331 basic_string<CharT, Traits> &
1337 throw std::out_of_range(
"Index exceeds size.");
1339 count = (std::min)(count, sz - index);
1341 auto pop = get_pool();
1343 auto first =
begin() +
static_cast<difference_type
>(index);
1344 auto last = first +
static_cast<difference_type
>(count);
1346 if (is_sso_used()) {
1348 auto move_len = sz - index - count;
1350 auto dest = sso.data.range(index, move_len + 1).
begin();
1352 traits_type::move(dest, &*last, move_len);
1354 auto new_size = sz - count;
1355 set_sso_size(new_size);
1356 sso.data[new_size] = value_type(
'\0');
1359 non_sso.data.erase(first, last);
1381 template <
typename CharT,
typename Traits>
1385 return erase(pos, pos + 1);
1406 template <
typename CharT,
typename Traits>
1411 static_cast<size_type
>(std::distance(
cbegin(), first));
1412 size_type len =
static_cast<size_type
>(std::distance(first, last));
1416 return begin() +
static_cast<difference_type
>(index);
1438 template <
typename CharT,
typename Traits>
1443 auto new_size = sz + count;
1445 if (new_size > max_size())
1446 throw std::length_error(
"Size exceeds max size.");
1448 if (is_sso_used()) {
1449 auto pop = get_pool();
1452 if (new_size > sso_capacity) {
1453 sso_to_large(new_size);
1455 non_sso.data.insert(
1456 non_sso.data.cbegin() +
1457 static_cast<difference_type
>(
1475 sso.data.range(sz, count + 1).begin();
1476 traits_type::assign(dest, count, ch);
1478 set_sso_size(new_size);
1479 sso.data[new_size] = value_type(
'\0');
1483 non_sso.data.insert(non_sso.data.cbegin() +
1484 static_cast<difference_type
>(sz),
1509 template <
typename CharT,
typename Traits>
1513 return append(str.
data(), str.
size());
1541 template <
typename CharT,
typename Traits>
1546 auto sz = str.
size();
1549 throw std::out_of_range(
"Index out of range.");
1551 count = (std::min)(count, sz - pos);
1553 append(str.
data() + pos, count);
1577 template <
typename CharT,
typename Traits>
1581 return append(s, s + count);
1603 template <
typename CharT,
typename Traits>
1607 return append(s, traits_type::length(s));
1631 template <
typename CharT,
typename Traits>
1632 template <
typename InputIt,
typename Enable>
1637 auto count =
static_cast<size_type
>(std::distance(first, last));
1638 auto new_size = sz + count;
1640 if (new_size > max_size())
1641 throw std::length_error(
"Size exceeds max size.");
1643 if (is_sso_used()) {
1644 auto pop = get_pool();
1647 if (new_size > sso_capacity) {
1656 std::vector<value_type> str(first, last);
1658 sso_to_large(new_size);
1659 non_sso.data.insert(
1660 non_sso.data.cbegin() +
1661 static_cast<difference_type
>(
1663 str.begin(), str.end());
1673 sso.data.range(sz, count + 1).begin();
1674 std::copy(first, last, dest);
1676 set_sso_size(new_size);
1677 sso.data[new_size] = value_type(
'\0');
1681 non_sso.data.insert(non_sso.data.cbegin() +
1682 static_cast<difference_type
>(sz),
1707 template <
typename CharT,
typename Traits>
1711 return append(ilist.begin(), ilist.end());
1731 template <
typename CharT,
typename Traits>
1734 const CharT *s, size_type count2)
const
1737 throw std::out_of_range(
"Index out of range.");
1739 if (count1 > size() - pos)
1740 count1 = size() - pos;
1742 auto ret = traits_type::compare(cdata() + pos, s,
1743 std::min<size_type>(count1, count2));
1748 if (count1 < count2)
1750 else if (count1 == count2)
1764 template <
typename CharT,
typename Traits>
1768 return compare(0, size(), other.
cdata(), other.
size());
1779 template <
typename CharT,
typename Traits>
1782 const std::basic_string<CharT> &other)
const
1784 return compare(0, size(), other.data(), other.size());
1800 template <
typename CharT,
typename Traits>
1805 return compare(pos, count, other.
cdata(), other.
size());
1822 template <
typename CharT,
typename Traits>
1825 size_type pos, size_type count,
1826 const std::basic_string<CharT> &other)
const
1828 return compare(pos, count, other.data(), other.size());
1849 template <
typename CharT,
typename Traits>
1853 size_type count2)
const
1855 if (pos2 > other.
size())
1856 throw std::out_of_range(
"Index out of range.");
1858 if (count2 > other.
size() - pos2)
1859 count2 = other.
size() - pos2;
1861 return compare(pos1, count1, other.
cdata() + pos2, count2);
1882 template <
typename CharT,
typename Traits>
1885 const std::basic_string<CharT> &other,
1886 size_type pos2, size_type count2)
const
1888 if (pos2 > other.size())
1889 throw std::out_of_range(
"Index out of range.");
1891 if (count2 > other.size() - pos2)
1892 count2 = other.size() - pos2;
1894 return compare(pos1, count1, other.data() + pos2, count2);
1905 template <
typename CharT,
typename Traits>
1909 return compare(0, size(), s, traits_type::length(s));
1925 template <
typename CharT,
typename Traits>
1928 const CharT *s)
const
1930 return compare(pos, count, s, traits_type::length(s));
1936 template <
typename CharT,
typename Traits>
1940 return is_sso_used() ? sso.data.cdata() : non_sso.data.cdata();
1946 template <
typename CharT,
typename Traits>
1956 template <
typename CharT,
typename Traits>
1966 template <
typename CharT,
typename Traits>
1967 typename basic_string<CharT, Traits>::size_type
1976 template <
typename CharT,
typename Traits>
1977 typename basic_string<CharT, Traits>::size_type
1980 return PMEMOBJ_MAX_ALLOC_SIZE /
sizeof(CharT) - 1;
1987 template <
typename CharT,
typename Traits>
1988 typename basic_string<CharT, Traits>::size_type
1991 return is_sso_used() ? sso_capacity : non_sso.data.capacity() - 1;
2012 template <
typename CharT,
typename Traits>
2016 if (count > max_size())
2017 throw std::length_error(
"Count exceeds max size.");
2021 auto pop = get_pool();
2025 append(count - sz, ch);
2026 }
else if (is_sso_used()) {
2027 set_sso_size(count);
2028 sso.data[count] = value_type(
'\0');
2030 non_sso.data.resize(count + 1, ch);
2031 non_sso.data.back() = value_type(
'\0');
2053 template <
typename CharT,
typename Traits>
2057 resize(count, CharT());
2078 template <
typename CharT,
typename Traits>
2082 if (new_cap > max_size())
2083 throw std::length_error(
"New capacity exceeds max size.");
2085 if (new_cap < capacity() || new_cap <= sso_capacity)
2088 if (is_sso_used()) {
2089 auto pop = get_pool();
2093 non_sso.data.reserve(new_cap + 1);
2109 template <
typename CharT,
typename Traits>
2116 if (size() <= sso_capacity) {
2117 auto pop = get_pool();
2121 non_sso.data.shrink_to_fit();
2134 template <
typename CharT,
typename Traits>
2144 template <
typename CharT,
typename Traits>
2151 template <
typename CharT,
typename Traits>
2155 return sso._size & _sso_mask;
2158 template <
typename CharT,
typename Traits>
2160 basic_string<CharT, Traits>::destroy_data()
2162 assert(pmemobj_tx_stage() == TX_STAGE_WORK);
2164 if (is_sso_used()) {
2168 non_sso.data.free_data();
2169 detail::destroy<decltype(non_sso.data)>(non_sso.data);
2179 template <
typename CharT,
typename Traits>
2180 template <
typename InputIt,
typename Enable>
2181 typename basic_string<CharT, Traits>::size_type
2184 return static_cast<size_type
>(std::distance(first, last));
2193 template <
typename CharT,
typename Traits>
2194 typename basic_string<CharT, Traits>::size_type
2206 template <
typename CharT,
typename Traits>
2207 typename basic_string<CharT, Traits>::size_type
2210 return other.
size();
2220 template <
typename CharT,
typename Traits>
2221 template <
typename... Args>
2222 typename basic_string<CharT, Traits>::pointer
2225 assert(pmemobj_tx_stage() == TX_STAGE_WORK);
2227 auto new_size = get_size(std::forward<Args>(args)...);
2230 if (!is_sso_used() && new_size <= capacity())
2231 return assign_large_data(std::forward<Args>(args)...);
2236 return initialize(std::forward<Args>(args)...);
2250 template <
typename CharT,
typename Traits>
2251 template <
typename... Args>
2252 typename basic_string<CharT, Traits>::pointer
2255 assert(pmemobj_tx_stage() == TX_STAGE_WORK);
2257 auto size = get_size(std::forward<Args>(args)...);
2259 if (is_sso_used()) {
2261 return assign_sso_data(std::forward<Args>(args)...);
2263 return assign_large_data(std::forward<Args>(args)...);
2276 template <
typename CharT,
typename Traits>
2280 assert(pmemobj_tx_stage() == TX_STAGE_WORK);
2282 if (capacity <= sso_capacity) {
2292 if (!is_sso_used()) {
2293 detail::conditional_add_to_tx(&non_sso.data);
2294 detail::create<decltype(non_sso.data)>(&non_sso.data);
2295 non_sso.data.reserve(capacity +
sizeof(
'\0'));
2302 template <
typename CharT,
typename Traits>
2303 template <
typename InputIt,
typename Enable>
2304 typename basic_string<CharT, Traits>::pointer
2307 auto size =
static_cast<size_type
>(std::distance(first, last));
2309 assert(pmemobj_tx_stage() == TX_STAGE_WORK);
2310 assert(size <= sso_capacity);
2312 auto dest = sso.data.range(0, size + 1).begin();
2313 std::copy(first, last, dest);
2315 dest[size] = value_type(
'\0');
2323 template <
typename CharT,
typename Traits>
2324 typename basic_string<CharT, Traits>::pointer
2327 assert(pmemobj_tx_stage() == TX_STAGE_WORK);
2328 assert(count <= sso_capacity);
2330 auto dest = sso.data.range(0, count + 1).begin();
2331 traits_type::assign(dest, count, ch);
2333 dest[count] = value_type(
'\0');
2341 template <
typename CharT,
typename Traits>
2342 typename basic_string<CharT, Traits>::pointer
2345 assert(pmemobj_tx_stage() == TX_STAGE_WORK);
2347 return assign_sso_data(other.cbegin(), other.cend());
2354 template <
typename CharT,
typename Traits>
2355 template <
typename InputIt,
typename Enable>
2356 typename basic_string<CharT, Traits>::pointer
2359 assert(pmemobj_tx_stage() == TX_STAGE_WORK);
2361 auto size =
static_cast<size_type
>(std::distance(first, last));
2363 non_sso.data.reserve(size + 1);
2364 non_sso.data.assign(first, last);
2365 non_sso.data.push_back(value_type(
'\0'));
2367 return non_sso.data.data();
2374 template <
typename CharT,
typename Traits>
2375 typename basic_string<CharT, Traits>::pointer
2378 assert(pmemobj_tx_stage() == TX_STAGE_WORK);
2380 non_sso.data.reserve(count + 1);
2381 non_sso.data.assign(count, ch);
2382 non_sso.data.push_back(value_type(
'\0'));
2384 return non_sso.data.data();
2391 template <
typename CharT,
typename Traits>
2392 typename basic_string<CharT, Traits>::pointer
2395 assert(pmemobj_tx_stage() == TX_STAGE_WORK);
2397 if (other.is_sso_used())
2398 return assign_large_data(other.cbegin(), other.cend());
2400 non_sso.data = std::move(other.non_sso.data);
2402 return non_sso.data.data();
2408 template <
typename CharT,
typename Traits>
2412 auto pop = pmemobj_pool_by_ptr(
this);
2413 assert(pop !=
nullptr);
2421 template <
typename CharT,
typename Traits>
2425 if (pmemobj_pool_by_ptr(
this) ==
nullptr)
2432 template <
typename CharT,
typename Traits>
2436 if (pmemobj_tx_stage() != TX_STAGE_WORK)
2444 template <
typename CharT,
typename Traits>
2449 check_tx_stage_work();
2455 template <
typename CharT,
typename Traits>
2462 #if LIBPMEMOBJ_CPP_VG_MEMCHECK_ENABLED
2463 VALGRIND_MAKE_MEM_DEFINED(&sso.data,
sizeof(sso.data));
2471 template <
typename CharT,
typename Traits>
2472 typename basic_string<CharT, Traits>::size_type
2475 return sso._size & ~_sso_mask;
2481 template <
typename CharT,
typename Traits>
2487 sso._size |= (size_type)(_sso_mask);
2493 template <
typename CharT,
typename Traits>
2497 sso._size &= ~_sso_mask;
2503 template <
typename CharT,
typename Traits>
2507 sso._size = new_size | _sso_mask;
2521 template <
typename CharT,
typename Traits>
2525 assert(pmemobj_tx_stage() == TX_STAGE_WORK);
2526 assert(new_capacity > sso_capacity);
2532 tmp[sz] = value_type(
'\0');
2535 allocate(new_capacity);
2542 assert(!is_sso_used());
2554 template <
typename CharT,
typename Traits>
2558 assert(pmemobj_tx_stage() == TX_STAGE_WORK);
2562 assert(sz <= sso_capacity);
2566 tmp[sz] = value_type(
'\0');
2576 assert(is_sso_used());
2583 template <
typename CharT,
typename Traits>
2584 template <
typename T,
typename Enable>
2588 return erase(
static_cast<size_type
>(param));
2595 template <
typename CharT,
typename Traits>
2596 template <
typename T,
typename Enable>
2600 return erase(
static_cast<const_iterator
>(param));
2606 template <
class CharT,
class Traits>
2617 template <
class CharT,
class Traits>
2628 template <
class CharT,
class Traits>
2639 template <
class CharT,
class Traits>
2650 template <
class CharT,
class Traits>
2661 template <
class CharT,
class Traits>
2672 template <
class CharT,
class Traits>
2682 template <
class CharT,
class Traits>
2692 template <
class CharT,
class Traits>
2702 template <
class CharT,
class Traits>
2712 template <
class CharT,
class Traits>
2722 template <
class CharT,
class Traits>
2732 template <
class CharT,
class Traits>
2742 template <
class CharT,
class Traits>
2752 template <
class CharT,
class Traits>
2762 template <
class CharT,
class Traits>
2772 template <
class CharT,
class Traits>
2782 template <
class CharT,
class Traits>
2792 template <
class CharT,
class Traits>
2803 template <
class CharT,
class Traits>
2814 template <
class CharT,
class Traits>
2816 operator<(
const std::basic_string<CharT, Traits> &lhs,
2825 template <
class CharT,
class Traits>
2827 operator<=(
const std::basic_string<CharT, Traits> &lhs,
2836 template <
class CharT,
class Traits>
2847 template <
class CharT,
class Traits>
2858 template <
class CharT,
class Traits>
2861 const std::basic_string<CharT, Traits> &rhs)
2869 template <
class CharT,
class Traits>
2872 const std::basic_string<CharT, Traits> &rhs)
2880 template <
class CharT,
class Traits>
2883 const std::basic_string<CharT, Traits> &rhs)
2891 template <
class CharT,
class Traits>
2894 const std::basic_string<CharT, Traits> &rhs)
2902 template <
class CharT,
class Traits>
2905 const std::basic_string<CharT, Traits> &rhs)
2913 template <
class CharT,
class Traits>
2916 const std::basic_string<CharT, Traits> &rhs)