Re: locale specific ordering in EN_US -- why is a<A<b<B<y<Y<z<Z?
From:
Chet Ramey
Subject:
Re: locale specific ordering in EN_US -- why is a<A<b<B<y<Y<z<Z?
Date:
Mon, 21 May 2012 15:46:00 -0400
User-agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:11.0) Gecko/20120327 Thunderbird/11.0.1
On 5/21/12 3:37 PM, Linda Walsh wrote:
> ----
> This is a prime example of Posix being stupid and bad for
> computer science.
>
> They take a deterministic behavior and define it to be
> non-deterministic and break 1000's of programs.
Try being a little less English-centric. Collating order varies by
language.
Posix says that ranges work the way you are used to if you force the
traditional ordering using the `C' or `Posix' locale. Take a deep
breath and use LC_ALL=C in your scripts to avoid depending on whatever
your OS uses as the default.
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU chet@case.edu http://cnswww.cns.cwru.edu/~chet/