...
Mistakes regarding precedence rules may cause an expression to be evaluated in an unintended way, which can lead to unexpected and abnormal program behavior.
Recommendation | Severity | Likelihood |
|---|
Remediation CostDetectable | Repairable | Priority | Level |
|---|
EXP00-C | Low | Probable | Yes |
MediumP4L3Automated Detection
Tool | Version | Checker | Description |
|---|
| Axivion Bauhaus Suite | | Include Page |
|---|
| Axivion Bauhaus Suite_V |
|---|
| Axivion Bauhaus Suite_V |
|---|
|
| CertC-EXP00 | Fully implemented |
| CodeSonar | | LANG.STRUCT.PARENS | Missing Parentheses |
ECLAIR | | CC2.EXP00
| Fully implemented |
| Helix QAC | | C3389, C3390, C3391, C3392, C3393, C3394, C3395, C3396, C3397, C3398, C3399, C3400 |
|
| Klocwork | | CERT.EXPR.PARENS |
|
| LDRA tool suite | | 361 S, 49 S
| Fully implemented |
| Parasoft C/C++test |
9.5 | CODSTA-97 | | CERT_C-EXP00-a | Use parenthesis to clarify expression order if operators with precedence lower than arithmetic are used |
| PC-lint Plus | | Include Page |
|---|
| PC-lint Plus_V |
|---|
| PC-lint Plus_V |
|---|
|
| 9050 | Fully supported |
| Polyspace Bug Finder | |
Fully implementedR2016a | Possibly unintended evaluation of expression because of operator precedence rules |
Operator precedence rules cause unexpected evaluation order in arithmetic expression | PRQA QA-CPRQA QACvPRQA QACv3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400
| Fully implemented | Related Vulnerabilities
Search for vulnerabilities resulting from the violation of this rule on the CERT website.
Related Guidelines
Bibliography
...
Image Modified
Image Modified
Image Modified