[pypy-svn] r8552 - pypy/dist/pypy/interpreter

tismer at codespeak.net tismer at codespeak.net
Tue Jan 25 13:04:30 CET 2005


Author: tismer
Date: Tue Jan 25 13:04:30 2005
New Revision: 8552

Modified:
   pypy/dist/pypy/interpreter/generator.py
Log:
fixed a bug in GeneratorIterator.
It was not stopping the frame after the first StopIteration.

Modified: pypy/dist/pypy/interpreter/generator.py
==============================================================================
--- pypy/dist/pypy/interpreter/generator.py	(original)
+++ pypy/dist/pypy/interpreter/generator.py	Tue Jan 25 13:04:30 2005
@@ -58,6 +58,7 @@
             try:
                 return self.frame.resume()
             except OperationError, e:
+                self.frame.exhausted = True
                 if e.match(self.space, self.space.w_StopIteration):
                     raise OperationError(space.w_StopIteration, space.w_None) 
                 else:



More information about the Pypy-commit mailing list