17.10 Overloading the Function Call
Operator
- Objects can be used as functions (function object)
- Must be defined as a member function
- Can carry (and change) its own data values
- Only operator where the number of arguments is not
fixed
- Can be passed where template functions can't
- Used extensively by various generic algorithms in the STL (chptr. 24)
prev
|top
|next