Jelajahi Sumber

* set proctypeoption for procvars

Sven/Sarah Barth 4 tahun lalu
induk
melakukan
934e3bba63
1 mengubah file dengan 4 tambahan dan 1 penghapusan
  1. 4 1
      compiler/ptype.pas

+ 4 - 1
compiler/ptype.pas

@@ -1609,8 +1609,11 @@ implementation
             if is_func then
               begin
                 consume(_COLON);
+                pd.proctypeoption:=potype_function;
                 pd.returndef:=result_type([stoAllowSpecialization]);
-              end;
+              end
+            else
+              pd.proctypeoption:=potype_procedure;
             if try_to_consume(_OF) then
               begin
                 consume(_OBJECT);