aboutsummaryrefslogtreecommitdiff
path: root/lib/std/Build/Cache
diff options
context:
space:
mode:
authorBenjamin Jurk <106487517+bnjmnjrk@users.noreply.github.com>2025-11-20 23:46:23 +0100
committerGitHub <noreply@github.com>2025-11-20 14:46:23 -0800
commit4b5351bc0ddc248d6935d7d160a57cb4dfe4dedd (patch)
tree8ce84d4e44a8ee1abaf0ef71d8287cec4b0f8c0a /lib/std/Build/Cache
parentdb622f14c445b4f55981636543c546e22346abd5 (diff)
downloadzig-4b5351bc0ddc248d6935d7d160a57cb4dfe4dedd.tar.gz
zig-4b5351bc0ddc248d6935d7d160a57cb4dfe4dedd.zip
update deprecated ArrayListUnmanaged usage (#25958)
Diffstat (limited to 'lib/std/Build/Cache')
-rw-r--r--lib/std/Build/Cache/DepTokenizer.zig12
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/std/Build/Cache/DepTokenizer.zig b/lib/std/Build/Cache/DepTokenizer.zig
index 8221f92dba..4fe61603c8 100644
--- a/lib/std/Build/Cache/DepTokenizer.zig
+++ b/lib/std/Build/Cache/DepTokenizer.zig
@@ -363,7 +363,7 @@ pub const Token = union(enum) {
};
/// Resolve escapes in target or prereq. Only valid with .target_must_resolve or .prereq_must_resolve.
- pub fn resolve(self: Token, gpa: Allocator, list: *std.ArrayListUnmanaged(u8)) error{OutOfMemory}!void {
+ pub fn resolve(self: Token, gpa: Allocator, list: *std.ArrayList(u8)) error{OutOfMemory}!void {
switch (self) {
.target_must_resolve => |bytes| {
var state: enum { start, escape, dollar } = .start;
@@ -429,7 +429,7 @@ pub const Token = union(enum) {
}
}
- pub fn printError(self: Token, gpa: Allocator, list: *std.ArrayListUnmanaged(u8)) error{OutOfMemory}!void {
+ pub fn printError(self: Token, gpa: Allocator, list: *std.ArrayList(u8)) error{OutOfMemory}!void {
switch (self) {
.target, .target_must_resolve, .prereq, .prereq_must_resolve => unreachable, // not an error
.incomplete_quoted_prerequisite,
@@ -1027,8 +1027,8 @@ fn depTokenizer(input: []const u8, expect: []const u8) !void {
defer arena_allocator.deinit();
var it: Tokenizer = .{ .bytes = input };
- var buffer: std.ArrayListUnmanaged(u8) = .empty;
- var resolve_buf: std.ArrayListUnmanaged(u8) = .empty;
+ var buffer: std.ArrayList(u8) = .empty;
+ var resolve_buf: std.ArrayList(u8) = .empty;
var i: usize = 0;
while (it.next()) |token| {
if (i != 0) try buffer.appendSlice(arena, "\n");
@@ -1076,11 +1076,11 @@ fn depTokenizer(input: []const u8, expect: []const u8) !void {
try testing.expectEqualStrings(expect, buffer.items);
}
-fn printCharValues(gpa: Allocator, list: *std.ArrayListUnmanaged(u8), bytes: []const u8) !void {
+fn printCharValues(gpa: Allocator, list: *std.ArrayList(u8), bytes: []const u8) !void {
for (bytes) |b| try list.append(gpa, printable_char_tab[b]);
}
-fn printUnderstandableChar(gpa: Allocator, list: *std.ArrayListUnmanaged(u8), char: u8) !void {
+fn printUnderstandableChar(gpa: Allocator, list: *std.ArrayList(u8), char: u8) !void {
if (std.ascii.isPrint(char)) {
try list.print(gpa, "'{c}'", .{char});
} else {