Skip to content

Collating sequences are used inconsistently. (PR#289)

2 messages · Brian Ripley, Peter Dalgaard

#
R 0.65.0 (and all others I have seen), Solaris 2.6.
[1] "A" "a" "B" "b"
[1] FALSE

in the en_UK locale. I don't think it is good idea that sort and <
have a different idea of ordering, so I rate this as a bug. As far as I can
see sort uses strcoll and hence the locale, and < uses ASCII.
#
ripley@stats.ox.ac.uk writes:
Agreed. I did a i quick runover of all uses of strcmp in the code, and it
seems that the sign only gets used in two files, relop.c (4 times)
and in gnuwin32/dynload.c. The latter one is in a binary search of the
symbol table, which I'll assume is in ASCII order...

I'll make the changes to relop.c if you haven't done so already.