Home Segments Index Top Previous Next

107: Mainline

Unlike most languages, C++ allows you to define multiple functions with the same name, as long as each version has a different arrangement of parameter data types.

Whenever there is more than one definition for a function, the function name is said to be overloaded. The use of the word overloaded is unfortunate, because the word overloaded usually suggests abuse, as in the overloaded circuit blew a fuse. In C++, no suggestion of abuse is intended, however. Instead, the ability to handle function overloading is a distinctive feature of the language.