qsort_r argument order

Dustin Lang dstn@cs.toronto.edu
Wed Dec 3 14:23:00 GMT 2008


> Exactly as you have said before, it is because qsort_r is not part of any standard.
>
> So, the same argument can be made for BSD and Mac OSX: why they permute the parameters?

qsort_r appeared in FreeBSD in 2002 [1], possibly earlier in other BSDs. 
If I'm not mistaken, it appeared in glibc in 2007 [2].

http://www.freebsd.org/cgi/cvsweb.cgi/src/lib/libc/stdlib/qsort.c?annotate=1.12
http://sources.redhat.com/cgi-bin/cvsweb.cgi/libc/include/stdlib.h?rev=1.42&content-type=text/x-cvsweb-markup&cvsroot=glibc

cheers,
dstn.



More information about the Libc-alpha mailing list