diff options
author | Andrew Svetlov <andrew.svetlov@gmail.com> | 2012-11-01 11:31:31 (GMT) |
---|---|---|
committer | Andrew Svetlov <andrew.svetlov@gmail.com> | 2012-11-01 11:31:31 (GMT) |
commit | 73ee816d0561f5a2655974a507ae2288e41615db (patch) | |
tree | 9eb2fb5d897dd67132756dcd0b251d0686c39eb9 /Lib/collections/abc.py | |
parent | 312c95f8e5494385cae9d91d45303d419b58ae04 (diff) | |
parent | b904e4256e739ccd40b634842a248fe6a9971ad9 (diff) | |
download | cpython-73ee816d0561f5a2655974a507ae2288e41615db.zip cpython-73ee816d0561f5a2655974a507ae2288e41615db.tar.gz cpython-73ee816d0561f5a2655974a507ae2288e41615db.tar.bz2 |
Merge issue #16373: Prevent infinite recursion for ABC Set class operations.
Patch by Serhiy Storchaka.
Diffstat (limited to 'Lib/collections/abc.py')
-rw-r--r-- | Lib/collections/abc.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/collections/abc.py b/Lib/collections/abc.py index 440c35b..18c07bf 100644 --- a/Lib/collections/abc.py +++ b/Lib/collections/abc.py @@ -200,12 +200,12 @@ class Set(Sized, Iterable, Container): def __gt__(self, other): if not isinstance(other, Set): return NotImplemented - return other < self + return other.__lt__(self) def __ge__(self, other): if not isinstance(other, Set): return NotImplemented - return other <= self + return other.__le__(self) def __eq__(self, other): if not isinstance(other, Set): |