Module Beloch.Session

Incremental evaluation session. Memoizes one Eval.snapshot per statement along Spine's prefix-stable hash chain: on re-eval, the longest matching key prefix is reused and only the divergent suffix is recomputed.

In-memory only (Phase 1).

type t = {
  1. mutable keys : string array;
  2. mutable snaps : Eval.snapshot array;
  3. mutable last_ran : int;
}
val create : unit -> t
val last_ran : t -> int
val eval : t -> filename:string -> string -> Eval.folded