commit | 95a97b7c0cd52fafb9defaa1737d432a0eb1c95f | [log] [tgz] |
---|---|---|
author | Antoine Pitrou <solipsis@pitrou.net> | Tue Feb 21 00:00:06 2012 +0100 |
committer | Antoine Pitrou <solipsis@pitrou.net> | Tue Feb 21 00:00:06 2012 +0100 |
tree | 11a861bf271e8bad0a1076fc0119ee2f740177dd | |
parent | 9edceb3e591063f382ae82e14313813ffc1af0bf [diff] [blame] |
Delete the iterator, which could accidentally keep a temporary reference to the yielded element.
diff --git a/Lib/test/test_weakset.py b/Lib/test/test_weakset.py index 58a1f87..3cddf40 100644 --- a/Lib/test/test_weakset.py +++ b/Lib/test/test_weakset.py
@@ -335,6 +335,7 @@ try: it = iter(s) next(it) + del it # Schedule an item for removal and recreate it u = ustr(str(items.pop())) gc.collect() # just in case