An operator function
shall either
- be a member function or
- be a non-member function that
has at least one non-object parameter whose type is a class, a reference to a class, an
enumeration, or a reference to an enumeration.
It is not possible to change the precedence, grouping, or number of operands
of operators
. The meaning of
the operators
=, (unary)
&, and
, (comma),
predefined for each type, can be changed for specific class types by
defining operator functions that implement these operators
. Likewise, the meaning of the operators (unary)
& and
, (comma)
can be changed for specific enumeration types
. Operator functions are inherited in the same manner as other base class
functions
.