replace %defer with errdefer

See #632

now we have 1 less sigil
This commit is contained in:
Andrew Kelley
2018-01-23 23:08:09 -05:00
parent ad2527d47a
commit b3a6faf13e
21 changed files with 87 additions and 89 deletions

View File

@@ -71,7 +71,7 @@ pub const NullTerminated2DArray = struct {
byte_count += index_size;
const buf = try allocator.alignedAlloc(u8, @alignOf(?&u8), byte_count);
%defer allocator.free(buf);
errdefer allocator.free(buf);
var write_index = index_size;
const index_buf = ([]?&u8)(buf);