[fpc-pascal] Re: Correct way for partial generic specialization
leledumbo
leledumbo_cool at yahoo.co.id
Wed Apr 17 02:11:25 CEST 2013
> This must only work if you write "generic TType2 =...". Otherwise this is
a bug.
The code should have it, I missed it when copypaste-ing.
> One can argue however that the following should be valid as well (AFAIK it
> is not currently):
Yes, this is my original question. Let me rephrase:
Having this declaration:
type
generic TType1<A,B> = class end;
Why the following is not valid:
generic TType2 = specialize TType1<A,String>;
but this one is:
generic TType2 = class(specialize TType1<A,String>) end;
?
Is it possible to do partial generic specialization without the need of
inheritance?
--
View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Correct-way-for-partial-generic-specialization-tp5714160p5714169.html
Sent from the Free Pascal - General mailing list archive at Nabble.com.
More information about the fpc-pascal
mailing list