can anyone help me with this one? i am getting a syntax error that reads like this:
lab2aa.C: In member function `bool IntArray::operator==(const IntArray&)
const':
lab2aa.C:80: syntax error before `}' token
my size() method works (tested it before i put in these operator things) ...
and self is *this in an include file ... TRUE and FALSE are true and false respectively in the include file, too.
what am i missing here?
bool IntArray::
operator == ( const IntArray &rhs ) const
{
if ( size() != rhs.size() ) {
return ( FALSE );
}
int i = 0;
while ( i < size() ){
if ( self[i] != rhs[i] ){
return ( FALSE );
}
else i++
}
return ( TRUE );
}
thanks!!
charity