[fpc-devel] Creating Generic Object
Amir
Amir at Aavani.net
Sun Apr 15 23:13:08 CEST 2018
Hi all,
Currently, FPC allows declaring objects as
var
MyMap: specialize TFPGMap<AnsiString, MyData>;
This is very nice feature since I do not need define every Map/List/etc
as a separate type.
But to create MyMap object, one has to write something like:
MyMap := (specialize TFPGMap<AnsiString, MyData>).Create()
Wondering if there is any shorter way to handle the objects'
initialization, .e.g., something like
MyMap := auto.Create;
Thanks,
Amir
More information about the fpc-devel
mailing list