* allow a range of Low(Longint) to High(DWord) in TryStrToInt, see also issue #39406

* moved test
This commit is contained in:
florian 2022-01-02 21:33:01 +01:00
parent 2a93e65511
commit 435f3a9fe2
2 changed files with 1 additions and 1 deletions

View File

@ -963,7 +963,7 @@ var
li : Int64;
begin
Val(s, li, Error);
TryStrToInt:=(Error=0) and (li<=High(Longint)) and (li>=Low(Longint));
TryStrToInt:=(Error=0) and (li<=High(DWord)) and (li>=Low(Longint));
if TryStrToInt then
i:=li;
end;