diff options
author | Chris Phan <cphan@us.ibm.com> | 2012-08-13 16:09:03 -0500 |
---|---|---|
committer | A. Patrick Williams III <iawillia@us.ibm.com> | 2012-08-13 16:47:58 -0500 |
commit | 62dc0e454971e96aef85398cf5e81cabcf8c0646 (patch) | |
tree | eca7ffd7800300e8471de646e9a0a68ffa48c571 | |
parent | 5023b07888935148844de78239f07d6fa371d9e8 (diff) | |
download | talos-hostboot-62dc0e454971e96aef85398cf5e81cabcf8c0646.tar.gz talos-hostboot-62dc0e454971e96aef85398cf5e81cabcf8c0646.zip |
Fix assert statements in erase()
Change-Id: I148b90dccbe488b3f5553f0907fdf5ae3816fcc8
Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1522
Tested-by: Jenkins Server
Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com>
Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
-rw-r--r-- | src/include/vector | 51 |
1 files changed, 26 insertions, 25 deletions
diff --git a/src/include/vector b/src/include/vector index 4827116dc..e34991fd5 100644 --- a/src/include/vector +++ b/src/include/vector @@ -1,25 +1,26 @@ -// IBM_PROLOG_BEGIN_TAG -// This is an automatically generated prolog. -// -// $Source: src/include/vector $ -// -// IBM CONFIDENTIAL -// -// COPYRIGHT International Business Machines Corp. 2011 -// -// p1 -// -// Object Code Only (OCO) source materials -// Licensed Internal Code Source Materials -// IBM HostBoot Licensed Internal Code -// -// The source code for this program is not published or other- -// wise divested of its trade secrets, irrespective of what has -// been deposited with the U.S. Copyright Office. -// -// Origin: 30 -// -// IBM_PROLOG_END +/* IBM_PROLOG_BEGIN_TAG + * This is an automatically generated prolog. + * + * $Source: src/include/vector $ + * + * IBM CONFIDENTIAL + * + * COPYRIGHT International Business Machines Corp. 2011-2012 + * + * p1 + * + * Object Code Only (OCO) source materials + * Licensed Internal Code Source Materials + * IBM HostBoot Licensed Internal Code + * + * The source code for this program is not published or other- + * wise divested of its trade secrets, irrespective of what has + * been deposited with the U.S. Copyright Office. + * + * Origin: 30 + * + * IBM_PROLOG_END_TAG + */ #ifndef stl_vector #define stl_vector @@ -524,7 +525,7 @@ namespace std * @return new location of the element that followed the last * element erased, or end() if the operation erased * the last element in the sequence. - * @pre begin() <= first,last <= end(), first < last. + * @pre begin() <= first,last <= end(), first <= last. * @post All previously obtained iterators are invalid. * @note The element pointed to be last is not deleted. */ @@ -532,8 +533,8 @@ namespace std { assert(last >= first); assert(first >= iv_start); - assert(first < iv_finish); - assert(last > iv_start); + assert(first <= iv_finish); + assert(last >= iv_start); assert(last <= iv_finish); last = copy(last,iv_finish,first); |