summaryrefslogtreecommitdiff
path: root/day_07.zig
diff options
context:
space:
mode:
authorChristian Segundo2022-12-07 22:38:25 +0100
committerChristian Segundo2022-12-07 22:38:25 +0100
commit05da5d5b839eabb430f24afb5adf410a52b55f8c (patch)
treeb0d2b4c7046450a6a88a878184dc7a9ff373d206 /day_07.zig
parentbe2c84d0f69c3cb9dc747a61a782e9fcd8ca7b4d (diff)
downloadadvent-of-zig-2022-05da5d5b839eabb430f24afb5adf410a52b55f8c.tar.gz
remove bogus block
Diffstat (limited to 'day_07.zig')
-rw-r--r--day_07.zig8
1 files changed, 1 insertions, 7 deletions
diff --git a/day_07.zig b/day_07.zig
index e11fe2f..8c2658e 100644
--- a/day_07.zig
+++ b/day_07.zig
@@ -82,13 +82,7 @@ fn build_tree(allocator: std.mem.Allocator, root: *Node, input: []const u8) !voi
if (std.mem.eql(u8, line[0..3], "dir")) break :blk NodeType.Dir;
break :blk NodeType.File;
},
- .Size = blk: {
- break :blk std.fmt.parseInt(
- usize,
- line[0..std.mem.indexOf(u8, line, " ").?],
- 0,
- ) catch 0;
- },
+ .Size = std.fmt.parseInt(usize, line[0..std.mem.indexOf(u8, line, " ").?], 0) catch 0,
};
current_root.*.append(node);
}