STINNER Victor <victor.stin...@haypocalc.com> added the comment: Le mardi 22 mars 2011 à 09:01 +0000, Marc-Andre Lemburg a écrit : > Perhaps you could consider adding a similar approach (raising > an exception instead of writing a traceback) to the module. > We could then port our code to use your module, which is > more advanced.
I already wrote a patch implementing this idea, 2 years ago, and the idea was rejected. Re-read the history of the module, described in the first message of this issue: << History of this module. I first proposed a segfault handler using setjmp/longjmp to raise a classic Python exception. So it was possible to execute Python code after a segfault (including stack overflow). But the idea was rejected because the Python internal state may be corrupted if the segfault was an invalid memory write (buffer overflow?), and anyway we cannot warranty that the internal state is still consistent after a long jump. => http://bugs.python.org/issue3999 (sept. 2009) ... >> You may dig python-dev archives to learn more about this proposition. > BTW: Why do you call the traceback functions "*backtrace*" instead > of "*traceback*" ? Oh... I don't know. Since Python uses "traceback" word, I will rename my functions. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue11393> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com