summaryrefslogtreecommitdiffstats
path: root/Lib/lib-old
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1995-02-27 13:15:45 (GMT)
committerGuido van Rossum <guido@python.org>1995-02-27 13:15:45 (GMT)
commitc7acf2a106caacc11397e35afe054816fd6181fa (patch)
tree3eb0a826eabd8d7968198399eb28b5efb9902286 /Lib/lib-old
parentcebfa70a794ba3d4aeda681b3164123d934d1c28 (diff)
downloadcpython-c7acf2a106caacc11397e35afe054816fd6181fa.zip
cpython-c7acf2a106caacc11397e35afe054816fd6181fa.tar.gz
cpython-c7acf2a106caacc11397e35afe054816fd6181fa.tar.bz2
handle class exceptions
Diffstat (limited to 'Lib/lib-old')
-rw-r--r--Lib/lib-old/tb.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/Lib/lib-old/tb.py b/Lib/lib-old/tb.py
index 6b9cd9a..0442ba8 100644
--- a/Lib/lib-old/tb.py
+++ b/Lib/lib-old/tb.py
@@ -74,7 +74,10 @@ def browserexec(tb, cmd):
exec(cmd+'\n', globals, locals)
except:
print '*** Exception:',
- print sys.exc_type,
+ if type(sys.exc_type) == type(''):
+ print sys.exc_type,
+ else:
+ print sys.exc_type.__name__,
if sys.exc_value <> None:
print ':', sys.exc_value,
print