diff --git a/Demo/classes/Complex.py b/Demo/classes/Complex.py index b6c4b10e006..64c56d46538 100755 --- a/Demo/classes/Complex.py +++ b/Demo/classes/Complex.py @@ -39,7 +39,6 @@ # # These conversions accept complex arguments only if their imaginary part is zero: # int(z) -# long(z) # float(z) # # The following operators accept two complex numbers, or one complex number @@ -147,11 +146,6 @@ class Complex: raise ValueError("can't convert Complex with nonzero im to int") return int(self.re) - def __long__(self): - if self.im: - raise ValueError("can't convert Complex with nonzero im to long") - return int(self.re) - def __float__(self): if self.im: raise ValueError("can't convert Complex with nonzero im to float") diff --git a/Demo/classes/bitvec.py b/Demo/classes/bitvec.py index 9ee3ebf8cbe..62b26ccf3f5 100755 --- a/Demo/classes/bitvec.py +++ b/Demo/classes/bitvec.py @@ -315,9 +315,6 @@ class BitVec: def __int__(self): return int(self._data) - def __long__(self): - return int(self._data) - def __float__(self): return float(self._data) diff --git a/Lib/collections.py b/Lib/collections.py index 458cbefdf6b..c3faa9a44df 100644 --- a/Lib/collections.py +++ b/Lib/collections.py @@ -255,7 +255,6 @@ class UserString(Sequence): def __str__(self): return str(self.data) def __repr__(self): return repr(self.data) def __int__(self): return int(self.data) - def __long__(self): return int(self.data) def __float__(self): return float(self.data) def __complex__(self): return complex(self.data) def __hash__(self): return hash(self.data)