mirror of
https://github.com/c-cube/ocaml-containers.git
synced 2025-12-06 11:15:31 -05:00
use neat trick to alias properly type of Format
This commit is contained in:
parent
53137a6183
commit
1b9c014e25
1 changed files with 4 additions and 5 deletions
|
|
@ -7,11 +7,10 @@
|
|||
|
||||
type 'a sequence = ('a -> unit) -> unit
|
||||
|
||||
include module type of Format
|
||||
with type formatter = Format.formatter
|
||||
and type formatter_out_functions = Format.formatter_out_functions
|
||||
and type formatter_tag_functions = Format.formatter_tag_functions
|
||||
|
||||
(* include Format, and alias all its types.
|
||||
see https://discuss.ocaml.org/t/extend-existing-module/1389/4
|
||||
*)
|
||||
include module type of struct include Format end
|
||||
|
||||
type t = Format.formatter
|
||||
type 'a printer = t -> 'a -> unit
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue