Module PPrintOCaml
A set of functions that construct representations of OCaml values.
type constructor= stringtype type_name= stringtype record_field= stringtype tag= inttype representation= PPrintEngine.documentA representation of a value is a
PPrintdocument.
val variant : type_name -> constructor -> tag -> representation list -> representationvariant _ dc _ argsis a description of a constructed value whose data constructor isdcand whose arguments areargs. The other two parameters are presently unused.
val record : type_name -> (record_field * representation) list -> representationrecord _ fieldsis a description of a record value whose fields arefields. The other parameter is presently unused.
val tuple : representation list -> representationtuple argsis a description of a tuple value whose components areargs.
val string : string -> representationstring sis a representation of the strings.
val int : int -> representationint iis a representation of the integeri.
val int32 : int32 -> representationint32 iis a representation of the 32-bit integeri.
val int64 : int64 -> representationint64 iis a representation of the 64-bit integeri.
val nativeint : nativeint -> representationnativeint iis a representation of the native integeri.
val float : float -> representationfloat fis a representation of the floating-point numberf.
val char : char -> representationchar cis a representation of the characterc.
val bool : bool -> representationbool bis a representation of the Boolenan valueb.
val option : ('a -> representation) -> 'a option -> representationoption f ois a representation of the optiono, where the representation of the element, if present, is computed by the functionf.
val list : ('a -> representation) -> 'a list -> representationlist f xsis a representation of the listxs, where the representation of each element is computed by the functionf.
val array : ('a -> representation) -> 'a array -> representationarray f xsis a representation of the arrayxs, where the representation of each element is computed by the functionf.
val ref : ('a -> representation) -> 'a Stdlib.ref -> representationref ris a representation of the referencer, where the representation of the content is computed by the functionf.
val unknown : type_name -> 'a -> representationunknown t _is a representation of an unknown value of typet.