the explanations i made at last post demonstrated what i wanted to say and didn't try to change the evaluation order you are talking about. |
Evaluation order, indeed. In the
there are many things to evaluate:
A: the value of 'a'
B: the value of 'b'
C: the value of 'c'
D: the value of '*'
E: the value of '/' |
Only the D and E have associativity, priority, precedence, order.
Only the order of D and E can be modified with parentheses.
Without parentheses:
* D and C must occur before E
* A and B must occur before D
There is no way to force order to the evaluation of A, B and C (unless you split the statement and use named temporaries). It is the undefined evaluation order of A, B and C that your original question and answers to it are about. Not the D and E.
Your original statement has 6 operators:
A: the value of 'i++'
B: the value of 'i++'
C: the value of '++i'
D: the value of '<<'
E: the value of '<<'
F: the value of '<<' |
The order D E F is defined. The only thing known about A B C is that they have to occur
latest just before the << that needs their return value.