From 20e7cc8d88dc1490d8635db0e6f96fff194763e6 Mon Sep 17 00:00:00 2001 From: Andrew Kelley Date: Tue, 23 Jun 2026 22:40:09 -0700 Subject: [PATCH] std.Build.Cache: bump max number of prefixes --- lib/compiler/Maker.zig | 2 +- lib/std/Build/Cache.zig | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/compiler/Maker.zig b/lib/compiler/Maker.zig index 9f90bf0722fc221569b8e756abd205511797fdbc..42c5a80f588fc1665ebc78a015c776033cbf199c 100644 --- a/lib/compiler/Maker.zig +++ b/lib/compiler/Maker.zig @@ -566,9 +566,9 @@ pub fn main(init: process.Init.Minimal) !void { }; graph.cache.addPrefix(.{ .path = null, .handle = cwd }); graph.cache.addPrefix(graph.build_root_directory); - graph.cache.addPrefix(zig_lib_directory); graph.cache.addPrefix(graph.local_cache_root); graph.cache.addPrefix(global_cache_directory); + graph.cache.addPrefix(zig_lib_directory); graph.cache.hash.addBytes(builtin.zig_version_string); const NO_COLOR = EnvVar.NO_COLOR.isSet(&graph.environ_map); diff --git a/lib/std/Build/Cache.zig b/lib/std/Build/Cache.zig index 68f5cfc49af5e8e48724db42455115313108f9e1..724c1fc4322c7761583b6125c6d16146613790da 100644 --- a/lib/std/Build/Cache.zig +++ b/lib/std/Build/Cache.zig @@ -28,7 +28,7 @@ mutex: Io.Mutex = .init, /// are replaced with single-character indicators. This is not to save /// space but to eliminate absolute file paths. This improves portability /// and usefulness of the cache for advanced use cases. -prefixes_buffer: [4]Directory = undefined, +prefixes_buffer: [5]Directory = undefined, prefixes_len: usize = 0, /// Used to identify prefixes. References external memory. cwd: []const u8, -- 2.54.0