CamlinternalFormat(3)

✨ CamlinternalFormat(3) ✨

Bestie, welcome to the CamlinternalFormat(3) page from the OCaml library. The manpage opens with no description, so we're keeping it real: the signatures are the main character today. πŸ’…

✨ NAME ✨

CamlinternalFormat - no description.

Like… that's the whole NAME section. No cap. 😭

🧚 Module 🧚

Module CamlinternalFormat

: sig end

🌸 Documentation 🌸

Module CamlinternalFormat

: sig end

Okay so this is the full documentation lineup. Every val, every type, every constructor, every wild type parameter β€” all of it, slaying in order. 🫢

First, the char-set squad:

val is_in_char_set : CamlinternalFormatBasics.char_set -> char -> bool

val rev_char_set : CamlinternalFormatBasics.char_set ->
CamlinternalFormatBasics.char_set

type mutable_char_set = bytes

val create_char_set : unit -> mutable_char_set

val add_in_char_set : mutable_char_set -> char -> unit

val freeze_char_set : mutable_char_set ->
CamlinternalFormatBasics.char_set

Then the param_format_ebb type and the ignored-format glow-up:

type ('a, 'b, 'c, 'd, 'e, 'f) param_format_ebb =
 | Param_format_EBB : ('x -> 'a0, 'b0, 'c0, 'd0, 'e0, 'f0)
CamlinternalFormatBasics.fmt -> ('a0, 'b0, 'c0, 'd0, 'e0, 'f0)
param_format_ebb

val param_format_of_ignored_format : ('a, 'b, 'c, 'd, 'y, 'x)
CamlinternalFormatBasics.ignored -> ('x, 'b, 'c, 'y, 'e, 'f)
CamlinternalFormatBasics.fmt -> ('a, 'b, 'c, 'd, 'e, 'f)
param_format_ebb

Next up, the accumulator types. They're giving recursive variant excellence:

type ('b, 'c) acc_formatting_gen =
 | Acc_open_tag of ('b, 'c) acc
 | Acc_open_box of ('b, 'c) acc

type ('b, 'c) acc =
 | Acc_formatting_lit of ('b, 'c) acc *
CamlinternalFormatBasics.formatting_lit
 | Acc_formatting_gen of ('b, 'c) acc * ('b, 'c) acc_formatting_gen
 | Acc_string_literal of ('b, 'c) acc * string
 | Acc_char_literal of ('b, 'c) acc * char
 | Acc_data_string of ('b, 'c) acc * string
 | Acc_data_char of ('b, 'c) acc * char
 | Acc_delay of ('b, 'c) acc * ('b -> 'c)
 | Acc_flush of ('b, 'c) acc
 | Acc_invalid_arg of ('b, 'c) acc * string
 | End_of_acc

Heterogeneous list moment β€” yes, the heter_list is here and it's iconic:

type ('a, 'b) heter_list =
 | Cons : 'c * ('a0, 'b0) heter_list -> ('c -> 'a0, 'b0) heter_list
 | Nil : ('b1, 'b1) heter_list

Then fmt_ebb and the printf-making crew:

type ('b, 'c, 'e, 'f) fmt_ebb =
 | Fmt_EBB : ('a, 'b0, 'c0, 'd, 'e0, 'f0) CamlinternalFormatBasics.fmt
-> ('b0, 'c0, 'e0, 'f0) fmt_ebb

val make_printf : (('b, 'c) acc -> 'd) -> ('b, 'c) acc -> ('a, 'b, 'c,
'c, 'c, 'd) CamlinternalFormatBasics.fmt -> 'a

val make_iprintf : ('s -> 'f) -> 's -> ('a, 'b, 'c, 'd, 'e, 'f)
CamlinternalFormatBasics.fmt -> 'a

val output_acc : out_channel -> (out_channel, unit) acc -> unit

val bufput_acc : Buffer.t -> (Buffer.t, unit) acc -> unit

val strput_acc : Buffer.t -> (unit, string) acc -> unit

Tiny module moment:

module Args : sig end

And make_lprintf plus the format-typing beauties:

val make_lprintf : (('b, 'c) acc -> 'f) -> ('b, 'c) acc -> ('a, 'b, 'c,
'c, 'c, 'f) CamlinternalFormatBasics.fmt -> ('a, 'f) Args.t -> 'f

val type_format : ('x, 'b, 'c, 't, 'u, 'v) CamlinternalFormatBasics.fmt
-> ('a, 'b, 'c, 'd, 'e, 'f) CamlinternalFormatBasics.fmtty -> ('a, 'b,
'c, 'd, 'e, 'f) CamlinternalFormatBasics.fmt

val fmt_ebb_of_string : ?legacy_behavior:bool -> string -> ('b, 'c, 'e,
'f) fmt_ebb

val format_of_string_fmtty : string -> ('a, 'b, 'c, 'd, 'e, 'f)
CamlinternalFormatBasics.fmtty -> ('a, 'b, 'c, 'd, 'e, 'f)
CamlinternalFormatBasics.format6

val format_of_string_format : string -> ('a, 'b, 'c, 'd, 'e, 'f)
CamlinternalFormatBasics.format6 -> ('a, 'b, 'c, 'd, 'e, 'f)
CamlinternalFormatBasics.format6

Stringify squad, char conversion, and box opening:

val char_of_iconv : CamlinternalFormatBasics.int_conv -> char

val string_of_formatting_lit : CamlinternalFormatBasics.formatting_lit
-> string

val string_of_fmtty : ('a, 'b, 'c, 'd, 'e, 'f)
CamlinternalFormatBasics.fmtty -> string

val string_of_fmt : ('a, 'b, 'c, 'd, 'e, 'f)
CamlinternalFormatBasics.fmt -> string

val open_box_of_string : string -> int *
CamlinternalFormatBasics.block_type

Finally, the fmtty_rel girlies: symm, trans, and recast. Very type-parameter-heavy, very demure:

val symm : ('a1, 'b1, 'c1, 'd1, 'e1, 'f1, 'a2, 'b2, 'c2, 'd2, 'e2, 'f2)
CamlinternalFormatBasics.fmtty_rel -> ('a2, 'b2, 'c2, 'd2, 'e2, 'f2,
'a1, 'b1, 'c1, 'd1, 'e1, 'f1) CamlinternalFormatBasics.fmtty_rel

val trans : ('a1, 'b1, 'c1, 'd1, 'e1, 'f1, 'a2, 'b2, 'c2, 'd2, 'e2, 'f2)
CamlinternalFormatBasics.fmtty_rel -> ('a2, 'b2, 'c2, 'd2, 'e2, 'f2,
'a3, 'b3, 'c3, 'd3, 'e3, 'f3) CamlinternalFormatBasics.fmtty_rel ->
('a1, 'b1, 'c1, 'd1, 'e1, 'f1, 'a3, 'b3, 'c3, 'd3, 'e3, 'f3)
CamlinternalFormatBasics.fmtty_rel

val recast : ('a1, 'b1, 'c1, 'd1, 'e1, 'f1) CamlinternalFormatBasics.fmt
-> ('a1, 'b1, 'c1, 'd1, 'e1, 'f1, 'a2, 'b2, 'c2, 'd2, 'e2, 'f2)
CamlinternalFormatBasics.fmtty_rel -> ('a2, 'b2, 'c2, 'd2, 'e2, 'f2)
CamlinternalFormatBasics.fmt

And that's the whole page. No hidden surprise options, because there are literally no options here β€” just signatures and vibes. ✨


Bestie sign-off: this page is brought to you by OCamldoc, dated 2026-06-22, and yes, it's still CamlinternalFormat(3). Periodt. πŸ’…πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from