authorgravatar for jhc@dismail.deJimmi Holst Christensen <jhc@dismail.de> 2018-07-04 11:35:29+02:00
committergravatar for jhc@dismail.deJimmi Holst Christensen <jhc@dismail.de> 2018-07-04 11:35:29+02:00
log28821b5f31ec3a23d3a5def6ea0d242fdfede422
tree4eb945f8049ea6503e1837b252978eb082f4bf52
parent4f32b86142bec636b9d6be7b72d02b836120eb35

Fixed last commit compiler error


1 files changed, 1 insertions(+), 1 deletions(-)

std/mem.zig+1-1
...@@ -34,7 +34,7 @@ pub const Allocator = struct {...@@ -34,7 +34,7 @@ pub const Allocator = struct {
34 /// Call `destroy` with the result34 /// Call `destroy` with the result
35 pub fn create(self: *Allocator, init: var) Error!*@typeOf(init) {35 pub fn create(self: *Allocator, init: var) Error!*@typeOf(init) {
36 const T = @typeOf(init);36 const T = @typeOf(init);
37 if (@sizeOf(T) == 0) return &T{};37 if (@sizeOf(T) == 0) return &(T{});
38 const slice = try self.alloc(T, 1);38 const slice = try self.alloc(T, 1);
39 const ptr = &slice[0];39 const ptr = &slice[0];
40 ptr.* = init;40 ptr.* = init;