aboutsummaryrefslogtreecommitdiff
path: root/lib/std/Build/Cache.zig
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2024-07-11 18:28:05 -0700
committerAndrew Kelley <andrew@ziglang.org>2024-07-12 00:15:11 -0700
commit5a34e6c3e608e1f526bababd3a2a146f6216d045 (patch)
tree154864ee4b7841598494d5c4a5449b38de09ed3c /lib/std/Build/Cache.zig
parenta3c20dffaed77727494d34f7b4b03c0d10771270 (diff)
downloadzig-5a34e6c3e608e1f526bababd3a2a146f6216d045.tar.gz
zig-5a34e6c3e608e1f526bababd3a2a146f6216d045.zip
frontend: add file system inputs for incremental cache mode
These are also used for whole cache mode in the case that any compile errors are emitted.
Diffstat (limited to 'lib/std/Build/Cache.zig')
-rw-r--r--lib/std/Build/Cache.zig1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/std/Build/Cache.zig b/lib/std/Build/Cache.zig
index 8ba2f9f128..fe2a6b0a83 100644
--- a/lib/std/Build/Cache.zig
+++ b/lib/std/Build/Cache.zig
@@ -1010,6 +1010,7 @@ pub const Manifest = struct {
pub fn populateFileSystemInputs(man: *Manifest, buf: *std.ArrayListUnmanaged(u8)) Allocator.Error!void {
assert(@typeInfo(std.zig.Server.Message.PathPrefix).Enum.fields.len == man.cache.prefixes_len);
+ buf.clearRetainingCapacity();
const gpa = man.cache.gpa;
const files = man.files.keys();
if (files.len > 0) {