tag 11006 notabug
thanks
On 03/13/2012 06:20 AM, Philipp Thomas wrote:
> I got this bug report for coreutils 8.14:
>
> ----------------------------------------------------
>
> export LANG=en_US.UTF-8
> { echo 16301 3.574885; echo 163 0.171036; } | sort
>
> Produces
>
> 16301 3.574885
> 163 0.171036
>
>
> which is incorrect. The lines should be in the other order
>
> With "LANG=C" it works correctly.
>
> ----------------------------------------------------
>
> Is this really a bug or is this because of differing collating rules?This is correct behavior, and not a bug in sort. The use of LANG=C to switch the behavior is indeed intended, as the en_US.UTF-8 really does collate with punctuation and whitespace elided, where '163013' is before '163017'. I suggest you point the original poster to the FAQ. https://www.gnu.org/software/coreutils/faq/#Sort-does-not-sort-in-normal-order_0021 I'm closing this as not a bug. -- Eric Blake [email protected] +1-919-301-3266 Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
