Scope Resolution Operator

Started by beingchinmay, 09-07-2016, 05:24:14

Previous topic - Next topic

beingchinmayTopic starter

The scope resolution operator, the highest-precedence operator in the language, comes in two forms. The unary form is used to uncover or to access a name that has external scope and has been hidden by local or class scope. The binary form places the class or namespace identifier before the operator and the identifier after the operator.


Quote::i // unary - refers to external scope
point::x // binary - refers to class scope
std::cout // binary - refers to namespace scope