Link to home
Start Free TrialLog in
Avatar of Wanting2LearnMan
Wanting2LearnManFlag for United Kingdom of Great Britain and Northern Ireland

asked on

overloaded '=' operator in c++ class

I am looking at some existing C++ code and I see several c++ classes that are derived from abstract base classes.

I see that all these classed have an overleaded '=' operator that is public.
e.g.
SomeClass& operator = (const SomeClass& rhs);

Open in new window


Can someone explain why this is needed??
And why is it public??

Thanks
ASKER CERTIFIED SOLUTION
Avatar of kaufmed
kaufmed
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial