summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
Diffstat (limited to 'Lib')
-rw-r--r--Lib/sets.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/Lib/sets.py b/Lib/sets.py
index 2605c98..6d2c032 100644
--- a/Lib/sets.py
+++ b/Lib/sets.py
@@ -102,6 +102,11 @@ class BaseSet(object):
"""
return self._data.iterkeys()
+ # Three-way comparison is not supported
+
+ def __cmp__(self, other):
+ raise TypeError, "can't compare sets using cmp()"
+
# Equality comparisons using the underlying dicts
def __eq__(self, other):