[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Patch] to correctly sort the items with emphasis marks in a list
From: |
Maxim Nikulin |
Subject: |
Re: [Patch] to correctly sort the items with emphasis marks in a list |
Date: |
Thu, 15 Apr 2021 21:58:23 +0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 |
I can reproduce the issue with emacs-27.1 from ubuntu-21.04 beta live
image running in qemu. Org mode is current git HEAD. It seems that
something is changed in emacs since locale is correct:
ubuntu@ubuntu:~$ printf '%s- v\n- /v/\n- a\n- /a/\n' '' \
| LANG=C.UTF-8 sort
- /a/
- /v/
- a
- v
ubuntu@ubuntu:~$ printf '%s- v\n- /v/\n- a\n- /a/\n' '' \
| LANG=es_ES.UTF-8 sort
- /a/
- a
- /v/
- v
Concerning org-sort-list, I do not see any problem with en_US.UTF-8,
it_IT.UTF-8, and ru_RU.UTF-8 locales. However emphasized items are
sorted first for at least es_ES.UTF-8, es_MX.UTF-8, and es_US.UTF-8.
I have found some evidence that the problem is on the org side
cat list.el
(message "%S" (sort '("- /v/" "- v" "- a" "- /a/")
#'string-collate-lessp))
LC_ALL=C.UTF-8 emacs --batch -Q -l list.el
("- /a/" "- /v/" "- a" "- v")
LC_ALL=en_US.UTF-8 emacs --batch -Q -l list.el
("- /a/" "- a" "- /v/" "- v")
LC_ALL=es_ES.UTF-8 emacs --batch -Q -l list.el
("- /a/" "- a" "- /v/" "- v")
So even string-collate-lessp works as expected.
I'm puzzled why the problem is specific to org-sort-list and namely to
Spanish locales.
- Re: [Patch] to correctly sort the items with emphasis marks in a list, (continued)
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Nicolas Goaziou, 2021/04/09
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Juan Manuel Macías, 2021/04/09
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Nicolas Goaziou, 2021/04/10
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Juan Manuel Macías, 2021/04/10
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Maxim Nikulin, 2021/04/13
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Juan Manuel Macías, 2021/04/13
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Maxim Nikulin, 2021/04/14
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Maxim Nikulin, 2021/04/14
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Juan Manuel Macías, 2021/04/14
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Juan Manuel Macías, 2021/04/14
- Re: [Patch] to correctly sort the items with emphasis marks in a list,
Maxim Nikulin <=
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Juan Manuel Macías, 2021/04/15
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Maxim Nikulin, 2021/04/16
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Maxim Nikulin, 2021/04/16
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Maxim Nikulin, 2021/04/17
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Juan Manuel Macías, 2021/04/18
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Juan Manuel Macías, 2021/04/18
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Nicolas Goaziou, 2021/04/19
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Maxim Nikulin, 2021/04/19
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Nicolas Goaziou, 2021/04/19
- Re: [Patch] to correctly sort the items with emphasis marks in a list, Greg Minshall, 2021/04/19