summaryrefslogtreecommitdiffstats
path: root/Lib/weakref.py
diff options
context:
space:
mode:
authorMichael Foord <fuzzyman@voidspace.org.uk>2010-03-29 20:04:23 (GMT)
committerMichael Foord <fuzzyman@voidspace.org.uk>2010-03-29 20:04:23 (GMT)
commite6410c536c9dca5a3a7899888c071f41a1767291 (patch)
treea654e088538f3ca6b1b78aa3a2f2c95315124852 /Lib/weakref.py
parentb8d688cd7c8b7d267cb84f2431457b71e52628fb (diff)
downloadcpython-e6410c536c9dca5a3a7899888c071f41a1767291.zip
cpython-e6410c536c9dca5a3a7899888c071f41a1767291.tar.gz
cpython-e6410c536c9dca5a3a7899888c071f41a1767291.tar.bz2
Backport of weakref.WeakSet and tests from Python 3.
Diffstat (limited to 'Lib/weakref.py')
-rw-r--r--Lib/weakref.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/Lib/weakref.py b/Lib/weakref.py
index 84d81a2..88c60e7 100644
--- a/Lib/weakref.py
+++ b/Lib/weakref.py
@@ -20,6 +20,8 @@ from _weakref import (
ProxyType,
ReferenceType)
+from _weakrefset import WeakSet
+
from exceptions import ReferenceError
@@ -27,7 +29,7 @@ ProxyTypes = (ProxyType, CallableProxyType)
__all__ = ["ref", "proxy", "getweakrefcount", "getweakrefs",
"WeakKeyDictionary", "ReferenceError", "ReferenceType", "ProxyType",
- "CallableProxyType", "ProxyTypes", "WeakValueDictionary"]
+ "CallableProxyType", "ProxyTypes", "WeakValueDictionary", 'WeakSet']
class WeakValueDictionary(UserDict.UserDict):