Category
Operators, C++-Specific Keywords
Syntax
operator <operator symbol>( <parameters> ) { <statements>; }
Description
Use the operator keyword to define a new (overloaded) action of the given operator. When the operator is overloaded as a member function, only one argument is allowed, as *this is implicitly the first argument.
When you overload an operator as a friend, you can specify two arguments.
Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
|
What do you think about this topic? Send feedback!
|