commit | 859416e980dd6b4b96ad066e723709928c5afa81 | [log] [tgz] |
---|---|---|
author | Antoine Pitrou <solipsis@pitrou.net> | Sun Mar 04 20:20:34 2012 +0100 |
committer | Antoine Pitrou <solipsis@pitrou.net> | Sun Mar 04 20:20:34 2012 +0100 |
tree | 73fff0f2dc51fb418a235f7c89d642700e259db0 | |
parent | 1cb2e04238fa09094ce02d26833a19d2bd70d81d [diff] [blame] |
Fix sporadic failure in test_weakset
diff --git a/Lib/_weakrefset.py b/Lib/_weakrefset.py index 91077c5..b8d8043 100644 --- a/Lib/_weakrefset.py +++ b/Lib/_weakrefset.py
@@ -116,11 +116,8 @@ def update(self, other): if self._pending_removals: self._commit_removals() - if isinstance(other, self.__class__): - self.data.update(other.data) - else: - for element in other: - self.add(element) + for element in other: + self.add(element) def __ior__(self, other): self.update(other)