[Python-checkins] r67606 - python/branches/py3k/Doc/whatsnew/3.0.rst

georg.brandl python-checkins at python.org
Sat Dec 6 09:14:46 CET 2008


Author: georg.brandl
Date: Sat Dec  6 09:14:46 2008
New Revision: 67606

Log:
cmp() is not really gone.


Modified:
   python/branches/py3k/Doc/whatsnew/3.0.rst

Modified: python/branches/py3k/Doc/whatsnew/3.0.rst
==============================================================================
--- python/branches/py3k/Doc/whatsnew/3.0.rst	(original)
+++ python/branches/py3k/Doc/whatsnew/3.0.rst	Sat Dec  6 09:14:46 2008
@@ -189,12 +189,11 @@
   argument instead. N.B. the *key* and *reverse* arguments are now
   "keyword-only".
 
-* The :func:`cmp` function is gone, and the :meth:`__cmp__` special
-  method is no longer supported.  Use :meth:`__lt__` for sorting,
-  :meth:`__eq__` with :meth:`__hash__`, and other rich comparisons as
-  needed.  (If you really need the :func:`cmp` functionality, you
-  could use the expression ``(a > b) - (a < b)`` as the equivalent for
-  ``cmp(a, b)``.)
+* The :func:`cmp` function should be treated as gone, and the :meth:`__cmp__`
+  special method is no longer supported.  Use :meth:`__lt__` for sorting,
+  :meth:`__eq__` with :meth:`__hash__`, and other rich comparisons as needed.
+  (If you really need the :func:`cmp` functionality, you could use the
+  expression ``(a > b) - (a < b)`` as the equivalent for ``cmp(a, b)``.)
 
 Integers
 --------


More information about the Python-checkins mailing list