Deprecate offsetvector.__cmp__
This method is deprecated and will be removed in a future release because:
- According to the Python standard library documentation,
cmp(a, b)
is expected to return 0 ifa == b
. This method breaks that expectation. - The
cmp()
method has been removed from Python 3.
Instead of cmp(a, b)
, you should call a.deltas != b.deltas
.
Also fix the doctests so that we don't try to call the undefined
function cmp()
and cause a NameError
.
Fixes #2 (closed).