MCPcopy Create free account
hub / github.com/ActiveState/code / __cmp__

Method __cmp__

recipes/Python/440656_List_mixin/recipe-440656.py:26–27  ·  view source on GitHub ↗
(self, other)

Source from the content-addressed store, hash-verified

24 of the given iterable.
25 """
26 def __cmp__(self, other):
27 return cmp(list(self), list(other))
28
29 def __hash__(self):
30 raise TypeError('list objects are unhashable')

Callers 6

__eq__Method · 0.45
__ne__Method · 0.45
__lt__Method · 0.45
__le__Method · 0.45
__gt__Method · 0.45
__ge__Method · 0.45

Calls 1

listClass · 0.85

Tested by

no test coverage detected