mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
Added a test to catch the base class.
This commit is contained in:
parent
9357854187
commit
992cb8ab53
2 changed files with 5 additions and 0 deletions
|
@ -21,3 +21,4 @@ SystemExit
|
||||||
TypeError
|
TypeError
|
||||||
ValueError
|
ValueError
|
||||||
ZeroDivisionError
|
ZeroDivisionError
|
||||||
|
Exception
|
||||||
|
|
|
@ -94,4 +94,8 @@ r(ZeroDivisionError)
|
||||||
try: x = 1/0
|
try: x = 1/0
|
||||||
except ZeroDivisionError: pass
|
except ZeroDivisionError: pass
|
||||||
|
|
||||||
|
r(Exception)
|
||||||
|
try: x = 1/0
|
||||||
|
except Exception, e: pass
|
||||||
|
|
||||||
unlink(TESTFN)
|
unlink(TESTFN)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue