Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
Signed-off-by: Antonio Nuno Monteiro <[email protected]>
  • Loading branch information
anmonteiro committed Mar 17, 2021
1 parent 4991c11 commit 18c3f9d
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions src/dune_engine/sub_dirs.ml
Original file line number Diff line number Diff line change
Expand Up @@ -190,13 +190,12 @@ end

let descendant_path =
Dune_lang.Decoder.plain_string (fun ~loc fn ->
if Filename.is_relative fn then
Path.Local.parse_string_exn ~loc fn |> Path.Local.explode
else
let msg = [ Pp.textf "invalid sub-directory path %S" fn ] in
let hints = [ Pp.textf "subdirectory path must be relative" ]
in
User_error.raise ~loc ~hints msg)
if Filename.is_relative fn then
Path.Local.parse_string_exn ~loc fn |> Path.Local.explode
else
let msg = [ Pp.textf "invalid sub-directory path %S" fn ] in
let hints = [ Pp.textf "subdirectory path must be relative" ] in
User_error.raise ~loc ~hints msg)

let strict_subdir field_name =
let open Dune_lang.Decoder in
Expand Down

0 comments on commit 18c3f9d

Please sign in to comment.