![]() |
![]() |
1028 | ![]() |
||||
![]() | |||||||
| Language extensions | REFERENCE - ISO:C90-6.8.1 Conditional Inclusion - Semantics, ISO:C90-6.1.1 Keywords | ||||||
Keywords (such as sizeof) are not recognised in preprocessing directives such as #if and #elif. However some compilers do permit this form as a language extension. QAC allows it but will issue message 1028. For example:
/*PRQA S 553,2017,3205 ++*/
#if (sizeof(int) < 4) /* Message 1028 */
typedef long XTYPE;
#else
typedef int XTYPE;
#endif
MISRA C:2012 Rules applicable to message 1028:
| Rule-1.2 (Advisory) | Language extensions should not be used |
![]() | ||
| QA·C Source Code Analyser 8.1
MISRA C:2012 Compliance Module 1.0 © 2012 Programming Research. www.programmingresearch.com | Personality Groups | Glossary | Message Index | MISRA C:2012 Rule Index | Contents |