Misc.Stdlib.String.Tbl(3)

Manual name check: this page lives in the OCaml library manual, and its title is Misc.Stdlib.String.Tbl(3). okay so bestie, let’s get into it πŸ’–


🌸 NAME 🌸

The entire NAME line is Misc.Stdlib.String.Tbl - no description. That’s it. The manpage is giving mysterious main character energy and refusing to elaborate πŸ˜­πŸ’€.


🧚 Module 🧚

Module Misc.Stdlib.String.Tbl

πŸ’… Documentation πŸ’…

okay so under Documentation we have Module Tbl, and the literal signature line is:

Module Tbl
 : sig end

Then comes the full type-and-value lineup, no cap ✨

  • type key β€” this is the key type, exactly as written. iconic, minimal, unbothered πŸŽ€
  • type !'a t β€” this is the 'a t type, and yes, that exclamation mark is literally part of it. do not touch it πŸ’…

✨ the values, in order, with zero skipped ✨

  • val create : int -> 'a t β€” int goes in, 'a t comes out, per the signature. no extra lore added 🫢
  • val clear : 'a t -> unit β€” 'a t in, unit out. type vibes only πŸ’–
  • val reset : 'a t -> unit β€” 'a t in, unit out again. Since 4.00.
  • val copy : 'a t -> 'a t β€” 'a t in, 'a t out. the signature is doing the talking 🌸
  • val add : 'a t -> key -> 'a -> unit β€” takes 'a t, then key, then 'a, and gives unit. exact type, no invented behavior πŸ¦‹
  • val remove : 'a t -> key -> unit β€” 'a t, then key, then unit. periodt πŸ’…
  • val find_and_remove : 'a t -> key -> 'a option β€” 'a t, then key, then an 'a option. Since 5.5.
  • val find : 'a t -> key -> 'a β€” 'a t, then key, then 'a. the signature said what it said ✨
  • val find_opt : 'a t -> key -> 'a option β€” 'a t, then key, then 'a option. Since 4.05.
  • val find_all : 'a t -> key -> 'a list β€” 'a t, then key, then 'a list. no notes πŸ”₯
  • val replace : 'a t -> key -> 'a -> unit β€” 'a t, key, 'a, and unit. literally right there in the type πŸŽ€
  • val find_and_replace : 'a t -> key -> 'a -> 'a option β€” 'a t, key, 'a, and an 'a option. Since 5.5.
  • val mem : 'a t -> key -> bool β€” 'a t, then key, then bool. slay πŸ¦‹
  • val iter : (key -> 'a -> unit) -> 'a t -> unit β€” takes a (key -> 'a -> unit) function, then 'a t, then gives unit. exact function shape, bestie πŸ’–
  • val filter_map_inplace : (key -> 'a -> 'a option) -> 'a t -> unit β€” takes a (key -> 'a -> 'a option) function, then 'a t, then unit. Since 4.03.
  • val fold : (key -> 'a -> 'acc -> 'acc) -> 'a t -> 'acc -> 'acc β€” takes (key -> 'a -> 'acc -> 'acc), then 'a t, then 'acc, then 'acc. no cap 🌈
  • val length : 'a t -> int β€” 'a t in, int out. cute and typed 🌸
  • val stats : 'a t -> Hashtbl.statistics β€” 'a t in, Hashtbl.statistics out. Since 4.00.
  • val to_seq : 'a t -> (key * 'a) Seq.t β€” 'a t in, (key * 'a) Seq.t out. Since 4.07.
  • val to_seq_keys : 'a t -> key Seq.t β€” 'a t in, key Seq.t out. Since 4.07.
  • val to_seq_values : 'a t -> 'a Seq.t β€” 'a t in, 'a Seq.t out. Since 4.07.
  • val add_seq : 'a t -> (key * 'a) Seq.t -> unit β€” 'a t, then (key * 'a) Seq.t, then unit. Since 4.07.
  • val replace_seq : 'a t -> (key * 'a) Seq.t -> unit β€” 'a t, then (key * 'a) Seq.t, then unit. Since 4.07.
  • val of_seq : (key * 'a) Seq.t -> 'a t β€” (key * 'a) Seq.t in, 'a t out. Since 4.07.

okay bestie, the footer tea: this page is sourced from OCamldoc, dated 2026-06-22, and it’s the Misc.Stdlib.String.Tbl(3) page. bye bestie, go forth and respect the exact signatures πŸ’–βœ¨πŸŽ€

πŸ“¦ where this page comes from