![]() |
![]() |
2996 | ![]() |
||||
![]() | |||||||
| Invariant operations | |||||||
The result of this logical operation is always 'false' (0). The fact that this expression is "degenerate" suggests a logical flaw in the code. For example:
/*PRQA S 2017,2100,3120,2982,2983,2984,2986,3198,3199,3203,3227,3356,3408 ++*/
void foo(unsigned char x, int y)
{
int r;
r = x > 300; /* 2996 */
if (y < 20)
{
r = y > 30; /* 2996 */
}
}
See also:
![]() | ||
| QA·C Source Code Analyser 8.1.2
© 2013 Programming Research. www.programmingresearch.com | Personality Groups | Glossary | Message Index | Contents |