File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -39,7 +39,8 @@ let fork_daemon ~sw f =
39
39
(* The daemon was cancelled because all non-daemon fibers are finished. *)
40
40
()
41
41
| exception ex ->
42
- Switch. fail sw ex; (* The [with_daemon] ensures this will succeed *)
42
+ let bt = Printexc. get_raw_backtrace () in
43
+ Switch. fail ~bt sw ex; (* The [with_daemon] ensures this will succeed *)
43
44
) (* else the fiber should report the error to [sw], but [sw] is failed anyway *)
44
45
45
46
let fork_promise ~sw f =
@@ -65,7 +66,8 @@ let fork_promise_exn ~sw f =
65
66
match Switch. with_op sw f with
66
67
| x -> Promise. resolve r x
67
68
| exception ex ->
68
- Switch. fail sw ex (* The [with_op] ensures this will succeed *)
69
+ let bt = Printexc. get_raw_backtrace () in
70
+ Switch. fail ~bt sw ex (* The [with_op] ensures this will succeed *)
69
71
);
70
72
p
71
73
You can’t perform that action at this time.
0 commit comments