base

Full standard library replacement for OCaml
IN THIS PACKAGE
type t =
| T : 'a Caml.ref * 'a -> t
val set : t -> unit

set (T (r, x)) is equivalent to r := x.

val sets : t list -> unit

sets ts = List.iter ts ~f:set

val snapshot : t -> t

snapshot (T (r, _)) returns T (r, !r).