|
The assaignment operator functıon may return a
const reference:
class Myclass {
public:
const
Myclass&operator==(const Myclass &);
//...
};
----- Original Message -----
Sent: Thursday, December 16, 2004 2:00
PM
Subject: (PT) C++ Question....
Hi All!! see this problem...
Suppose that
objects A, B, and C are instances of class MyClass (MyClass A, B, C;). How
should you design an assignment operator so that the "A=B=C;" statement
would be allowed by a compiler but "(A=B)=C;" would not be allowed by a
compiler?
BSR Nishi Sahu
__________________________________ Do
you Yahoo!? The all-new My Yahoo! - Get yours free! http://my.yahoo.com
To unsubscribe :
[EMAIL PROTECTED]
To unsubscribe : [EMAIL PROTECTED]
| Yahoo! Groups Sponsor |
ADVERTISEMENT
![click here]() |
|
![Web Bug from http://us.adserver.yahoo.com/l?M=294855.5468653.6549235.3001176/D=groups/S=:HM/A=2455397/rand=856872646]() |
Yahoo! Groups Links
|