![]() |
![]() |
3411 | ![]() |
||||
![]() | |||||||
| Macro Definition | |||||||
This macro definition contains brackets or parentheses which are not balanced. This is either a very unusual macro or, more probably, a typing mistake. For example:
/*PRQA S 553,2017,3412,3429,3435,3453,3456 ++*/
#define M1(X) ((X) + (X) /* 3411 */
#define M2(X) {int x; foo(&x); bar(x); /* 3411 */
#define M3(X) (buf[X]1]) /* 3411 */
MISRA-C:2004 Rules applicable to message 3411:
| Rule 19.4 (Required) | C macros shall only expand to a braced initialiser, a constant, a string literal, a parenthesised expression, a type qualifier, a storage class specifier, or a do-while-zero construct. |
![]() | ||
| QA·C Source Code Analyser 8.1
MISRA-C:2004 Compliance Module 3.2 © 2012 Programming Research. www.programmingresearch.com | Personality Groups | Glossary | Message Index | MISRA-C:2004 Rule Index | Contents |