mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-12 01:06:02 +02:00
* fixed bug #9577 using short boolean eval. While fixing also fixed next IF.
git-svn-id: trunk@8357 -
This commit is contained in:
parent
825ac6ebe4
commit
6f9c7ede62
@ -352,7 +352,7 @@ type TArgSet = set of 0..31;
|
|||||||
|
|
||||||
function MsgToSet(const Msg, FileName: string; var R: TArgSet): Boolean;
|
function MsgToSet(const Msg, FileName: string; var R: TArgSet): Boolean;
|
||||||
var
|
var
|
||||||
i, j, num : integer;
|
i, j,l, num : integer;
|
||||||
code : word;
|
code : word;
|
||||||
begin
|
begin
|
||||||
R:=[];
|
R:=[];
|
||||||
@ -360,9 +360,9 @@ function MsgToSet(const Msg, FileName: string; var R: TArgSet): Boolean;
|
|||||||
for i:=1 to Length(Msg) do
|
for i:=1 to Length(Msg) do
|
||||||
if Msg[i]='$' then
|
if Msg[i]='$' then
|
||||||
begin
|
begin
|
||||||
j:=i+1;
|
j:=i+1; l:=length(msg)+1;
|
||||||
while Msg[j] in ['0'..'9'] do Inc(j);
|
while (j<l) and (Msg[j] in ['0'..'9']) do Inc(j);
|
||||||
if j > i+1 then
|
if j = l then
|
||||||
begin
|
begin
|
||||||
val(copy(Msg,i+1,j-i-1),num,code);
|
val(copy(Msg,i+1,j-i-1),num,code);
|
||||||
if num > high(TArgSet) then begin
|
if num > high(TArgSet) then begin
|
||||||
|
Loading…
Reference in New Issue
Block a user