Skip to content

Commit

Permalink
diffing: add parentheses in functor (sig end)
Browse files Browse the repository at this point in the history
  • Loading branch information
Octachron committed Dec 15, 2020
1 parent 4a3d180 commit bc2b23c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion testsuite/tests/typing-modules/functors.ml
Original file line number Diff line number Diff line change
Expand Up @@ -1569,7 +1569,7 @@ Error: Signature mismatch:
functor (Arg : $S1) (X : $S2) (Res : X.T) (Res : X.T) (Res :
X.T) -> ...
is not included in
functor sig end (X : $T2) X.T X.T -> ...
functor (sig end) (X : $T2) X.T X.T -> ...
1. Module types do not match:
$S1 = sig type wrong end
does not include
Expand Down
2 changes: 2 additions & 0 deletions typing/includemod.ml
Original file line number Diff line number Diff line change
Expand Up @@ -1401,6 +1401,8 @@ module Pp = struct

let functor_param x = match Short_name.functor_param x with
| Short_name.Unit -> Format.dprintf "()"
| Short_name.Named (None, Original (Mty_signature []) ) ->
Format.dprintf "(sig end)"
| Short_name.Named (None, short_mty) ->
Short_name.pp dmodtype short_mty
| Short_name.Named (Some p, short_mty) ->
Expand Down

0 comments on commit bc2b23c

Please sign in to comment.