More progress towards a working #3691.
This commit is contained in:
parent
656da1f6a9
commit
1c233ba27a
5 changed files with 23 additions and 10 deletions
|
|
@ -1,10 +1,25 @@
|
|||
discard """
|
||||
output: '''Hello'''
|
||||
output: '''Hello
|
||||
Hello
|
||||
'''
|
||||
"""
|
||||
proc test[T]() =
|
||||
try:
|
||||
raise newException(T, "Hello")
|
||||
except T as foobar:
|
||||
echo(foobar.msg)
|
||||
echo(declared(foobar))
|
||||
doAssert(not declared(foobar))
|
||||
|
||||
template testTemplate() =
|
||||
try:
|
||||
raise newException(Exception, "Hello")
|
||||
except Exception as foobar:
|
||||
echo(foobar.msg)
|
||||
doAssert(not declared(foobar))
|
||||
|
||||
proc test2() =
|
||||
testTemplate()
|
||||
doAssert(not declared(foobar))
|
||||
|
||||
test[Exception]()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue