![]() |
MISRA C:2012 Dir-1.1: (Required) |
|
|||||
![]() | |||||||
Amplification:
Appendix G of MISRA C:2012 lists, for both C90 and C99, those implementation-defined behaviours that:
All of these implementation-defined behaviours on which the program output depends must be:
Note: a conforming implementation is required to document its treatment of all implementation-defined behaviour. The developer of an implementation should be consulted if any documentation is missing.
QAC messages that encompass this guideline:
| 0180 | [C99] Use of ll for conversion specifier. |
| 0202 | [I] '-' character in '[]' conversion specification is implementation defined. |
| 0284 | [I] Multiple character constants have implementation defined values. |
| 0285 | [I] Character constant contains character which is not a member of the basic source character set. |
| 0286 | [I] String literal contains character which is not a member of the basic source character set. |
| 0287 | [I] Header name contains character which is not a member of the basic source character set. |
| 0288 | [I] Source file '%s' has comments containing characters which are not members of the basic source character set. |
| 0289 | [I] Source file '%s' has preprocessing tokens containing characters which are not members of the basic source character set. |
| 0292 | [I] Source file '%s' has comments containing one of the characters '$', '@' or '`'. |
| 0299 | [I] Source file '%s' includes #pragma directives containing characters which are not members of the basic source character set. |
| 0320 | [C99] Declaration within 'for' statement. |
| 0371 | [L] Nesting levels of blocks exceeds 127 - program does not conform strictly to ISO:C99. |
| 0372 | [L] More than 63 levels of nested conditional inclusion - program does not conform strictly to ISO:C99. |
| 0375 | [L] Nesting of parenthesized expressions exceeds 63 - program does not conform strictly to ISO:C99. |
| 0380 | [L] Number of macro definitions exceeds 4095 - program does not conform strictly to ISO:C99. |
| 0388 | [L] '#include "%s"' causes nesting to exceed 15 levels - program does not conform strictly to ISO:C99. |
| 0390 | [L] Number of members in 'struct' or 'union' exceeds 1023 - program does not conform strictly to ISO:C99. |
| 0391 | [L] Number of enumeration constants exceeds 1023 - program does not conform strictly to ISO:C99. |
| 0392 | [L] Nesting of 'struct' or 'union' types exceeds 63 - program does not conform strictly to ISO:C99. |
| 0410 | [L] Nesting of parentheses exceeds 32 - program does not conform strictly to ISO:C90. |
| 0581 | [I] Floating-point constant may be too small to be representable. |
| 0604 | [C99] Declaration appears after statements in a compound statement. |
| 0609 | [L] More than 12 pointer, array or function declarators modifying a declaration - program does not conform strictly to ISO:C90. |
| 0611 | [L] Nesting of 'struct' or 'union' types exceeds 15 - program does not conform strictly to ISO:C90. |
| 0612 | [L] Size of object '%s' exceeds 32767 bytes - program does not conform strictly to ISO:C90. |
| 0614 | [L] More than 127 block scope identifiers defined within a block - program does not conform strictly to ISO:C90. |
| 0617 | [C99] 'const' qualifier has been duplicated. |
| 0618 | [C99] 'volatile' qualifier has been duplicated. |
| 0634 | [I] Bit-fields in this struct/union have not been declared explicitly as unsigned or signed. |
| 0639 | [L] Number of members in 'struct' or 'union' exceeds 127 - program does not conform strictly to ISO:C90. |
| 0647 | [L] Number of enumeration constants exceeds 127 - program does not conform strictly to ISO:C90. |
| 0715 | [L] Nesting of control structures (statements) exceeds 15 - program does not conform strictly to ISO:C90. |
| 0739 | [L] Number of 'case' labels exceeds 257 - program does not conform strictly to ISO:C90. |
| 0810 | [L] '#include "%s"' causes nesting to exceed 8 levels - program does not conform strictly to ISO:C90. |
| 0828 | [L] More than 8 levels of nested conditional inclusion - program does not conform strictly to ISO:C90. |
| 0850 | [C99] Macro argument is empty. |
| 0857 | [L] Number of macro definitions exceeds 1024 - program does not conform strictly to ISO:C90. |
| 0858 | [L] Number of macro parameters exceeds 31 - program does not conform strictly to ISO:C90. |
| 0859 | [L] Number of arguments in macro call exceeds 31 - program does not conform strictly to ISO:C90. |
| 0875 | [L] String literal exceeds 509 characters - program does not conform strictly to ISO:C90. |
| 0930 | [C99] Trailing comma at the end of an enumerator-list. |
| 1011 | [C99] Use of '//' comment. |
| 1018 | [C99] Use of LL suffix. |
| 1027 | [C99] Use of type 'long long'. |
| 1030 | [C99] Macro defined with variable argument list. |
| 1031 | [C99] Initializer for 'struct', 'union' or array type is not a constant expression. |
| 1053 | [C99] Designators have been used in this initialization list. |
| 1054 | [C99] A compound literal has been used. |
| 1055 | [C99] The keyword 'inline' has been used. |
| 1056 | [C99] The keyword '_Bool' has been used. |
| 2855 | Constant: Casting to a signed integer type of insufficient size. |
| 2856 | Definite: Casting to a signed integer type of insufficient size. |
| 2857 | Apparent: Casting to a signed integer type of insufficient size. |
| 2860 | Constant: Implementation-defined value resulting from left shift operation on expression of signed type. |
| 2861 | Definite: Implementation-defined value resulting from left shift operation on expression of signed type. |
| 2862 | Apparent: Implementation-defined value resulting from left shift operation on expression of signed type. |
| 2890 | Constant: Negative value implicitly converted to an unsigned type. |
| 2891 | Definite: Negative value implicitly converted to an unsigned type. |
| 2892 | Apparent: Negative value implicitly converted to an unsigned type. |
| 2895 | Constant: Negative value cast to an unsigned type. |
| 2896 | Definite: Negative value cast to an unsigned type. |
| 2897 | Apparent: Negative value cast to an unsigned type. |
| 3116 | Unrecognized #pragma arguments '%s' This #pragma directive has been ignored. |
Related rules:
| Rule-6.1 | Bit-fields shall only be declared with an appropriate type |
|
||
(c) The Motor Industry Research Association, 2012
|
QA C Source Code Analyser 8.1.2
MISRA C:2012 Compliance Module 1.0 © 2013 Programming Research www.programmingresearch.com |
Personality Groups | Glossary | Message Index | MISRA C:2012 Rule Index | Contents |