commit | f49562586f965ef8f670fcf8e7f89bf3df0a876e | [log] [tgz] |
---|---|---|
author | Guido van Rossum <guido@python.org> | Sat Apr 13 14:03:38 2002 +0000 |
committer | Guido van Rossum <guido@python.org> | Sat Apr 13 14:03:38 2002 +0000 |
tree | 1865287f476cfe0fe80823c346ae2920d80fd0d4 | |
parent | 0e871188e8cd9a4e41be7c734e250bfce2d92d56 [diff] |
Add pop() to UserDict.
diff --git a/Lib/UserDict.py b/Lib/UserDict.py index b78860f..91af83c 100644 --- a/Lib/UserDict.py +++ b/Lib/UserDict.py
@@ -50,6 +50,8 @@ if not self.has_key(key): self[key] = failobj return self[key] + def pop(self, key): + return self.data.pop(key) def popitem(self): return self.data.popitem() def __contains__(self, key):