Former-commit-id: b7d8fe2f35
This commit is contained in:
Jarred Sumner
2021-05-09 18:57:48 -07:00
parent ae90b3deea
commit 166c353ddb
12 changed files with 892 additions and 269 deletions

View File

@@ -14,6 +14,10 @@ pub const MutableString = struct {
};
}
pub fn deinit(str: *MutableString) void {
str.list.deinit(str.allocator);
}
pub fn growIfNeeded(self: *MutableString, amount: usize) !void {
try self.list.ensureUnusedCapacity(self.allocator, amount);
}