mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-24 09:39:11 +02:00
compiler: don't remove 'self' if the method is static but not a class method
git-svn-id: trunk@14579 -
This commit is contained in:
parent
58c71c3c59
commit
2fdf045e74
@ -2774,12 +2774,15 @@ const
|
||||
if not (po_staticmethod in currpd.procoptions) then
|
||||
begin
|
||||
include(currpd.procoptions, po_staticmethod);
|
||||
{ remove self from the hidden paras }
|
||||
symentry:=currpd.parast.Find('self');
|
||||
if symentry<>nil then
|
||||
if (po_classmethod in currpd.procoptions) then
|
||||
begin
|
||||
currpd.parast.Delete(symentry);
|
||||
currpd.calcparas;
|
||||
{ remove self from the hidden paras }
|
||||
symentry:=currpd.parast.Find('self');
|
||||
if symentry<>nil then
|
||||
begin
|
||||
currpd.parast.Delete(symentry);
|
||||
currpd.calcparas;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user