[previous] 0848 [next] [U] Attempting to #undef '%s', which is a predefined macro name.
Explicitly undefined REFERENCE - ISO:C90-6.8.8 Predefined Macro Names

You have attempted to undefine a pre-defined macro name. This is not allowed.

Pre-defined macro names specified in ISO:C90 include '__LINE__', '__FILE__', '__DATE__', '__TIME__' and '__STDC__'. None of these macros can be either redefined or undefined.

For example:


/*PRQA S 553,841,2017 ++*/

#undef __STDC__                 /* Message 0848 */


MISRA-C:2004 Rules applicable to message 0848:

Rule  1.2  (Required) No reliance shall be placed on undefined or unspecified behaviour.
Rule  20.1  (Required) Reserved identifiers, macros and functions in the standard library, shall not be defined, redefined or undefined.


See also:

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