[fpc-pascal] generics class hierarchy

Honza befelemepeseveze at gmail.com
Sun Dec 19 14:08:14 CET 2010

2010/12/19 Sven Barth <pascaldragon at googlemail.com>:
> While I DO agree with you (after some thinking about the consequences) that
> a base class should not be allowed to be specified by a template parameter
> (and this is the way it already is), I don't agree with you that the
> documentation states this as clearly as you propose it.

I admit, that it looks clear to me only now - after/because of several
hours bouncing my head against the keyboard when I struggled to get
generics make what I wanted, so I'm not anymore unbiased when looking
at the docs :-)

> Here the documentation of generics should state more clearly that "class(T)"
> is not allowed, neither in the main class nor in sub classes.

I believe any reasonable improvement patch of the docs would be
welcome by the dev team. You can then get into the chapter text
exactly those words you would like to read there - a nice compensation
for a little effort I think :-)

Best regards,


More information about the fpc-pascal mailing list