|
1 |
| -diff --git a/swift-build/Sources/SWBUtil/FSProxy.swift b/swift-build/Sources/SWBUtil/FSProxy.swift |
2 |
| -index b446d21..f88f3c3 100644 |
3 |
| ---- a/swift-build/Sources/SWBUtil/FSProxy.swift |
4 |
| -+++ b/swift-build/Sources/SWBUtil/FSProxy.swift |
5 |
| -@@ -49,7 +49,7 @@ public struct FileInfo: Equatable, Sendable { |
6 |
| - #if os(Windows) |
7 |
| - return (statBuf.st_mode & UInt16(ucrt.S_IFREG)) != 0 |
8 |
| - #else |
9 |
| -- return (statBuf.st_mode & S_IFREG) != 0 |
10 |
| -+ return (mode_t(statBuf.st_mode) & S_IFREG) != 0 |
11 |
| - #endif |
12 |
| - } |
13 |
| - |
14 |
| -@@ -57,7 +57,7 @@ public struct FileInfo: Equatable, Sendable { |
15 |
| - #if os(Windows) |
16 |
| - return (statBuf.st_mode & UInt16(ucrt.S_IFDIR)) != 0 |
17 |
| - #else |
18 |
| -- return (statBuf.st_mode & S_IFDIR) != 0 |
19 |
| -+ return (mode_t(statBuf.st_mode) & S_IFDIR) != 0 |
20 |
| - #endif |
21 |
| - } |
22 |
| - |
23 |
| -@@ -65,7 +65,7 @@ public struct FileInfo: Equatable, Sendable { |
24 |
| - #if os(Windows) |
25 |
| - return (statBuf.st_mode & UInt16(S_IFLNK)) == S_IFLNK |
26 |
| - #else |
27 |
| -- return (statBuf.st_mode & S_IFMT) == S_IFLNK |
28 |
| -+ return (mode_t(statBuf.st_mode) & S_IFMT) == S_IFLNK |
29 |
| - #endif |
30 |
| - } |
31 |
| - |
32 |
| -@@ -75,7 +75,7 @@ public struct FileInfo: Equatable, Sendable { |
33 |
| - // Don't use FileManager.isExecutableFile due to https://github.com/swiftlang/swift-foundation/issues/860 |
34 |
| - return (statBuf.st_mode & UInt16(_S_IEXEC)) != 0 |
35 |
| - #else |
36 |
| -- return (statBuf.st_mode & S_IXUSR) != 0 |
37 |
| -+ return (mode_t(statBuf.st_mode) & S_IXUSR) != 0 |
38 |
| - #endif |
39 |
| - } |
40 |
| - |
41 |
| -@@ -1395,9 +1395,9 @@ public class PseudoFS: FSProxy, @unchecked Sendable { |
42 |
| - #else |
43 |
| - info.st_mtimespec = timespec(tv_sec: time_t(node.timestamp), tv_nsec: 0) |
44 |
| - #endif |
45 |
| -- info.st_size = off_t(contents.bytes.count) |
46 |
| -- info.st_dev = node.device |
47 |
| -- info.st_ino = node.inode |
48 |
| -+ info.st_size = numericCast(contents.bytes.count) |
49 |
| -+ info.st_dev = numericCast(node.device) |
50 |
| -+ info.st_ino = numericCast(node.inode) |
51 |
| - return createFileInfo(info) |
52 |
| - case .directory(let dir): |
53 |
| - var info = stat() |
54 |
| -@@ -1405,12 +1405,12 @@ public class PseudoFS: FSProxy, @unchecked Sendable { |
55 |
| - info.st_mode = UInt16(ucrt.S_IFDIR) |
56 |
| - info.st_mtimespec = timespec(tv_sec: Int64(node.timestamp), tv_nsec: 0) |
57 |
| - #else |
58 |
| -- info.st_mode = S_IFDIR |
59 |
| -+ info.st_mode = numericCast(S_IFDIR) |
60 |
| - info.st_mtimespec = timespec(tv_sec: time_t(node.timestamp), tv_nsec: 0) |
61 |
| - #endif |
62 |
| -- info.st_size = off_t(dir.contents.count) |
63 |
| -- info.st_dev = node.device |
64 |
| -- info.st_ino = node.inode |
65 |
| -+ info.st_size = numericCast(dir.contents.count) |
66 |
| -+ info.st_dev = numericCast(node.device) |
67 |
| -+ info.st_ino = numericCast(node.inode) |
68 |
| - return createFileInfo(info) |
69 |
| - case .symlink(_): |
70 |
| - var info = stat() |
71 |
| -@@ -1418,12 +1418,12 @@ public class PseudoFS: FSProxy, @unchecked Sendable { |
72 |
| - info.st_mode = UInt16(S_IFLNK) |
73 |
| - info.st_mtimespec = timespec(tv_sec: Int64(node.timestamp), tv_nsec: 0) |
74 |
| - #else |
75 |
| -- info.st_mode = S_IFLNK |
76 |
| -+ info.st_mode = numericCast(S_IFLNK) |
77 |
| - info.st_mtimespec = timespec(tv_sec: time_t(node.timestamp), tv_nsec: 0) |
78 |
| - #endif |
79 |
| -- info.st_size = off_t(0) |
80 |
| -- info.st_dev = node.device |
81 |
| -- info.st_ino = node.inode |
82 |
| -+ info.st_size = numericCast(0) |
83 |
| -+ info.st_dev = numericCast(node.device) |
84 |
| -+ info.st_ino = numericCast(node.inode) |
85 |
| - return createFileInfo(info) |
86 |
| - } |
87 |
| - } |
88 | 1 | diff --git a/swift-build/Sources/SWBUtil/Lock.swift b/swift-build/Sources/SWBUtil/Lock.swift
|
89 | 2 | index 2135ce6..fbff6f6 100644
|
90 | 3 | --- a/swift-build/Sources/SWBUtil/Lock.swift
|
|
0 commit comments