Overloading of Operators
In C++, the concept of programmer-defined types (classes) is an extension of the concept of built-in numeric types. You can define variables of programmer-defined types using the same syntax as for simple numeric variables. Similar to built-in types, you can use object instances of programmer-defined types as array elements or as data members of even more-complex types. You can pass objects of programmer-defined types as parameters and return them from functions. You can set pointers and references to programmer-defined values using the same syntax as for built-in values. You can define pointers as constant pointers. You can define pointers and references as pointers and references to constant values using the same syntax ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access