terminal: remove errdefer deleted call for refcountedset

This commit is contained in:
Mitchell Hashimoto
2024-07-09 09:07:28 -07:00
parent 8589f2c0fb
commit 54034468b7

View File

@ -237,11 +237,6 @@ pub fn RefCountedSet(
return id; return id;
} }
// Notify the context that the value is "deleted" if we return an
// error. This allows callers to clean up any resources associated
// with the value.
errdefer if (comptime @hasDecl(Context, "deleted")) ctx.deleted(value);
// If the item doesn't exist, we need an available ID. // If the item doesn't exist, we need an available ID.
if (self.next_id >= self.layout.cap) { if (self.next_id >= self.layout.cap) {
// Arbitrarily chosen, threshold for rehashing. // Arbitrarily chosen, threshold for rehashing.