Nested function calls order of evaluation

后端 未结 4 1085
孤街浪徒
孤街浪徒 2020-12-17 00:52

It\'s well-known that the order of evaluation of a function\'s arguments in unspecified and can differ between different compilers.

What doesn\'t seem so clear is wh

4条回答
  •  感动是毒
    2020-12-17 01:20

    The evaluation order is unspecified - see section 5.2.2/8 of the Standard:

    The order of evaluation of arguments is unspecified. All side effects of argument expression evaluations take effect before the function is entered.

提交回复
热议问题