Skip to content

Commit e0dbecd

Browse files
ANSCoderclaude
andcommitted
Modernize concurrency: Swift 6 mode, safety fixes, README rewrite
- Move package to swift-tools 6.0 with Swift 6 language mode - Retry: saturate exponential backoff (no overflow trap), drop force unwrap, use Task.sleep(for:), inherit caller isolation via #isolation - SingleFlight: propagate cancellation with waiter counting; guard cleanup by flight identity; remove dead AnyFlight protocol - AsyncLifetime: drop finished tasks so they don't accumulate - AsyncTask: lock-protect ownership and completion state - README: correct examples (weak self, MainActor hops), Swift 6 reqs Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
1 parent ca50bb1 commit e0dbecd

7 files changed

Lines changed: 247 additions & 242 deletions

File tree

‎Package.swift‎

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// swift-tools-version: 5.9
1+
// swift-tools-version: 6.0
22
import PackageDescription
33

44
let package = Package(
@@ -18,18 +18,13 @@ let package = Package(
1818
targets: [
1919
.target(
2020
name: "AsyncGuardKit",
21-
path: "Sources/AsyncGuardKit",
22-
swiftSettings: [
23-
.enableExperimentalFeature("StrictConcurrency")
24-
]
21+
path: "Sources/AsyncGuardKit"
2522
),
2623
.testTarget(
2724
name: "AsyncGuardKitTests",
2825
dependencies: ["AsyncGuardKit"],
29-
path: "Tests/AsyncGuardKitTests",
30-
swiftSettings: [
31-
.enableExperimentalFeature("StrictConcurrency")
32-
]
26+
path: "Tests/AsyncGuardKitTests"
3327
)
34-
]
28+
],
29+
swiftLanguageModes: [.v6]
3530
)

0 commit comments

Comments
 (0)