bug#51011: [GNU sort] Numerical sort with delimiter may be broken (bug)

2021-10-08 Thread Paul Eggert
On 10/8/21 7:32 PM, Pádraig Brady wrote: it's not a thousands separator, rather a grouping character, and groups can be in 2, 3, 4, and even 5. Sure, but 'sort' could determine the group sizes from the locale, and reject digit strings that are formatted improperly according to the

bug#51011: [GNU sort] Numerical sort with delimiter may be broken (bug)

2021-10-08 Thread Pádraig Brady
On 08/10/2021 21:48, Paul Eggert wrote: On 10/8/21 6:37 AM, Pádraig Brady wrote: The difference here is due to ',' being treated as a thousands sep, not a decimal point. Oh, thanks. Of course! I should have figured that out myself. It is unfortunate that "," is treated as a thousands

bug#51011: [GNU sort] Numerical sort with delimiter may be broken (bug)

2021-10-08 Thread Paul Eggert
On 10/8/21 6:37 AM, Pádraig Brady wrote: The difference here is due to ',' being treated as a thousands sep, not a decimal point. Oh, thanks. Of course! I should have figured that out myself. It is unfortunate that "," is treated as a thousands seperator even though it's obviously not one

bug#51011: [GNU sort] Numerical sort with delimiter may be broken (bug)

2021-10-08 Thread Pádraig Brady
On 04/10/2021 21:01, Paul Eggert wrote: On 10/4/21 08:58, Pádraig Brady wrote: The --debug option points out the issue:   $ printf '%s\n' 1,a 0,9 | sort --debug -nk1 -t ,   sort: key 1 is numeric and spans multiple fields   1,a   _   ___   0,9   ___   ___ As Juncheng points