![]() |
![]() |
0466 | ![]() |
||||
![]() | |||||||
| Constraint violations | REFERENCE - ISO:C90-6.3.3.3 Unary Arithmetic Operators - Constraints | ||||||
This is a constraint error The operand of the unary '+' operator must be of arithmetic type. Check the type of the operand. For example:
/*PRQA S 2213,3408,3447,3600,3617 ++*/
struct ST { int x; };
extern struct ST field1;
extern struct ST field2;
extern int *p1;
extern int *p2;
void foo(void)
{
field2 = +field1; /* Message 0466 */
p2 = +p1; /* Message 0466 */
}
MISRA-C:2004 Rules applicable to message 0466:
| Rule 1.1 (Required) | All code shall conform to ISO/IEC 9899:1990 C programming language, ISO 9899, amended and corrected by ISO/IEC 9899/COR1:1995, ISO/IEC 9899/AMD1:1995, and ISO/IEC 9899/COR2: 1996192 |
![]() | ||
| 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 |