Module BatFormat


module BatFormat: sig .. end
Pretty printing.

This module extends Stdlib's Format module, go there for documentation on the rest of the functions and types.
Author(s): Pierre Weis (Base module), David Teller



Boxes


Redirecting formatter output

val set_formatter_output : 'a BatIO.output -> unit
val formatter_of_output : 'a BatIO.output -> Format.formatter
formatter_of_output out returns a new formatter that writes to the corresponding output out.
val std_formatter : Format.formatter
The standard formatter used by the formatting functions above. It is defined as formatter_of_output stdout.
val err_formatter : Format.formatter
A formatter to use with formatting functions below for output to standard error. It is defined as formatter_of_output stderr.

Basic functions to use with formatters

val pp_set_formatter_output : Format.formatter -> 'a BatIO.output -> unit
Deprecated

val set_formatter_out_channel : 'a BatIO.output -> unit
Redirect the pretty-printer output to the given channel.
val formatter_of_out_channel : 'a BatIO.output -> Format.formatter
formatter_of_out_channel oc returns a new formatter that writes to the corresponding channel oc.
val pp_set_formatter_out_channel : Format.formatter -> 'a BatIO.output -> unit