[issue11441] compile() raises SystemError if called from except clause

Amaury Forgeot d'Arc report at bugs.python.org
Wed Mar 9 10:44:11 CET 2011


Amaury Forgeot d'Arc <amauryfa at gmail.com> added the comment:

> That's why I thought that calling PyErr_NormalizeException with the new
> tuple is the simplest thing to do, becuase I guess that'll take care of
> all fields automatically.

You could also call PyErr_NormalizeException at the beginning, and update the fields directly in the PySyntaxErrorObject structure.  No need to deal with any tuple.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue11441>
_______________________________________


More information about the Python-bugs-list mailing list