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.
Zig › std/ › zig/ › llvm/ › BitcodeReader.zig › Block
Block
BitcodeReader.Block
pub const Block = struct
File
Code
pub const Block = struct {
name : []const u8 ,
id : u32 ,
len : u32 ,
const block_info : u32 = 0 ;
const first_reserved : u32 = 1 ;
const last_standard : u32 = 7 ;
const Info = struct {
block_name : []const u8 ,
record_names : std .AutoHashMapUnmanaged (u32 , []const u8 ),
abbrevs : Abbrev .Store ,
const default : Info = .{
.block_name = &.{},
.record_names = .empty ,
.abbrevs = .{ .abbrevs = .empty },
};
const set_bid_id : u32 = 1 ;
const block_name_id : u32 = 2 ;
const set_record_name_id : u32 = 3 ;
fn deinit (info : *Info , allocator : std .mem .Allocator ) void {
allocator .free (info .block_name );
var record_names_it = info .record_names .valueIterator ();
while (record_names_it .next ()) |record_name | allocator .free (record_name .*);
info .record_names .deinit (allocator );
info .abbrevs .deinit (allocator );
info .* = undefined ;
}
};
}