mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-11 10:35:58 +02:00
codetools: fixed parsing variable hint modifiers not behind semicolon
git-svn-id: branches/fixes_1_6@50722 -
This commit is contained in:
parent
73ebe1446e
commit
7c617e4023
@ -3358,7 +3358,8 @@ begin
|
||||
end;
|
||||
|
||||
// optional: hint modifier
|
||||
ReadHintModifiers([cafSemicolon,cafEqual]);
|
||||
if CurPos.Flag<>cafSemicolon then
|
||||
ReadHintModifiers([cafSemicolon,cafEqual]);
|
||||
|
||||
if (ParentNode.Desc=ctnVarSection) then begin
|
||||
// optional: initial value
|
||||
@ -3762,7 +3763,8 @@ begin
|
||||
SaveRaiseStringExpectedButAtomFound(ctsStringConstant);
|
||||
ReadConstant(true,false,[]);
|
||||
// read hint modifier
|
||||
ReadHintModifiers;
|
||||
if CurPos.Flag<>cafSemicolon then
|
||||
ReadHintModifiers;
|
||||
// read ;
|
||||
if CurPos.Flag<>cafSemicolon then
|
||||
SaveRaiseCharExpectedButAtomFound(';');
|
||||
@ -3903,7 +3905,8 @@ begin
|
||||
end;
|
||||
ReadConstExpr;
|
||||
// optional: hint modifier
|
||||
ReadHintModifiers;
|
||||
if CurPos.Flag<>cafSemicolon then
|
||||
ReadHintModifiers;
|
||||
if CurPos.Flag=cafSemicolon then begin
|
||||
if (CurNode.Parent.Desc=ctnConstSection)
|
||||
and (CurNode.Parent.Parent.Desc in AllCodeSections) then begin
|
||||
@ -3993,7 +3996,8 @@ begin
|
||||
ReadNextAtom;
|
||||
ParseType(CurPos.StartPos);
|
||||
// read hint modifier
|
||||
ReadHintModifiers;
|
||||
if CurPos.Flag<>cafSemicolon then
|
||||
ReadHintModifiers;
|
||||
// read ;
|
||||
if CurPos.Flag<>cafSemicolon then
|
||||
SaveRaiseCharExpectedButAtomFound(';');
|
||||
|
Loading…
Reference in New Issue
Block a user