diff --git a/asyncstdlib/heapq.py b/asyncstdlib/heapq.py index ac2f5e7..a949bb0 100644 --- a/asyncstdlib/heapq.py +++ b/asyncstdlib/heapq.py @@ -99,6 +99,9 @@ async def pull_head(self) -> bool: def __lt__(self, other: "_KeyIter[LT]") -> bool: return self.reverse ^ (self.head_key < other.head_key) + def __eq__(self, other: "_KeyIter[LT]") -> bool: # type: ignore[override] + return not (self.head_key < other.head_key or other.head_key < self.head_key) + @overload def merge(