Skip to content

Commit 7ac4a09

Browse files
committed
refactor: add libs/datastructures
1 parent dfdd93e commit 7ac4a09

File tree

8 files changed

+18
-5
lines changed

8 files changed

+18
-5
lines changed

β€Ž2024/day12.zigβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
const std = @import("std");
22
const aoc = @import("aoc");
33
const t = @import("term");
4-
const VectorSet = @import("./VectorSet.zig").VectorSet;
4+
const VectorSet = @import("datastructures").VectorSet;
55

66
const DAY: u8 = 12;
77
const Allocator = std.mem.Allocator;

β€Ž2024/day20.zigβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
const std = @import("std");
22
const aoc = @import("aoc");
33
const t = @import("term");
4-
const VectorSet = @import("./VectorSet.zig").VectorSet;
4+
const VectorSet = @import("datastructures").VectorSet;
55

66
const DAY: u8 = 20;
77
const Allocator = std.mem.Allocator;

β€Ž2024/day6.zigβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
const std = @import("std");
22
const aoc = @import("aoc");
33
const t = @import("term");
4-
const VectorSet = @import("./VectorSet.zig").VectorSet;
4+
const VectorSet = @import("datastructures").VectorSet;
55

66
const DAY: u8 = 6;
77
const Allocator = std.mem.Allocator;

β€Ž2025/SUMMARY.mdβ€Ž

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# AoC 2025
2+
### Notes & Comments
3+
4+
## Day 1
File renamed without changes.

β€Žbuild.zigβ€Ž

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,15 @@ const BuildTargetResults = struct {
99
tests: *std.Build.Step.Compile,
1010
};
1111

12-
fn createBuildTarget(b: *std.Build, target: std.Build.ResolvedTarget, optimize: std.builtin.OptimizeMode, aoc_module: *std.Build.Module, libs: *std.StringHashMap(*std.Build.Module), year: u16, day: usize) !BuildTargetResults {
12+
fn createBuildTarget(
13+
b: *std.Build,
14+
target: std.Build.ResolvedTarget,
15+
optimize: std.builtin.OptimizeMode,
16+
aoc_module: *std.Build.Module,
17+
libs: *std.StringHashMap(*std.Build.Module),
18+
year: u16,
19+
day: usize,
20+
) !BuildTargetResults {
1321
var src_buf: [32]u8 = undefined;
1422
const source_file = try std.fmt.bufPrint(&src_buf, "{d}/day{d}.zig", .{ year, day });
1523

@@ -66,7 +74,7 @@ pub fn build(b: *std.Build) !void {
6674

6775
var libs = std.StringHashMap(*std.Build.Module).init(b.allocator);
6876

69-
const lib_names = .{ "ppm", "math", "svg", "term" };
77+
const lib_names = .{ "ppm", "math", "svg", "term", "datastructures" };
7078
inline for (0..lib_names.len) |i| {
7179
const lib_name = lib_names[i];
7280
const module = b.addModule(lib_name, .{

β€Žlibs/datastructures.zigβ€Ž

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
pub const VectorSet = @import("./datastructures/VectorSet.zig").VectorSet;
File renamed without changes.

0 commit comments

Comments
Β (0)