string_dict

Efficient static string dictionaries
Legend:
Library
Module
Module type
Parameter
Class
Class type
Library string_dict
Module String_dict
type 'a t
val hash_fold_t : ( Base.Hash.state -> 'a -> Base.Hash.state ) -> Base.Hash.state -> 'a t -> Base.Hash.state
val compare : ( 'a -> 'a -> Base.int ) -> 'a t -> 'a t -> Base.int
val sexp_of_t : ( 'a -> Base.Sexp.t ) -> 'a t -> Base.Sexp.t

We don't use [@@deriving sexp], to avoid a circular dependency.

val t_of_sexp : ( Base.Sexp.t -> 'a ) -> Base.Sexp.t -> 'a t
val of_alist : (Base.string * 'a) Base.list -> ( 'a t, Base.string ) Caml.result

Creates a dictionary from an association list. It is an error for the list to contain duplicate keys.

val of_alist_exn : (Base.string * 'a) Base.list -> 'a t
val find : 'a t -> Base.string -> 'a Base.option
val find_exn : 'a t -> Base.string -> 'a
val to_alist : 'a t -> (Base.string * 'a) Base.list