Forward port total_ordering() and cmp_to_key().

This commit is contained in:
Raymond Hettinger 2010-04-05 18:56:31 +00:00
parent 5daab45158
commit c50846aaef
10 changed files with 186 additions and 25 deletions

View file

@ -1209,8 +1209,7 @@ Basic customization
Arguments to rich comparison methods are never coerced.
To automatically generate ordering operations from a single root operation,
see the `Total Ordering recipe in the ASPN cookbook
<http://code.activestate.com/recipes/576529/>`_\.
see :func:`functools.total_ordering`.
.. method:: object.__hash__(self)