diff options
Diffstat (limited to 'ace/Vector_T.cpp')
-rw-r--r-- | ace/Vector_T.cpp | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/ace/Vector_T.cpp b/ace/Vector_T.cpp index 9fc23b0d712..1101fe04139 100644 --- a/ace/Vector_T.cpp +++ b/ace/Vector_T.cpp @@ -56,19 +56,20 @@ void ACE_Vector<T, DEFAULT_SIZE>::dump (void) const } // Compare this vector with <s> for equality. -template <class T, size_t DEFAULT_SIZE> int +template <class T, size_t DEFAULT_SIZE> bool ACE_Vector<T, DEFAULT_SIZE>::operator== (const ACE_Vector<T, DEFAULT_SIZE> &s) const { if (this == &s) - return 1; + return true; else if (this->size () != s.size ()) - return 0; + return false; - for (size_t slot = 0; slot < s.size (); slot++) + const size_t len = s.size (); + for (size_t slot = 0; slot < len; ++slot) if ((*this)[slot] != s[slot]) - return 0; + return false; - return 1; + return true; } #if 0 |