Skip to content

Commit

Permalink
Pick used instead of choose for the First
Browse files Browse the repository at this point in the history
  • Loading branch information
clarus committed Mar 11, 2015
1 parent 9f95743 commit cc63e34
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ioSystem.ml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ let join (x : 'a Lwt.t) (y : 'b Lwt.t) : ('a * 'b) Lwt.t =

(** First. *)
let first (x : 'a Lwt.t) (y : 'b Lwt.t) : ('a, 'b) Sum.t Lwt.t =
Lwt.choose [
Lwt.pick [
Lwt.bind x (fun x -> Lwt.return @@ Sum.Left x);
Lwt.bind y (fun y -> Lwt.return @@ Sum.Right y)]

Expand Down

0 comments on commit cc63e34

Please sign in to comment.