![]() |
![]() |
0362 | ![]() |
||||
![]() | |||||||
| Pointers | REFERENCE - ISO:C99-6.3.1.2 Boolean type | ||||||
This message is issued whenever an expression of essentially Boolean type has been cast to a pointer type. For example:
/*PRQA S 1-9999 ++*/
/*PRQA S 0362 --*/
void foo (int * c);
int * f0362 (int a, _Bool b)
{
foo ((int *) (a < 0)); /* 0362 */
return ((int *) b); /* 0362 */
}
MISRA-C:2004 Rules applicable to message 0362:
| Rule 11.3 (Advisory) | A cast should not be performed between a pointer type and an integral type. |
![]() | ||
| 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 |