Show backtraces when using parallel fibers and resource pools
This commit is contained in:
parent
5af6233e5b
commit
46b4c87e92
1 changed files with 11 additions and 2 deletions
|
|
@ -387,7 +387,11 @@ available. Return the resource once PROC has returned."
|
|||
(lambda ()
|
||||
(call-with-values
|
||||
(lambda ()
|
||||
(proc resource))
|
||||
(with-throw-handler #t
|
||||
(lambda ()
|
||||
(proc resource))
|
||||
(lambda _
|
||||
(backtrace))))
|
||||
(lambda vals
|
||||
(put-message pool `(return ,resource))
|
||||
(apply values vals))))
|
||||
|
|
@ -433,7 +437,12 @@ available. Return the resource once PROC has returned."
|
|||
(lambda (exn)
|
||||
(put-message reply (cons 'exception exn)))
|
||||
(lambda ()
|
||||
(call-with-values thunk
|
||||
(call-with-values
|
||||
(lambda ()
|
||||
(with-throw-handler #t
|
||||
thunk
|
||||
(lambda _
|
||||
(backtrace))))
|
||||
(lambda vals
|
||||
(put-message reply vals))))
|
||||
#:unwind? #t))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue