Author: Maciej Fijalkowski <[email protected]>
Branch:
Changeset: r74265:fd3027c58ac4
Date: 2014-10-28 17:51 +0100
http://bitbucket.org/pypy/pypy/changeset/fd3027c58ac4/
Log: another fix for tests
diff --git a/rpython/rlib/rgc.py b/rpython/rlib/rgc.py
--- a/rpython/rlib/rgc.py
+++ b/rpython/rlib/rgc.py
@@ -63,10 +63,13 @@
"""Unpin 'obj', allowing it to move again.
Must only be called after a call to pin(obj) returned True.
"""
- for i in range(len(_pinned_objects)):
+ i = 0
+ while i < len(_pinned_objects):
try:
if _pinned_objects[i] == obj:
del _pinned_objects[i]
+ else:
+ i += 1
except TypeError:
pass
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit