Skip to content

Commit

Permalink
Delay pair destructuring to reduce code size
Browse files Browse the repository at this point in the history
  • Loading branch information
polytypic committed Oct 14, 2024
1 parent 2d1820f commit 9ab7b9f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/picos/picos.ocaml5.ml
Original file line number Diff line number Diff line change
Expand Up @@ -404,9 +404,9 @@ module Computation = struct
if try_attach t trigger then begin
match Trigger.await trigger with
| None -> begin match op with Ignore -> () | Peek -> peek_exn t end
| Some (exn, bt) ->
| Some exn_bt ->
unsafe_unsuspend t Backoff.default |> ignore;
Printexc.raise_with_backtrace exn bt
Printexc.raise_with_backtrace (fst exn_bt) (snd exn_bt)
end
else begin
match op with Ignore -> () | Peek -> peek_exn t
Expand Down Expand Up @@ -657,9 +657,9 @@ module Fiber = struct
if Computation.try_attach sleep trigger then
match Trigger.await trigger with
| None -> ()
| Some (exn, bt) ->
| Some exn_bt ->
Computation.finish sleep;
Printexc.raise_with_backtrace exn bt
Printexc.raise_with_backtrace (fst exn_bt) (snd exn_bt)

(* END FIBER COMMON *)
end
Expand Down

0 comments on commit 9ab7b9f

Please sign in to comment.