[pypy-svn] r64470 - pypy/trunk/pypy/rlib

cfbolz at codespeak.net cfbolz at codespeak.net
Mon Apr 20 18:44:37 CEST 2009


Author: cfbolz
Date: Mon Apr 20 18:44:37 2009
New Revision: 64470

Modified:
   pypy/trunk/pypy/rlib/rcoroutine.py
Log:
nice comment that explains the strange code


Modified: pypy/trunk/pypy/rlib/rcoroutine.py
==============================================================================
--- pypy/trunk/pypy/rlib/rcoroutine.py	(original)
+++ pypy/trunk/pypy/rlib/rcoroutine.py	Mon Apr 20 18:44:37 2009
@@ -300,6 +300,10 @@
         # very strange effects
 
         if not we_are_translated():
+            # we need to make sure that we postpone each coroutine only once on
+            # top of CPython, because this resurrects the coroutine and CPython
+            # calls __del__ again, thus postponing and resurrecting the
+            # coroutine once more :-(
             if self.__already_postponed:
                 return
             self.__already_postponed = True



More information about the Pypy-commit mailing list