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.
fnrationalApproxBinary32(z: f32) f32 {
constpS0: f32 = 1.6666586697e-01;
constpS1: f32 = -4.2743422091e-02;
constpS2: f32 = -8.6563630030e-03;
constqS1: f32 = -7.0662963390e-01;
// f64 is used instead of f32 to avoid
// a vectorization on x86_64. The vectorization
// causes extra floating point execeptions
// that are prohibited by libc-test.
constp: f64 = @as(f64, @floatCast(z)) * (pS0 + z * (pS1 + z * pS2));
constq: f64 = 1.0 + z * qS1;
return@floatCast(p / q);
}