14-05-2008, 09:15 AM
Code:
uint16_t mc2_1206_x;
uint16_t mc2_1206_y;
uint16_t mc2_1206_z;
mc2_1206_x = ( mc2_1206_y == mc2_1206_z ); /* Not compliant - mc2_1206_x is not effectively boolean */
This code has been marked as violation of rule 12.6 but I fail to see why. There are no (&&, || and !) operators so the first part of the rule does not apply. The boolean expression is used as operand of "=" so the second part of the rule is complied to as well.
Please correct me if I'm wrong.