mirror of
git://gcc.gnu.org/git/gcc.git
synced 2024-12-21 10:40:07 +08:00
c68cd521fa
Nathan Myers <ncm@cantrip.org> * include/bits/basic_string.h (replace(__pos, __n1, __s, __n2)): Optimize by avoiding temporaries (i.e., call _M_replace_safe) when possible. (replace(__pos, __n, __str)): Call replace(__pos, __n1, __s, __n2). (replace(__pos, __n1, __s)): Call replace(__pos, __n1, __s , __n2). (replace(__i1, __i2, __str)): Call replace(__i1, __i2, __s, __n). (replace(__i1, __i2, __s)): Call replace(__i1, __i2, __s, __n). (replace(__i1, __i2, __s, __n)): Call replace(__pos1, __n1, __s, __n2). * include/bits/basic_string.tcc (replace(__pos1, __n1, __str, __pos2, __n2)): Call replace(__pos, __n1, __s, __n2). * testsuite/21_strings/replace.cc (test03): New testcases. * include/bits/basic_string.h (insert(__pos, __s, __n)): Adjust comparison wrt overflow. Co-Authored-By: Nathan Myers <ncm@cantrip.org> From-SVN: r48834 |
||
---|---|---|
.. | ||
append.cc | ||
assign.cc | ||
c_strings.cc | ||
capacity.cc | ||
char_traits_requirements.cc | ||
char_traits_typedefs.cc | ||
compare.cc | ||
ctor_copy_dtor.cc | ||
element_access.cc | ||
find.cc | ||
insert.cc | ||
inserters_extractors.cc | ||
invariants.cc | ||
nonmember.cc | ||
operations.cc | ||
replace.cc | ||
rfind.cc | ||
substr.cc |