Reference: http://www.weixueyuan.net/view/6380.html
Summarize:
Overloaded operators cannot change the precedence and syntax characteristics of an operator.
Overloaded operators cannot change the precedence and syntax characteristics of an operator. For example, the addition operator overload function in the plural class of the previous section, the precedence of the addition is still unchanged after overloading, and is still a two-dollar operator after overloading.
Example 1:
int Main () { complex c1,c2,c3,c4; // ...... C4 = c1 + C2 * c3; return 0 ;}
Continue to follow the complex plural class in example 1 in the previous section, define four objects of the class in Example 1, and then arithmetic, C4 = c1 + C2 * C3; This statement is also equivalent to C4 = c1 + (C2 * C3), although the addition and subtraction multiplier four operators are overloaded in the plural class, they do not change the attributes of their two-tuple operators, and they do not change their precedence, so their precedence is lower than the multiplication operator for overloaded addition operators.
The usage of the overloaded operator is not changed, for example, the addition operator always appears between two operands, and after overloading, the addition operator must still be placed between the two operands. For example, the addition and multiplication operators in Example 1 still maintain their original usage after overloading.
5.2 Precedence of C + + overloaded operators