33#ifndef _STLP_INTERNAL_ROPE_H
34#define _STLP_INTERNAL_ROPE_H
36#ifndef _STLP_INTERNAL_ALGOBASE_H
40#if !defined (_STLP_USE_NO_IOSTREAMS) && !defined (_STLP_INTERNAL_IOSFWD)
44#ifndef _STLP_INTERNAL_ALLOC_H
48#ifndef _STLP_INTERNAL_ITERATOR_H
52#ifndef _STLP_INTERNAL_ALGO_H
56#ifndef _STLP_INTERNAL_FUNCTION_BASE_H
60#ifndef _STLP_INTERNAL_NUMERIC_H
64#ifndef _STLP_INTERNAL_HASH_FUN_H
68#ifndef _STLP_CHAR_TRAITS_H
72#ifndef _STLP_INTERNAL_THREADS_H
76#ifdef _STLP_SGI_THREADS
80#ifndef _STLP_DONT_SUPPORT_REBIND_MEMBER_TEMPLATE
81# define _STLP_CREATE_ALLOCATOR(__atype,__a, _Tp) (_Alloc_traits<_Tp,__atype>::create_allocator(__a))
83# define _STLP_CREATE_ALLOCATOR(__atype,__a, _Tp) __stl_alloc_create(__a,(_Tp*)0)
91template<
class _CharT, _STLP_DFL_TMPL_PARAM(_Alloc, allocator<_CharT>) >
class rope;
104template <
class _CharT>
110#ifdef _STLP_HAS_WCHAR_T
120template<
class _CharT,
class _Alloc>
123 rope<_CharT,_Alloc> > {
130template <
class _CharT,
class _Alloc>
139template <
class _CharT>
143template <
class _CharT>
145{ _STLP_STD::_Construct(__p); }
147template <
class _CharT>
157template <
class _CharT>
162 _CharT* __buffer) = 0;
183template<
class _Sequence
184# if !(defined (_STLP_NON_TYPE_TMPL_PARAM_BUG) || \
185 defined ( _STLP_NO_DEFAULT_NON_TYPE_PARAM ))
186 ,
size_t _Buf_sz = 100
187# if defined(__sgi) && !defined(__GNUC__)
188# define __TYPEDEF_WORKAROUND
189 ,
class _V =
typename _Sequence::value_type
196# ifndef __TYPEDEF_WORKAROUND
199# if !(defined (_STLP_NON_TYPE_TMPL_PARAM_BUG) || \
200 defined ( _STLP_NO_DEFAULT_NON_TYPE_PARAM ))
205 enum { _Buf_sz = 100};
260 for (; __j < __len; __i++, __j++) {
289template<
class _CharT>
291#if !defined (_STLP_MEMBER_TEMPLATES)
296 virtual bool operator()(
const _CharT* __buffer,
size_t __len) = 0;
326template<
class _CharT,
class _Alloc>
342# define __ROPE_MAX_DEPTH 45
343# define __ROPE_DEPTH_SIZE 46
364#ifdef _STLP_NO_ARROW_OPERATOR
366# if defined (_STLP_CHECK_RUNTIME_COMPATIBILITY)
367 _STLP_CHECK_RUNTIME_COMPATIBILITY();
382#if defined (_STLP_CHECK_RUNTIME_COMPATIBILITY)
383 _STLP_CHECK_RUNTIME_COMPATIBILITY();
396 static size_t _S_rounded_up_size_aux(
size_t __n,
__true_type const& ) {
401 static size_t _S_rounded_up_size_aux(
size_t __n,
__false_type const& ) {
413 _STLP_STD::_Destroy_Range(__s, __s + __len);
415# ifndef _STLP_DONT_SUPPORT_REBIND_MEMBER_TEMPLATE
450template<
class _CharT,
class _Alloc>
477# ifdef _STLP_NO_ARROW_OPERATOR
486 if (
_M_data != this->_M_c_string) {
493template<
class _CharT,
class _Alloc>
508# ifdef _STLP_NO_ARROW_OPERATOR
520template <
class _CharT,
class _Alloc>
535# ifdef _STLP_NO_ARROW_OPERATOR
548 if (_M_delete_when_done) {
563template<
class _CharT,
class _Alloc>
582 (*__fn)(__start_pos +
_M_start, __req_len, __buffer);
624template<
class _CharT,
class _Alloc>
629# ifdef _STLP_USE_EXCEPTIONS
640 {
_M_ptr = __x;
return *
this; }
650template<
class _CharT,
class _Alloc>
674 inline operator _CharT ()
const;
682#ifdef _STLP_FUNCTION_TMPL_PARTIAL_ORDER
683template<
class _CharT,
class __Alloc>
684inline void swap(_Rope_char_ref_proxy <_CharT, __Alloc > __a,
685 _Rope_char_ref_proxy <_CharT, __Alloc > __b) {
697# define _ROPE_SWAP_SPECIALIZATION(_CharT, __Alloc) \
698 inline void swap(_Rope_char_ref_proxy <_CharT, __Alloc > __a, \
699 _Rope_char_ref_proxy <_CharT, __Alloc > __b) { \
700 _CharT __tmp = __a; \
707# ifndef _STLP_NO_WCHAR_T
713template<
class _CharT,
class _Alloc>
752template<
class _CharT,
class _Alloc>
781# if defined (__BORLANDC__) && (__BORLANDC__ < 0x560)
804# if defined (__BORLANDC__) && (__BORLANDC__ < 0x560)
870template<
class _CharT,
class _Alloc>
877# ifndef _STLP_HAS_NO_NAMESPACES
908#if !defined (__DMC__)
964template<
class _CharT,
class _Alloc>
1047 return _Self(_M_root_rope, __old_pos);
1052 return _Self(_M_root_rope, __old_pos);
1059# ifdef _STLP_USE_OLD_HP_ITERATOR_QUERIES
1060template <
class _CharT,
class _Alloc>
1063template <
class _CharT,
class _Alloc>
1065template <
class _CharT,
class _Alloc>
1067template <
class _CharT,
class _Alloc>
1070template <
class _CharT,
class _Alloc>
1072template <
class _CharT,
class _Alloc>
1076template <
class _CharT,
class _Alloc,
class _CharConsumer>
1079 size_t __begin,
size_t __end);
1082template <
class _CharT,
class _Alloc>
1084#
if defined (_STLP_USE_PARTIAL_SPEC_WORKAROUND)
1161 size_t __start,
size_t __endp1);
1164 const _CharT* __iter,
size_t __slen);
1169 const _CharT* __iter,
size_t __slen);
1179#if defined (_STLP_MEMBER_TEMPLATES)
1180 template <
class _CharConsumer>
1200 new(__space)
_RopeLeaf(__s, _p_size, __a);
1231 if (0 == _p_size)
return 0;
1258 const _CharT* __iter,
size_t __slen);
1263 (
_RopeLeaf* __r,
const _CharT* __iter,
size_t __slen);
1271#if !defined (__GNUC__) || (__GNUC__ < 3)
1294 size_t __start,
size_t __len,
1338 static void _S_dump(
_RopeRep* __r,
int __indent = 0);
1367 rope(
const _CharT* __s,
size_t __len,
1375 rope(
const _CharT *__s,
const _CharT *__e,
1383 __e._M_current_pos))
1389 __e._M_current_pos))
1412# define __exponentiate_threshold size_t(32)
1432 __remainder_rope.
_M_tree_ptr._M_data = __remainder;
1433 if (__exponent != 0) {
1446 if (1 == __exponent) {
1447 __result = __base_rope;
1453 if (0 != __remainder) {
1454 __result += __remainder_rope;
1457 __result = __remainder_rope;
1461# undef __exponentiate_threshold
1480#if !defined (_STLP_NO_MOVE_SEMANTIC)
1483 __src.
get()._M_tree_ptr._M_data = 0;
1545 void copy(_CharT* __buffer)
const {
1546 _STLP_STD::_Destroy_Range(__buffer, __buffer +
size());
1558 size_t _p_size =
size();
1559 size_t __len = (__pos +
__n > _p_size? _p_size - __pos :
__n);
1561 _STLP_STD::_Destroy_Range(__buffer, __buffer + __len);
1576 const _CharT*
c_str()
const;
1603 return (*
this)[__pos];
1639 return const_reverse_iterator(
end());
1643 return const_reverse_iterator(
end());
1646 const_reverse_iterator
rend()
const {
1647 return const_reverse_iterator(
begin());
1651 return const_reverse_iterator(
begin());
1666 append(__c_string, __len);
1704#if defined (_STLP_USE_PARTIAL_SPEC_WORKAROUND) && !defined (_STLP_FUNCTION_TMPL_PARTIAL_ORDER)
1705 void _M_swap_workaround(
_Self& __x) {
swap(__x); }
1712 if (0 == __old) {
_S_ref(__r);
return __r; }
1753 void insert(
size_t __p,
const _CharT* __c_string) {
1762 _CharT
__c = _CharT();
1766 void insert(
size_t __p,
const _CharT* __i,
const _CharT* __j) {
1767 _Self __r(__i, __j);
1773 _Self __r(__i, __j);
1779 _Self __r(__i, __j);
1790 const _CharT* __i,
size_t __i_len) {
1791 _Self __r(__i, __i_len);
1801 _Self __r(__c_string);
1806 const _CharT* __i,
const _CharT* __j) {
1807 _Self __r(__i, __j);
1813 _Self __r(__i, __j);
1819 _Self __r(__i, __j);
1834 void replace(
size_t __p,
const _CharT* __i,
size_t __i_len) {
1835 replace(__p, 1, __i, __i_len);
1838 void replace(
size_t __p,
const _CharT* __c_string) {
1842 void replace(
size_t __p,
const _CharT* __i,
const _CharT* __j) {
1864 erase(__p, __p + 1);
1897 const _CharT* __c_string)
1900 const _CharT* __i,
size_t __n)
1903 const _CharT* __i,
const _CharT* __j)
1931 size_t __p_index = __p.
index();
1936 size_t __p_index = __p.
index();
1937 erase(__p_index, 1);
1951 size_t __pos = __start.
index();
1962 size_t __pos = __start.
index();
1969 if (__pos >=
size())
1970# ifndef _STLP_OLD_ROPE_SEMANTICS
1978 __result_pos = __result.
index();
1979# ifndef _STLP_OLD_ROPE_SEMANTICS
1980 if (__result_pos ==
size()) __result_pos =
npos;
1982 return __result_pos;
1989 __result_pos = __result.
index();
1990# ifndef _STLP_OLD_ROPE_SEMANTICS
1991 if (__result_pos ==
size()) __result_pos =
npos;
1993 return __result_pos;
2023 return (*
this)[__pos];
2038 return copy(__pos,
__n, __buffer);
2062#if defined (__GNUC__) && (__GNUC__ == 2) && (__GNUC_MINOR__ == 96)
2063template <
class _CharT,
class _Alloc>
2067template <
class _CharT,
class _Alloc>
2072template <
class _CharT,
class _Alloc>
2079template <
class _CharT,
class _Alloc>
2084#ifdef _STLP_USE_SEPARATE_RELOPS_NAMESPACE
2086template <
class _CharT,
class _Alloc>
2089{
return !(__x == __y); }
2091template <
class _CharT,
class _Alloc>
2094{
return __y < __x; }
2096template <
class _CharT,
class _Alloc>
2099{
return !(__y < __x); }
2101template <
class _CharT,
class _Alloc>
2104{
return !(__x < __y); }
2108template <
class _CharT,
class _Alloc>
2113#if !defined( __MWERKS__ ) || __MWERKS__ >= 0x2000
2114template <
class _CharT,
class _Alloc>
2120template <
class _CharT,
class _Alloc>
2125template <
class _CharT,
class _Alloc>
2130template <
class _CharT,
class _Alloc>
2137template <
class _CharT,
class _Alloc>
2142#if defined (_STLP_USE_SEPARATE_RELOPS_NAMESPACE)
2143template <
class _CharT,
class _Alloc>
2146{
return !(__x == __y); }
2148template <
class _CharT,
class _Alloc>
2151{
return __y < __x; }
2153template <
class _CharT,
class _Alloc>
2156{
return !(__y < __x); }
2158template <
class _CharT,
class _Alloc>
2161{
return !(__x < __y); }
2164template <
class _CharT,
class _Alloc>
2169#if !defined( __MWERKS__ ) || __MWERKS__ >= 0x2000
2170template <
class _CharT,
class _Alloc>
2178template <
class _CharT,
class _Alloc>
2185template <
class _CharT,
class _Alloc>
2191template <
class _CharT,
class _Alloc>
2200template <
class _CharT,
class _Alloc>
2208template <
class _CharT,
class _Alloc>
2211 const _CharT* __right) {
2216template <
class _CharT,
class _Alloc>
2219 const _CharT* __right) {
2224template <
class _CharT,
class _Alloc>
2230template <
class _CharT,
class _Alloc>
2237template <
class _CharT,
class _Alloc>
2241 return __left.
compare(__right) < 0;
2244template <
class _CharT,
class _Alloc>
2248 return __left.
compare(__right) == 0;
2251#ifdef _STLP_USE_SEPARATE_RELOPS_NAMESPACE
2253template <
class _CharT,
class _Alloc>
2256 return !(__x == __y);
2259template <
class _CharT,
class _Alloc>
2265template <
class _CharT,
class _Alloc>
2268 return !(__y < __x);
2271template <
class _CharT,
class _Alloc>
2274 return !(__x < __y);
2277template <
class _CharT,
class _Alloc>
2280 return !(__x == __y);
2285template <
class _CharT,
class _Alloc>
2291#if !defined (_STLP_USE_NO_IOSTREAMS)
2292template<
class _CharT,
class _Traits,
class _Alloc>
2298#if defined (_STLP_HAS_WCHAR_T)
2303{
return __c.mutable_reference_at(__i); }
2305#if defined (_STLP_HAS_WCHAR_T)
2307{
return __c.mutable_reference_at(__i); }
2310#if defined (_STLP_FUNCTION_TMPL_PARTIAL_ORDER)
2311template <
class _CharT,
class _Alloc>
2317# ifdef _STLP_HAS_WCHAR_T
2318inline void swap(wrope& __x, wrope& __y) { __x.swap(__y); }
2327 size_t _p_size = __str.
size();
2329 if (0 == _p_size)
return 0;
2330 return 13*__str[0] + 5*__str[_p_size - 1] + _p_size;
2334#if defined (_STLP_HAS_WCHAR_T)
2336 size_t operator()(
const wrope& __str)
const {
2337 size_t _p_size = __str.size();
2339 if (0 == _p_size)
return 0;
2340 return 13*__str[0] + 5*__str[_p_size - 1] + _p_size;
2345#if (!defined (_STLP_MSVC) || (_STLP_MSVC >= 1310))
2347template<
class _CharT,
class _Alloc>
2348# if defined (__DMC__)
2361template <
class _CharT,
class _Alloc>
2363 if (_M_current_valid) {
2366 return _My_rope::_S_fetch(_M_root->_M_tree_ptr._M_data, _M_pos);
2370#if defined (_STLP_CLASS_PARTIAL_SPECIALIZATION) && !defined (_STLP_NO_MOVE_SEMANTIC)
2371template <
class _CharT,
class _Alloc>
2381#if !defined (_STLP_LINK_TIME_INSTANTIATION)
#define random_access_iterator_tag
_STLP_INLINE_LOOP _InputIter __last
#define _STLP_FORCE_ALLOCATORS(a, y)
allocator< _Tp2 > &_STLP_CALL __stl_alloc_rebind(allocator< _Tp1 > &__a, const _Tp2 *)
bool _STLP_CALL operator!=(const allocator< _T1 > &, const allocator< _T2 > &) _STLP_NOTHROW
#define _STLP_MPWFIX_CATCH
bool _STLP_CALL operator>(const _Bit_iterator_base &__x, const _Bit_iterator_base &__y)
bool _STLP_CALL operator>=(const _Bit_iterator_base &__x, const _Bit_iterator_base &__y)
bool _STLP_CALL operator<=(const _Bit_iterator_base &__x, const _Bit_iterator_base &__y)
void _Copy_Construct(_Tp *__p, const _Tp &__val)
#define _STLP_ASSERT(expr)
_Tp __power(_Tp __x, _Integer __n, _MonoidOperation __opr)
crope::reference __mutable_reference_at(crope &__c, size_t __i)
void _S_construct_null(_CharT *__p)
bool operator<(const _Rope_const_iterator< _CharT, _Alloc > &__x, const _Rope_const_iterator< _CharT, _Alloc > &__y)
_Rope_const_iterator< _CharT, _Alloc > operator+(const _Rope_const_iterator< _CharT, _Alloc > &__x, ptrdiff_t __n)
ptrdiff_t operator-(const _Rope_const_iterator< _CharT, _Alloc > &__x, const _Rope_const_iterator< _CharT, _Alloc > &__y)
bool _S_apply_to_pieces(_CharConsumer &__c, _Rope_RopeRep< _CharT, _Alloc > *__r, size_t __begin, size_t __end)
rope< char, allocator< char > > crope
void rotate(_Rope_iterator< char, allocator< char > > __first, _Rope_iterator< char, allocator< char > > __middle, _Rope_iterator< char, allocator< char > > __last)
basic_ostream< _CharT, _Traits > & operator<<(basic_ostream< _CharT, _Traits > &__o, const rope< _CharT, _Alloc > &__r)
rope< _CharT, _Alloc > __identity_element(_Rope_Concat_fn< _CharT, _Alloc >)
bool operator==(const _Rope_const_iterator< _CharT, _Alloc > &__x, const _Rope_const_iterator< _CharT, _Alloc > &__y)
rope< _CharT, _Alloc > & operator+=(rope< _CharT, _Alloc > &__left, const rope< _CharT, _Alloc > &__right)
void _Rope_rotate(_Rope_iterator< _CharT, _Alloc > __first, _Rope_iterator< _CharT, _Alloc > __middle, _Rope_iterator< _CharT, _Alloc > __last)
#define _STLP_CREATE_ALLOCATOR(__atype, __a, _Tp)
#define __ROPE_DEPTH_SIZE
#define __exponentiate_threshold
#define _ROPE_SWAP_SPECIALIZATION(_CharT, __Alloc)
_STLP_MOVE_TO_STD_NAMESPACE void _S_construct_null_aux(_CharT *__p, const __true_type &)
_STLP_MOVE_TO_STD_NAMESPACE void uninitialized_fill_n(_ForwardIter __first, _Size __n, const _Tp &__x)
_STLP_MOVE_TO_PRIV_NAMESPACE _STLP_INLINE_LOOP pair< _InputIter, _ForwardIter > __ucopy_n(_InputIter __first, _Size __count, _ForwardIter __result, const input_iterator_tag &)
void get(int argc, const char *argv[])
virtual bool operator()(const _CharT *__buffer, size_t __len)=0
virtual ~_Rope_char_consumer()
_Rope_char_ref_proxy< _CharT, _Alloc > operator*() const
_Rope_char_ptr_proxy< _CharT, _Alloc > _Self
rope< _CharT, _Alloc > * _M_root
friend class _Rope_char_ref_proxy< _CharT, _Alloc >
_Rope_char_ptr_proxy(_CharT *__x)
_Self & operator=(const _Self &__x)
_Rope_char_ptr_proxy(const _Rope_char_ref_proxy< _CharT, _Alloc > &__x)
_Rope_char_ptr_proxy(const _Self &__x)
_Rope_char_ref_proxy(const _Self &__x)
_Rope_char_ref_proxy(_My_rope *__r, size_t __p)
_Self & operator=(_CharT __c)
_Rope_RopeRep< _CharT, _Alloc > _RopeRep
rope< _CharT, _Alloc > _My_rope
_Rope_char_ref_proxy< _CharT, _Alloc > _Self
_Rope_char_ptr_proxy< _CharT, _Alloc > operator&() const
_Rope_char_ref_proxy(_My_rope *__r, size_t __p, _CharT __c)
_Rope_self_destruct_ptr< _CharT, _Alloc > _Self_destruct_ptr
reference operator[](size_t __n)
_Rope_RopeRep< _CharT, _Alloc > _RopeRep
_Self & operator-=(ptrdiff_t __n)
_Rope_const_iterator(const _Self &__x)
_Rope_const_iterator(const rope< _CharT, _Alloc > &__r, size_t __pos)
_Rope_const_iterator(const _Rope_iterator< _CharT, _Alloc > &__x)
_Self & operator+=(ptrdiff_t __n)
_Rope_const_iterator< _CharT, _Alloc > _Self
_Rope_const_iterator(const _RopeRep *__root, size_t __pos)
random_access_iterator_tag iterator_category
ptrdiff_t difference_type
_Rope_iterator_base< _CharT, _Alloc > _Base
_Self & operator=(const _Self &__x)
_Self & operator=(const _Self &__x)
struct _Rope_iterator_base::@1858 _M_tmp_buf
static void _S_setcache(_Rope_iterator_base< _CharT, _Alloc > &__x)
static void _S_setbuf(_Rope_iterator_base< _CharT, _Alloc > &__x)
_RopeRep const * _M_data[_S_path_cache_len]
unsigned char _M_path_directions
_Rope_iterator_base(const _Self &__x)
void _M_copy_buf(const _Self &__x)
struct _Rope_iterator_base::@1857 _M_path_end
_Rope_RopeRep< _CharT, _Alloc > _RopeRep
_Rope_RopeConcatenation< _CharT, _Alloc > _RopeConcat
static void _S_setcache_for_incr(_Rope_iterator_base< _CharT, _Alloc > &__x)
_Rope_iterator_base< _CharT, _Alloc > _Self
_Rope_iterator_base(_RopeRep *__root, size_t __pos)
_Rope_RopeRep< _CharT, _Alloc > _RopeRep
_Self & operator=(const _Self &__x)
rope< _CharT, _Alloc > * _M_root_rope
_Rope_iterator< _CharT, _Alloc > _Self
ptrdiff_t difference_type
_Rope_char_ref_proxy< _CharT, _Alloc > reference
_Rope_iterator_base< _CharT, _Alloc > _Base
_Rope_char_ref_proxy< _CharT, _Alloc > * pointer
random_access_iterator_tag iterator_category
rope< _CharT, _Alloc > & container()
reference operator[](ptrdiff_t __n)
_Self & operator+=(ptrdiff_t __n)
_Self & operator-=(ptrdiff_t __n)
_Rope_iterator(const _Self &__x)
static size_t _STLP_CALL length(const char_type *__s)
virtual void operator()(size_t __start_pos, size_t __len, _CharT *__buffer)=0
void replace(const iterator &__p, _CharT __c)
void replace(size_t __p, const _CharT *__i, const _CharT *__j)
ptrdiff_t difference_type
void replace(const iterator &__p, const iterator &__q, const _CharT *__i, const _CharT *__j)
void apply_to_pieces(size_t __begin, size_t __end, _CharConsumer &__c) const
const_reverse_iterator const_rbegin() const
void replace(const iterator &__p, iterator __i, iterator __j)
void insert(size_t __p, const _CharT *__c_string)
size_type find(const _CharT *__s, size_type __pos=0) const
void replace(const iterator &__p, const_iterator __i, const_iterator __j)
static _RopeLeaf * _S_destr_leaf_concat_char_iter(_RopeLeaf *__r, const _CharT *__iter, size_t __slen)
const_reverse_iterator rbegin() const
void _STLP_FUNCTION_THROWS _M_throw_out_of_range() const
size_type find(const _Self &__s, size_type __pos=0) const
_Self & append(const _CharT *__s, const _CharT *__e)
void insert(size_t __p, const iterator &__i, const iterator &__j)
const_iterator begin() const
static _RopeRep * _S_concat_and_set_balanced(_RopeRep *__left, _RopeRep *__right)
static _RopeLeaf * _S_RopeLeaf_from_unowned_char_ptr(const _CharT *__s, size_t _p_size, allocator_type __a)
void replace(const iterator &__p, const _CharT *__i, const _CharT *__j)
iterator insert(const iterator &__p, const _CharT *__i, size_t __n)
static bool _S_is_almost_balanced(_RopeRep *__r)
iterator erase(const iterator &__p, const iterator &__q)
static void _S_unref(_RopeRep *__t)
void replace(size_t __p, const iterator &__i, const iterator &__j)
_Rope_char_ref_proxy< _CharT, _Alloc > reference
void copy(_CharT *__buffer) const
static _RopeRep * _S_substring(_RopeRep *__base, size_t __start, size_t __endp1)
size_type copy(size_type __pos, size_type __n, _CharT *__buffer) const
void replace(size_t __p, size_t __n, const _CharT *__i, size_t __i_len)
_Self & append(_CharT __c)
rope(size_t __n, _CharT __c, const allocator_type &__a=allocator_type())
static int _S_compare(const _RopeRep *__x, const _RopeRep *__y)
_Self & operator=(const _Self &__x)
static const unsigned long _S_min_len[__ROPE_DEPTH_SIZE]
const _CharT * c_str() const
rope(_CharT __c, const allocator_type &__a=allocator_type())
void replace(const iterator &__p, const iterator &__q, const iterator &__i, const iterator &__j)
void push_front(_CharT __x)
_Self & append(const _CharT *__c_string)
static _RopeLeaf * _S_new_RopeLeaf(_CharT *__s, size_t _p_size, allocator_type __a)
_CharT at(size_type __pos) const
const_iterator const_begin() const
iterator insert(const iterator &__p, const _Self &__r)
void insert(size_t __p, const _CharT *__i, const _CharT *__j)
_Rope_self_destruct_ptr< _CharT, _Alloc > _Self_destruct_ptr
static _RopeFunction * _S_new_RopeFunction(char_producer< _CharT > *__f, size_t _p_size, bool __d, allocator_type __a)
const_iterator const_end() const
static _CharT * _S_fetch_ptr(_RopeRep *__r, size_type __pos)
void replace(const iterator &__p, const iterator &__q, const _Self &__r)
int compare(const _Self &__y) const
static void _S_ref(_RopeRep *__t)
static _RopeRep * _S_tree_concat(_RopeRep *__left, _RopeRep *__right)
const_reverse_iterator const_rend() const
_Self substr(size_t __start, size_t __len=1) const
void replace(const iterator &__p, const _Self &__r)
static _RopeRep * _S_concat_rep(_RopeRep *__left, _RopeRep *__right)
_Rope_const_iterator< _CharT, _Alloc > const_iterator
static _CharT _S_fetch(_RopeRep *__r, size_type __pos)
const _CharT * replace_with_c_str()
rope< _CharT, _Alloc > _Self
static _RopeRep * _S_destr_concat_char_iter(_RopeRep *__r, const _CharT *__iter, size_t __slen)
iterator insert(const iterator &__p, const iterator &__i, const iterator &__j)
iterator insert(const iterator &__p)
const_iterator end() const
static _RopeRep * _S_concat_char_iter(_RopeRep *__r, const _CharT *__iter, size_t __slen)
_CharT operator[](size_type __pos) const
void insert(size_t __p, const const_iterator &__i, const const_iterator &__j)
_Self substr(iterator __start, iterator __end) const
void replace(const iterator &__p, const _CharT *__c_string)
_Self substr(iterator __start) const
void insert(size_t __p, size_t __n, _CharT __c)
void replace(size_t __p, const _CharT *__i, size_t __i_len)
_Rope_RopeRep< _CharT, _Alloc > _RopeRep
void replace(const iterator &__p, const iterator &__q, const const_iterator &__i, const const_iterator &__j)
allocator_type get_allocator() const
static _RopeRep * _S_balance(_RopeRep *__r)
rope(__move_source< _Self > __src)
void insert(size_t __p, _CharT __c)
void replace(size_t __p, size_t __n, const _Self &__r)
void _M_reset(_RopeRep *__r)
_Rope_RopeFunction< _CharT, _Alloc > _RopeFunction
_Self substr(const_iterator __start, const_iterator __end) const
static _CharT * _S_flatten(_RopeRep *__r, _CharT *__buffer)
_Self & append(const_iterator __s, const_iterator __e)
static size_t _S_rounded_up_size(size_t __n)
_Self & append(const _CharT *__iter, size_t __n)
rope(const _CharT *__s, const allocator_type &__a=allocator_type())
iterator erase(const iterator &__p)
void replace(size_t __p, size_t __n, const iterator &__i, const iterator &__j)
rope(const const_iterator &__s, const const_iterator &__e, const allocator_type &__a=allocator_type())
void replace(size_t __p, const _CharT *__c_string)
void replace(size_t __p, size_t __n, const const_iterator &__i, const const_iterator &__j)
iterator insert(const iterator &__p, const _CharT *c_string)
_Self & append(size_t __n, _CharT __c)
void replace(size_t __p, size_t __n, _CharT __c)
rope(const _CharT *__s, size_t __len, const allocator_type &__a=allocator_type())
static _RopeSubstring * _S_new_RopeSubstring(_Rope_RopeRep< _CharT, _Alloc > *__b, size_t __s, size_t __l, allocator_type __a)
rope< _CharT, _Alloc > substr(const_iterator __start)
static bool _S_is_roughly_balanced(_RopeRep *__r)
rope(char_producer< _CharT > *__fn, size_t __len, bool __delete_fn, const allocator_type &__a=allocator_type())
_Rope_char_ptr_proxy< _CharT, _Alloc > pointer
iterator insert(const iterator &__p, _CharT __c)
static _RopeRep * replace(_RopeRep *__old, size_t __pos1, size_t __pos2, _RopeRep *__r)
void replace(const iterator &__p, const iterator &__q, const _CharT *__i, size_t __n)
_Rope_RopeConcatenation< _CharT, _Alloc > _RopeConcatenation
iterator insert(const iterator &__p, size_t __n, _CharT __c)
static bool _S_is_balanced(_RopeRep *__r)
reverse_iterator mutable_rbegin()
static _CharT _S_empty_c_str[1]
void replace(const iterator &__p, const iterator &__q, _CharT __c)
rope(_RopeRep *__t, const allocator_type &__a=allocator_type())
rope(const _CharT *__s, const _CharT *__e, const allocator_type &__a=allocator_type())
void replace(const iterator &__p, const iterator &__q, const _CharT *__c_string)
static void _S_add_leaf_to_forest(_RopeRep *__r, _RopeRep **__forest)
_STLP_PRIV _STLP_alloc_proxy< _RopeRep *, _CharT, allocator_type > _M_tree_ptr
_Rope_RopeLeaf< _CharT, _Alloc > _RopeLeaf
static size_t _S_char_ptr_len(const _CharT *__s)
void insert(size_t __p, const _Self &__r)
_RopeRep::_IsBasicCharType _IsBasicCharType
reference mutable_reference_at(size_type __pos)
void insert(size_t __p, const _CharT *__i, size_t __n)
_Rope_RopeSubstring< _CharT, _Alloc > _RopeSubstring
void erase(size_t __p, size_t __n)
size_type max_size() const
const _CharT * const_pointer
void replace(size_t __p, size_t __n, const _CharT *__c_string)
const_reverse_iterator rbegin()
rope(const allocator_type &__a=allocator_type())
void replace(size_t __p, size_t __n, const _CharT *__i, const _CharT *__j)
const_reverse_iterator rend()
_Self & append(const _Self &__y)
void replace(size_t __p, const _Self &__r)
void replace(size_t __p, const const_iterator &__i, const const_iterator &__j)
void replace(size_t __p, _CharT __c)
reverse_iterator mutable_rend()
const_reverse_iterator rend() const
rope(const iterator &__s, const iterator &__e, const allocator_type &__a=allocator_type())
iterator insert(const iterator &__p, const const_iterator &__i, const const_iterator &__j)
iterator insert(const iterator &__p, const _CharT *__i, const _CharT *__j)
void push_back(_CharT __x)
static _RopeConcatenation * _S_new_RopeConcatenation(_RopeRep *__left, _RopeRep *__right, allocator_type __a)
static _RopeLeaf * _S_leaf_concat_char_iter(_RopeLeaf *__r, const _CharT *__iter, size_t __slen)
_Rope_char_consumer< _CharT > _CharConsumer
_STLP_DECLARE_RANDOM_ACCESS_REVERSE_ITERATORS
_STLP_PRIV _Rope_Concat_fn< _CharT, _Alloc > _Concat_fn
static void _S_add_to_forest(_RopeRep *__r, _RopeRep **__forest)
_Rope_iterator< _CharT, _Alloc > iterator
void replace(const iterator &__p, const _CharT *__i, size_t __n)
value_type _M_buffer[_Buf_sz]
_Self & write(const value_type *__s, size_t __len)
_Self & operator=(_Self &__x)
_Self & operator=(const value_type &__rhs)
void append(const value_type *__s, size_t __len)
sequence_buffer< _Sequence, _Buf_sz > _Self
_Self & put(value_type __x)
sequence_buffer(_Sequence &__s)
sequence_buffer(const _Self &__x)
sequence_buffer(_Self &__x)
void push_back(value_type __x)
_Sequence::value_type value_type
static BOOL reserve(struct dynamic_array *array, int count, int itemsize)
__kernel_ptrdiff_t ptrdiff_t
#define _STLP_UNWIND(action)
#define _STLP_TEMPLATE_NULL
#define _STLP_RET_AFTER_THROW(data)
#define _STLP_FUNCTION_THROWS
#define _STLP_MOVE_TO_STD_NAMESPACE
#define __STATIC_CAST(__x, __y)
#define __CONST_CAST(__x, __y)
#define _STLP_BEGIN_NAMESPACE
#define _STLP_END_NAMESPACE
#define _STLP_MOVE_TO_PRIV_NAMESPACE
static void dump(const void *ptr, unsigned len)
rope< _CharT, _Alloc > operator()(const rope< _CharT, _Alloc > &__x, const rope< _CharT, _Alloc > &__y)
_Rope_RopeRep< _CharT, _Alloc > _RopeRep
~_Rope_RopeConcatenation()
_RopeRep::allocator_type allocator_type
_Rope_RopeRep< _CharT, _Alloc > _RopeRep
char_producer< _CharT > * _M_fn
_Rope_RopeFunction(char_producer< _CharT > *__f, size_t _p_size, bool __d, allocator_type __a)
_Rope_RopeRep< _CharT, _Alloc >::allocator_type allocator_type
_Rope_RopeRep< _CharT, _Alloc > _RopeRep
void _M_init(__true_type const &)
_RopeRep::_IsBasicCharType _IsBasicCharType
void _M_init(__false_type const &)
_RopeRep::allocator_type allocator_type
_Rope_RopeRep< _CharT, _Alloc > _Self
_CharT *_STLP_VOLATILE _M_c_string
static void _S_free_string(_CharT *__s, size_t __len, allocator_type __a)
_Rope_RopeRep(_Tag __t, unsigned char __d, bool __b, size_t _p_size, allocator_type __a)
static void _S_ref(_Self *__t)
allocator_type get_allocator() const
static size_t _S_rounded_up_size(size_t __n)
static void _S_unref(_Self *__t)
_STLP_PRIV _STLP_alloc_proxy< size_t, _CharT, allocator_type > _M_size
_STLP_TYPENAME _STLP_PRIV _BasicCharType< _CharT >::_Ret _IsBasicCharType
_Rope_RopeRep< _CharT, _Alloc > _RopeRep
virtual ~_Rope_RopeSubstring()
void operator()(size_t __start_pos, size_t __req_len, _CharT *__buffer)
_RopeRep::allocator_type allocator_type
_Rope_self_destruct_ptr(_Rope_RopeRep< _CharT, _Alloc > *__p)
_Rope_self_destruct_ptr()
_Rope_self_destruct_ptr< _CharT, _Alloc > & operator=(_Rope_RopeRep< _CharT, _Alloc > *__x)
~_Rope_self_destruct_ptr()
_Rope_RopeRep< _CharT, _Alloc > * operator->()
_Rope_RopeRep< _CharT, _Alloc > & operator*()
_Rope_RopeRep< _CharT, _Alloc > * _M_ptr
__type_traits< _Tp >::has_trivial_destructor complete
size_t operator()(const crope &__str) const