Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source
Page
Library
Module
Module type
Parameter
Class
Class type
Source
PPrint.OCaml
SourceThis module offers document combinators that help print OCaml values. The strings produced by rendering these documents are supposed to be accepted by the OCaml parser as valid values.
These functions do not distinguish between mutable and immutable values. They do not recognize sharing, and do not incorporate a protection against cyclic values.
variant _ dc _ args
represents a constructed value whose data constructor is dc
and whose arguments are args
. The other two parameters are presently unused.
record _ fields
represents a record value whose fields are fields
. The other parameter is presently unused.
tuple args
represents a tuple value whose components are args
.
option f o
represents the option o
. The representation of the element, if present, is computed by the function f
.
list f xs
represents the list xs
. The representation of each element is computed by the function f
. If the whole list fits on a single line, then it is printed on a single line; otherwise each element is printed on a separate line.
flowing_list f xs
represents the list xs
. The representation of each element is computed by the function f
. As many elements are possible are printed on each line.
array f xs
represents the array xs
. The representation of each element is computed by the function f
. If the whole array fits on a single line, then it is printed on a single line; otherwise each element is printed on a separate line.
flowing_array f xs
represents the array xs
. The representation of each element is computed by the function f
. As many elements are possible are printed on each line.
ref r
represents the reference r
. The representation of the content is computed by the function f
.