Skip to content

Commit

Permalink
ocamlPackages.uucp: use throw instead of lib.assertMsg
Browse files Browse the repository at this point in the history
This makes the uucp evaluation fail silently for nix-env -qaP
ocaml-ng.ocamlPackages_4_02, as throw messages are not printed to
stderr.
  • Loading branch information
sternenseemann authored and vbgl committed Feb 17, 2021
1 parent 9fbcf91 commit 6b1057b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pkgs/development/ocaml-modules/uucp/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,9 @@ let
doCheck = true;
in

assert lib.assertMsg (lib.versionAtLeast ocaml.version minimumOCamlVersion)
"${pname} needs at least OCaml ${minimumOCamlVersion}";
if !(lib.versionAtLeast ocaml.version minimumOCamlVersion)
then builtins.throw "${pname} needs at least OCaml ${minimumOCamlVersion}"
else

stdenv.mkDerivation {

Expand Down

0 comments on commit 6b1057b

Please sign in to comment.