aboutsummaryrefslogtreecommitdiff
path: root/lib/pp.mli
diff options
context:
space:
mode:
authorEmilio Jesus Gallego Arias2016-12-05 18:17:46 +0100
committerEmilio Jesus Gallego Arias2017-03-21 15:51:38 +0100
commita8ec2dc5c330ded1ba400ef202c57e68d2533312 (patch)
treef333e6c9367c51f7a3c208413d3fb607916a724e /lib/pp.mli
parent6885a398229918865378ea24f07d93d2bcdd2802 (diff)
[pp] Remove special tag type and handler from Pp.
For legacy reasons, pretty printing required to provide a "tag" interpretation function `pp_tag`. However such function was not of much use as the backends (richpp and terminal) hooked at the `Format.tag` level. We thus remove this unused indirection layer and annotate expressions with their `Format` tags. This is a step towards moving the last bit of terminal code out of the core system.
Diffstat (limited to 'lib/pp.mli')
-rw-r--r--lib/pp.mli10
1 files changed, 4 insertions, 6 deletions
diff --git a/lib/pp.mli b/lib/pp.mli
index 12747d3a1d..ff42065349 100644
--- a/lib/pp.mli
+++ b/lib/pp.mli
@@ -33,7 +33,7 @@
(************************************************************************)
(* XXX: Improve and add attributes *)
-type pp_tag = string list
+type pp_tag = string
type block_type =
| Pp_hbox of int
@@ -165,9 +165,7 @@ val pr_loc : Loc.t -> std_ppcmds
(** {6 Main renderers, to formatter and to string } *)
-(** FIXME: These ignore the logging settings and call [Format] directly *)
-type tag_handler = pp_tag -> Format.tag
-
(** [msg_with fmt pp] Print [pp] to [fmt] and don't flush [fmt] *)
-val pp_with : ?pp_tag:tag_handler -> Format.formatter -> std_ppcmds -> unit
-val string_of_ppcmds : ?pp_tag:tag_handler -> std_ppcmds -> string
+val pp_with : Format.formatter -> std_ppcmds -> unit
+
+val string_of_ppcmds : std_ppcmds -> string