Skip to content

Commit

Permalink
refactor(pkg): use [Stdune] more (#11249)
Browse files Browse the repository at this point in the history
Signed-off-by: Rudi Grinberg <[email protected]>
  • Loading branch information
rgrinberg authored Dec 27, 2024
1 parent 3e93d6a commit 4f15a12
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/opam-0install/lib/solver.ml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
open Stdune
open Fiber.O
open Pp.O

Expand Down Expand Up @@ -66,7 +67,7 @@ module Make (Context : S.CONTEXT) = struct
;;

let diagnostics_rolemap req =
Solver.do_solve req ~closest_match:true >>| Option.get >>= Diagnostics.of_result
Solver.do_solve req ~closest_match:true >>| Option.value_exn >>= Diagnostics.of_result
;;

let diagnostics ?(verbose = false) req =
Expand All @@ -80,6 +81,6 @@ module Make (Context : S.CONTEXT) = struct
Solver.Output.to_map sels
|> Solver.Output.RoleMap.to_seq
|> List.of_seq
|> List.filter_map (fun (_role, sel) -> Input.version (Solver.Output.unwrap sel))
|> List.filter_map ~f:(fun (_role, sel) -> Input.version (Solver.Output.unwrap sel))
;;
end

0 comments on commit 4f15a12

Please sign in to comment.