Skip to content

Commit 6ee8e6b

Browse files
committed
use canImport for synchronization imports
1 parent 705d181 commit 6ee8e6b

File tree

5 files changed

+12
-0
lines changed

5 files changed

+12
-0
lines changed

Sources/FoundationEssentials/ProgressManager/ProgressManager+Interop.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@
1212

1313
#if FOUNDATION_FRAMEWORK
1414
internal import _ForSwiftFoundation
15+
#if canImport(Synchronization)
1516
internal import Synchronization
17+
#endif
1618

1719
//MARK: Progress Parent - Subprogress / ProgressReporter Child Interop
1820
@available(FoundationPreview 6.4, *)

Sources/FoundationEssentials/ProgressManager/ProgressManager+Properties+Accessors.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@
1010
//
1111
//===----------------------------------------------------------------------===//
1212

13+
#if canImport(Synchronization)
1314
internal import Synchronization
15+
#endif
1416

1517
@available(FoundationPreview 6.4, *)
1618
extension ProgressManager {

Sources/FoundationEssentials/ProgressManager/ProgressManager+Properties+Helpers.swift

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,10 @@
1010
//
1111
//===----------------------------------------------------------------------===//
1212

13+
#if canImport(Synchronization)
1314
internal import Synchronization
15+
#endif
16+
1417
@available(FoundationPreview 6.4, *)
1518
extension ProgressManager {
1619

Sources/FoundationEssentials/ProgressManager/ProgressManager+State.swift

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@
99
// See https://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
1010
//
1111
//===----------------------------------------------------------------------===//
12+
13+
#if canImport(Synchronization)
1214
internal import Synchronization
15+
#endif
1316

1417
@available(FoundationPreview 6.4, *)
1518
extension ProgressManager {

Sources/FoundationEssentials/ProgressManager/ProgressManager.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,9 @@
1111
//===----------------------------------------------------------------------===//
1212

1313
import Observation
14+
#if canImport(Synchronization)
1415
internal import Synchronization
16+
#endif
1517

1618
#if canImport(CollectionsInternal)
1719
internal import CollectionsInternal

0 commit comments

Comments
 (0)