Fpath.Map
Path maps.
type key = path
of_list bs
is List.fold_left (fun m (k, v) -> add k v m) empty
bs
.
add k v m
is m
with k
mapping to l
such that l
is v :: find k m
if k
was bound in m
and [v]
otherwise.
val add_to_set :
(module Stdlib.Set.S with type elt = 'a and type t = 'set) ->
path ->
'a ->
'set t ->
'set t
add (module S) k v m
is m
with k
mapping to s
such that s
is S.add v (find k m)
if k
was bound in m
and S.singleton [v]
otherwise.
pp ~sep pp_binding ppf m
formats the bindings of m
on ppf
. Each binding is formatted with pp_binding
and bindings are separated by sep
(defaults to Format.pp_print_cut
). If the map is empty leaves ppf
untouched.