Commit f7ad0651 authored by Moul's avatar Moul

[enh] block_uid: Use NotImplemented

parent 3a1e5d61
......@@ -56,22 +56,22 @@ class BlockUID:
def __lt__(self, other: object) -> bool:
if not isinstance(other, BlockUID):
return False
return NotImplemented
return self.number < other.number
def __gt__(self, other: object) -> bool:
if not isinstance(other, BlockUID):
return False
return NotImplemented
return self.number > other.number
def __le__(self, other: object) -> bool:
if not isinstance(other, BlockUID):
return False
return NotImplemented
return self.number <= other.number
def __ge__(self, other: object) -> bool:
if not isinstance(other, BlockUID):
return False
return NotImplemented
return self.number >= other.number
def __hash__(self) -> int:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment