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/ › Io/ › Threaded.zig › dirOpenFileWindows
dirOpenFileWindows
Threaded.dirOpenFileWindows
fn dirOpenFileWindows (
userdata : ?*anyopaque ,
dir : Dir ,
sub_path : []const u8 ,
flags : Dir .OpenFileOptions ,
) File .OpenError !File
File
Code
fn dirOpenFileWindows (
userdata : ?*anyopaque ,
dir : Dir ,
sub_path : []const u8 ,
flags : Dir .OpenFileOptions ,
) File .OpenError !File {
const t : *Threaded = @ptrCast (@alignCast (userdata ));
_ = t ;
const sub_path_w_array = try sliceToPrefixedFileW (dir .handle , sub_path , .{});
const sub_path_w = sub_path_w_array .span ();
const dir_handle = if (Dir .path .isAbsoluteWindowsWtf16 (sub_path_w )) null else dir .handle ;
return dirOpenFileWtf16 (dir_handle , sub_path_w , flags );
}