Skip to content

Commit ff757df

Browse files
committed
More warnings.
1 parent 877182b commit ff757df

File tree

4 files changed

+10
-6
lines changed

4 files changed

+10
-6
lines changed

analysis/src/Commands.ml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -245,14 +245,16 @@ let format ~path =
245245
in
246246
if List.length diagnostics > 0 then ""
247247
else
248-
Res_printer.printImplementation !Res_cli.ResClflags.width structure
249-
comments
248+
Res_printer.printImplementation ~width:!Res_cli.ResClflags.width ~comments
249+
structure
250250
else if Filename.check_suffix path ".resi" then
251251
let {Res_driver.parsetree = signature; comments; diagnostics} =
252252
Res_driver.parsingEngine.parseInterface ~forPrinter:true ~filename:path
253253
in
254254
if List.length diagnostics > 0 then ""
255-
else Res_printer.printInterface !Res_cli.ResClflags.width signature comments
255+
else
256+
Res_printer.printInterface ~width:!Res_cli.ResClflags.width ~comments
257+
signature
256258
else ""
257259

258260
let test ~path =

analysis/src/CreateInterface.ml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,8 @@ let printSignature ~extractor ~signature =
108108
let rec processSignature ~indent (signature : Types.signature) : unit =
109109
match signature with
110110
| Sig_value
111-
( makePropsId (* makeProps *),
111+
( makePropsId
112+
(* makeProps *),
112113
{val_loc = makePropsLoc; val_type = makePropsType} )
113114
:: Sig_value (makeId (* make *), makeValueDesc) :: rest
114115
when Ident.name makePropsId = Ident.name makeId ^ "Props"

analysis/src/Files.ml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ let relpath base path =
4141
let maybeStat path =
4242
try Some (Unix.stat path) with Unix.Unix_error (Unix.ENOENT, _, _) -> None
4343

44-
let readFile ~filename =
44+
let readFile filename =
4545
try
4646
(* windows can't use open_in *)
4747
let chan = open_in_bin filename in
@@ -51,6 +51,7 @@ let readFile ~filename =
5151
with _ -> None
5252

5353
let exists path = match maybeStat path with None -> false | Some _ -> true
54+
5455
let ifExists path = if exists path then Some path else None
5556

5657
let readDirectory dir =

analysis/src/dune

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
; The main module that will become the binary.
55
(name Cli)
66
(flags
7-
(-w "+26+27+32+33+39")
7+
(-w "+6+26+27+32+33+39")
88
(-open Compilerlibs406)
99
(-open Jsonlib)
1010
(-open Outcomeprinter))

0 commit comments

Comments
 (0)