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 › Build › Configuration › InstallDestDir Public Enum InstallDestDir Doc Source Public Enum std.Build.Configuration.InstallDestDir
pub const InstallDestDir = enum (u32 ) Types Functions File Build/Configuration.zig: 1883
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915 pub const InstallDestDir = enum (u32 ) {
none = max_u32 - 4 ,
prefix = max_u32 - 3 ,
lib = max_u32 - 2 ,
bin = max_u32 - 1 ,
header = max_u32 ,
/// A `String` path relative to the prefix.
_ ,
pub fn initCustom (sub_path : String ) InstallDestDir {
assert (@backingInt (sub_path ) < @backingInt (InstallDestDir .none ));
return @fromBackingInt (@intCast (@backingInt (sub_path )));
}
pub const Unpacked = union (enum ) {
prefix ,
lib ,
bin ,
header ,
sub_path : String ,
};
pub fn unpack (this : @This ()) ?Unpacked {
return switch (this ) {
.none => null ,
.prefix => .prefix ,
.lib => .lib ,
.bin => .bin ,
.header => .header ,
_ => .{ .sub_path = @fromBackingInt (@intCast (@backingInt (this ))) },
};
}
}