integer operations with -1 failing
Original Reporter info from Mantis: Robert Kosek
-
Reporter name: Robert K
Original Reporter info from Mantis: Robert Kosek
- Reporter name: Robert K
Description:
This is a really bizarre and, technically, impossible bug. I am getting an error message of "invalid integer expression" on lines that always work. Yet, give the test project to someone else and they can reproduce the issue.
Here are the five lines where the errors are thrown. All variables shown, complained about, are integer values being passed correct integer values and operations.
Line 87 Column 9:
B := -1; // B is an integer, -1 should be too.
Line 116 Column 14:
if idx <> -1 then
Line 127 Column 14:
if idx <> -1 then
Line 194 Column 12:
Find := -1; // assignment to the result
Line 235 Column 11:
if F = -1 then Exit;
I have listed this as sometimes since it seems to work outside of generics. I've built a few other applications with this same installation, and only when I attempted a generic type did it begin to throw these. Please see the included source; uFastList.pas is the generic type unit and where all the errors occur.
Mantis conversion info:
- Mantis ID: 11035
- Version: 2.2.0
- Fixed in version: 2.2.2