Skip to content

Commit

Permalink
zig master updates
Browse files Browse the repository at this point in the history
  • Loading branch information
kivikakk committed Oct 11, 2021
1 parent 167e369 commit 6d9031a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
7 changes: 4 additions & 3 deletions src/main.zig
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
const std = @import("std");
const builtin = @import("builtin");
const assert = std.debug.assert;

const clap = @import("clap");
Expand All @@ -17,7 +18,7 @@ pub fn main() !void {

var allocator: *std.mem.Allocator = undefined;

if (std.builtin.mode == .Debug) {
if (builtin.mode == .Debug) {
gpa = std.heap.GeneralPurposeAllocator(.{}){};
allocator = &gpa.allocator;
} else {
Expand All @@ -26,7 +27,7 @@ pub fn main() !void {
}

defer {
if (std.builtin.mode == .Debug) {
if (builtin.mode == .Debug) {
_ = gpa.deinit();
} else {
arena.deinit();
Expand Down Expand Up @@ -58,7 +59,7 @@ pub fn main() !void {
};
defer allocator.free(output);

if (std.builtin.mode == .Debug) {
if (builtin.mode == .Debug) {
args.deinit();
parser.deinit();
doc.deinit();
Expand Down
2 changes: 1 addition & 1 deletion vendor/libpcre.zig
Submodule libpcre.zig updated 4 files
+3 −1 .gitignore
+2 −1 build.zig
+11 −0 zig.mod
+1 −0 zigmod.lock
2 changes: 1 addition & 1 deletion vendor/zig-clap

0 comments on commit 6d9031a

Please sign in to comment.