Implements getCurrentException for try in async procs. Ref #1487.
This commit is contained in:
parent
6689fa68f5
commit
dd33069d59
3 changed files with 20 additions and 7 deletions
|
|
@ -2,7 +2,7 @@ discard """
|
|||
file: "tasynctry.nim"
|
||||
exitcode: 0
|
||||
output: '''
|
||||
Generic except
|
||||
Generic except: Test
|
||||
Specific except
|
||||
Multiple idents in except
|
||||
Multiple except branches
|
||||
|
|
@ -22,7 +22,7 @@ proc catch() {.async.} =
|
|||
try:
|
||||
await foobar()
|
||||
except:
|
||||
echo("Generic except")
|
||||
echo("Generic except: ", getCurrentExceptionMsg())
|
||||
|
||||
try:
|
||||
await foobar()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue