This is a discussion on Can someone explain this error? within the Windows Programming forums, part of the Platform Specific Boards category; http://home.houston.rr.com/bjohnston2/cpp.jpg...
hmmm...... i have been getting hits on my firewall from home.houston.rr.com
C++ Is Powerful
I use C++
There fore I am Powerful
sorry man, it's a very large image, try zipping it to make it easier to download
well as the compiler error indicates, your class has no copy constructor, which could look like:
Code:yourClass (const yourclass &c_roOther);
Your overload looks a little odd too. Typically an assignment operator overload looks like this...
Xyz operator = (Xyz instance)
... although you should always be careful about returning classes from a function without specifying a copy constructor.
Wave upon wave of demented avengers march cheerfully out of obscurity unto the dream.
Your assignment operator looks fine as long as it returns *this
and copies your member variables.
You need a copy constructor like this though:
CLocation( const CLocation& other )
*this = other;