[fpc-devel] Sorting tests

J. Gareth Moreton gareth at moreton-family.com
Tue Nov 29 10:31:20 CET 2022

Hmmm, that's a problem!  Fair enough.


On 29/11/2022 09:21, Michael Van Canneyt via fpc-devel wrote:
> On Tue, 29 Nov 2022, J. Gareth Moreton via fpc-devel wrote:
>> Surely that's a bug in the comparison functions that should be fixed 
>> and not something that can be blamed on introsort.  If a comparison 
>> function is faulty, then pretty nuch any sorting algorithm can be 
>> considered to have unpredictable behaviour.
> No-one is blaming introsort.
> It's about not breaking other software that depends on the sort 
> mechanisms
> provided by the RTL. They were documented as using quicksort.
> Since we don't control the external functions, we cannot set introsort 
> as the default till we know for sure that all external functions are 
> OK with
> that.
> We of course could do that and just tell people to fix their 
> implementation.
> But that's not very friendly. From their point of view, their function 
> is working fine (it may well be for quicksort which was the default 
> mechanism), and we would break it.
> Michael.
> _______________________________________________
> fpc-devel maillist  -  fpc-devel at lists.freepascal.org
> https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel

More information about the fpc-devel mailing list