bikeshed: rename util.allocator to util.gpa

This is less typing and more clear. A definite win.
This commit is contained in:
Isaac Freund
2020-06-19 14:31:53 +02:00
parent aae89356a1
commit 12d34d4ded
18 changed files with 47 additions and 47 deletions

View File

@ -51,7 +51,7 @@ pub fn init(self: *Self, server: *Server) !void {
self.seats = std.TailQueue(Seat).init();
const seat_node = try util.allocator.create(std.TailQueue(Seat).Node);
const seat_node = try util.gpa.create(std.TailQueue(Seat).Node);
try seat_node.data.init(self, default_seat_name);
self.default_seat = &seat_node.data;
self.seats.prepend(seat_node);
@ -78,7 +78,7 @@ pub fn init(self: *Self, server: *Server) !void {
pub fn deinit(self: *Self) void {
while (self.seats.pop()) |seat_node| {
seat_node.data.deinit();
util.allocator.destroy(seat_node);
util.gpa.destroy(seat_node);
}
}