Chris Rebert wrote:
On Mon, Oct 12, 2009 at 7:04 PM, Steven D'Aprano
<ste...@remove.this.cybersource.com.au> wrote:

This can be simplified to:

return cmp((self._a, self._b), (other._a, other._b))

Assuming you're not using Python 3.x that is.

If you're using Python 3, you won't be writing a __cmp__
method in the first place.

--
Greg
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to