package soteria

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Tiny_values.Save_counter

include Soteria.Soteria_std.Reversible.Mutable with type t = int ref
type t = int ref
val init : unit -> t

Create a new reversible state initialized with the default value.

val backtrack_n : t -> int -> unit

Remove the last n checkpoints from state.

val save : t -> unit

Save the current state as a new checkpoint.

val reset : t -> unit

Clear all checkpoints and reset to the default value.