[pypy-svn] r11039 - pypy/dist/pypy/objspace/std
pedronis at codespeak.net
pedronis at codespeak.net
Fri Apr 22 22:13:58 CEST 2005
Author: pedronis
Date: Fri Apr 22 22:13:58 2005
New Revision: 11039
Modified:
pypy/dist/pypy/objspace/std/typeobject.py
Log:
avoid migration of .space to W_Root
Modified: pypy/dist/pypy/objspace/std/typeobject.py
==============================================================================
--- pypy/dist/pypy/objspace/std/typeobject.py (original)
+++ pypy/dist/pypy/objspace/std/typeobject.py Fri Apr 22 22:13:58 2005
@@ -310,7 +310,7 @@
if mro_blockinglist(candidate, orderlists) is GOODCANDIDATE:
break # good candidate
else:
- return mro_error(orderlists) # no candidate found
+ return mro_error(space, orderlists) # no candidate found
assert candidate not in order
order.append(candidate)
for i in range(len(orderlists)-1, -1, -1):
@@ -331,10 +331,9 @@
def _getname(space, w_cls):
return space.getattr(w_cls, space.wrap('__name__'))
-def mro_error(orderlists):
+def mro_error(space, orderlists):
cycle = []
candidate = orderlists[-1][0]
- space = candidate.space
if candidate in orderlists[-1][1:]:
# explicit error message for this specific case
raise OperationError(space.w_TypeError,
More information about the Pypy-commit
mailing list