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.

F16T

compiler_rt.F16T
pub fn F16T(comptime OtherType: type) type

File

lib/compiler_rt.zig:446

Code

pub fn F16T(comptime OtherType: type) type {
    return switch (builtin.cpu.arch) {
        .x86, .x86_64 => if (builtin.target.os.tag.isDarwin()) switch (OtherType) {
            // Starting with LLVM 16, Darwin uses different abi for f16
            // depending on the type of the other return/argument..???
            f32, f64 => u16,
            f80, f128 => f16,
            else => unreachable,
        } else f16,
        else => f16,
    };
}