Zig 0.17.0-dev (Split by item)

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 library itself.

testStaticBitSet

bit_set.testStaticBitSet
fn testStaticBitSet(comptime Set: type) !void

File

lib/std/bit_set.zig:1697

Code

fn testStaticBitSet(comptime Set: type) !void {
    var a = Set.empty;
    var b = Set.full;
    try testing.expectEqual(@as(usize, 0), a.count());
    try testing.expectEqual(@as(usize, Set.bit_length), b.count());

    try testEql(a, b, Set.bit_length);
    try testBitSet(&a, &b, Set.bit_length);

    try testPureBitSet(Set);
}