swift6-concurrencylisted
Install: claude install-skill wei18/apple-dev-skills
# Swift 6 / Strict Concurrency
## When to invoke
- Starting a new Swift iOS / macOS App project and deciding the language mode.
- Writing `Package.swift` and setting `swiftLanguageModes` / `SWIFT_STRICT_CONCURRENCY`.
- Adding a new third-party dependency and hitting concurrency warnings / errors.
- User asks "how do I configure Swift 6 / complete concurrency / Sendable / actor / `@preconcurrency`".
## Default decisions
- **Swift 6 language mode + complete concurrency checking**, applied from the first line of code.
- All in-house types are treated as **needing `Sendable`** by default; any type shared across actors must declare it explicitly (`struct Foo: Sendable` or `final class Foo: Sendable` — the latter only valid when all stored properties are Sendable and the class is non-inheritable; for classes with mutable state, prefer `actor Foo` or `@unchecked Sendable` with manual synchronisation).
- Protocols that cross actor boundaries (DI injection points) are always declared `Sendable`, with methods `async throws`.
- For third-party deps that don't support Swift 6 complete checking, in order of preference:
1. `@preconcurrency import X` to isolate the import
2. Switch packages
3. Defer adoption
## Rationale
- A greenfield project has no legacy code to migrate, so the pain of complete checking gets amortised — solved once per actor / Sendable as you write — rather than as a one-shot big-bang migration later.
- Swift 6 is the long-term direction of the language; earl