I'm using the CPoint class from MFC. There is no explicitly defined assignment operator or copy constructor (AFAIK). Yet, this works:
CPoint p1(1, 2), p2; p2 = p1; // p2 now is equal to p1
I'm assuming this is working automagically because of a compiler generated assignment operator. Correct?
If so, can I be confident that this isn't doing anything unexpected? In this case CPoint is so simple I think all is well, but in general this is something that worries me a bit. Is it better form to do:
p2.SetPoint(p1.x, p2.x);
-cr