std: fifo.deinit didn't need to take a pointer

This commit is contained in:
daurnimator 2019-11-23 17:57:17 +11:00
parent 3062e0e932
commit b4091e3aec
No known key found for this signature in database
GPG Key ID: 45B429A8F9D9D22A

View File

@ -78,9 +78,8 @@ pub fn LinearFifo(
},
};
pub fn deinit(self: *Self) void {
pub fn deinit(self: Self) void {
if (buffer_type == .Dynamic) self.allocator.free(self.buf);
self.* = undefined;
}
pub fn realign(self: *Self) void {