mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
Backport of weakref.WeakSet and tests from Python 3.
This commit is contained in:
parent
b8d688cd7c
commit
e6410c536c
6 changed files with 602 additions and 1 deletions
|
@ -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):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue