[fpc-pascal] Re: Inheriting from generics specialized classes
Sven Barth
pascaldragon at googlemail.com
Thu Nov 24 17:36:22 CET 2011
Am 24.11.2011 17:30, schrieb Juha Manninen:
> 2011/11/24 Sven Barth <pascaldragon at googlemail.com
> <mailto:pascaldragon at googlemail.com>>
>
> Thanks for the explanations.
>
>
> In mode Delphi and my generic branch (I hope ^^) you are able to do
> it like this as well:
>
> myV := TMyDerived.Create(False);
> if myV is TFPGObjectList<TMyGen> then
> ...
>
> Under the condition that "TMyDerived" is declared like in your
> previous mail.
>
>
> I think the syntax you gave should be
> if myV is TFPGObjectList<TControl> then
Yes, of course. Thank you for the correction.
> I will continue learning where to usegenerics and where not to use them.
Have fun and feel free to ask further questions :)
Regards,
Sven
More information about the fpc-pascal
mailing list