Merge pull request #1108 from rgrinberg/fix-1107

Fix #1107
This commit is contained in:
Rudi Grinberg 2018-08-07 13:06:24 +03:00 committed by GitHub
commit 0ec0f4d279
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 1 deletions

View File

@ -9,6 +9,9 @@ next
- Fix duplicate profile argument in suggested command when an external library
is missing (#1109, #1106, @emillon)
- Fix #1107. `-opaque` wasn't correctly being added to modules without
an interface. (#1108, fix #1107, @rgrinberg)
1.1.0 (06/08/2018)
------------------

View File

@ -88,7 +88,9 @@ let build_cm cctx ?sandbox ?(dynlink=true) ~dep_graphs ~cm_kind (m : Module.t) =
SC.add_rule sctx (Build.symlink ~src:in_obj_dir ~dst:in_dir))
end;
let opaque_arg =
if opaque && cm_kind = Cmi then
let intf_only = cm_kind = Cmi && not (Module.has_impl m) in
if opaque
|| (intf_only && Ocaml_version.supports_opaque_for_mli ctx.version) then
Arg_spec.A "-opaque"
else
As []