executing-plans
executing-plans
Use when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available
swift-concurrencyImplement async/await, Actors, and structured concurrency in Swift. Use when implementing Swift async/await, Actors, or structured concurrency in iOS/macOS.
Independent GitHub snapshot · Automated classification · Original documentation governs
async and call with await.async let: Use async let for parallel execution when multiple tasks independent.withTaskGroup or withThrowingTaskGroup for spawning dynamic number of tasks.throws. Always handle CancellationError.See implementation examples for parallel fetch with async let and Task Groups.
actor for shared mutable state to avoid data races.@MainActor: Annotate UI classes (Views, ViewModels) with @MainActor for main thread execution. Use MainActor.run { ... } for inline UI updates in async blocks.@GlobalActor for specific thread-bound resources.nonisolated for methods that don't access actor state to avoid unnecessary hops.See implementation examples for Actor-based state isolation and nonisolated methods.
Task { ... }.Task.isCancelled in long loops. Use try Task.checkCancellation() for throwing functions.Task.detached unless you explicitly want to break context inheritance.MainActor.