summaryrefslogtreecommitdiffstats
path: root/Lib/collections
diff options
context:
space:
mode:
authorRaymond Hettinger <python@rcn.com>2011-05-05 21:34:35 (GMT)
committerRaymond Hettinger <python@rcn.com>2011-05-05 21:34:35 (GMT)
commit1c7b7f7fbeb79eaddcd21b20a43802db0f7790a1 (patch)
tree57bdef35d8520e3ca1d9e8f3b7286b05e488d117 /Lib/collections
parent7b48432a77c9a3e902e28fa654882f04c38423fd (diff)
downloadcpython-1c7b7f7fbeb79eaddcd21b20a43802db0f7790a1.zip
cpython-1c7b7f7fbeb79eaddcd21b20a43802db0f7790a1.tar.gz
cpython-1c7b7f7fbeb79eaddcd21b20a43802db0f7790a1.tar.bz2
Userlist.copy() wasn't returning a UserList.
Diffstat (limited to 'Lib/collections')
-rw-r--r--Lib/collections/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/collections/__init__.py b/Lib/collections/__init__.py
index 53e3dd7..4b447ac 100644
--- a/Lib/collections/__init__.py
+++ b/Lib/collections/__init__.py
@@ -887,7 +887,7 @@ class UserList(MutableSequence):
def pop(self, i=-1): return self.data.pop(i)
def remove(self, item): self.data.remove(item)
def clear(self): self.data.clear()
- def copy(self): return self.data.copy()
+ def copy(self): return self.__class__(self)
def count(self, item): return self.data.count(item)
def index(self, item, *args): return self.data.index(item, *args)
def reverse(self): self.data.reverse()