ReactOS 0.4.16-dev-36-g301675c
basic_string< _CharT, _Traits, _Alloc > Class Template Reference

#include <_string.h>

Inheritance diagram for basic_string< _CharT, _Traits, _Alloc >:
Collaboration diagram for basic_string< _CharT, _Traits, _Alloc >:

Public Types

typedef _CharT value_type
 
typedef _Traits traits_type
 
typedef value_typepointer
 
typedef const value_typeconst_pointer
 
typedef value_typereference
 
typedef const value_typeconst_reference
 
typedef _Base::size_type size_type
 
typedef ptrdiff_t difference_type
 
typedef random_access_iterator_tag _Iterator_category
 
typedef const value_typeconst_iterator
 
typedef value_typeiterator
 
typedef _STLP_PRIV _String_reserve_t _Reserve_t
 
typedef _Base::allocator_type allocator_type
 
typedef _Base::_Iterator_category _Iterator_category
 
typedef _Base::traits_type traits_type
 
typedef _Base::_Reserve_t _Reserve_t
 
typedef _Base::traits_type traits_type
 
typedef _STLP_PRIV _DBG_iter< _Base, _STLP_PRIV _DbgTraits< _Nonconst_traits< value_type > > > iterator
 
typedef _STLP_PRIV _DBG_iter< _Base, _STLP_PRIV _DbgTraits< _Const_traits< value_type > > > const_iterator
 
typedef _Base::_Reserve_t _Reserve_t
 

Public Member Functions

allocator_type get_allocator () const
 
 basic_string (const allocator_type &__a=allocator_type())
 
 basic_string (_Reserve_t, size_t __n, const allocator_type &__a=allocator_type())
 
 basic_string (const _Self &)
 
 basic_string (const _Self &__s, size_type __pos, size_type __n=npos, const allocator_type &__a=allocator_type())
 
 basic_string (const _CharT *__s, size_type __n, const allocator_type &__a=allocator_type())
 
 basic_string (const _CharT *__s, const allocator_type &__a=allocator_type())
 
 basic_string (size_type __n, _CharT __c, const allocator_type &__a=allocator_type())
 
 basic_string (__move_source< _Self > src)
 
 basic_string (const _CharT *__f, const _CharT *__l, const allocator_type &__a _STLP_ALLOCATOR_TYPE_DFL)
 
 if (__n > max_size() - __size) this -> _M_throw_length_error()
 
 if (__len > max_size()||__len< __size) __len
 
template<class _InputIter >
void _M_range_initialize (_InputIter __f, _InputIter __l, const input_iterator_tag &__tag)
 
template<class _ForwardIter >
void _M_range_initialize (_ForwardIter __f, _ForwardIter __l, const forward_iterator_tag &)
 
template<class _InputIter >
void _M_range_initializeT (_InputIter __f, _InputIter __l)
 
template<class _Integer >
void _M_initialize_dispatch (_Integer __n, _Integer __x, const __true_type &)
 
template<class _InputIter >
void _M_initialize_dispatch (_InputIter __f, _InputIter __l, const __false_type &)
 
_Selfoperator= (const _Self &__s)
 
_Selfoperator= (const _CharT *__s)
 
_Selfoperator= (_CharT __c)
 
iterator begin ()
 
iterator end ()
 
const_iterator begin () const
 
const_iterator end () const
 
reverse_iterator rbegin ()
 
reverse_iterator rend ()
 
const_reverse_iterator rbegin () const
 
const_reverse_iterator rend () const
 
size_type size () const
 
size_type length () const
 
size_type max_size () const
 
void resize (size_type __n, _CharT __c)
 
void resize (size_type __n)
 
void reserve (size_type=0)
 
size_type capacity () const
 
void clear ()
 
bool empty () const
 
const_reference operator[] (size_type __n) const
 
reference operator[] (size_type __n)
 
const_reference at (size_type __n) const
 
reference at (size_type __n)
 
_Selfoperator+= (const _Self &__s)
 
_Selfoperator+= (const _CharT *__s)
 
_Selfoperator+= (_CharT __c)
 
_Selfappend (const _CharT *__first, const _CharT *__last)
 
_Selfappend (const _Self &__s)
 
_Selfappend (const _Self &__s, size_type __pos, size_type __n)
 
_Selfappend (const _CharT *__s, size_type __n)
 
_Selfappend (const _CharT *__s)
 
_Selfappend (size_type __n, _CharT __c)
 
void push_back (_CharT __c)
 
void pop_back ()
 
_Selfassign (const _Self &__s)
 
_Selfassign (const _Self &__s, size_type __pos, size_type __n)
 
_Selfassign (const _CharT *__s, size_type __n)
 
_Selfassign (const _CharT *__s)
 
_Selfassign (size_type __n, _CharT __c)
 
_Selfassign (const _CharT *__f, const _CharT *__l)
 
_Selfinsert (size_type __pos, const _Self &__s)
 
_Selfinsert (size_type __pos, const _Self &__s, size_type __beg, size_type __n)
 
_Selfinsert (size_type __pos, const _CharT *__s, size_type __n)
 
_Selfinsert (size_type __pos, const _CharT *__s)
 
_Selfinsert (size_type __pos, size_type __n, _CharT __c)
 
iterator insert (iterator __p, _CharT __c)
 
void insert (iterator __p, size_t __n, _CharT __c)
 
pointer _M_insert_aux (pointer, _CharT)
 
void _M_copy (const _CharT *__f, const _CharT *__l, _CharT *__res)
 
void _M_move (const _CharT *__f, const _CharT *__l, _CharT *__res)
 
void insert (iterator __p, const _CharT *__f, const _CharT *__l)
 
_Selferase (size_type __pos=0, size_type __n=npos)
 
iterator erase (iterator __pos)
 
iterator erase (iterator __first, iterator __last)
 
_Selfreplace (size_type __pos, size_type __n, const _Self &__s)
 
_Selfreplace (size_type __pos1, size_type __n1, const _Self &__s, size_type __pos2, size_type __n2)
 
_Selfreplace (size_type __pos, size_type __n1, const _CharT *__s, size_type __n2)
 
_Selfreplace (size_type __pos, size_type __n1, const _CharT *__s)
 
_Selfreplace (size_type __pos, size_type __n1, size_type __n2, _CharT __c)
 
_Selfreplace (iterator __first, iterator __last, const _Self &__s)
 
_Selfreplace (iterator __first, iterator __last, const _CharT *__s, size_type __n)
 
_Selfreplace (iterator __first, iterator __last, const _CharT *__s)
 
_Selfreplace (iterator __first, iterator __last, size_type __n, _CharT __c)
 
_Selfreplace (iterator __first, iterator __last, const _CharT *__f, const _CharT *__l)
 
size_type copy (_CharT *__s, size_type __n, size_type __pos=0) const
 
void swap (_Self &__s)
 
const _CharT * c_str () const
 
const _CharT * data () const
 
size_type find (const _Self &__s, size_type __pos=0) const
 
size_type find (const _CharT *__s, size_type __pos=0) const
 
size_type find (const _CharT *__s, size_type __pos, size_type __n) const
 
size_type find (_CharT __c) const
 
size_type find (_CharT __c, size_type __pos) const
 
size_type rfind (const _Self &__s, size_type __pos=npos) const
 
size_type rfind (const _CharT *__s, size_type __pos=npos) const
 
size_type rfind (const _CharT *__s, size_type __pos, size_type __n) const
 
size_type rfind (_CharT __c, size_type __pos=npos) const
 
size_type find_first_of (const _Self &__s, size_type __pos=0) const
 
size_type find_first_of (const _CharT *__s, size_type __pos=0) const
 
size_type find_first_of (const _CharT *__s, size_type __pos, size_type __n) const
 
size_type find_first_of (_CharT __c, size_type __pos=0) const
 
size_type find_last_of (const _Self &__s, size_type __pos=npos) const
 
size_type find_last_of (const _CharT *__s, size_type __pos=npos) const
 
size_type find_last_of (const _CharT *__s, size_type __pos, size_type __n) const
 
size_type find_last_of (_CharT __c, size_type __pos=npos) const
 
size_type find_first_not_of (const _Self &__s, size_type __pos=0) const
 
size_type find_first_not_of (const _CharT *__s, size_type __pos=0) const
 
size_type find_first_not_of (const _CharT *__s, size_type __pos, size_type __n) const
 
size_type find_first_not_of (_CharT __c, size_type __pos=0) const
 
size_type find_last_not_of (const _Self &__s, size_type __pos=npos) const
 
size_type find_last_not_of (const _CharT *__s, size_type __pos=npos) const
 
size_type find_last_not_of (const _CharT *__s, size_type __pos, size_type __n) const
 
size_type find_last_not_of (_CharT __c, size_type __pos=npos) const
 
_Self substr (size_type __pos=0, size_type __n=npos) const
 
int compare (const _Self &__s) const
 
int compare (size_type __pos1, size_type __n1, const _Self &__s) const
 
int compare (size_type __pos1, size_type __n1, const _Self &__s, size_type __pos2, size_type __n2) const
 
int compare (const _CharT *__s) const
 
int compare (size_type __pos1, size_type __n1, const _CharT *__s) const
 
int compare (size_type __pos1, size_type __n1, const _CharT *__s, size_type __n2) const
 
 basic_string (const allocator_type &__a=allocator_type())
 
 basic_string (_Reserve_t __r, size_t __n, const allocator_type &__a=allocator_type())
 
 basic_string (const _Self &__s)
 
 basic_string (const _Self &__s, size_type __pos, size_type __n=npos, const allocator_type &__a=allocator_type())
 
 basic_string (const _CharT *__s, size_type __n, const allocator_type &__a=allocator_type())
 
 basic_string (const _CharT *__s, const allocator_type &__a=allocator_type())
 
 basic_string (size_type __n, _CharT __c, const allocator_type &__a=allocator_type())
 
 basic_string (__move_source< _Self > src)
 
template<class _InputIterator >
 basic_string (_InputIterator __f, _InputIterator __l, const allocator_type &__a _STLP_ALLOCATOR_TYPE_DFL)
 
_Selfoperator= (const _Self &__s)
 
_Selfoperator= (const _CharT *__s)
 
_Selfoperator= (_CharT __c)
 
_Selfoperator+= (const _Self &__s)
 
_Selfoperator+= (const _CharT *__s)
 
_Selfoperator+= (_CharT __c)
 
_Selfappend (const _Self &__s)
 
_Selfappend (const _Self &__s, size_type __pos, size_type __n)
 
_Selfappend (const _CharT *__s, size_type __n)
 
_Selfappend (const _CharT *__s)
 
_Selfappend (size_type __n, _CharT __c)
 
template<class _InputIter >
_Selfappend (_InputIter __first, _InputIter __last)
 
_Selfappend (const _CharT *__f, const _CharT *__l)
 
_Selfassign (const _Self &__s)
 
_Selfassign (const _Self &__s, size_type __pos, size_type __n)
 
_Selfassign (const _CharT *__s, size_type __n)
 
_Selfassign (const _CharT *__s)
 
_Selfassign (size_type __n, _CharT __c)
 
template<class _InputIter >
_Selfassign (_InputIter __first, _InputIter __last)
 
_Selfassign (const _CharT *__f, const _CharT *__l)
 
_Selfinsert (size_type __pos, const _Self &__s)
 
_Selfinsert (size_type __pos, const _Self &__s, size_type __beg, size_type __n)
 
_Selfinsert (size_type __pos, const _CharT *__s, size_type __n)
 
_Selfinsert (size_type __pos, const _CharT *__s)
 
_Selfinsert (size_type __pos, size_type __n, _CharT __c)
 
iterator insert (iterator __p, _CharT __c)
 
void insert (iterator __p, size_t __n, _CharT __c)
 
template<class _InputIter >
void insert (iterator __p, _InputIter __first, _InputIter __last)
 
void insert (iterator __p, const _CharT *__f, const _CharT *__l)
 
_Selferase (size_type __pos=0, size_type __n=npos)
 
iterator erase (iterator __pos)
 
iterator erase (iterator __first, iterator __last)
 
_Selfreplace (size_type __pos, size_type __n, const _Self &__s)
 
_Selfreplace (size_type __pos1, size_type __n1, const _Self &__s, size_type __pos2, size_type __n2)
 
_Selfreplace (size_type __pos, size_type __n1, const _CharT *__s, size_type __n2)
 
_Selfreplace (size_type __pos, size_type __n1, const _CharT *__s)
 
_Selfreplace (size_type __pos, size_type __n1, size_type __n2, _CharT __c)
 
_Selfreplace (iterator __first, iterator __last, const _Self &__s)
 
_Selfreplace (iterator __first, iterator __last, const _CharT *__s, size_type __n)
 
_Selfreplace (iterator __first, iterator __last, const _CharT *__s)
 
_Selfreplace (iterator __first, iterator __last, size_type __n, _CharT __c)
 
template<class _InputIter >
_Selfreplace (iterator __first, iterator __last, _InputIter __f, _InputIter __l)
 
_Selfreplace (iterator __first, iterator __last, const _CharT *__f, const _CharT *__l)
 
void swap (_Self &__s)
 
_Self substr (size_type __pos=0, size_type __n=npos) const
 
allocator_type get_allocator () const
 
 basic_string (const allocator_type &__a=allocator_type())
 
 basic_string (_Reserve_t __r, size_t __n, const allocator_type &__a=allocator_type())
 
 basic_string (const _Self &__s)
 
 basic_string (const _Self &__s, size_type __pos, size_type __n=npos, const allocator_type &__a=allocator_type())
 
 basic_string (const _CharT *__s, size_type __n, const allocator_type &__a=allocator_type())
 
 basic_string (const _CharT *__s, const allocator_type &__a=allocator_type())
 
 basic_string (size_type __n, _CharT __c, const allocator_type &__a=allocator_type())
 
 basic_string (__move_source< _Self > src)
 
 basic_string (const _CharT *__f, const _CharT *__l, const allocator_type &__a=allocator_type())
 
 basic_string (const_iterator __f, const_iterator __l, const allocator_type &__a=allocator_type())
 
_Selfoperator= (const _Self &__s)
 
_Selfoperator= (const _CharT *__s)
 
_Selfoperator= (_CharT __c)
 
iterator begin ()
 
const_iterator begin () const
 
iterator end ()
 
const_iterator end () const
 
reverse_iterator rbegin ()
 
const_reverse_iterator rbegin () const
 
reverse_iterator rend ()
 
const_reverse_iterator rend () const
 
size_type size () const
 
size_type length () const
 
size_t max_size () const
 
void resize (size_type __n, _CharT __c)
 
void resize (size_type __n)
 
size_type capacity () const
 
void reserve (size_type __s=0)
 
void clear ()
 
bool empty () const
 
const_reference operator[] (size_type __n) const
 
reference operator[] (size_type __n)
 
const_reference at (size_type __n) const
 
reference at (size_type __n)
 
_Selfoperator+= (const _Self &__s)
 
_Selfoperator+= (const _CharT *__s)
 
_Selfoperator+= (_CharT __c)
 
_Selfappend (const _CharT *__f, const _CharT *__l)
 
_Selfappend (const_iterator __f, const_iterator __l)
 
_Selfappend (const _Self &__s)
 
_Selfappend (const _Self &__s, size_type __pos, size_type __n)
 
_Selfappend (const _CharT *__s, size_type __n)
 
_Selfappend (const _CharT *__s)
 
_Selfappend (size_type __n, _CharT __c)
 
void push_back (_CharT __c)
 
void pop_back ()
 
_Selfassign (const _Self &__s)
 
_Selfassign (const _Self &__s, size_type __pos, size_type __n)
 
_Selfassign (const _CharT *__s, size_type __n)
 
_Selfassign (const _CharT *__s)
 
_Selfassign (size_type __n, _CharT __c)
 
_Selfassign (const _CharT *__f, const _CharT *__l)
 
_Selfassign (const_iterator __f, const_iterator __l)
 
_Selfinsert (size_type __pos, const _Self &__s)
 
_Selfinsert (size_type __pos, const _Self &__s, size_type __beg, size_type __n)
 
_Selfinsert (size_type __pos, const _CharT *__s, size_type __n)
 
_Selfinsert (size_type __pos, const _CharT *__s)
 
_Selfinsert (size_type __pos, size_type __n, _CharT __c)
 
iterator insert (iterator __p, _CharT __c)
 
void insert (iterator __p, size_t __n, _CharT __c)
 
void insert (iterator __p, const _CharT *__f, const _CharT *__l)
 
void insert (iterator __p, const_iterator __f, const_iterator __l)
 
void insert (iterator __p, iterator __f, iterator __l)
 
_Selferase (size_type __pos=0, size_type __n=npos)
 
iterator erase (iterator __pos)
 
iterator erase (iterator __f, iterator __l)
 
_Self substr (size_type __pos=0, size_type __n=npos) const
 
_Selfreplace (size_type __pos, size_type __n, const _Self &__s)
 
_Selfreplace (size_type __pos1, size_type __n1, const _Self &__s, size_type __pos2, size_type __n2)
 
_Selfreplace (size_type __pos, size_type __n1, const _CharT *__s, size_type __n2)
 
_Selfreplace (size_type __pos, size_type __n1, const _CharT *__s)
 
_Selfreplace (size_type __pos, size_type __n1, size_type __n2, _CharT __c)
 
_Selfreplace (iterator __f, iterator __l, const _Self &__s)
 
_Selfreplace (iterator __f, iterator __l, const _CharT *__s, size_type __n)
 
_Selfreplace (iterator __f, iterator __l, const _CharT *__s)
 
_Selfreplace (iterator __f, iterator __l, size_type __n, _CharT __c)
 
_Selfreplace (iterator __first, iterator __last, const _CharT *__f, const _CharT *__l)
 
_Selfreplace (iterator __first, iterator __last, const_iterator __f, const_iterator __l)
 
_Selfreplace (iterator __first, iterator __last, iterator __f, iterator __l)
 
void swap (_Self &__s)
 
int compare (const _Self &__s) const
 
int compare (size_type __pos, size_type __n, const _Self &__s) const
 
int compare (size_type __pos1, size_type __n1, const _Self &__s, size_type __pos2, size_type __n2) const
 
int compare (const _CharT *__s) const
 
int compare (size_type __pos, size_type __n, const _CharT *__s) const
 
int compare (size_type __pos1, size_type __n1, const _CharT *__s, size_type __n2) const
 
const _CharT * c_str () const
 
const _CharT * data () const
 
size_type copy (_CharT *__s, size_type __n, size_type __pos=0) const
 
size_type find (const _Self &__s, size_type __pos=0) const
 
size_type find (const _CharT *__s, size_type __pos=0) const
 
size_type find (const _CharT *__s, size_type __pos, size_type __n) const
 
size_type find (_CharT __c) const
 
size_type find (_CharT __c, size_type __pos) const
 
size_type rfind (const _Self &__s, size_type __pos=npos) const
 
size_type rfind (const _CharT *__s, size_type __pos=npos) const
 
size_type rfind (const _CharT *__s, size_type __pos, size_type __n) const
 
size_type rfind (_CharT __c, size_type __pos=npos) const
 
size_type find_first_of (const _Self &__s, size_type __pos=0) const
 
size_type find_first_of (const _CharT *__s, size_type __pos=0) const
 
size_type find_first_of (const _CharT *__s, size_type __pos, size_type __n) const
 
size_type find_first_of (_CharT __c, size_type __pos=0) const
 
size_type find_last_of (const _Self &__s, size_type __pos=npos) const
 
size_type find_last_of (const _CharT *__s, size_type __pos=npos) const
 
size_type find_last_of (const _CharT *__s, size_type __pos, size_type __n) const
 
size_type find_last_of (_CharT __c, size_type __pos=npos) const
 
size_type find_first_not_of (const _Self &__s, size_type __pos=0) const
 
size_type find_first_not_of (const _CharT *__s, size_type __pos=0) const
 
size_type find_first_not_of (const _CharT *__s, size_type __pos, size_type __n) const
 
size_type find_first_not_of (_CharT __c, size_type __pos=0) const
 
size_type find_last_not_of (const _Self &__s, size_type __pos=npos) const
 
size_type find_last_not_of (const _CharT *__s, size_type __pos=npos) const
 
size_type find_last_not_of (const _CharT *__s, size_type __pos, size_type __n) const
 
size_type find_last_not_of (_CharT __c, size_type __pos=npos) const
 

Static Public Member Functions

static int _STLP_CALL _M_compare (const _CharT *__f1, const _CharT *__l1, const _CharT *__f2, const _CharT *__l2)
 
static int _STLP_CALL _M_compare (const _CharT *__f1, const _CharT *__l1, const _CharT *__f2, const _CharT *__l2)
 
static int _STLP_CALL _M_compare (const_iterator __f1, const_iterator __l1, const _CharT *__f2, const _CharT *__l2)
 
static int _STLP_CALL _M_compare (const _CharT *__f1, const _CharT *__l1, const_iterator __f2, const_iterator __l2)
 
static int _STLP_CALL _M_compare (const_iterator __f1, const_iterator __l1, const_iterator __f2, const_iterator __l2)
 

Public Attributes

 _STLP_DECLARE_RANDOM_ACCESS_REVERSE_ITERATORS
 
_STLP_PRIVATE __pad1__: size_type _M_compute_next_size(size_type __n) { const size_type __size = size()
 
size_type __len = __size + (max)(__n, __size) + 1
 
return __len
 
_STLP_PRIVATE __pad3__: void _M_insert(iterator __p
 
_STLP_PRIVATE const _CharT * __first
 
_STLP_PRIVATE const _CharT const _CharT * __last
 
_STLP_PRIVATE const _CharT const _CharT bool __self_ref
 
_STLP_PRIVATE __pad4__: _Self& _M_replace(iterator __first
 
_STLP_PRIVATE iterator __last
 
_STLP_PRIVATE iterator const _CharT * __f
 
_STLP_PRIVATE iterator const _CharT const _CharT * __l
 
_STLP_PRIVATE iterator const _CharT const _CharT bool __self_ref
 

Protected Types

typedef _STLP_NON_DBG_STRING _Base
 
typedef basic_string< _CharT, _Traits, _Alloc_Self
 
typedef _STLP_PRIV __construct_checker< _STLP_NON_DBG_STRING_ConstructCheck
 
typedef _IsPOD< _CharT >::_Type _Char_Is_POD
 

Private Types

typedef basic_string< _CharT, _Traits, _Alloc_Self
 
typedef basic_string< _CharT, _Traits, _Alloc_Self
 
typedef _STLP_NO_MEM_T_STRING_BASE _Base
 
typedef _Base::_CalledFromWorkaround_t _CalledFromWorkaround_t
 

Private Member Functions

void _M_terminate_string ()
 
bool _M_inside (const _CharT *__s) const
 
void _M_range_initialize (const _CharT *__f, const _CharT *__l)
 
void _M_reserve (size_type)
 
_Self_M_append (const _CharT *__first, const _CharT *__last)
 
_Self_M_assign (const _CharT *__f, const _CharT *__l)
 
template<class _InputIter >
void _M_range_initialize (_InputIter __f, _InputIter __l, const input_iterator_tag &__tag)
 
template<class _ForwardIter >
void _M_range_initialize (_ForwardIter __f, _ForwardIter __l, const forward_iterator_tag &)
 
template<class _InputIter >
void _M_range_initializeT (_InputIter __f, _InputIter __l)
 
template<class _Integer >
void _M_initialize_dispatch (_Integer __n, _Integer __x, const __true_type &)
 
template<class _InputIter >
void _M_initialize_dispatch (_InputIter __f, _InputIter __l, const __false_type &)
 
template<class _InputIter >
_Self_M_appendT (_InputIter __first, _InputIter __last, const input_iterator_tag &)
 
template<class _ForwardIter >
_Self_M_appendT (_ForwardIter __first, _ForwardIter __last, const forward_iterator_tag &)
 
template<class _Integer >
_Self_M_append_dispatch (_Integer __n, _Integer __x, const __true_type &)
 
template<class _InputIter >
_Self_M_append_dispatch (_InputIter __f, _InputIter __l, const __false_type &)
 
template<class _Integer >
_Self_M_assign_dispatch (_Integer __n, _Integer __x, const __true_type &)
 
template<class _InputIter >
_Self_M_assign_dispatch (_InputIter __f, _InputIter __l, const __false_type &)
 
void _M_insert (iterator __p, const _CharT *__f, const _CharT *__l, bool __self_ref)
 
template<class _ForwardIter >
void _M_insert_overflow (iterator __pos, _ForwardIter __first, _ForwardIter __last, size_type __n)
 
template<class _InputIter >
void _M_insertT (iterator __p, _InputIter __first, _InputIter __last, const input_iterator_tag &)
 
template<class _ForwardIter >
void _M_insertT (iterator __pos, _ForwardIter __first, _ForwardIter __last, const forward_iterator_tag &)
 
template<class _Integer >
void _M_insert_dispatch (iterator __p, _Integer __n, _Integer __x, const __true_type &)
 
template<class _InputIter >
void _M_insert_dispatch (iterator __p, _InputIter __first, _InputIter __last, const __false_type &)
 
template<class _InputIterator >
void _M_copyT (_InputIterator __first, _InputIterator __last, pointer __result)
 
void _M_copyT (const _CharT *__f, const _CharT *__l, _CharT *__res)
 
_Self_M_replace (iterator __first, iterator __last, const _CharT *__f, const _CharT *__l, bool __self_ref)
 
template<class _Integer >
_Self_M_replace_dispatch (iterator __first, iterator __last, _Integer __n, _Integer __x, const __true_type &)
 
template<class _InputIter >
_Self_M_replace_dispatch (iterator __first, iterator __last, _InputIter __f, _InputIter __l, const __false_type &)
 
void _Invalidate_all ()
 
void _Compare_Capacity (size_type __old_capacity)
 
void _Invalidate_iterator (const iterator &__it)
 
void _Invalidate_iterators (const iterator &__f, const iterator &__l)
 
 basic_string (const _Base &__x)
 

Static Private Member Functions

static _CharT _STLP_CALL _M_null ()
 

Private Attributes

_STLP_PRIVATE __pad0__: typedef _STLP_PRIV _String_base<_CharT
 
_STLP_PRIVATE _Alloc _Base
 
_STLP_PRIVATE __pad2__: void _M_construct_null(_CharT* __p) const { _STLP_STD::_Construct(__p)
 
_Base _M_non_dbg_impl
 
_STLP_PRIV __owned_list _M_iter_list
 

Detailed Description

template<class _CharT, class _Traits, class _Alloc>
class basic_string< _CharT, _Traits, _Alloc >

Definition at line 121 of file _string.h.

Member Typedef Documentation

◆ _Base [1/2]

template<class _CharT , class _Traits , class _Alloc >
typedef _STLP_NO_MEM_T_STRING_BASE basic_string< _CharT, _Traits, _Alloc >::_Base
private

Definition at line 35 of file _string_workaround.h.

◆ _Base [2/2]

template<class _CharT , class _Traits , class _Alloc >
typedef _STLP_NON_DBG_STRING basic_string< _CharT, _Traits, _Alloc >::_Base
protected

Definition at line 54 of file _string.h.

◆ _CalledFromWorkaround_t

template<class _CharT , class _Traits , class _Alloc >
typedef _Base::_CalledFromWorkaround_t basic_string< _CharT, _Traits, _Alloc >::_CalledFromWorkaround_t
private

Definition at line 36 of file _string_workaround.h.

◆ _Char_Is_POD

template<class _CharT , class _Traits , class _Alloc >
typedef _IsPOD<_CharT>::_Type basic_string< _CharT, _Traits, _Alloc >::_Char_Is_POD
protected

Definition at line 57 of file _string.h.

◆ _ConstructCheck

template<class _CharT , class _Traits , class _Alloc >
typedef _STLP_PRIV __construct_checker<_STLP_NON_DBG_STRING > basic_string< _CharT, _Traits, _Alloc >::_ConstructCheck
protected

Definition at line 56 of file _string.h.

◆ _Iterator_category [1/2]

template<class _CharT , class _Traits , class _Alloc >
typedef random_access_iterator_tag basic_string< _CharT, _Traits, _Alloc >::_Iterator_category

Definition at line 140 of file _string.h.

◆ _Iterator_category [2/2]

template<class _CharT , class _Traits , class _Alloc >
typedef _Base::_Iterator_category basic_string< _CharT, _Traits, _Alloc >::_Iterator_category

Definition at line 41 of file _string_workaround.h.

◆ _Reserve_t [1/3]

template<class _CharT , class _Traits , class _Alloc >
typedef _STLP_PRIV _String_reserve_t basic_string< _CharT, _Traits, _Alloc >::_Reserve_t

Definition at line 149 of file _string.h.

◆ _Reserve_t [2/3]

template<class _CharT , class _Traits , class _Alloc >
typedef _Base::_Reserve_t basic_string< _CharT, _Traits, _Alloc >::_Reserve_t

Definition at line 43 of file _string_workaround.h.

◆ _Reserve_t [3/3]

template<class _CharT , class _Traits , class _Alloc >
typedef _Base::_Reserve_t basic_string< _CharT, _Traits, _Alloc >::_Reserve_t

Definition at line 67 of file _string.h.

◆ _Self [1/3]

template<class _CharT , class _Traits , class _Alloc >
typedef basic_string<_CharT, _Traits, _Alloc> basic_string< _CharT, _Traits, _Alloc >::_Self
private

Definition at line 128 of file _string.h.

◆ _Self [2/3]

template<class _CharT , class _Traits , class _Alloc >
typedef basic_string<_CharT, _Traits, _Alloc> basic_string< _CharT, _Traits, _Alloc >::_Self
private

Definition at line 34 of file _string_workaround.h.

◆ _Self [3/3]

template<class _CharT , class _Traits , class _Alloc >
typedef basic_string<_CharT, _Traits, _Alloc> basic_string< _CharT, _Traits, _Alloc >::_Self
protected

Definition at line 55 of file _string.h.

◆ allocator_type

template<class _CharT , class _Traits , class _Alloc >
typedef _Base::allocator_type basic_string< _CharT, _Traits, _Alloc >::allocator_type

Definition at line 152 of file _string.h.

◆ const_iterator [1/2]

template<class _CharT , class _Traits , class _Alloc >
typedef const value_type* basic_string< _CharT, _Traits, _Alloc >::const_iterator

Definition at line 142 of file _string.h.

◆ const_iterator [2/2]

template<class _CharT , class _Traits , class _Alloc >
typedef _STLP_PRIV _DBG_iter<_Base, _STLP_PRIV _DbgTraits<_Const_traits<value_type> > > basic_string< _CharT, _Traits, _Alloc >::const_iterator

Definition at line 63 of file _string.h.

◆ const_pointer

template<class _CharT , class _Traits , class _Alloc >
typedef const value_type* basic_string< _CharT, _Traits, _Alloc >::const_pointer

Definition at line 135 of file _string.h.

◆ const_reference

template<class _CharT , class _Traits , class _Alloc >
typedef const value_type& basic_string< _CharT, _Traits, _Alloc >::const_reference

Definition at line 137 of file _string.h.

◆ difference_type

template<class _CharT , class _Traits , class _Alloc >
typedef ptrdiff_t basic_string< _CharT, _Traits, _Alloc >::difference_type

Definition at line 139 of file _string.h.

◆ iterator [1/2]

template<class _CharT , class _Traits , class _Alloc >
typedef value_type* basic_string< _CharT, _Traits, _Alloc >::iterator

Definition at line 143 of file _string.h.

◆ iterator [2/2]

template<class _CharT , class _Traits , class _Alloc >
typedef _STLP_PRIV _DBG_iter<_Base, _STLP_PRIV _DbgTraits<_Nonconst_traits<value_type> > > basic_string< _CharT, _Traits, _Alloc >::iterator

Definition at line 62 of file _string.h.

◆ pointer

template<class _CharT , class _Traits , class _Alloc >
typedef value_type* basic_string< _CharT, _Traits, _Alloc >::pointer

Definition at line 134 of file _string.h.

◆ reference

template<class _CharT , class _Traits , class _Alloc >
typedef value_type& basic_string< _CharT, _Traits, _Alloc >::reference

Definition at line 136 of file _string.h.

◆ size_type

template<class _CharT , class _Traits , class _Alloc >
typedef _Base::size_type basic_string< _CharT, _Traits, _Alloc >::size_type

Definition at line 138 of file _string.h.

◆ traits_type [1/3]

template<class _CharT , class _Traits , class _Alloc >
typedef _Traits basic_string< _CharT, _Traits, _Alloc >::traits_type

Definition at line 132 of file _string.h.

◆ traits_type [2/3]

template<class _CharT , class _Traits , class _Alloc >
typedef _Base::traits_type basic_string< _CharT, _Traits, _Alloc >::traits_type

Definition at line 42 of file _string_workaround.h.

◆ traits_type [3/3]

template<class _CharT , class _Traits , class _Alloc >
typedef _Base::traits_type basic_string< _CharT, _Traits, _Alloc >::traits_type

Definition at line 61 of file _string.h.

◆ value_type

template<class _CharT , class _Traits , class _Alloc >
typedef _CharT basic_string< _CharT, _Traits, _Alloc >::value_type

Definition at line 131 of file _string.h.

Constructor & Destructor Documentation

◆ basic_string() [1/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const allocator_type __a = allocator_type())
inlineexplicit

Definition at line 158 of file _string.h.

161 : _STLP_PRIV _String_base<_CharT,_Alloc>(allocator_type(), _Base::_DEFAULT_SIZE)
163 explicit basic_string(const allocator_type& __a)
164#endif
165 : _STLP_PRIV _String_base<_CharT,_Alloc>(__a, _Base::_DEFAULT_SIZE)
#define _STLP_PRIV
Definition: _dm.h:70
void _M_terminate_string()
Definition: _string.h:369
_Base::allocator_type allocator_type
Definition: _string.h:152

◆ basic_string() [2/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( _Reserve_t  ,
size_t  __n,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 169 of file _string.h.

175 basic_string(_Reserve_t, size_t __n, const allocator_type& __a)
176#endif
return __n
Definition: _algo.h:75
_STLP_PRIV _String_reserve_t _Reserve_t
Definition: _string.h:149

◆ basic_string() [3/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _Self __s)

Definition at line 647 of file _string.c.

648 : _STLP_PRIV _String_base<_CharT,_Alloc>(__s.get_allocator())
649{ _M_range_initialize(__s._M_Start(), __s._M_Finish()); }
void _M_range_initialize(_InputIter __f, _InputIter __l, const input_iterator_tag &__tag)
Definition: _string.h:313

◆ basic_string() [4/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _Self __s,
size_type  __pos,
size_type  __n = npos,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 183 of file _string.h.

188 if (__pos > __s.size())
189 this->_M_throw_out_of_range();
190 else
191 _M_range_initialize(__s._M_Start() + __pos, __s._M_Finish());
192 }
193 basic_string(const _Self& __s, size_type __pos, size_type __n)
195 if (__pos > __s.size())
196 this->_M_throw_out_of_range();
197 else
198 _M_range_initialize(__s._M_Start() + __pos,
199 __s._M_Start() + __pos + (min) (__n, __s.size() - __pos));
200 }
201 basic_string(const _Self& __s, size_type __pos, size_type __n,
202 const allocator_type& __a)
203#endif
205 if (__pos > __s.size())
206 this->_M_throw_out_of_range();
207 else
208 _M_range_initialize(__s._M_Start() + __pos,
209 __s._M_Start() + __pos + (min) (__n, __s.size() - __pos));
210 }
#define _Alloc
Definition: _bvector.h:330
_Base::size_type size_type
Definition: _string.h:138
basic_string< _CharT, _Traits, _Alloc > _Self
Definition: _string.h:128
#define min(a, b)
Definition: monoChain.cc:55

◆ basic_string() [5/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _CharT *  __s,
size_type  __n,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 213 of file _string.h.

219 _M_range_initialize(__s, __s + __n);
220 }
221 basic_string(const _CharT* __s, size_type __n, const allocator_type& __a)
222#endif
225 _M_range_initialize(__s, __s + __n);
226 }
#define _STLP_FIX_LITERAL_BUG(__x)
Definition: features.h:301

◆ basic_string() [6/29]

template<class _CharT , class _Traits , class _Alloc >
_STLP_MOVE_TO_STD_NAMESPACE basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _CharT *  __s,
const allocator_type __a = allocator_type() 
)

Definition at line 639 of file _string.c.

643 _M_range_initialize(__s, __s + traits_type::length(__s));
644}

◆ basic_string() [7/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( size_type  __n,
_CharT  __c,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 237 of file _string.h.

242 this->_M_finish = _STLP_PRIV __uninitialized_fill_n(this->_M_Start(), __n, __c);
244 }
245 basic_string(size_type __n, _CharT __c, const allocator_type& __a)
246#endif
248 this->_M_finish = _STLP_PRIV __uninitialized_fill_n(this->_M_Start(), __n, __c);
250 }
_ForwardIter __uninitialized_fill_n(_ForwardIter __first, _Size __n, const _Tp &__x)
#define __c
Definition: schilyio.h:209

◆ basic_string() [8/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( __move_source< _Self src)
inline

Definition at line 253 of file _string.h.

◆ basic_string() [9/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _CharT *  __f,
const _CharT *  __l,
const allocator_type &__a  _STLP_ALLOCATOR_TYPE_DFL 
)
inline

Definition at line 277 of file _string.h.

282 }
_STLP_PRIVATE iterator const _CharT const _CharT * __l
Definition: _string.h:890
_STLP_PRIVATE iterator const _CharT * __f
Definition: _string.h:890

◆ basic_string() [10/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const allocator_type __a = allocator_type())
inlineexplicit

Definition at line 48 of file _string_workaround.h.

#define _STLP_NO_MEM_T_STRING_BASE

◆ basic_string() [11/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( _Reserve_t  __r,
size_t  __n,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 51 of file _string_workaround.h.

53 : _STLP_NO_MEM_T_STRING_BASE(__r, __n, __a) {}

◆ basic_string() [12/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _Self __s)
inline

Definition at line 55 of file _string_workaround.h.

◆ basic_string() [13/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _Self __s,
size_type  __pos,
size_type  __n = npos,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 58 of file _string_workaround.h.

60 : _STLP_NO_MEM_T_STRING_BASE(__s, __pos, __n, __a) {}

◆ basic_string() [14/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _CharT *  __s,
size_type  __n,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 62 of file _string_workaround.h.

64 : _STLP_NO_MEM_T_STRING_BASE(__s, __n, __a) {}

◆ basic_string() [15/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _CharT *  __s,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 66 of file _string_workaround.h.

68 : _STLP_NO_MEM_T_STRING_BASE(__s, __a) {}

◆ basic_string() [16/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( size_type  __n,
_CharT  __c,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 70 of file _string_workaround.h.

◆ basic_string() [17/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( __move_source< _Self src)
inline

Definition at line 75 of file _string_workaround.h.

◆ basic_string() [18/29]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIterator >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( _InputIterator  __f,
_InputIterator  __l,
const allocator_type &__a  _STLP_ALLOCATOR_TYPE_DFL 
)
inline

Definition at line 82 of file _string_workaround.h.

85 typedef typename _IsIntegral<_InputIterator>::_Ret _Integral;
86 _M_initialize_dispatch(__f, __l, _Integral());
87 }
void _M_initialize_dispatch(_Integer __n, _Integer __x, const __true_type &)
Definition: _string.h:335
_Base::_CalledFromWorkaround_t _CalledFromWorkaround_t

◆ basic_string() [19/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const allocator_type __a = allocator_type())
inlineexplicit

Definition at line 90 of file _string.h.

_Base _M_non_dbg_impl
Definition: _string.h:70
_STLP_PRIV __owned_list _M_iter_list
Definition: _string.h:71

◆ basic_string() [20/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( _Reserve_t  __r,
size_t  __n,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 93 of file _string.h.

◆ basic_string() [21/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _Self __s)
inline

Definition at line 97 of file _string.h.

98 : _ConstructCheck(__s),
99 _M_non_dbg_impl(__s._M_non_dbg_impl), _M_iter_list(&_M_non_dbg_impl) {}
_STLP_PRIV __construct_checker< _STLP_NON_DBG_STRING > _ConstructCheck
Definition: _string.h:56

◆ basic_string() [22/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _Self __s,
size_type  __pos,
size_type  __n = npos,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 101 of file _string.h.

103 : _M_non_dbg_impl(__s._M_non_dbg_impl, __pos, __n, __a),

◆ basic_string() [23/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _CharT *  __s,
size_type  __n,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 106 of file _string.h.

◆ basic_string() [24/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _CharT *  __s,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 111 of file _string.h.

◆ basic_string() [25/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( size_type  __n,
_CharT  __c,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 116 of file _string.h.

◆ basic_string() [26/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( __move_source< _Self src)
inline

Definition at line 121 of file _string.h.

122 : _M_non_dbg_impl(__move_source<_Base >(src.get()._M_non_dbg_impl)),
124# if defined (_STLP_NO_EXTENSIONS) || (_STLP_DEBUG_LEVEL == _STLP_STANDARD_DBG_LEVEL)
125 src.get()._M_iter_list._Invalidate_all();
126# else
127 src.get()._M_iter_list._Set_owner(_M_iter_list);
128# endif
129 }

◆ basic_string() [27/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _CharT *  __f,
const _CharT *  __l,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 133 of file _string.h.

◆ basic_string() [28/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const_iterator  __f,
const_iterator  __l,
const allocator_type __a = allocator_type() 
)
inline

Definition at line 138 of file _string.h.

141 _M_non_dbg_impl(__f._M_iterator, __l._M_iterator, __a), _M_iter_list(&_M_non_dbg_impl) {
142 }

◆ basic_string() [29/29]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc >::basic_string ( const _Base __x)
inlineprivate

Definition at line 161 of file _string.h.

Member Function Documentation

◆ _Compare_Capacity()

template<class _CharT , class _Traits , class _Alloc >
void basic_string< _CharT, _Traits, _Alloc >::_Compare_Capacity ( size_type  __old_capacity)
inlineprivate

◆ _Invalidate_all()

◆ _Invalidate_iterator()

template<class _CharT , class _Traits , class _Alloc >
void basic_string< _CharT, _Traits, _Alloc >::_Invalidate_iterator ( const iterator __it)
inlineprivate

Definition at line 80 of file _string.h.

81 { _STLP_PRIV __invalidate_iterator(&_M_iter_list, __it); }
_STLP_MOVE_TO_PRIV_NAMESPACE const _InputIterator const input_iterator_tag &_InputIterator __it(__first)

Referenced by basic_string< _CharT, _Traits, _Alloc >::pop_back().

◆ _Invalidate_iterators()

template<class _CharT , class _Traits , class _Alloc >
void basic_string< _CharT, _Traits, _Alloc >::_Invalidate_iterators ( const iterator __f,
const iterator __l 
)
inlineprivate

◆ _M_append()

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc > & basic_string< _CharT, _Traits, _Alloc >::_M_append ( const _CharT *  __first,
const _CharT *  __last 
)
private

Definition at line 196 of file _string.c.

196 {
197 if (__first != __last) {
199 if (__n >= this->_M_rest()) {
200 size_type __len = _M_compute_next_size(__n);
201 pointer __new_start = this->_M_start_of_storage.allocate(__len, __len);
202 pointer __new_finish = _STLP_PRIV __ucopy(this->_M_Start(), this->_M_Finish(), __new_start);
203 __new_finish = _STLP_PRIV __ucopy(__first, __last, __new_finish);
204 _M_construct_null(__new_finish);
205 this->_M_deallocate_block();
206 this->_M_reset(__new_start, __new_finish, __new_start + __len);
207 }
208 else {
209 const _CharT* __f1 = __first;
210 ++__f1;
211 _STLP_PRIV __ucopy(__f1, __last, this->_M_finish + 1);
212 _M_construct_null(this->_M_finish + __n);
213 _Traits::assign(*end(), *__first);
214 this->_M_finish += __n;
215 }
216 }
217 return *this;
218}
_STLP_BEGIN_NAMESPACE _STLP_MOVE_TO_PRIV_NAMESPACE _OutputIter __ucopy(_InputIter __first, _InputIter __last, _OutputIter __result, _Distance *)
iterator end()
Definition: _string.h:386
size_type __len
Definition: _string.h:306
_STLP_PRIVATE const _CharT const _CharT * __last
Definition: _string.h:671
_STLP_PRIVATE const _CharT * __first
Definition: _string.h:671
#define __STATIC_CAST(__x, __y)
Definition: features.h:585
GLsizei const GLvoid * pointer
Definition: glext.h:5848

Referenced by basic_string< _CharT, _Traits, _Alloc >::append().

◆ _M_append_dispatch() [1/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
_Self & basic_string< _CharT, _Traits, _Alloc >::_M_append_dispatch ( _InputIter  __f,
_InputIter  __l,
const __false_type  
)
inlineprivate

Definition at line 244 of file _string_workaround.h.

245 { return _M_appendT(__f, __l, _STLP_ITERATOR_CATEGORY(__f, _InputIter)); }
#define _STLP_ITERATOR_CATEGORY(_It, _Tp)
_Self & _M_appendT(_InputIter __first, _InputIter __last, const input_iterator_tag &)

◆ _M_append_dispatch() [2/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _Integer >
_Self & basic_string< _CharT, _Traits, _Alloc >::_M_append_dispatch ( _Integer  __n,
_Integer  __x,
const __true_type  
)
inlineprivate

Definition at line 240 of file _string_workaround.h.

241 { return append((size_type) __n, (_CharT) __x); }
_Self & append(const _CharT *__first, const _CharT *__last)
Definition: _string.h:509

Referenced by basic_string< _CharT, _Traits, _Alloc >::append().

◆ _M_appendT() [1/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _ForwardIter >
_Self & basic_string< _CharT, _Traits, _Alloc >::_M_appendT ( _ForwardIter  __first,
_ForwardIter  __last,
const forward_iterator_tag  
)
inlineprivate

Definition at line 216 of file _string_workaround.h.

217 {
218 if (__first != __last) {
219 const size_type __n = __STATIC_CAST(size_type, _STLP_STD::distance(__first, __last));
220 if (__n >= this->_M_rest()) {
221 size_type __len = this->_M_compute_next_size(__n);
222 pointer __new_start = this->_M_start_of_storage.allocate(__len, __len);
223 pointer __new_finish = uninitialized_copy(this->_M_Start(), this->_M_Finish(), __new_start);
224 __new_finish = uninitialized_copy(__first, __last, __new_finish);
225 this->_M_construct_null(__new_finish);
226 this->_M_deallocate_block();
227 this->_M_reset(__new_start, __new_finish, __new_start + __len);
228 }
229 else {
230 _Traits::assign(*this->_M_finish, *__first++);
231 uninitialized_copy(__first, __last, this->_M_Finish() + 1);
232 this->_M_construct_null(this->_M_Finish() + __n);
233 this->_M_finish += __n;
234 }
235 }
236 return *this;
237 }
_STLP_MOVE_TO_STD_NAMESPACE _ForwardIter uninitialized_copy(_InputIter __first, _InputIter __last, _ForwardIter __result)

◆ _M_appendT() [2/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
_Self & basic_string< _CharT, _Traits, _Alloc >::_M_appendT ( _InputIter  __first,
_InputIter  __last,
const input_iterator_tag  
)
inlineprivate

◆ _M_assign()

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc > & basic_string< _CharT, _Traits, _Alloc >::_M_assign ( const _CharT *  __f,
const _CharT *  __l 
)
private

Definition at line 242 of file _string.c.

242 {
243 ptrdiff_t __n = __l - __f;
244 if (__STATIC_CAST(size_type, __n) <= size()) {
245 _Traits::copy(this->_M_Start(), __f, __n);
246 erase(begin() + __n, end());
247 }
248 else {
249 _Traits::copy(this->_M_Start(), __f, size());
250 _M_append(__f + size(), __l);
251 }
252 return *this;
253}
_Self & _M_append(const _CharT *__first, const _CharT *__last)
Definition: _string.c:196
_Self & erase(size_type __pos=0, size_type __n=npos)
Definition: _string.h:788
size_type size() const
Definition: _string.h:400
iterator begin()
Definition: _string.h:385
__kernel_ptrdiff_t ptrdiff_t
Definition: linux.h:247

Referenced by basic_string< _CharT, _Traits, _Alloc >::assign(), and basic_string< _CharT, _Traits, _Alloc >::operator=().

◆ _M_assign_dispatch() [1/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
_Self & basic_string< _CharT, _Traits, _Alloc >::_M_assign_dispatch ( _InputIter  __f,
_InputIter  __l,
const __false_type  
)
inlineprivate

Definition at line 283 of file _string_workaround.h.

283 {
284 pointer __cur = this->_M_Start();
285 while (__f != __l && __cur != this->_M_Finish()) {
286 _Traits::assign(*__cur, *__f);
287 ++__f;
288 ++__cur;
289 }
290 if (__f == __l)
291 _Base::erase(__cur, this->_M_Finish());
292 else
294 return *this;
295 }

◆ _M_assign_dispatch() [2/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _Integer >
_Self & basic_string< _CharT, _Traits, _Alloc >::_M_assign_dispatch ( _Integer  __n,
_Integer  __x,
const __true_type  
)
inlineprivate

Definition at line 279 of file _string_workaround.h.

280 { return assign((size_type) __n, (_CharT) __x); }
_Self & assign(const _Self &__s)
Definition: _string.h:548

Referenced by basic_string< _CharT, _Traits, _Alloc >::assign().

◆ _M_compare() [1/5]

template<class _CharT , class _Traits , class _Alloc >
static int _STLP_CALL basic_string< _CharT, _Traits, _Alloc >::_M_compare ( const _CharT *  __f1,
const _CharT *  __l1,
const _CharT *  __f2,
const _CharT *  __l2 
)
inlinestatic

Definition at line 1071 of file _string.h.

1072 {
1073 const ptrdiff_t __n1 = __l1 - __f1;
1074 const ptrdiff_t __n2 = __l2 - __f2;
1075 const int cmp = _Traits::compare(__f1, __f2, (min) (__n1, __n2));
1076 return cmp != 0 ? cmp : (__n1 < __n2 ? -1 : (__n1 > __n2 ? 1 : 0));
1077 }
#define cmp(status, error)
Definition: error.c:114

Referenced by basic_string< _CharT, _Traits, _Alloc >::compare().

◆ _M_compare() [2/5]

template<class _CharT , class _Traits , class _Alloc >
static int _STLP_CALL basic_string< _CharT, _Traits, _Alloc >::_M_compare ( const _CharT *  __f1,
const _CharT *  __l1,
const _CharT *  __f2,
const _CharT *  __l2 
)
inlinestatic

Definition at line 673 of file _string.h.

675 { return _Base::_M_compare(__f1, __l1, __f2, __l2); }

◆ _M_compare() [3/5]

template<class _CharT , class _Traits , class _Alloc >
static int _STLP_CALL basic_string< _CharT, _Traits, _Alloc >::_M_compare ( const _CharT *  __f1,
const _CharT *  __l1,
const_iterator  __f2,
const_iterator  __l2 
)
inlinestatic

Definition at line 679 of file _string.h.

681 { return _Base::_M_compare(__f1, __l1, __f2._M_iterator, __l2._M_iterator); }

◆ _M_compare() [4/5]

template<class _CharT , class _Traits , class _Alloc >
static int _STLP_CALL basic_string< _CharT, _Traits, _Alloc >::_M_compare ( const_iterator  __f1,
const_iterator  __l1,
const _CharT *  __f2,
const _CharT *  __l2 
)
inlinestatic

Definition at line 676 of file _string.h.

678 { return _Base::_M_compare(__f1._M_iterator, __l1._M_iterator, __f2, __l2); }

◆ _M_compare() [5/5]

template<class _CharT , class _Traits , class _Alloc >
static int _STLP_CALL basic_string< _CharT, _Traits, _Alloc >::_M_compare ( const_iterator  __f1,
const_iterator  __l1,
const_iterator  __f2,
const_iterator  __l2 
)
inlinestatic

Definition at line 682 of file _string.h.

684 { return _Base::_M_compare(__f1._M_iterator, __l1._M_iterator, __f2._M_iterator, __l2._M_iterator); }

◆ _M_copy()

template<class _CharT , class _Traits , class _Alloc >
void basic_string< _CharT, _Traits, _Alloc >::_M_copy ( const _CharT *  __f,
const _CharT *  __l,
_CharT *  __res 
)
inline

Definition at line 675 of file _string.h.

675 {
678 _Traits::copy(__res, __f, __l - __f);
679 }

◆ _M_copyT() [1/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIterator >
void basic_string< _CharT, _Traits, _Alloc >::_M_copyT ( _InputIterator  __first,
_InputIterator  __last,
pointer  __result 
)
inlineprivate

Definition at line 441 of file _string_workaround.h.

441 {
443 for ( ; __first != __last; ++__first, ++__result)
444 _Traits::assign(*__result, *__first);
445 }

Referenced by basic_string< _CharT, _Traits, _Alloc >::_M_insertT().

◆ _M_copyT() [2/2]

template<class _CharT , class _Traits , class _Alloc >
void basic_string< _CharT, _Traits, _Alloc >::_M_copyT ( const _CharT *  __f,
const _CharT *  __l,
_CharT *  __res 
)
inlineprivate

Definition at line 448 of file _string_workaround.h.

448 {
450 _Base::_M_copy(__f, __l, __res);
451 }

◆ _M_initialize_dispatch() [1/4]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
void basic_string< _CharT, _Traits, _Alloc >::_M_initialize_dispatch ( _InputIter  __f,
_InputIter  __l,
const __false_type  
)
inline

Definition at line 342 of file _string.h.

342 {
344 }
void _M_range_initializeT(_InputIter __f, _InputIter __l)
Definition: _string.h:330

◆ _M_initialize_dispatch() [2/4]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
void basic_string< _CharT, _Traits, _Alloc >::_M_initialize_dispatch ( _InputIter  __f,
_InputIter  __l,
const __false_type  
)
inlineprivate

Definition at line 143 of file _string_workaround.h.

143 {
145 }

◆ _M_initialize_dispatch() [3/4]

template<class _CharT , class _Traits , class _Alloc >
template<class _Integer >
void basic_string< _CharT, _Traits, _Alloc >::_M_initialize_dispatch ( _Integer  __n,
_Integer  __x,
const __true_type  
)
inline

Definition at line 335 of file _string.h.

335 {
336 this->_M_allocate_block(__n + 1);
337 this->_M_finish = _STLP_PRIV __uninitialized_fill_n(this->_M_Start(), __n, __x);
338 this->_M_terminate_string();
339 }

Referenced by basic_string< _CharT, _Traits, _Alloc >::basic_string().

◆ _M_initialize_dispatch() [4/4]

template<class _CharT , class _Traits , class _Alloc >
template<class _Integer >
void basic_string< _CharT, _Traits, _Alloc >::_M_initialize_dispatch ( _Integer  __n,
_Integer  __x,
const __true_type  
)
inlineprivate

Definition at line 136 of file _string_workaround.h.

136 {
137 this->_M_allocate_block(__n + 1);
138 this->_M_finish = uninitialized_fill_n(this->_M_Start(), __n, __x);
139 this->_M_terminate_string();
140 }
_STLP_MOVE_TO_STD_NAMESPACE void uninitialized_fill_n(_ForwardIter __first, _Size __n, const _Tp &__x)

◆ _M_insert()

template<class _CharT , class _Traits , class _Alloc >
void basic_string< _CharT, _Traits, _Alloc >::_M_insert ( iterator  __p,
const _CharT *  __f,
const _CharT *  __l,
bool  __self_ref 
)
inlineprivate

Definition at line 369 of file _string_workaround.h.

369 {
371 _Base::_M_insert(__p, __f, __l, __self_ref);
372 }
_STLP_PRIVATE const _CharT const _CharT bool __self_ref
Definition: _string.h:671

Referenced by basic_string< _CharT, _Traits, _Alloc >::insert().

◆ _M_insert_aux()

template<class _CharT , class _Traits , class _Alloc >
_CharT * basic_string< _CharT, _Traits, _Alloc >::_M_insert_aux ( pointer  ,
_CharT   
)

Definition at line 256 of file _string.c.

257 {
258 pointer __new_pos = __p;
259 if (this->_M_rest() > 1 ) {
260 _M_construct_null(this->_M_finish + 1);
261 _Traits::move(__p + 1, __p, this->_M_finish - __p);
262 _Traits::assign(*__p, __c);
263 ++this->_M_finish;
264 }
265 else {
266 size_type __len = _M_compute_next_size(1);
267 pointer __new_start = this->_M_start_of_storage.allocate(__len, __len);
268 __new_pos = _STLP_PRIV __ucopy(this->_M_Start(), __p, __new_start);
269 _Traits::assign(*__new_pos, __c);
270 pointer __new_finish = __new_pos + 1;
271 __new_finish = _STLP_PRIV __ucopy(__p, this->_M_finish, __new_finish);
272 _M_construct_null(__new_finish);
273 this->_M_deallocate_block();
274 this->_M_reset(__new_start, __new_finish, __new_start + __len);
275 }
276 return __new_pos;
277}

Referenced by basic_string< _CharT, _Traits, _Alloc >::insert().

◆ _M_insert_dispatch() [1/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
void basic_string< _CharT, _Traits, _Alloc >::_M_insert_dispatch ( iterator  __p,
_InputIter  __first,
_InputIter  __last,
const __false_type  
)
inlineprivate

Definition at line 432 of file _string_workaround.h.

433 {
435 /* We are forced to do a temporary string to avoid the self referencing issue. */
436 const _Self __self(__first, __last, this->get_allocator());
437 _M_insertT(__p, __self.begin(), __self.end(), _STLP_ITERATOR_CATEGORY(__first, _InputIter));
438 }
void _M_insertT(iterator __p, _InputIter __first, _InputIter __last, const input_iterator_tag &)
allocator_type get_allocator() const
Definition: _string.h:154

◆ _M_insert_dispatch() [2/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _Integer >
void basic_string< _CharT, _Traits, _Alloc >::_M_insert_dispatch ( iterator  __p,
_Integer  __n,
_Integer  __x,
const __true_type  
)
inlineprivate

Definition at line 427 of file _string_workaround.h.

429 { insert(__p, (size_type) __n, (_CharT) __x); }
static int insert
Definition: xmllint.c:138

Referenced by basic_string< _CharT, _Traits, _Alloc >::insert().

◆ _M_insert_overflow()

template<class _CharT , class _Traits , class _Alloc >
template<class _ForwardIter >
void basic_string< _CharT, _Traits, _Alloc >::_M_insert_overflow ( iterator  __pos,
_ForwardIter  __first,
_ForwardIter  __last,
size_type  __n 
)
inlineprivate

Definition at line 375 of file _string_workaround.h.

376 {
377 size_type __len = this->_M_compute_next_size(__n);
378 pointer __new_start = this->_M_start_of_storage.allocate(__len, __len);
379 pointer __new_finish = uninitialized_copy(this->_M_Start(), __pos, __new_start);
380 __new_finish = uninitialized_copy(__first, __last, __new_finish);
381 __new_finish = uninitialized_copy(__pos, this->_M_Finish(), __new_finish);
382 this->_M_construct_null(__new_finish);
383 this->_M_deallocate_block();
384 this->_M_reset(__new_start, __new_finish, __new_start + __len);
385 }

Referenced by basic_string< _CharT, _Traits, _Alloc >::_M_insertT().

◆ _M_insertT() [1/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
void basic_string< _CharT, _Traits, _Alloc >::_M_insertT ( iterator  __p,
_InputIter  __first,
_InputIter  __last,
const input_iterator_tag  
)
inlineprivate

Definition at line 388 of file _string_workaround.h.

389 {
390 for ( ; __first != __last; ++__first) {
391 __p = insert(__p, *__first);
392 ++__p;
393 }
394 }

Referenced by basic_string< _CharT, _Traits, _Alloc >::_M_insert_dispatch().

◆ _M_insertT() [2/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _ForwardIter >
void basic_string< _CharT, _Traits, _Alloc >::_M_insertT ( iterator  __pos,
_ForwardIter  __first,
_ForwardIter  __last,
const forward_iterator_tag  
)
inlineprivate

Definition at line 397 of file _string_workaround.h.

398 {
399 if (__first != __last) {
400 size_type __n = __STATIC_CAST(size_type, _STLP_STD::distance(__first, __last));
401 if (__n < this->_M_rest()) {
402 const size_type __elems_after = this->_M_finish - __pos;
403 if (__elems_after >= __n) {
404 uninitialized_copy((this->_M_Finish() - __n) + 1, this->_M_Finish() + 1, this->_M_Finish() + 1);
405 this->_M_finish += __n;
406 _Traits::move(__pos + __n, __pos, (__elems_after - __n) + 1);
407 _M_copyT(__first, __last, __pos);
408 }
409 else {
410 pointer __old_finish = this->_M_Finish();
411 _ForwardIter __mid = __first;
412 _STLP_STD::advance(__mid, __elems_after + 1);
413 _STLP_STD::uninitialized_copy(__mid, __last, this->_M_Finish() + 1);
414 this->_M_finish += __n - __elems_after;
415 uninitialized_copy(__pos, __old_finish + 1, this->_M_Finish());
416 this->_M_finish += __elems_after;
417 _M_copyT(__first, __mid, __pos);
418 }
419 }
420 else {
422 }
423 }
424 }
void _M_copyT(_InputIterator __first, _InputIterator __last, pointer __result)
void _M_insert_overflow(iterator __pos, _ForwardIter __first, _ForwardIter __last, size_type __n)

◆ _M_inside()

template<class _CharT , class _Traits , class _Alloc >
bool basic_string< _CharT, _Traits, _Alloc >::_M_inside ( const _CharT *  __s) const
inlineprivate

Definition at line 371 of file _string.h.

371 {
373 return (__s >= this->_M_Start()) && (__s < this->_M_Finish());
374 }

Referenced by basic_string< _CharT, _Traits, _Alloc >::insert(), and basic_string< _CharT, _Traits, _Alloc >::replace().

◆ _M_move()

template<class _CharT , class _Traits , class _Alloc >
void basic_string< _CharT, _Traits, _Alloc >::_M_move ( const _CharT *  __f,
const _CharT *  __l,
_CharT *  __res 
)
inline

Definition at line 681 of file _string.h.

681 {
683 _Traits::move(__res, __f, __l - __f);
684 }

◆ _M_null()

template<class _CharT , class _Traits , class _Alloc >
static _CharT _STLP_CALL basic_string< _CharT, _Traits, _Alloc >::_M_null ( )
inlinestaticprivate

◆ _M_range_initialize() [1/5]

template<class _CharT , class _Traits , class _Alloc >
template<class _ForwardIter >
void basic_string< _CharT, _Traits, _Alloc >::_M_range_initialize ( _ForwardIter  __f,
_ForwardIter  __l,
const forward_iterator_tag  
)
inline

Definition at line 321 of file _string.h.

322 {
323 difference_type __n = _STLP_STD::distance(__f, __l);
324 this->_M_allocate_block(__n + 1);
325 this->_M_finish = uninitialized_copy(__f, __l, this->_M_Start());
326 this->_M_terminate_string();
327 }
ptrdiff_t difference_type
Definition: _string.h:139

◆ _M_range_initialize() [2/5]

template<class _CharT , class _Traits , class _Alloc >
template<class _ForwardIter >
void basic_string< _CharT, _Traits, _Alloc >::_M_range_initialize ( _ForwardIter  __f,
_ForwardIter  __l,
const forward_iterator_tag  
)
inlineprivate

Definition at line 122 of file _string_workaround.h.

123 {
124 difference_type __n = _STLP_STD::distance(__f, __l);
125 this->_M_allocate_block(__n + 1);
126 this->_M_finish = uninitialized_copy(__f, __l, this->_M_Start());
127 this->_M_terminate_string();
128 }

◆ _M_range_initialize() [3/5]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
void basic_string< _CharT, _Traits, _Alloc >::_M_range_initialize ( _InputIter  __f,
_InputIter  __l,
const input_iterator_tag __tag 
)
inline

Definition at line 313 of file _string.h.

314 {
315 this->_M_allocate_block();
316 _M_construct_null(this->_M_Finish());
317 _M_appendT(__f, __l, __tag);
318 }

Referenced by basic_string< _CharT, _Traits, _Alloc >::_M_range_initializeT(), and basic_string< _CharT, _Traits, _Alloc >::basic_string().

◆ _M_range_initialize() [4/5]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
void basic_string< _CharT, _Traits, _Alloc >::_M_range_initialize ( _InputIter  __f,
_InputIter  __l,
const input_iterator_tag __tag 
)
inlineprivate

Definition at line 114 of file _string_workaround.h.

115 {
116 this->_M_allocate_block();
117 this->_M_construct_null(this->_M_Finish());
118 _M_appendT(__f, __l, __tag);
119 }

◆ _M_range_initialize() [5/5]

template<class _CharT , class _Traits , class _Alloc >
void basic_string< _CharT, _Traits, _Alloc >::_M_range_initialize ( const _CharT *  __f,
const _CharT *  __l 
)
inlineprivate

Definition at line 376 of file _string.h.

376 {
378 ptrdiff_t __n = __l - __f;
379 this->_M_allocate_block(__n + 1);
380 this->_M_finish = uninitialized_copy(__f, __l, this->_M_Start());
382 }

◆ _M_range_initializeT() [1/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
void basic_string< _CharT, _Traits, _Alloc >::_M_range_initializeT ( _InputIter  __f,
_InputIter  __l 
)
inline

◆ _M_range_initializeT() [2/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
void basic_string< _CharT, _Traits, _Alloc >::_M_range_initializeT ( _InputIter  __f,
_InputIter  __l 
)
inlineprivate

Definition at line 131 of file _string_workaround.h.

131 {
133 }

◆ _M_replace()

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc > & basic_string< _CharT, _Traits, _Alloc >::_M_replace ( iterator  __first,
iterator  __last,
const _CharT *  __f,
const _CharT *  __l,
bool  __self_ref 
)
inlineprivate

◆ _M_replace_dispatch() [1/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
_Self & basic_string< _CharT, _Traits, _Alloc >::_M_replace_dispatch ( iterator  __first,
iterator  __last,
_InputIter  __f,
_InputIter  __l,
const __false_type  
)
inlineprivate

Definition at line 567 of file _string_workaround.h.

568 {
570 /* We are forced to do a temporary string to avoid the self referencing issue. */
571 const _Self __self(__f, __l, this->get_allocator());
572 return _M_replace(__first, __last, __self._M_Start(), __self._M_Finish(), false);
573 }
_Self & _M_replace(iterator __first, iterator __last, const _CharT *__f, const _CharT *__l, bool __self_ref)

◆ _M_replace_dispatch() [2/2]

template<class _CharT , class _Traits , class _Alloc >
template<class _Integer >
_Self & basic_string< _CharT, _Traits, _Alloc >::_M_replace_dispatch ( iterator  __first,
iterator  __last,
_Integer  __n,
_Integer  __x,
const __true_type  
)
inlineprivate

Definition at line 560 of file _string_workaround.h.

561 {
563 return replace(__first, __last, (size_type) __n, (_CharT) __x);
564 }
_Self & replace(size_type __pos, size_type __n, const _Self &__s)
Definition: _string.h:813

Referenced by basic_string< _CharT, _Traits, _Alloc >::replace().

◆ _M_reserve()

template<class _CharT , class _Traits , class _Alloc >
void basic_string< _CharT, _Traits, _Alloc >::_M_reserve ( size_type  __n)
private

Definition at line 170 of file _string.c.

170 {
171 pointer __new_start = this->_M_start_of_storage.allocate(__n, __n);
172 pointer __new_finish = _STLP_PRIV __ucopy(this->_M_Start(), this->_M_Finish(), __new_start);
173 _M_construct_null(__new_finish);
174 this->_M_deallocate_block();
175 this->_M_reset(__new_start, __new_finish, __new_start + __n);
176}

Referenced by basic_string< _CharT, _Traits, _Alloc >::push_back().

◆ _M_terminate_string()

template<class _CharT , class _Traits , class _Alloc >
void basic_string< _CharT, _Traits, _Alloc >::_M_terminate_string ( )
inlineprivate

◆ append() [1/20]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( _InputIter  __first,
_InputIter  __last 
)
inline

Definition at line 191 of file _string_workaround.h.

191 {
192 typedef typename _IsIntegral<_InputIter>::_Ret _Integral;
193 return _M_append_dispatch(__first, __last, _Integral());
194 }
_Self & _M_append_dispatch(_Integer __n, _Integer __x, const __true_type &)

◆ append() [2/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _CharT *  __f,
const _CharT *  __l 
)
inline

Definition at line 198 of file _string_workaround.h.

198 {
200 _Base::append(__f, __l);
201 return *this;
202 }

◆ append() [3/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _CharT *  __f,
const _CharT *  __l 
)
inline

Definition at line 255 of file _string.h.

255 {
257 _STLP_DEBUG_CHECK(_STLP_PRIV __check_ptr_range(__f, __l))
258 size_type __old_capacity = capacity();
259 _M_non_dbg_impl.append(__f, __l);
260 _Compare_Capacity(__old_capacity);
261 return *this;
262 }
#define _STLP_DEBUG_CHECK(expr)
Definition: _debug.h:440
void _Compare_Capacity(size_type __old_capacity)
Definition: _string.h:75

◆ append() [4/20]

◆ append() [5/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _CharT *  __s)
inline

Definition at line 529 of file _string.h.

530 { _STLP_FIX_LITERAL_BUG(__s) return _M_append(__s, __s + traits_type::length(__s)); }

◆ append() [6/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _CharT *  __s)
inline

Definition at line 178 of file _string_workaround.h.

178 {
180 _Base::append(__s);
181 return *this;
182 }

◆ append() [7/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _CharT *  __s)
inline

Definition at line 296 of file _string.h.

296 {
298 _STLP_VERBOSE_ASSERT((__s != 0), _StlMsg_INVALID_ARGUMENT)
299 size_type __old_capacity = capacity();
300 _M_non_dbg_impl.append(__s);
301 _Compare_Capacity(__old_capacity);
302 return *this;
303 }
#define _STLP_VERBOSE_ASSERT(expr, diagnostic)
Definition: _debug.h:439

◆ append() [8/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _CharT *  __s,
size_type  __n 
)
inline

Definition at line 527 of file _string.h.

528 { _STLP_FIX_LITERAL_BUG(__s) return _M_append(__s, __s+__n); }

◆ append() [9/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _CharT *  __s,
size_type  __n 
)
inline

Definition at line 173 of file _string_workaround.h.

173 {
175 _Base::append(__s, __n);
176 return *this;
177 }

◆ append() [10/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _CharT *  __s,
size_type  __n 
)
inline

Definition at line 287 of file _string.h.

287 {
289 _STLP_VERBOSE_ASSERT((__s != 0), _StlMsg_INVALID_ARGUMENT)
290 size_type __old_capacity = capacity();
291 _M_non_dbg_impl.append(__s, __n);
292 _Compare_Capacity(__old_capacity);
293 return *this;
294 }

◆ append() [11/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _Self __s)
inline

Definition at line 516 of file _string.h.

517 { return _M_append(__s._M_Start(), __s._M_Finish()); }

◆ append() [12/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _Self __s)
inline

Definition at line 162 of file _string_workaround.h.

162 {
163 _Base::append(__s);
164 return *this;
165 }

◆ append() [13/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _Self __s)
inline

Definition at line 273 of file _string.h.

273 {
274 size_type __old_capacity = capacity();
275 _M_non_dbg_impl.append(__s._M_non_dbg_impl);
276 _Compare_Capacity(__old_capacity);
277 return *this;
278 }

◆ append() [14/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _Self __s,
size_type  __pos,
size_type  __n 
)
inline

Definition at line 519 of file _string.h.

520 {
521 if (__pos > __s.size())
522 this->_M_throw_out_of_range();
523 return _M_append(__s._M_Start() + __pos,
524 __s._M_Start() + __pos + (min) (__n, __s.size() - __pos));
525 }

◆ append() [15/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _Self __s,
size_type  __pos,
size_type  __n 
)
inline

Definition at line 167 of file _string_workaround.h.

168 {
169 _Base::append(__s, __pos, __n);
170 return *this;
171 }

◆ append() [16/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const _Self __s,
size_type  __pos,
size_type  __n 
)
inline

Definition at line 280 of file _string.h.

280 {
281 size_type __old_capacity = capacity();
282 _M_non_dbg_impl.append(__s._M_non_dbg_impl, __pos, __n);
283 _Compare_Capacity(__old_capacity);
284 return *this;
285 }

◆ append() [17/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( const_iterator  __f,
const_iterator  __l 
)
inline

Definition at line 264 of file _string.h.

264 {
265 _STLP_DEBUG_CHECK(_STLP_PRIV __check_range(__f, __l))
266 size_type __old_capacity = capacity();
267 _M_non_dbg_impl.append(__f._M_iterator, __l._M_iterator);
268 _Compare_Capacity(__old_capacity);
269 return *this;
270 }

◆ append() [18/20]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc > & basic_string< _CharT, _Traits, _Alloc >::append ( size_type  __n,
_CharT  __c 
)

Definition at line 180 of file _string.c.

180 {
181 if (__n > 0) {
182 if (__n > max_size() - size())
183 this->_M_throw_length_error();
184 if (__n >= this->_M_rest())
185 _M_reserve(_M_compute_next_size(__n));
186 _STLP_PRIV __uninitialized_fill_n(this->_M_finish + 1, __n - 1, __c);
187 _M_construct_null(this->_M_finish + __n);
188 _Traits::assign(*end(), __c);
189 this->_M_finish += __n;
190 }
191 return *this;
192}
void _M_reserve(size_type)
Definition: _string.c:170
size_type max_size() const
Definition: _string.h:402

◆ append() [19/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( size_type  __n,
_CharT  __c 
)
inline

Definition at line 183 of file _string_workaround.h.

183 {
184 _Base::append(__n, __c);
185 return *this;
186 }

◆ append() [20/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::append ( size_type  __n,
_CharT  __c 
)
inline

Definition at line 305 of file _string.h.

305 {
306 size_type __old_capacity = this->capacity();
307 _M_non_dbg_impl.append(__n, __c);
308 _Compare_Capacity(__old_capacity);
309 return *this;
310 }

◆ assign() [1/20]

template<class _CharT , class _Traits , class _Alloc >
template<class _InputIter >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( _InputIter  __first,
_InputIter  __last 
)
inline

Definition at line 301 of file _string_workaround.h.

301 {
302 typedef typename _IsIntegral<_InputIter>::_Ret _Integral;
303 return _M_assign_dispatch(__first, __last, _Integral());
304 }
_Self & _M_assign_dispatch(_Integer __n, _Integer __x, const __true_type &)

◆ assign() [2/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _CharT *  __f,
const _CharT *  __l 
)
inline

Definition at line 601 of file _string.h.

601 {
603 return _M_assign(__f, __l);
604 }
_Self & _M_assign(const _CharT *__f, const _CharT *__l)
Definition: _string.c:242

◆ assign() [3/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _CharT *  __f,
const _CharT *  __l 
)
inline

Definition at line 311 of file _string_workaround.h.

311 {
313 _Base::assign(__f, __l);
314 return *this;
315 }

◆ assign() [4/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _CharT *  __f,
const _CharT *  __l 
)
inline

Definition at line 373 of file _string.h.

373 {
375 _STLP_DEBUG_CHECK(_STLP_PRIV __check_ptr_range(__f, __l))
377 _M_non_dbg_impl.assign(__f, __l);
378 return *this;
379 }

◆ assign() [5/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _CharT *  __s)
inline

Definition at line 562 of file _string.h.

563 { _STLP_FIX_LITERAL_BUG(__s) return _M_assign(__s, __s + _Traits::length(__s)); }

◆ assign() [6/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _CharT *  __s)
inline

Definition at line 265 of file _string_workaround.h.

265 {
267 _Base::assign(__s);
268 return *this;
269 }

◆ assign() [7/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _CharT *  __s)
inline

Definition at line 346 of file _string.h.

346 {
348 _STLP_VERBOSE_ASSERT((__s != 0), _StlMsg_INVALID_ARGUMENT)
350 _M_non_dbg_impl.assign(__s);
351 return *this;
352 }

◆ assign() [8/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _CharT *  __s,
size_type  __n 
)
inline

Definition at line 559 of file _string.h.

560 { _STLP_FIX_LITERAL_BUG(__s) return _M_assign(__s, __s + __n); }

◆ assign() [9/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _CharT *  __s,
size_type  __n 
)
inline

Definition at line 259 of file _string_workaround.h.

259 {
261 _Base::assign(__s, __n);
262 return *this;
263 }

◆ assign() [10/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _CharT *  __s,
size_type  __n 
)
inline

Definition at line 338 of file _string.h.

338 {
340 _STLP_VERBOSE_ASSERT((__s != 0), _StlMsg_INVALID_ARGUMENT)
342 _M_non_dbg_impl.assign(__s, __s + __n);
343 return *this;
344 }

◆ assign() [11/20]

◆ assign() [12/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _Self __s)
inline

Definition at line 248 of file _string_workaround.h.

248 {
249 _Base::assign(__s);
250 return *this;
251 }

◆ assign() [13/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _Self __s)
inline

Definition at line 324 of file _string.h.

324 {
326 _M_non_dbg_impl.assign(__s._M_non_dbg_impl);
327 return *this;
328 }

◆ assign() [14/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _Self __s,
size_type  __pos,
size_type  __n 
)
inline

Definition at line 551 of file _string.h.

552 {
553 if (__pos > __s.size())
554 this->_M_throw_out_of_range();
555 return _M_assign(__s._M_Start() + __pos,
556 __s._M_Start() + __pos + (min) (__n, __s.size() - __pos));
557 }

◆ assign() [15/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _Self __s,
size_type  __pos,
size_type  __n 
)
inline

Definition at line 253 of file _string_workaround.h.

254 {
255 _Base::assign(__s, __pos, __n);
256 return *this;
257 }

◆ assign() [16/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const _Self __s,
size_type  __pos,
size_type  __n 
)
inline

Definition at line 330 of file _string.h.

330 {
331 if (__pos < __s.size()) {
333 }
334 _M_non_dbg_impl.assign(__s._M_non_dbg_impl, __pos, __n);
335 return *this;
336 }

◆ assign() [17/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( const_iterator  __f,
const_iterator  __l 
)
inline

Definition at line 380 of file _string.h.

380 {
381 _STLP_DEBUG_CHECK(_STLP_PRIV __check_range(__f, __l))
383 _M_non_dbg_impl.assign(__f._M_iterator, __l._M_iterator);
384 return *this;
385 }

◆ assign() [18/20]

template<class _CharT , class _Traits , class _Alloc >
basic_string< _CharT, _Traits, _Alloc > & basic_string< _CharT, _Traits, _Alloc >::assign ( size_type  __n,
_CharT  __c 
)

Definition at line 222 of file _string.c.

222 {
223 if (__n <= size()) {
224 _Traits::assign(this->_M_Start(), __n, __c);
225 erase(begin() + __n, end());
226 }
227 else {
228 if (__n < capacity()) {
229 _Traits::assign(this->_M_Start(), size(), __c);
230 append(__n - size(), __c);
231 }
232 else {
233 _Self __str(__n, __c);
234 this->swap(__str);
235 }
236 }
237 return *this;
238}
#define swap(a, b)
Definition: qsort.c:63

◆ assign() [19/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( size_type  __n,
_CharT  __c 
)
inline

Definition at line 271 of file _string_workaround.h.

271 {
272 _Base::assign(__n, __c);
273 return *this;
274 }

◆ assign() [20/20]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::assign ( size_type  __n,
_CharT  __c 
)
inline

Definition at line 354 of file _string.h.

354 {
356 _M_non_dbg_impl.assign(__n, __c);
357 return *this;
358 }

◆ at() [1/4]

template<class _CharT , class _Traits , class _Alloc >
reference basic_string< _CharT, _Traits, _Alloc >::at ( size_type  __n)
inline

Definition at line 443 of file _string.h.

443 {
444 if (__n >= size())
445 this->_M_throw_out_of_range();
446 return *(this->_M_Start() + __n);
447 }

◆ at() [2/4]

template<class _CharT , class _Traits , class _Alloc >
reference basic_string< _CharT, _Traits, _Alloc >::at ( size_type  __n)
inline

Definition at line 231 of file _string.h.

231{ return _M_non_dbg_impl.at(__n); }

◆ at() [3/4]

template<class _CharT , class _Traits , class _Alloc >
const_reference basic_string< _CharT, _Traits, _Alloc >::at ( size_type  __n) const
inline

Definition at line 437 of file _string.h.

437 {
438 if (__n >= size())
439 this->_M_throw_out_of_range();
440 return *(this->_M_Start() + __n);
441 }

Referenced by __bstr_sum< _CharT, _Traits, _Alloc, _Left, _Right, _StorageDirection >::at().

◆ at() [4/4]

template<class _CharT , class _Traits , class _Alloc >
const_reference basic_string< _CharT, _Traits, _Alloc >::at ( size_type  __n) const
inline

Definition at line 230 of file _string.h.

230{ return _M_non_dbg_impl.at(__n); }

◆ begin() [1/4]

◆ begin() [2/4]

template<class _CharT , class _Traits , class _Alloc >
iterator basic_string< _CharT, _Traits, _Alloc >::begin ( )
inline

Definition at line 183 of file _string.h.

183{ return iterator(&_M_iter_list, _M_non_dbg_impl.begin()); }
value_type * iterator
Definition: _string.h:143

◆ begin() [3/4]

template<class _CharT , class _Traits , class _Alloc >
const_iterator basic_string< _CharT, _Traits, _Alloc >::begin ( ) const
inline

Definition at line 387 of file _string.h.

387{ return this->_M_Start(); }

◆ begin() [4/4]

template<class _CharT , class _Traits , class _Alloc >
const_iterator basic_string< _CharT, _Traits, _Alloc >::begin ( ) const
inline

Definition at line 184 of file _string.h.

184{ return const_iterator(&_M_iter_list, _M_non_dbg_impl.begin()); }
const value_type * const_iterator
Definition: _string.h:142

◆ c_str() [1/2]

◆ c_str() [2/2]

template<class _CharT , class _Traits , class _Alloc >
const _CharT * basic_string< _CharT, _Traits, _Alloc >::c_str ( ) const
inline

Definition at line 686 of file _string.h.

686{ return _M_non_dbg_impl.c_str(); }

◆ capacity() [1/2]

◆ capacity() [2/2]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::capacity ( ) const
inline

Definition at line 206 of file _string.h.

206{ return _M_non_dbg_impl.capacity(); }

◆ clear() [1/2]

template<class _CharT , class _Traits , class _Alloc >
void basic_string< _CharT, _Traits, _Alloc >::clear ( )
inline

Definition at line 421 of file _string.h.

421 {
422 if (!empty()) {
423 _Traits::assign(*(this->_M_Start()), _M_null());
424 this->_M_finish = this->_M_Start();
425 }
426 }
static _CharT _STLP_CALL _M_null()
Definition: _string.h:362
bool empty() const
Definition: _string.h:428

Referenced by getline(), operator>>(), and StringOut().

◆ clear() [2/2]

template<class _CharT , class _Traits , class _Alloc >
void basic_string< _CharT, _Traits, _Alloc >::clear ( )
inline

Definition at line 213 of file _string.h.

213 {
215 _M_non_dbg_impl.clear();
216 }

◆ compare() [1/12]

template<class _CharT , class _Traits , class _Alloc >
int basic_string< _CharT, _Traits, _Alloc >::compare ( const _CharT *  __s) const
inline

Definition at line 1047 of file _string.h.

1047 {
1049 return _M_compare(this->_M_Start(), this->_M_Finish(), __s, __s + _Traits::length(__s));
1050 }
static int _STLP_CALL _M_compare(const _CharT *__f1, const _CharT *__l1, const _CharT *__f2, const _CharT *__l2)
Definition: _string.h:1071

◆ compare() [2/12]

template<class _CharT , class _Traits , class _Alloc >
int basic_string< _CharT, _Traits, _Alloc >::compare ( const _CharT *  __s) const
inline

Definition at line 658 of file _string.h.

658 {
660 return _M_non_dbg_impl.compare(__s);
661 }

◆ compare() [3/12]

template<class _CharT , class _Traits , class _Alloc >
int basic_string< _CharT, _Traits, _Alloc >::compare ( const _Self __s) const
inline

Definition at line 1026 of file _string.h.

1027 { return _M_compare(this->_M_Start(), this->_M_Finish(), __s._M_Start(), __s._M_Finish()); }

Referenced by __bstr_sum< _CharT, _Traits, _Alloc, _Left, _Right, _StorageDirection >::compare().

◆ compare() [4/12]

template<class _CharT , class _Traits , class _Alloc >
int basic_string< _CharT, _Traits, _Alloc >::compare ( const _Self __s) const
inline

Definition at line 651 of file _string.h.

652 { return _M_non_dbg_impl.compare(__s._M_non_dbg_impl); }

◆ compare() [5/12]

template<class _CharT , class _Traits , class _Alloc >
int basic_string< _CharT, _Traits, _Alloc >::compare ( size_type  __pos,
size_type  __n,
const _CharT *  __s 
) const
inline

Definition at line 662 of file _string.h.

662 {
664 return _M_non_dbg_impl.compare(__pos, __n, __s);
665 }

◆ compare() [6/12]

template<class _CharT , class _Traits , class _Alloc >
int basic_string< _CharT, _Traits, _Alloc >::compare ( size_type  __pos,
size_type  __n,
const _Self __s 
) const
inline

Definition at line 653 of file _string.h.

654 { return _M_non_dbg_impl.compare(__pos, __n, __s._M_non_dbg_impl); }

◆ compare() [7/12]

template<class _CharT , class _Traits , class _Alloc >
int basic_string< _CharT, _Traits, _Alloc >::compare ( size_type  __pos1,
size_type  __n1,
const _CharT *  __s 
) const
inline

Definition at line 1052 of file _string.h.

1052 {
1054 if (__pos1 > size())
1055 this->_M_throw_out_of_range();
1056 return _M_compare(this->_M_Start() + __pos1,
1057 this->_M_Start() + __pos1 + (min) (__n1, size() - __pos1),
1058 __s, __s + _Traits::length(__s));
1059 }

◆ compare() [8/12]

template<class _CharT , class _Traits , class _Alloc >
int basic_string< _CharT, _Traits, _Alloc >::compare ( size_type  __pos1,
size_type  __n1,
const _CharT *  __s,
size_type  __n2 
) const
inline

Definition at line 1061 of file _string.h.

1061 {
1063 if (__pos1 > size())
1064 this->_M_throw_out_of_range();
1065 return _M_compare(this->_M_Start() + __pos1,
1066 this->_M_Start() + __pos1 + (min) (__n1, size() - __pos1),
1067 __s, __s + __n2);
1068 }

◆ compare() [9/12]

template<class _CharT , class _Traits , class _Alloc >
int basic_string< _CharT, _Traits, _Alloc >::compare ( size_type  __pos1,
size_type  __n1,
const _CharT *  __s,
size_type  __n2 
) const
inline

Definition at line 666 of file _string.h.

667 {
669 return _M_non_dbg_impl.compare(__pos1, __n1, __s, __n2);
670 }

◆ compare() [10/12]

template<class _CharT , class _Traits , class _Alloc >
int basic_string< _CharT, _Traits, _Alloc >::compare ( size_type  __pos1,
size_type  __n1,
const _Self __s 
) const
inline

Definition at line 1029 of file _string.h.

1029 {
1030 if (__pos1 > size())
1031 this->_M_throw_out_of_range();
1032 return _M_compare(this->_M_Start() + __pos1,
1033 this->_M_Start() + __pos1 + (min) (__n1, size() - __pos1),
1034 __s._M_Start(), __s._M_Finish());
1035 }

◆ compare() [11/12]

template<class _CharT , class _Traits , class _Alloc >
int basic_string< _CharT, _Traits, _Alloc >::compare ( size_type  __pos1,
size_type  __n1,
const _Self __s,
size_type  __pos2,
size_type  __n2 
) const
inline

Definition at line 1037 of file _string.h.

1038 {
1039 if (__pos1 > size() || __pos2 > __s.size())
1040 this->_M_throw_out_of_range();
1041 return _M_compare(this->_M_Start() + __pos1,
1042 this->_M_Start() + __pos1 + (min) (__n1, size() - __pos1),
1043 __s._M_Start() + __pos2,
1044 __s._M_Start() + __pos2 + (min) (__n2, __s.size() - __pos2));
1045 }

◆ compare() [12/12]

template<class _CharT , class _Traits , class _Alloc >
int basic_string< _CharT, _Traits, _Alloc >::compare ( size_type  __pos1,
size_type  __n1,
const _Self __s,
size_type  __pos2,
size_type  __n2 
) const
inline

Definition at line 655 of file _string.h.

657 { return _M_non_dbg_impl.compare(__pos1, __n1, __s._M_non_dbg_impl, __pos2, __n2); }

◆ copy() [1/2]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::copy ( _CharT *  __s,
size_type  __n,
size_type  __pos = 0 
) const
inline

Definition at line 933 of file _string.h.

933 {
935 if (__pos > size())
936 this->_M_throw_out_of_range();
937 const size_type __len = (min) (__n, size() - __pos);
938 _Traits::copy(__s, this->_M_Start() + __pos, __len);
939 return __len;
940 }

Referenced by __bstr_sum< _CharT, _Traits, _Alloc, _Left, _Right, _StorageDirection >::copy().

◆ copy() [2/2]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::copy ( _CharT *  __s,
size_type  __n,
size_type  __pos = 0 
) const
inline

Definition at line 689 of file _string.h.

690 { return _M_non_dbg_impl.copy(__s, __n, __pos); }

◆ data() [1/2]

◆ data() [2/2]

template<class _CharT , class _Traits , class _Alloc >
const _CharT * basic_string< _CharT, _Traits, _Alloc >::data ( ) const
inline

Definition at line 687 of file _string.h.

687{ return _M_non_dbg_impl.data(); }

◆ empty() [1/2]

template<class _CharT , class _Traits , class _Alloc >
bool basic_string< _CharT, _Traits, _Alloc >::empty ( ) const
inline

Definition at line 428 of file _string.h.

428{ return this->_M_Start() == this->_M_Finish(); }

Referenced by __get_integer(), __get_monetary_value(), __money_do_get(), __money_do_put(), __put_float(), __read_float(), basic_string< _CharT, _Traits, _Alloc >::clear(), and operator>>().

◆ empty() [2/2]

template<class _CharT , class _Traits , class _Alloc >
bool basic_string< _CharT, _Traits, _Alloc >::empty ( ) const
inline

Definition at line 218 of file _string.h.

218{ return _M_non_dbg_impl.empty(); }

◆ end() [1/4]

◆ end() [2/4]

template<class _CharT , class _Traits , class _Alloc >
iterator basic_string< _CharT, _Traits, _Alloc >::end ( )
inline

Definition at line 185 of file _string.h.

185{ return iterator(&_M_iter_list, _M_non_dbg_impl.end()); }

◆ end() [3/4]

template<class _CharT , class _Traits , class _Alloc >
const_iterator basic_string< _CharT, _Traits, _Alloc >::end ( ) const
inline

Definition at line 388 of file _string.h.

388{ return this->_M_Finish(); }

◆ end() [4/4]

template<class _CharT , class _Traits , class _Alloc >
const_iterator basic_string< _CharT, _Traits, _Alloc >::end ( ) const
inline

Definition at line 186 of file _string.h.

◆ erase() [1/9]

template<class _CharT , class _Traits , class _Alloc >
iterator basic_string< _CharT, _Traits, _Alloc >::erase ( iterator  __f,
iterator  __l 
)
inline

Definition at line 504 of file _string.h.

504 {
505 _STLP_DEBUG_CHECK(_STLP_PRIV __check_range(__f, __l, begin(), end()))
507 return iterator(&_M_iter_list, _M_non_dbg_impl.erase(__f._M_iterator, __l._M_iterator));
508 }
return
Definition: dirsup.c:529
void _Invalidate_iterators(const iterator &__f, const iterator &__l)
Definition: _string.h:82
GLuint GLuint end
Definition: gl.h:1545

◆ erase() [2/9]

template<class _CharT , class _Traits , class _Alloc >
iterator basic_string< _CharT, _Traits, _Alloc >::erase ( iterator  __first,
iterator  __last 
)
inline

Definition at line 802 of file _string.h.

802 {
803 if (__first != __last) {
804 // The move includes the terminating _CharT().
805 traits_type::move(__first, __last, (this->_M_Finish() - __last) + 1);
806 this->_M_finish = this->_M_Finish() - (__last - __first);
807 }
808 return __first;
809 }

◆ erase() [3/9]

template<class _CharT , class _Traits , class _Alloc >
iterator basic_string< _CharT, _Traits, _Alloc >::erase ( iterator  __first,
iterator  __last 
)
inline

Definition at line 465 of file _string_workaround.h.

465 {
467 return _Base::erase(__first, __last);
468 }

◆ erase() [4/9]

template<class _CharT , class _Traits , class _Alloc >
iterator basic_string< _CharT, _Traits, _Alloc >::erase ( iterator  __pos)
inline

Definition at line 795 of file _string.h.

795 {
796 // The move includes the terminating _CharT().
797 _Traits::move(__pos, __pos + 1, this->_M_Finish() - __pos);
798 --this->_M_finish;
799 return __pos;
800 }

◆ erase() [5/9]

template<class _CharT , class _Traits , class _Alloc >
iterator basic_string< _CharT, _Traits, _Alloc >::erase ( iterator  __pos)
inline

Definition at line 460 of file _string_workaround.h.

460 {
462 return _Base::erase(__pos);
463 }

◆ erase() [6/9]

template<class _CharT , class _Traits , class _Alloc >
iterator basic_string< _CharT, _Traits, _Alloc >::erase ( iterator  __pos)
inline

Definition at line 498 of file _string.h.

498 {
500 _STLP_DEBUG_CHECK(_STLP_PRIV __check_if_owner(&_M_iter_list,__pos))
501 _Invalidate_iterators(__pos, end());
502 return iterator(&_M_iter_list, _M_non_dbg_impl.erase(__pos._M_iterator));
503 }
bool _Dereferenceable(const _Iterator &__it)
Definition: _iterator.h:93

◆ erase() [7/9]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::erase ( size_type  __pos = 0,
size_type  __n = npos 
)
inline

Definition at line 788 of file _string.h.

788 {
789 if (__pos > size())
790 this->_M_throw_out_of_range();
791 erase(begin() + __pos, begin() + __pos + (min) (__n, size() - __pos));
792 return *this;
793 }

Referenced by __bstr_sum< _CharT, _Traits, _Alloc, _Left, _Right, _StorageDirection >::erase(), basic_string< _CharT, _Traits, _Alloc >::erase(), TMapLoader::Load(), and basic_string< _CharT, _Traits, _Alloc >::resize().

◆ erase() [8/9]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::erase ( size_type  __pos = 0,
size_type  __n = npos 
)
inline

Definition at line 455 of file _string_workaround.h.

455 {
456 _Base::erase(__pos, __n);
457 return *this;
458 }

◆ erase() [9/9]

template<class _CharT , class _Traits , class _Alloc >
_Self & basic_string< _CharT, _Traits, _Alloc >::erase ( size_type  __pos = 0,
size_type  __n = npos 
)
inline

Definition at line 491 of file _string.h.

491 {
492 if (__pos < size()) {
493 _Invalidate_iterators(begin() + __pos, end());
494 }
495 _M_non_dbg_impl.erase(__pos, __n);
496 return *this;
497 }

◆ find() [1/10]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find ( _CharT  __c) const
inline

Definition at line 962 of file _string.h.

962{ return find(__c, 0); }
static TAGID TAGID find
Definition: db.cpp:155

Referenced by basic_string< _CharT, _Traits, _Alloc >::find().

◆ find() [2/10]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find ( _CharT  __c) const
inline

Definition at line 706 of file _string.h.

706{ return find(__c, 0); }

Referenced by basic_string< _CharT, _Traits, _Alloc >::find().

◆ find() [3/10]

template<class _CharT , class _Traits , class _Alloc >
__size_type__ basic_string< _CharT, _Traits, _Alloc >::find ( _CharT  __c,
size_type  __pos 
) const

Definition at line 438 of file _string.c.

439{
440 if (__pos >= size()) { /*__pos + 1 > size()*/
441 return npos;
442 }
443
444 const_pointer __result =
445 _STLP_STD::find_if(this->_M_Start() + __pos, this->_M_Finish(),
447 return __result != this->_M_Finish() ? __result - this->_M_Start() : npos;
448}
static const size_t npos
Definition: _string_npos.h:26
const value_type * const_pointer
Definition: _string.h:135

◆ find() [4/10]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find ( _CharT  __c,
size_type  __pos 
) const
inline

Definition at line 707 of file _string.h.

708 { return _M_non_dbg_impl.find(__c, __pos); }

◆ find() [5/10]

template<class _CharT , class _Traits , class _Alloc >
__size_type__ basic_string< _CharT, _Traits, _Alloc >::find ( const _CharT *  __s,
size_type  __pos,
size_type  __n 
) const

Definition at line 420 of file _string.c.

422{
423 const size_t __len = size();
424 if (__pos >= __len || __pos + __n > __len) {
425 if ( __n == 0 && __pos <= __len ) { // marginal case
426 return __pos;
427 }
428 return npos;
429 }
430
431 const_pointer __result =
432 _STLP_STD::search(this->_M_Start() + __pos, this->_M_Finish(),
433 __s, __s + __n, _STLP_PRIV _Eq_traits<_Traits>());
434 return __result != this->_M_Finish() ? __result - this->_M_Start() : npos;
435}

◆ find() [6/10]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find ( const _CharT *  __s,
size_type  __pos,
size_type  __n 
) const
inline

Definition at line 700 of file _string.h.

700 {
702 _STLP_VERBOSE_ASSERT((__s != 0), _StlMsg_INVALID_ARGUMENT)
703 return _M_non_dbg_impl.find(__s, __pos, __n);
704 }

◆ find() [7/10]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find ( const _CharT *  __s,
size_type  __pos = 0 
) const
inline

Definition at line 956 of file _string.h.

957 { _STLP_FIX_LITERAL_BUG(__s) return find(__s, __pos, _Traits::length(__s)); }

◆ find() [8/10]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find ( const _CharT *  __s,
size_type  __pos = 0 
) const
inline

Definition at line 695 of file _string.h.

695 {
697 _STLP_VERBOSE_ASSERT((__s != 0), _StlMsg_INVALID_ARGUMENT)
698 return _M_non_dbg_impl.find(__s, __pos);
699 }

◆ find() [9/10]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find ( const _Self __s,
size_type  __pos = 0 
) const
inline

◆ find() [10/10]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find ( const _Self __s,
size_type  __pos = 0 
) const
inline

Definition at line 693 of file _string.h.

694 { return _M_non_dbg_impl.find(__s._M_non_dbg_impl, __pos); }

◆ find_first_not_of() [1/8]

template<class _CharT , class _Traits , class _Alloc >
__size_type__ basic_string< _CharT, _Traits, _Alloc >::find_first_not_of ( _CharT  __c,
size_type  __pos = 0 
) const

Definition at line 528 of file _string.c.

528 {
529 if (1 > size())
530 return npos;
531 else {
532 const_pointer __result = _STLP_STD::find_if(this->_M_Start() + __pos, this->_M_Finish(),
534 return __result != this->_M_finish ? __result - this->_M_Start() : npos;
535 }
536}

◆ find_first_not_of() [2/8]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find_first_not_of ( _CharT  __c,
size_type  __pos = 0 
) const
inline

Definition at line 771 of file _string.h.

772 { return _M_non_dbg_impl.find_first_not_of(__c, __pos); }

◆ find_first_not_of() [3/8]

template<class _CharT , class _Traits , class _Alloc >
__size_type__ basic_string< _CharT, _Traits, _Alloc >::find_first_not_of ( const _CharT *  __s,
size_type  __pos,
size_type  __n 
) const

Definition at line 513 of file _string.c.

514 {
515 typedef typename _Traits::char_type _CharType;
516 if (__pos >= size()) /*__pos + 1 >= size()*/
517 return npos;
518 else {
519 const_pointer __result = _STLP_PRIV __str_find_first_not_of(this->_M_Start() + __pos, this->_M_Finish(),
520 __STATIC_CAST(const _CharType*, __s),
521 __STATIC_CAST(const _CharType*, __s) + __n,
522 __STATIC_CAST(_Traits*, 0));
523 return __result != this->_M_finish ? __result - this->_M_Start() : npos;
524 }
525}
_InputIter __str_find_first_not_of(_InputIter __first1, _InputIter __last1, const _CharT *__first2, const _CharT *__last2, _Traits *__traits)
Definition: _string.c:134

◆ find_first_not_of() [4/8]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find_first_not_of ( const _CharT *  __s,
size_type  __pos,
size_type  __n 
) const
inline

Definition at line 766 of file _string.h.

766 {
768 _STLP_VERBOSE_ASSERT((__s != 0), _StlMsg_INVALID_ARGUMENT)
769 return _M_non_dbg_impl.find_first_not_of(__s, __pos, __n);
770 }

◆ find_first_not_of() [5/8]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find_first_not_of ( const _CharT *  __s,
size_type  __pos = 0 
) const
inline

Definition at line 1003 of file _string.h.

1004 { _STLP_FIX_LITERAL_BUG(__s) return find_first_not_of(__s, __pos, _Traits::length(__s)); }
size_type find_first_not_of(const _Self &__s, size_type __pos=0) const
Definition: _string.h:1000

◆ find_first_not_of() [6/8]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find_first_not_of ( const _CharT *  __s,
size_type  __pos = 0 
) const
inline

Definition at line 761 of file _string.h.

761 {
763 _STLP_VERBOSE_ASSERT((__s != 0), _StlMsg_INVALID_ARGUMENT)
764 return _M_non_dbg_impl.find_first_not_of(__s, __pos);
765 }

◆ find_first_not_of() [7/8]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find_first_not_of ( const _Self __s,
size_type  __pos = 0 
) const
inline

◆ find_first_not_of() [8/8]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find_first_not_of ( const _Self __s,
size_type  __pos = 0 
) const
inline

Definition at line 759 of file _string.h.

760 { return _M_non_dbg_impl.find_first_not_of(__s._M_non_dbg_impl, __pos); }

◆ find_first_of() [1/8]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find_first_of ( _CharT  __c,
size_type  __pos = 0 
) const
inline

Definition at line 984 of file _string.h.

985 { return find(__c, __pos); }

◆ find_first_of() [2/8]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find_first_of ( _CharT  __c,
size_type  __pos = 0 
) const
inline

Definition at line 739 of file _string.h.

740 { return _M_non_dbg_impl.find_first_of(__c, __pos); }

◆ find_first_of() [3/8]

template<class _CharT , class _Traits , class _Alloc >
__size_type__ basic_string< _CharT, _Traits, _Alloc >::find_first_of ( const _CharT *  __s,
size_type  __pos,
size_type  __n 
) const

Definition at line 482 of file _string.c.

483 {
484 if (__pos >= size()) /*__pos + 1 > size()*/
485 return npos;
486 else {
487 const_iterator __result = _STLP_PRIV __str_find_first_of(begin() + __pos, end(),
488 __s, __s + __n,
489 __STATIC_CAST(_Traits*, 0));
490 return __result != end() ? __result - begin() : npos;
491 }
492}
_InputIter __str_find_first_of(_InputIter __first1, _InputIter __last1, const _CharT *__first2, const _CharT *__last2, _Traits *__traits)
Definition: _string.c:86

◆ find_first_of() [4/8]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find_first_of ( const _CharT *  __s,
size_type  __pos,
size_type  __n 
) const
inline

Definition at line 734 of file _string.h.

734 {
736 _STLP_VERBOSE_ASSERT((__s != 0), _StlMsg_INVALID_ARGUMENT)
737 return _M_non_dbg_impl.find_first_of(__s, __pos, __n);
738 }

◆ find_first_of() [5/8]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find_first_of ( const _CharT *  __s,
size_type  __pos = 0 
) const
inline

Definition at line 979 of file _string.h.

980 { _STLP_FIX_LITERAL_BUG(__s) return find_first_of(__s, __pos, _Traits::length(__s)); }
size_type find_first_of(const _Self &__s, size_type __pos=0) const
Definition: _string.h:976

◆ find_first_of() [6/8]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find_first_of ( const _CharT *  __s,
size_type  __pos = 0 
) const
inline

Definition at line 729 of file _string.h.

729 {
731 _STLP_VERBOSE_ASSERT((__s != 0), _StlMsg_INVALID_ARGUMENT)
732 return _M_non_dbg_impl.find_first_of(__s, __pos);
733 }

◆ find_first_of() [7/8]

template<class _CharT , class _Traits , class _Alloc >
size_type basic_string< _CharT, _Traits, _Alloc >::find_first_of ( const _Self __s,
size_type  __pos = 0 
) const
inline