[Python-ideas] INSANE FLOAT PERFORMANCE!!!
Nathaniel Smith
njs at pobox.com
Wed Oct 12 17:51:21 EDT 2016
The comparison methods on Python's str are codepoint-by-codepoint.
A neat fact about UTF-8 is that bytewise comparisons on UTF-8 are
equivalent to doing codepoint comparisons.
But this isn't relevant to Python's str, because Python's str never uses UTF-8.
-n
On Wed, Oct 12, 2016 at 2:45 PM, Elliot Gorokhovsky
<elliot.gorokhovsky at gmail.com> wrote:
>
>> So what's Python doing? Is it a codepoint ordering?
>
>
> ...ya...how is the python interpreter supposed to know what language strings
> are in? There is a unique ordering of unicode strings defined by the unicode
> standard, AFAIK.
> If you want to sort by natural language ordering, see here:
> https://pypi.python.org/pypi/natsort
>
> _______________________________________________
> Python-ideas mailing list
> Python-ideas at python.org
> https://mail.python.org/mailman/listinfo/python-ideas
> Code of Conduct: http://python.org/psf/codeofconduct/
--
Nathaniel J. Smith -- https://vorpus.org
More information about the Python-ideas
mailing list