[pypy-svn] r8966 - pypy/dist/pypy/interpreter
tismer at codespeak.net
tismer at codespeak.net
Mon Feb 7 19:54:19 CET 2005
Author: tismer
Date: Mon Feb 7 19:54:19 2005
New Revision: 8966
Modified:
pypy/dist/pypy/interpreter/function.py
Log:
fixed a small bug where closure is not set to a sequence.
In accordance to CPython, this returns w_None.
Modified: pypy/dist/pypy/interpreter/function.py
==============================================================================
--- pypy/dist/pypy/interpreter/function.py (original)
+++ pypy/dist/pypy/interpreter/function.py Mon Feb 7 19:54:19 2005
@@ -125,7 +125,10 @@
def fget_func_closure(space, w_self):
self = space.interpclass_w(w_self)
- w_res = space.newtuple( [ space.wrap(i) for i in self.closure ] )
+ if self.closure is not None:
+ w_res = space.newtuple( [ space.wrap(i) for i in self.closure ] )
+ else:
+ w_res= space.w_None
return w_res
More information about the Pypy-commit
mailing list