2005/12/7, Michael Stone <[EMAIL PROTECTED]>:
> On Wed, Dec 07, 2005 at 07:54:59PM +0100, Tomasz Wegrzanowski wrote:
> >http://mathworld.wolfram.com/LexicographicOrder.html
>
> That's a nice reference and all, but irrelevant. Or are you claiming that
> sort somehow generates non-sorted data?

$ cat X
a a
a c
ab c
$ cat X | LC_COLLATE=C sort
a a
a c
ab c
$ cat X | LC_COLLATE=pl_PL.UTF-8 sort
a a
ab c
a c

This is not lexicographic. There's no consistent ordering between b and space.

> The issue is that some symbols
> simply have no meaning for certain kinds of sort (that is, they have
> *no* relation such that A<B), which is different than saying that the
> sort isn't lexicographic. You're arguing for a difference in the
> interpretation of the symbols, not for a different kind of sort. (And
> that *can not* be done within sort except by sorting based on ASCII
> value (collate=C) and ignoring i18n, and eventually UTF, entirely.)

It's not about ignoring i18n. Characters may be ordered in any
locale-dependent way,
but the lines should be sorted consistently or bad things will happen.

Reply via email to