mirror of
https://github.com/c-cube/sidekick.git
synced 2025-12-10 05:03:59 -05:00
fix(model builder): allow multiple add
This commit is contained in:
parent
d741b4160d
commit
47a0b075f0
1 changed files with 4 additions and 4 deletions
|
|
@ -37,10 +37,10 @@ let require_eval (self : t) t : unit =
|
||||||
let mem self t : bool = T.Tbl.mem self.m t
|
let mem self t : bool = T.Tbl.mem self.m t
|
||||||
|
|
||||||
let add (self : t) ?(subs = []) t v : unit =
|
let add (self : t) ?(subs = []) t v : unit =
|
||||||
assert (not @@ T.Tbl.mem self.m t);
|
if not @@ T.Tbl.mem self.m t then (
|
||||||
T.Tbl.add self.m t v;
|
T.Tbl.add self.m t v;
|
||||||
List.iter (fun u -> require_eval self u) subs;
|
List.iter (fun u -> require_eval self u) subs
|
||||||
()
|
)
|
||||||
|
|
||||||
type eval_cache = Term.Internal_.cache
|
type eval_cache = Term.Internal_.cache
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue