Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix dependencies incorrectly dropped when specified with select #2665

Merged
merged 1 commit into from
Sep 23, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 9 additions & 3 deletions src/dune/lib.ml
Original file line number Diff line number Diff line change
Expand Up @@ -1184,15 +1184,21 @@ end = struct
in
(acc_res, acc_selects, acc_re_exports)
| Direct (loc, name) ->
let res =
let acc_res =
let+ lib = resolve_dep db name ~allow_private_deps ~loc ~stack
and+ acc_res = acc_res in
lib :: acc_res
in
(res, acc_selects, acc_re_exports)
(acc_res, acc_selects, acc_re_exports)
| Select select ->
let res, resolved_select = resolve_select select in
(res, resolved_select :: acc_selects, acc_re_exports))
let acc_res =
let+ res = res
and+ acc_res = acc_res
in
List.rev_append res acc_res
in
(acc_res, resolved_select :: acc_selects, acc_re_exports))
in
let res = Result.map ~f:List.rev res in
let re_exports = Result.map ~f:List.rev re_exports in
Expand Down