(class basic_string): Correct iterator return values in insert member

functions.

From-SVN: r20950
This commit is contained in:
Ulrich Drepper 1998-07-06 10:35:56 +00:00
parent 60afa297a0
commit 64e1d44458

View File

@ -213,9 +213,13 @@ public:
basic_string& insert (size_type pos, size_type n, charT c)
{ return replace (pos, 0, n, c); }
iterator insert(iterator p, charT c)
{ insert (p - ibegin (), 1, c); selfish (); return p; }
{ size_type __o = p - ibegin ();
insert (p - ibegin (), 1, c); selfish ();
return ibegin () + __o; }
iterator insert(iterator p, size_type n, charT c)
{ insert (p - ibegin (), n, c); selfish (); return p; }
{ size_type __o = p - ibegin ();
insert (p - ibegin (), n, c); selfish ();
return ibegin () + __o; }
#ifdef __STL_MEMBER_TEMPLATES
template<class InputIterator>
void insert(iterator p, InputIterator first, InputIterator last)