Any idea why I should be getting this error?
I create 2 objects of the same class and then try to set one equal to the other. The class does have a overloaded copy operator?
TString temp1;
TString temp2;
temp1 = temp2;
error: no matching function for call to ‘TString::TString(TString)’
note: candidates are: TString::TString(TString&)
note: TString::TString(const char*)
const TString &TString:
perator = (const TString &Src)
{
return Copy(Src);
}
arm-angstrom-linux-gnueabi-g++ (GCC) 4.2.4
Copyright (C) 2007 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.