mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
As discussed on python-dev, remove several operator functions
isSequenceType(), isMappingType(), and isNumberType() in favor of using abstract base classes. Also, remove repeat() and irepeat() in favor of mul() and imul(). After the buildbots have had a go at this. Will backport to Py3.0.1. For Py2.7, will just mark as deprecated.
This commit is contained in:
parent
d0005ff41f
commit
89e12963ad
7 changed files with 6 additions and 153 deletions
|
@ -725,8 +725,6 @@ class BaseTest(unittest.TestCase):
|
|||
self.assertRaises(BufferError, operator.setitem, a, slice(0, 0), a)
|
||||
self.assertRaises(BufferError, operator.delitem, a, 0)
|
||||
self.assertRaises(BufferError, operator.delitem, a, slice(0, 1))
|
||||
self.assertRaises(BufferError, operator.irepeat, a, 2)
|
||||
self.assertRaises(BufferError, operator.irepeat, a, 0)
|
||||
|
||||
def test_weakref(self):
|
||||
s = array.array(self.typecode, self.example)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue