[fpc-pascal] Operator overload resolution with arrays

Sven Barth pascaldragon at googlemail.com
Mon Feb 5 17:12:51 CET 2018

Am 05.02.2018 15:49 schrieb "Maciej Izak" <hnb.code at gmail.com>:

specialization for the same generic type can behaves in different way!

for example final code for TFoo< TSomeArray> will be different than for
TFoo<TSomeArray> declared in other module (!). What if TFoo<T> has some
class var + class constructor ? What if inside is used some dictionary
(declared as class var and handled in class constructor/destructor) to
handle different specializations (where as key of that dictionary is used
TypeInfo(T)) and some logic is hidden behind of type which behaves in
different way for the same specialization?

Totally nuclear destruction and non-fixable problems for language and
libraries. I will repeat it again : definitely non-consistent and
destructive feature. This can't work in proper way.

Which is exactly what I had meant with the whole new can of bugs :P

I found also many new compiler bugs related to generics types and I want to
> try to fix part of them before I decide to update rtl-generics.

Would be good if you'd report them on Mantis nevertheless, cause generics
are a bit of a sensitive area and I'd like to keep an overview there.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20180205/4969099e/attachment.html>

More information about the fpc-pascal mailing list