/* >>>------------------------------------------------------------ * * File: rule_15.2.c, Module: M2CM-3.2-QAC-8.1.2 * * RULE 15.2 (Required): * An unconditional break statement shall terminate every * non-empty switch clause. * * Implemented by messages: * 2003 The preceding 'switch' clause is not empty and does not * end with a 'jump' statement. Execution will fall * through. * * 2020 Final 'switch' clause does not end with an explicit * 'jump' statement. * * <<<------------------------------------------------------------ */ #include "misra.h" #include "m2cmex.h" extern S16 test_1502( void ) { switch ( s16a ) { case 0: case 1: ++s16b; break; case 2: ++s16c; case 3: /* MISRA Violation */ ++s16b; default: /* MISRA Violation */ ++s16c; } /* MISRA Violation */ return 1; }