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 standard library.
std › zig › llvm › Builder › WipFunction › WipPhi › finish Public Function finish Doc Source Public Function std.zig.llvm.Builder.WipFunction.WipPhi.finish
pub fn finish (
self : WipPhi ,
vals : []const Value ,
blocks : []const Block .Index ,
wip : *WipFunction ,
) void Params File zig/llvm/Builder.zig: 7149
7149
7150
7151
7152
7153
7154
7155
7156
7157
7158
7159
7160
7161
7162 pub fn finish (
self : WipPhi ,
vals : []const Value ,
blocks : []const Block .Index ,
wip : *WipFunction ,
) void {
const incoming_len = self .block .ptrConst (wip ).incoming ;
assert (vals .len == incoming_len and blocks .len == incoming_len );
const instruction = wip .instructions .get (@backingInt (self .instruction ));
var extra = wip .extraDataTrail (Instruction .Phi , instruction .data );
for (vals ) |val | assert (val .typeOfWip (wip ) == extra .data .type );
@memcpy (extra .trail .nextMut (incoming_len , Value , wip ), vals );
@memcpy (extra .trail .nextMut (incoming_len , Block .Index , wip ), blocks );
}