New submission from Stefan Behnel <sco...@users.sourceforge.net>: Following up on recent mailing list threads on pypy-dev and python-dev, this is a request for adding a public C-API to read and write the sys.exc_info() fields, currently stored in tstate->exc_*.
While not of major interest for CPython itself, this C-API addition would allow other Python implementations (currently PyPy) to hide their internal representation of these fields and to allow extensions that need to access them (most notably those generated by the Cython compiler) to write portable code. Martin von Löwis proposed the names PyErr_GetExcInfo() and PyErr_SetExcInfo(), making them simple getter and setter functions that operate on owned references. http://thread.gmane.org/gmane.comp.python.devel/129787/focus=129792 I'm currently working on a patch for CPython 3.3. ---------- components: Interpreter Core messages: 154052 nosy: loewis, scoder priority: normal severity: normal status: open title: provide public C-API for reading/setting sys.exc_info() type: enhancement versions: Python 3.3 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue14098> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com