Abraxas/Misra Home  Table of Contents

Module - m101.html

ABRAXAS SOFTWARE - CodeCheck MISRA Test-Suite Misra-C:1998 Misra-C:2004.

Misra-C Test Suite for Module - m101.c

/* Misra C Enforcement Testing */

Misra C Enforcement Testing */

/* Rule 101: Advisory */

Rule 101: Advisory */

/* Pointer arithmetic should not be used. */

Pointer arithmetic should not be used. */
void
func101 ( void ) 



Function Name: func101()

{
    
int m[10] = {
        0,1,2,3,4,5,6,7,8,9 
    };
int i = 1;
int *pi = &i;
int k;
    
    k = *pi; 
    k = * ( ++pi ) ; /*  RULE 101  */
    
    pi =&m[4];
    k = * ( pi+4 ) ; /*  RULE 101  */
    
}

Abraxas/Misra Home  Table of Contents

ABRAXAS SOFTWARE - CodeCheck MISRA Test-Suite Misra-C:1998 Misra-C:2004.