[pypy-svn] r10318 - in pypy/dist/pypy: objspace/std translator
pedronis at codespeak.net
pedronis at codespeak.net
Tue Apr 5 15:46:13 CEST 2005
Author: pedronis
Date: Tue Apr 5 15:46:13 2005
New Revision: 10318
Modified:
pypy/dist/pypy/objspace/std/fake.py
pypy/dist/pypy/translator/ann_override.py
Log:
annotation override for fake.wrap_exception
Modified: pypy/dist/pypy/objspace/std/fake.py
==============================================================================
--- pypy/dist/pypy/objspace/std/fake.py (original)
+++ pypy/dist/pypy/objspace/std/fake.py Tue Apr 5 15:46:13 2005
@@ -17,6 +17,7 @@
# real-to-wrapped exceptions
def wrap_exception(space):
+ """NOT_RPYTHON"""
exc, value, tb = sys.exc_info()
if exc is OperationError:
raise exc, value, tb # just re-raise it
Modified: pypy/dist/pypy/translator/ann_override.py
==============================================================================
--- pypy/dist/pypy/translator/ann_override.py (original)
+++ pypy/dist/pypy/translator/ann_override.py Tue Apr 5 15:46:13 2005
@@ -1,8 +1,13 @@
# overrides for annotation specific to PyPy codebase
from pypy.annotation.bookkeeper import getbookkeeper
+from pypy.annotation import model as annmodel
+
from pypy.interpreter import error
from pypy.interpreter import pyframe
+from pypy.objspace.std import fake
+def hole(*args):
+ return annmodel.SomeImpossibleValue(benign=True)
def ignore(*args):
bk = getbookkeeper()
@@ -17,4 +22,4 @@
install(pyframe.cpython_tb, ignore)
install(error.OperationError.record_interpreter_traceback, ignore)
-
+install(fake.wrap_exception, hole)
More information about the Pypy-commit
mailing list