[fpc-devel] Standard generic classes
Sven Barth
pascaldragon at googlemail.com
Sat Jun 8 15:13:34 CEST 2019
Marco van de Voort <fpc at pascalprogramming.org> schrieb am Sa., 8. Juni
2019, 13:43:
>
> Op 2019-06-06 om 16:57 schreef Ben Grasset:
> > On Wed, Jun 5, 2019 at 11:11 AM Sven Barth via fpc-devel
> > <fpc-devel at lists.freepascal.org
> > <mailto:fpc-devel at lists.freepascal.org>> wrote:
> >
> > You could try to adjust the FGL unit to use the pluggable sorting
> > system introduced here:
> >
> https://svn.freepascal.org/cgi-bin/viewvc.cgi?view=revision&revision=41167
> >
> >
> > Wouldn't that system itself need to be generic and not just use void
> > pointers first? Or is that part of what you meant?
> >
> > IMO something FGL would benefit from also is the removal of the
> > probably-not-the-best-design inheritance from non-generic TFPSList to
> > everything else, which prevents inlining in a large number of places
> > (the compiler notes indicating such are visible basically any time you
> > use anything from FGL.)
> >
> Yes, but that would be incompatible. However maybe some simple object
> based types next to it would furfill the remaining purpose of the unit (
> cases where you need some simple generic container in places that
> haven't access to the ones in packages (fcl-stl, rtl-generics)).
>
> But I would keep it simple and straightforward, and save the complex
> stuff for the more complicated libraries.
>
Yes, that would be a good compromise.
Regards,
Sven
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-devel/attachments/20190608/e41249f7/attachment.html>
More information about the fpc-devel
mailing list