Skip to content

Commit

Permalink
Fixed default lookup path when project root can't be found
Browse files Browse the repository at this point in the history
  • Loading branch information
AltGr committed Dec 20, 2013
1 parent ad93284 commit 34618b7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/indexOptions.ml
Expand Up @@ -265,10 +265,11 @@ let common_opts : t Term.t =
let lib_info ocamllib (_root,build) (opens,full_opens) context =
let dirs = match build with
| None -> ocamllib
| Some d -> LibIndex.Misc.unique_subdirs (d :: ocamllib)
| Some d -> d :: ocamllib
in
if dirs = [] then
failwith "Failed to guess OCaml / opam lib dirs. Please use `-I'";
let dirs = LibIndex.Misc.unique_subdirs dirs in
let info = LibIndex.load dirs in
let info =
List.fold_left (LibIndex.open_module ~cleanup_path:true) info opens
Expand Down

0 comments on commit 34618b7

Please sign in to comment.