A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2006-May/064972.html below:

[Python-Dev] total ordering.

[Python-Dev] total ordering. [Python-Dev] total ordering.Guido van Rossum guido at python.org
Thu May 11 16:36:36 CEST 2006
On 5/11/06, Vladimir 'Yu' Stepanov <vys at renet.ru> wrote:
> If for Python-3000 similar it will be shown concerning types
> str(), int(), complex() and so on, and the type of exceptions
> will strongly vary, it will make problematic redefinition of
> behavior of function of sorting.

Not really. We'll just document that sort() should only be used on a
list of objects that implement a total ordering. The behavior
otherwise will simply be undefined; it will raise whatever exception
is first raised by an unsupported comparison (most likely TypeError).
In practice this won't be a problem.

-- 
--Guido van Rossum (home page: http://www.python.org/~guido/)
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4