bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Case insensitivity seems to ignore lower bound of interval


From: Eric Bischoff
Subject: Re: Case insensitivity seems to ignore lower bound of interval
Date: Thu, 28 Apr 2011 09:38:55 +0200
User-agent: KMail/1.13.6 (Linux/2.6.38-8-generic; KDE/4.6.2; x86_64; ; )

Le jeudi 28 avril 2011 07:59:02, John Cowan a écrit :
> Eric Bischoff scripsit:
> > My understanding of the word "collation" is :
> >    "A", "a",  and "à" are "equivalent"with respect to alphabetical order
> > 
> > It is not :
> >    "A", "a" and "à" are "next to each other" in alphabetical order.
> 
> Proper collation algorithms do work this way: differences in letters
> are most important, but if they are equal, accents are looked at, and
> if *they* are equal, case is looked at.

Yes, that's more or less what I described as the correct algorithm.

But you are right, there are three stages of comparaison, not two.

> But that's not the way
> strcmp() works in C, unfortunately; the best approximation available
> to case-blindness is to sort b either before or after B.

Then it's using strcmp() that is plain wrong :-(.


-- 
Éric Bischoff - Bureau Cornavin
Technical writing and translations
http://www.bureau-cornavin.com
(+33) 3 68 46 00 85
sip:address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]