package batteries

  1. Overview
  2. Docs
A community-maintained standard library extension

Install

Dune Dependency

Authors

Maintainers

Sources

v3.4.0.tar.gz
md5=66b6e0b25769fc2363972c6a6ab6ac33
sha256=584d314cbaa5485e26d08ce87f7d7ff49043d9096101f2641b59def9aa6d7d71

doc/batteries.unthreaded/BatHashtbl/module-type-S/Infix/index.html

Module S.Infix

Infix operators over a BatHashtbl

val (-->) : 'a t -> key -> 'a

tbl-->x returns the current binding of x in tbl, or raises Not_found if no such binding exists. Equivalent to Hashtbl.find tbl x

val (<--) : 'a t -> (key * 'a) -> unit

tbl<--(x, y) adds a binding of x to y in table tbl. Previous bindings for x are not removed, but simply hidden. That is, after performing Hashtbl.remove tbl x, the previous binding for x, if any, is restored. (Same behavior as with association lists.) Equivalent to Hashtbl.add tbl x y

OCaml

Innovation. Community. Security.