This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/13650] string::compare should not (always) use traits_type::length()
- From: "jlabusch at eservglobal dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 12 Jan 2004 04:39:07 -0000
- Subject: [Bug libstdc++/13650] string::compare should not (always) use traits_type::length()
- References: <20040112041332.13650.jlabusch@eservglobal.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From jlabusch at eservglobal dot com 2004-01-12 04:39 -------
This should also mean that we can unify the two similar
comparisons into one which uses a default 4th argument
(as appears in the standard) -
These two
compare(size_type __pos, size_type __n1, const _CharT* __s,
size_type __n2) const
compare(size_type __pos, size_type __n1, const _CharT* __s) const
become
compare(size_type __pos, size_type __n1, const _CharT* __s,
size_type __n2 = npos) const
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13650