mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-08 20:35:58 +02:00
codetools: fixed MoveCursorToFirstProcSpecifier parsing operator
git-svn-id: trunk@34993 -
This commit is contained in:
parent
3f0753c04f
commit
325e87fb8e
@ -7284,6 +7284,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
MoveCursorToFirstProcSpecifier(ANode);
|
MoveCursorToFirstProcSpecifier(ANode);
|
||||||
if (CurPos.Flag<>cafSemicolon) and (CurPos.EndPos<ANode.FirstChild.EndPos)
|
if (CurPos.Flag<>cafSemicolon) and (CurPos.EndPos<ANode.FirstChild.EndPos)
|
||||||
|
and (LastAtoms.Count>0)
|
||||||
then begin
|
then begin
|
||||||
// add missing semicolon in front of proc modifiers
|
// add missing semicolon in front of proc modifiers
|
||||||
UndoReadNextAtom;
|
UndoReadNextAtom;
|
||||||
|
@ -873,12 +873,13 @@ begin
|
|||||||
end else begin
|
end else begin
|
||||||
MoveCursorToNodeStart(ProcNode);
|
MoveCursorToNodeStart(ProcNode);
|
||||||
ReadNextAtom;
|
ReadNextAtom;
|
||||||
if AtomIsIdentifier(false) then begin
|
if AtomIsCustomOperator(true,false) then begin
|
||||||
// read name
|
// read name
|
||||||
ReadNextAtom;
|
ReadNextAtom;
|
||||||
while (CurPos.Flag=cafPoint) do begin
|
while (CurPos.Flag=cafPoint) do begin
|
||||||
ReadNextAtom;
|
ReadNextAtom;
|
||||||
if CurPos.Flag<>cafWord then break;
|
if CurPos.Flag in [cafPoint,cafRoundBracketOpen,cafEdgedBracketOpen,cafColon,cafEnd,cafSemicolon]
|
||||||
|
then break;
|
||||||
ReadNextAtom;
|
ReadNextAtom;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
@ -900,7 +901,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
// CurPos now stands on the first proc specifier or on a semicolon
|
// CurPos now stands on the first proc specifier or on a semicolon or on the syntax error
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TPascalReaderTool.MoveCursorToProcSpecifier(ProcNode: TCodeTreeNode;
|
function TPascalReaderTool.MoveCursorToProcSpecifier(ProcNode: TCodeTreeNode;
|
||||||
|
Loading…
Reference in New Issue
Block a user