TFPExressionParser wrong test for failure
Original Reporter info from Mantis: taazz
-
Reporter name: John Kozikopoulos
Original Reporter info from Mantis: taazz
- Reporter name: John Kozikopoulos
Description:
unit FpExprPars
Class TFPExpressionParser
Method Primitive
Line No 1721.
The code reads
1716 if TryStrToInt64(CurrentToken,I) then
1717 Result:=TFPConstExpression.CreateInteger(I)
1718 else
1719 begin
1720 Val(CurrentToken,X,C);
1721 If (I=0) then
1722 Result:=TFPConstExpression.CreateFloat(X)
1723 else
1724 ParserError(Format(SErrInvalidFloat,[CurrentToken]));
1725 end;
end
the line
If (I=0) then
should read
If (C=0) then
Steps to reproduce:
no steps
Mantis conversion info:
- Mantis ID: 34288
- Version: 3.0.4
- Fixed in version: 3.3.1
- Fixed in revision: 39758 (#8307e46e)
- Target version: 3.2.0