32U unsigned, uint32_t. , uint8_t
A unsigned , 0 65535, . , , . uint8_t, a uint8_t , unsigned.
, , unsigned 16- , 32- 64- - , , a uint32_t.
The result of the expression arg % 32Ucan therefore be of type uint32_t(if it unsignedis 16 bits), uint32_t(if unsignedit uint32_tis the same 32-bit types), or unsigned(if it unsignedis a 64-bit type). In the latter case, initialization u32arequires conversion from unsignedto uint32_t.
Your static analyzer warns you of this potential change in behavior between systems.
So no, this is not a false positive.
source
share