[issue1771] Remove cmp parameter to list.sort() and builtin.sorted()
Lea Wiemann
report at bugs.python.org
Sun Feb 17 02:49:37 CET 2008
Lea Wiemann added the comment:
"Non-obvious" to the novice that this technique can be used, and non-
obvious to the reader of the program.
I'm envisioning key functions that return long sequences of -1/0/1
integers, or numbers between 0 and 2**50... Not good.
Instead of removing cmp, I'd suggest simply placing a note in the
documentation saying that key is preferred over cmp, to encourage
readability.
__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue1771>
__________________________________
More information about the Python-bugs-list
mailing list