mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-19 22:29:25 +02:00
Jedi Code Format: Add support for managed records operators. Issue #37983, patch from Domingo Galmés.
git-svn-id: trunk@64073 -
This commit is contained in:
parent
3b84caaf97
commit
419384ae30
@ -2301,28 +2301,27 @@ begin
|
||||
PushNode(nFunctionHeading);
|
||||
Recognise(ttClass);
|
||||
Recognise(ttOperator);
|
||||
|
||||
RecogniseMethodName(False);
|
||||
|
||||
if fcTokenList.FirstSolidTokenType = ttOpenBracket then
|
||||
RecogniseFormalParameters;
|
||||
|
||||
Recognise(ttColon);
|
||||
PushNode(nFunctionReturnType);
|
||||
RecogniseType;
|
||||
PopNode;
|
||||
|
||||
//Managed records have operators without return
|
||||
// Initialize, Finalize, Copy, AddRef.
|
||||
if fcTokenList.FirstSolidTokenType = ttColon then
|
||||
begin
|
||||
Recognise(ttColon);
|
||||
PushNode(nFunctionReturnType);
|
||||
RecogniseType;
|
||||
PopNode;
|
||||
end;
|
||||
RecogniseProcedureDirectives;
|
||||
|
||||
PopNode;
|
||||
|
||||
if pbHasBody then
|
||||
begin
|
||||
Recognise(ttSemiColon);
|
||||
RecogniseBlock;
|
||||
Recognise(ttSemiColon);
|
||||
end;
|
||||
|
||||
PopNode;
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user