-
Notifications
You must be signed in to change notification settings - Fork 470
Opam constraints operator precedence is not honored. #3431
Copy link
Copy link
Closed
ocaml/opam-repository
#24013Milestone
Description
A depends stanza such as the following one in the dune-project file will output a wrong OPAM constraint expression because logical operator precedence seems to be ignored.
(alcotest
(and
(or :with-test :dev)
(>= 1.1.0)))
Expected Behavior
"alcotest" { (with-test | dev) & >= "1.1.0"}
Actual Behavior
"alcotest" {with-test | dev & >= "1.1.0"}
Reproduction
dune build any project with a dune-project looking like
(lang dune 2.2)
(name coin)
(generate_opam_files true)
(package
(name coin)
(synopsis "COIN")
(depends
(alcotest
(or
(and (>= 1.1.0) :with-test)
(and (>= 1.1.0) :dev))))
and look at the generated coin.opam.
Specifications
- Version of
dune: 2.5.1 - Version of
ocaml: 4.06.0 - Operating system :
Linux 5.4.28-gentoo
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels