Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: xref exp30-c

...

OperatorContext 
ifControlling expression
whileControlling expression
do ... whileControlling expression
forSecond operand
?:First operand
?:Second or third operands, where the ternary expression is used in any of these contexts
&& Either operand 
|| either operand 
,

Second operand, when the comma expression is used in any of these contexts



Performing assignment statements in other contexts do not violate this rule. However, they may violate other rules, such as EXP30-C. Do not depend on the order of evaluation for side effects.


Noncompliant Code Example

...