summaryrefslogtreecommitdiffstats
path: root/struct.c
diff options
context:
space:
mode:
Diffstat (limited to 'struct.c')
-rw-r--r--struct.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/struct.c b/struct.c
index 693c20dc..27853839 100644
--- a/struct.c
+++ b/struct.c
@@ -882,6 +882,9 @@ static loc lookup_slot(val inst, struct struct_inst *si, val sym)
val key = cons(sym, num_fast(id));
val sl = gethash(slot_hash, key);
cnum slnum = coerce(cnum, sl) >> TAG_SHIFT;
+
+ rcyc_cons(key);
+
if (sl) {
cache_set_insert(*set, id, slnum);
if (slnum >= STATIC_SLOT_BASE) {
@@ -904,6 +907,8 @@ static loc lookup_slot(val inst, struct struct_inst *si, val sym)
sym->s.slot_cache = slot_cache;
+ rcyc_cons(key);
+
if (sl) {
cache_set_insert(*set, id, slnum);
if (slnum >= STATIC_SLOT_BASE) {
@@ -934,6 +939,9 @@ static struct stslot *lookup_static_slot_desc(struct struct_type *st, val sym)
val key = cons(sym, num_fast(id));
val sl = gethash(slot_hash, key);
cnum slnum = coerce(cnum, sl) >> TAG_SHIFT;
+
+ rcyc_cons(key);
+
if (sl) {
cache_set_insert(*set, id, slnum);
if (slnum >= STATIC_SLOT_BASE)
@@ -951,6 +959,8 @@ static struct stslot *lookup_static_slot_desc(struct struct_type *st, val sym)
sym->s.slot_cache = slot_cache;
+ rcyc_cons(key);
+
if (sl) {
cache_set_insert(*set, id, slnum);
if (slnum >= STATIC_SLOT_BASE)
@@ -1318,6 +1328,8 @@ val static_slot_p(val type, val sym)
val sl = gethash(slot_hash, key);
cnum slnum = coerce(cnum, sl) >> TAG_SHIFT;
+ rcyc_cons(key);
+
if (sl && slnum >= STATIC_SLOT_BASE)
return t;
}