FYI, this is just one of several basic_string operations (find and
compare) where we needlessly throw. We need to review them and fix
them all. STDCXX-466 should have been created for all of them.

Martin

[EMAIL PROTECTED] wrote:
Author: faridz
Date: Thu Jul 19 12:11:06 2007
New Revision: 557742

URL: http://svn.apache.org/viewvc?view=rev&rev=557742
Log:
2007-07-19 Farid Zaripov <[EMAIL PROTECTED]>

        STDCXX-466
        * string.cc (rfind): Don't throw std::length_error() if n > max_size().

Modified:
    incubator/stdcxx/trunk/include/string.cc

Modified: incubator/stdcxx/trunk/include/string.cc
URL: 
http://svn.apache.org/viewvc/incubator/stdcxx/trunk/include/string.cc?view=diff&rev=557742&r1=557741&r2=557742
==============================================================================
--- incubator/stdcxx/trunk/include/string.cc (original)
+++ incubator/stdcxx/trunk/include/string.cc Thu Jul 19 12:11:06 2007
@@ -753,12 +753,6 @@
 {
     _RWSTD_ASSERT(__s != 0);
- _RWSTD_REQUIRES (__n <= max_size (), - (_RWSTD_ERROR_LENGTH_ERROR, - _RWSTD_FUNC ("basic_string::rfind(const_pointer, "
-                                   "size_type, size_type) const"),
-                      __n, max_size ()));
-
     if (size() < __n)
       return npos;



Reply via email to