Zig 0.17.0-dev (Split by item)

Shortcut keys
?
Show these tips
S
Focus search field
Esc
Clear focus & close tips
U
Jump to source code
↑
Move up in search results
↓
Move down in search results
↵
Go to active search result
This is an example of documentation generated by ZigDoc, an alternative to Zig's built-in Auto Doc feature. See also examples in other modes/formats. The project being documented here (as the example) is the Zig standard library. Public Function

serveRunFuzzTestMessage

Public Function
std.zig.Client.serveRunFuzzTestMessage
pub fn serveRunFuzzTestMessage(
    c: *const Client,
    test_names: []const []const u8,
    kind: std.Build.abi.fuzz.LimitKind,
    amount_or_instance: u64,
) !void

Params

File

zig/Client.zig:138
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
pub fn serveRunFuzzTestMessage(
    c: *const Client,
    test_names: []const []const u8,
    kind: std.Build.abi.fuzz.LimitKind,
    amount_or_instance: u64,
) !void {
    try c.serveMessageHeader(.{
        .tag = .start_fuzzing,
        .bytes_len = 1 + 8 + 4 + count: {
            var bytes_len: u32 = @intCast(test_names.len * 4);
            for (test_names) |name| {
                bytes_len += @intCast(name.len);
            }
            break :count bytes_len;
        },
    });
    try c.out.writeByte(@backingInt(kind));
    try c.out.writeInt(u64, amount_or_instance, .little);
    try c.out.writeInt(u32, @intCast(test_names.len), .little);
    for (test_names) |test_name| {
        try c.out.writeInt(u32, @intCast(test_name.len), .little);
        try c.out.writeAll(test_name);
    }
    try c.out.flush();
}