| ... | ... | @@ -171,7 +171,7 @@ pub fn io(t: *Threaded) Io { |
| 171 | 171 | .dirStat = dirStat, |
| 172 | 172 | .dirStatPath = switch (builtin.os.tag) { |
| 173 | 173 | .linux => dirStatPathLinux, |
| 174 | | .windows => @panic("TODO"), |
| 174 | .windows => dirStatPathWindows, |
| 175 | 175 | .wasi => dirStatPathWasi, |
| 176 | 176 | else => dirStatPathPosix, |
| 177 | 177 | }, |
| ... | ... | @@ -1079,6 +1079,21 @@ fn dirStatPathPosix( |
| 1079 | 1079 | } |
| 1080 | 1080 | } |
| 1081 | 1081 | |
| 1082 | fn dirStatPathWindows( |
| 1083 | userdata: ?*anyopaque, |
| 1084 | dir: Io.Dir, |
| 1085 | sub_path: []const u8, |
| 1086 | options: Io.Dir.StatPathOptions, |
| 1087 | ) Io.Dir.StatPathError!Io.File.Stat { |
| 1088 | const t: *Threaded = @ptrCast(@alignCast(userdata)); |
| 1089 | const t_io = t.io(); |
| 1090 | var file = try dir.openFile(t_io, sub_path, .{ |
| 1091 | .follow_symlinks = options.follow_symlinks, |
| 1092 | }); |
| 1093 | defer file.close(t_io); |
| 1094 | return file.stat(t_io); |
| 1095 | } |
| 1096 | |
| 1082 | 1097 | fn dirStatPathWasi( |
| 1083 | 1098 | userdata: ?*anyopaque, |
| 1084 | 1099 | dir: Io.Dir, |