FpDebug: PascalParser, fixed parsing float. In Pascal the comma is a list-separator. It can not be decimal-point. So using the locale "DecimalSeparor" will get wrong results.

This commit is contained in:
Martin 2021-12-09 17:37:03 +01:00
parent 4548d90a7f
commit 343eb4e47c

View File

@ -1874,7 +1874,7 @@ var
else begin
while TokenEndPtr^ in ['0'..'9'] do inc(TokenEndPtr);
// identify "2.", but not "[2..3]" // CurExpr.IsFloatAllowed
if (TokenEndPtr^ = DecimalSeparator) and (TokenEndPtr[1] <> '.') then begin
if (TokenEndPtr^ = '.') and (TokenEndPtr[1] <> '.') then begin
inc(TokenEndPtr);
while TokenEndPtr^ in ['0'..'9'] do inc(TokenEndPtr);
if TokenEndPtr^ in ['a'..'z', 'A'..'Z', '_'] then