[fpc-pascal] FGL.TFPSList Find method needed (binary search)

Michael Van Canneyt michael at freepascal.org
Sun Feb 17 10:05:54 CET 2019



On Sat, 16 Feb 2019, AlexeyT wrote:

> Hello. Can you pls, add Sorted property to TFPSList / TFPGList (Add() 
> method must sort newly added item), and also Find method (which must use 
> binary search in Sorted case, and use plain loop if not sorted)?

You can use the rtl-generics generics.collections.pas if you want sorting
and binary search.

It makes no sense to re-implement all what is there in fgl.

Michael.



More information about the fpc-pascal mailing list