False positive range check warnings when -CO used
Original Reporter info from Mantis: PeterB
-
Reporter name: Peter Blackman
Original Reporter info from Mantis: PeterB
- Reporter name: Peter Blackman
Description:
When -CO is used in combination with -Cr, the warning
"Type size mismatch, possible loss of data / range check error"
frequently occurs. It occurs with CHAR constants, constant assignments to unsigned variables, 'new' statements and calls to 'SetLength' with constant length.
Steps to reproduce:
Compile the example with switches -Cr -CO
Additional information:
Switch -Cr or -CO on their own does not produce obvious false positives.
Mantis conversion info:
- Mantis ID: 28323
- OS: Linux
- OS Build: Debian Jessie
- Build: 2.6.4+dfsg-3 [2014/07/12]
- Platform: x64
- Version: 2.6.4