opam-file-format
opam-file-format copied to clipboard
OpamPrinter.format_value does not handle precedence
Hi,
When passed to OpamPrinter.format_value
, the expression (a | b) & c
is printed as a | b & c
, which is equivalent to a | (b & c)
. The function does not seem to have any way of printing parentheses (but the corresponding function in opam-format
seems to work).
See ocaml/dune#3431.
Thanks!