Overloaded Functions or Methods
Operators can be defined either as functions or as member functions.
How to decide which option is preferable
- An ordinary function is normally not permitted access to the private portions of the class, whereas a member function is allowed such access.
- Implicit conversions will be performed for both right and left arguments if the operator is defined in functional form, but only for the right argument if the operator is defined as a member function.