![]() |
![]() |
0635 | ![]() |
||||
![]() | |||||||
| Language extensions | REFERENCE - ISO:C90-6.5.2.1 Structure and Union Specifiers - Semantics | ||||||
According to the ISO:C Standard, a bit-field can only be defined with one of the following types:
/*PRQA S 2211,2213,3131,3211,3408,3602,3621 ++*/
enum ET {A=0, B=1, C=2, D=3}
struct ST /* Message 0635 */
{
signed int a:3; /* OK */
unsigned int b:4; /* OK */
unsigned char c:6; /* Non-portable */
unsigned short d:5; /* Non-portable */
enum ET e:2; /* Non-portable */
} F;
MISRA C:2012 Rules applicable to message 0635:
| Rule-1.2 (Advisory) | Language extensions should not be used |
| Rule-6.1 (Required) | Bit-fields shall only be declared with an appropriate type |
![]() | ||
| 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 |