06-08-2015, 04:32 PM
misra-c Wrote:The reason for this restriction is that the side-effect may or may not occur.
The method suggested by the previous poster is compliant with Rule 12.4 because the side-effect always occurs.
Could you please explain why does the side-effect may or may not occur? and Why the expression if(xxx && (reg > 0)) forces the side-effect to always occur?
Regards.
<t></t>