Tool/software: TI C/C++ Compiler
We recently tried updating our compiler on existing code and it began misreporting MISRA rule 12.7:
#define SWITCH_0_BIT 0x01U
#define SWITCH_1_BIT 0x02U
#define SWITCH_2_BIT 0x04U
#define SWITCH_3_BIT 0x08U
#define SWITCH_4_BIT 0x10U
samples = ((((uint32_t)GPIOPinRead(GPIO_PORTD_BASE, GPIO_PIN_4) == 0U) ? 0U : SWITCH_0_BIT)
| (((uint32_t)GPIOPinRead(GPIO_PORTJ_BASE, GPIO_PIN_0) == 0U) ? 0U : SWITCH_1_BIT)
| (((uint32_t)GPIOPinRead(GPIO_PORTD_BASE, GPIO_PIN_5) == 0U) ? 0U : SWITCH_2_BIT)
| (((uint32_t)GPIOPinRead(GPIO_PORTN_BASE, GPIO_PIN_3) == 0U) ? 0U : SWITCH_3_BIT)
| (((uint32_t)GPIOPinRead(GPIO_PORTJ_BASE, GPIO_PIN_1) == 0U) ? 0U : SWITCH_4_BIT) );
All bitwise operations should be unsigned here.