Re: [Python-Dev] WeakSet in Python 2.7

2010-03-29 Thread Michael Foord
On 29/03/2010 20:46, Daniel Stutzbach wrote: On Mon, Mar 29, 2010 at 2:21 PM, Michael Foord mailto:mich...@voidspace.org.uk>> wrote: It should be possible to fix it with a WeakKeyDictionary instead of WeakSet. True. I should have said "Backporting WeakSet would make it *easier* to b

Re: [Python-Dev] WeakSet in Python 2.7

2010-03-29 Thread Michael Foord
On 29/03/2010 20:20, Michael Foord wrote: On 29/03/2010 18:16, Michael Foord wrote: Hello all, Python 3 includes a WeakSet implementation. Any objections to me backporting this to 2.7? http://docs.python.org/py3k/library/weakref.html#weakref.WeakSet I needed this in unittest and used a Weak

Re: [Python-Dev] WeakSet in Python 2.7

2010-03-29 Thread Daniel Stutzbach
On Mon, Mar 29, 2010 at 2:21 PM, Michael Foord wrote: > It should be possible to fix it with a WeakKeyDictionary instead of > WeakSet. > True. I should have said "Backporting WeakSet would make it *easier* to backport the fix ..." :-) -- Daniel Stutzbach, Ph.D. President, Stutzbach Enterprises,

Re: [Python-Dev] WeakSet in Python 2.7

2010-03-29 Thread Michael Foord
On 29/03/2010 19:14, Daniel Stutzbach wrote: On Mon, Mar 29, 2010 at 12:16 PM, Michael Foord mailto:mich...@voidspace.org.uk>> wrote: Python 3 includes a WeakSet implementation. Any objections to me backporting this to 2.7? http://docs.python.org/py3k/library/weakref.html#weakref.W

Re: [Python-Dev] WeakSet in Python 2.7

2010-03-29 Thread Michael Foord
On 29/03/2010 18:16, Michael Foord wrote: Hello all, Python 3 includes a WeakSet implementation. Any objections to me backporting this to 2.7? http://docs.python.org/py3k/library/weakref.html#weakref.WeakSet I needed this in unittest and used a WeakKeyDictionary instead. Hmmm... I was unde

Re: [Python-Dev] WeakSet in Python 2.7

2010-03-29 Thread Daniel Stutzbach
On Mon, Mar 29, 2010 at 12:16 PM, Michael Foord wrote: > Python 3 includes a WeakSet implementation. Any objections to me > backporting this to 2.7? > > http://docs.python.org/py3k/library/weakref.html#weakref.WeakSet > Backporting WeakSet would also make it possible to backport the fix for this

[Python-Dev] WeakSet in Python 2.7

2010-03-29 Thread Michael Foord
Hello all, Python 3 includes a WeakSet implementation. Any objections to me backporting this to 2.7? http://docs.python.org/py3k/library/weakref.html#weakref.WeakSet I needed this in unittest and used a WeakKeyDictionary instead. Michael -- http://www.ironpythoninaction.com/ http://www.void