dom: remove useless deinit from html_collection

This commit is contained in:
Pierre Tachoire
2023-11-17 17:37:02 +01:00
parent dd28204797
commit 9acf3fb209

View File

@@ -20,13 +20,6 @@ const Match = union(enum) {
inline else => |case| return case.match(node),
}
}
pub fn deinit(self: Match, allocator: std.mem.Allocator) void {
_ = allocator;
switch (self) {
inline else => return,
}
}
};
pub const MatchByTagName = struct {
@@ -102,10 +95,6 @@ pub const HTMLCollection = struct {
cur_idx: ?u32 = undefined,
cur_node: ?*parser.Node = undefined,
pub fn deinit(self: *HTMLCollection, allocator: std.mem.Allocator) void {
self.match.deinit(allocator);
}
// get_next iterates over the DOM tree to return the next following node or
// null at the end.
//