Browse Source

+ additional flag po_staticmethod for procoptions for class operator. Each class operator is also static, patch by Maciej Izak

git-svn-id: trunk@34998 -
florian 8 years ago
parent
commit
5d8bcaeb4b
1 changed files with 5 additions and 1 deletions
  1. 5 1
      compiler/pdecsub.pas

+ 5 - 1
compiler/pdecsub.pas

@@ -1407,7 +1407,11 @@ implementation
               if pd.parast.symtablelevel>normal_function_level then
               if pd.parast.symtablelevel>normal_function_level then
                 Message(parser_e_no_local_operator);
                 Message(parser_e_no_local_operator);
               if isclassmethod then
               if isclassmethod then
-                include(pd.procoptions,po_classmethod);
+                begin
+                  include(pd.procoptions,po_classmethod);
+                  { any class operator is also static }
+                  include(pd.procoptions,po_staticmethod);
+                end;
               if token<>_ID then
               if token<>_ID then
                 begin
                 begin
                    if not(m_result in current_settings.modeswitches) then
                    if not(m_result in current_settings.modeswitches) then