Skip to content

Commit

Permalink
u3: simplifies u3z_reap() interface
Browse files Browse the repository at this point in the history
  • Loading branch information
joemfb committed Nov 9, 2023
1 parent 778e79a commit fc9deae
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion pkg/noun/manage.c
Original file line number Diff line number Diff line change
Expand Up @@ -1011,7 +1011,7 @@ u3m_love(u3_noun pro)
//
u3j_reap(&jed_u);
u3n_reap(byc_p);
u3z_reap(u3z_memo_keep, per_p);
u3z_reap(per_p);

// pop the stack
//
Expand Down
6 changes: 2 additions & 4 deletions pkg/noun/zave.c
Original file line number Diff line number Diff line change
Expand Up @@ -125,9 +125,7 @@ u3z_uniq(u3z_cid cid, u3_noun som)
/* u3z_reap(): promote memoization cache state.
*/
void
u3z_reap(u3z_cid cid, u3p(u3h_root) har_p)
u3z_reap(u3p(u3h_root) per_p)
{
u3_assert(u3z_memo_toss != cid);

u3h_take_uni(_har(u3R, cid), har_p);
u3h_take_uni(u3R->cax.per_p, per_p);
}
4 changes: 2 additions & 2 deletions pkg/noun/zave.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,10 @@
u3_noun
u3z_uniq(u3z_cid cid, u3_noun som);

/* u3z_reap(): promote memoization cache state.
/* u3z_reap(): promote persistent memoization cache.
*/
void
u3z_reap(u3z_cid cid, u3p(u3h_root) har_p);
u3z_reap(u3p(u3h_root) per_p);

/* u3z_free(): free memoization cache.
*/
Expand Down

0 comments on commit fc9deae

Please sign in to comment.