File tree 1 file changed +10
-2
lines changed
1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -40,8 +40,12 @@ public class DispatchWorkItem {
40
40
internal var _block : _DispatchBlock
41
41
42
42
public init ( qos: DispatchQoS = . unspecified, flags: DispatchWorkItemFlags = [ ] , block: @escaping @convention ( block) ( ) -> ( ) ) {
43
- #if os(Windows) && (arch(arm64) || arch(x86_64))
43
+ #if os(Windows)
44
+ #if arch(arm64) || arch(x86_64)
44
45
let flags = dispatch_block_flags_t ( UInt32 ( flags. rawValue) )
46
+ #else
47
+ let flags = dispatch_block_flags_t ( UInt ( flags. rawValue) )
48
+ #endif
45
49
#else
46
50
let flags : dispatch_block_flags_t = numericCast ( flags. rawValue)
47
51
#endif
@@ -52,8 +56,12 @@ public class DispatchWorkItem {
52
56
// Used by DispatchQueue.synchronously<T> to provide a path through
53
57
// dispatch_block_t, as we know the lifetime of the block in question.
54
58
internal init ( flags: DispatchWorkItemFlags = [ ] , noescapeBlock: ( ) -> ( ) ) {
55
- #if os(Windows) && (arch(arm64) || arch(x86_64))
59
+ #if os(Windows)
60
+ #if arch(arm64) || arch(x86_64)
56
61
let flags = dispatch_block_flags_t ( UInt32 ( flags. rawValue) )
62
+ #else
63
+ let flags = dispatch_block_flags_t ( UInt ( flags. rawValue) )
64
+ #endif
57
65
#else
58
66
let flags : dispatch_block_flags_t = numericCast ( flags. rawValue)
59
67
#endif
You can’t perform that action at this time.
0 commit comments