fix precatching exception behaviour to postcatching
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@5617 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
d6a9dfa874
commit
b32024f2ab
3 changed files with 77 additions and 37 deletions
|
|
@ -6,9 +6,21 @@ a = exception_order.A()
|
|||
try:
|
||||
a.foo()
|
||||
except RuntimeError,e:
|
||||
if e.args[0] != "E":
|
||||
if e.args[0] != "E1":
|
||||
print "bad exception order",
|
||||
raise RuntimeError, e.args
|
||||
|
||||
try:
|
||||
a.bar()
|
||||
except RuntimeError,e:
|
||||
if e.args[0] != "E2":
|
||||
print "bad exception order",
|
||||
raise RuntimeError, e.args
|
||||
|
||||
try:
|
||||
a.foobar()
|
||||
except RuntimeError,e:
|
||||
if e.args[0] != "postcatch unknown":
|
||||
print "bad exception order",
|
||||
raise RuntimeError, e.args
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue