[py-svn] r45294 - py/trunk/py/magic
fijal at codespeak.net
fijal at codespeak.net
Tue Jul 24 11:06:42 CEST 2007
Author: fijal
Date: Tue Jul 24 11:06:42 2007
New Revision: 45294
Modified:
py/trunk/py/magic/greenlet.py
Log:
Complain loudly when there is pypy without stackless
Modified: py/trunk/py/magic/greenlet.py
==============================================================================
--- py/trunk/py/magic/greenlet.py (original)
+++ py/trunk/py/magic/greenlet.py Tue Jul 24 11:06:42 2007
@@ -2,8 +2,10 @@
if '_stackless' in sys.builtin_module_names:
# when running on top of a pypy with stackless support
from _stackless import greenlet
+elif hasattr(sys, 'pypy_objspaceclass'):
+ raise ImportError("Detected pypy without stackless support")
else:
- # regular CPython (or pypy without stackless support, and then crash :-)
+ # regular CPython
import py
gdir = py.path.local(py.__file__).dirpath()
path = gdir.join('c-extension', 'greenlet', 'greenlet.c')
More information about the py-svn
mailing list