Message233686
| Author |
pnugues |
| Recipients |
ezio.melotti, pnugues, vstinner |
| Date |
2015年01月08日.20:54:41 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1420750482.34.0.750338196942.issue23196@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
Greek letters are not properly sorted when a locale is set. I tested a French and a Greek locales. Here is an output obtained from the Python interactive shell available from the python.org home page:
In [22]: a
Out[22]:
('Ά',
'Γ',
'Η',
'Κ',
'Ν',
'Ο',
'έ',
'ί',
'α',
'β',
'γ',
'δ',
'ε',
'ζ',
'ι',
'κ',
'λ',
'μ',
'ν',
'ο',
'ς',
'τ',
'φ',
'χ',
'ό',
'β',
'Ἀ',
'ῖ')
In [26]: sorted(a, key=locale.strxfrm)
Out[26]:
['Ἀ',
'ῖ',
'α',
'Ά',
'β',
'β',
'Γ',
'γ',
'δ',
'ε',
'έ',
'ζ',
'Η',
'ι',
'ί',
'Κ',
'κ',
'λ',
'μ',
'Ν',
'ν',
'Ο',
'ο',
'ό',
'ς',
'τ',
'φ',
'χ']
The letter 'ῖ' is wrongly sorted. You can try to sort the same character list with the ICU demonstration to see the correct ordering here:
http://demo.icu-project.org/icu-bin/locexp?_=el&d_=fr&x=col |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2015年01月08日 20:54:42 | pnugues | set | recipients:
+ pnugues, vstinner, ezio.melotti |
| 2015年01月08日 20:54:42 | pnugues | set | messageid: <1420750482.34.0.750338196942.issue23196@psf.upfronthosting.co.za> |
| 2015年01月08日 20:54:42 | pnugues | link | issue23196 messages |
| 2015年01月08日 20:54:41 | pnugues | create |
|