From: Guido van Rossum Date: Wed, 4 Mar 1992 16:39:39 +0000 (+0000) Subject: Set sys.last_{type,value} to characteristics of last unhandled exception. X-Git-Tag: v0.9.8~493 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c4adc8337850796b3ca74fde4e594df5d39279f0;p=thirdparty%2FPython%2Fcpython.git Set sys.last_{type,value} to characteristics of last unhandled exception. --- diff --git a/Python/pythonmain.c b/Python/pythonmain.c index f7ff36ccf96a..b00a270054de 100644 --- a/Python/pythonmain.c +++ b/Python/pythonmain.c @@ -300,6 +300,8 @@ print_error() goaway(1); } } + sysset("last_type", exception); + sysset("last_value", v); if (printobject(exception, stderr, PRINT_RAW) != 0) err_clear(); if (v != NULL && v != None) {