InternPool: fix more key lifetime issues

Reminder to look into deleting `get` and make keys less pointery and
more long lived.
This commit is contained in:
Jacob Young
2023-06-01 19:48:36 -04:00
committed by Andrew Kelley
parent 9b48fc2833
commit 8299ddfe4f
3 changed files with 9 additions and 7 deletions

View File

@@ -2119,7 +2119,8 @@ pub const Value = struct {
if (try (try val.elemValue(mod, index)).anyUndef(mod)) break true;
} else false,
},
.aggregate => |aggregate| for (aggregate.storage.values()) |elem| {
.aggregate => |aggregate| for (0..aggregate.storage.values().len) |i| {
const elem = mod.intern_pool.indexToKey(val.toIntern()).aggregate.storage.values()[i];
if (try anyUndef(elem.toValue(), mod)) break true;
} else false,
else => false,