deinit
Function parameters
Parameters
- d:*Diagnostics
Type definitions in this namespace
Types
- Diagnostics
- Provide this to receive detailed error messages.
- PipeOptions
- pipeToFileSystem options
- FileKind
- Type of the file returned by iterator `next` method.
- Iterator
- Iterator over entries in the tar file represented by reader.
Saves tar file content to the file systems.
Functions
- pipeToFileSystem
- Saves tar file content to the file systems.
Source
Implementation
pub fn deinit(d: *Diagnostics) void {
for (d.errors.items) |item| {
switch (item) {
.unable_to_create_sym_link => |info| {
d.allocator.free(info.file_name);
d.allocator.free(info.link_name);
},
.unable_to_create_file => |info| {
d.allocator.free(info.file_name);
},
.unsupported_file_type => |info| {
d.allocator.free(info.file_name);
},
.components_outside_stripped_prefix => |info| {
d.allocator.free(info.file_name);
},
}
}
d.errors.deinit(d.allocator);
d.allocator.free(d.root_dir);
d.* = undefined;
}