[fpc-devel] Should this compile (property)

Martin Frb lazarus at mfriebe.de
Thu Nov 12 17:12:07 CET 2026


Is the constructor a valid Getter?
And if so, create can be called on the instance and on the class, but as 
getter it only works on the instance. For "class property" it fails.

program Project1;{$Mode objfpc}
type

TFoo = class
   constructor Create;
   property CallCreate: TFoo read Create;
end;

constructor TFoo.Create;
begin
end;

begin
end.



More information about the fpc-devel mailing list