Can I use swift 6 but without strict concurrency check?
Generated on 8/2/2024
1 search
Yes, you can use Swift 6 without enabling strict concurrency checks. The new Swift 6 language mode, which includes full data-race safety, is opt-in. This means you can adopt it when you're ready and even do so incrementally, module by module. You can also interoperate with dependencies that may not have migrated to Swift 6 yet.
For example, in the session Migrate your app to Swift 6, it is mentioned that you can start by enabling warnings for concurrency issues without fully adopting the strict concurrency checks. This allows you to gradually address concurrency issues while still building and running your project.
Additionally, in the session What’s new in Swift, it is noted that data-race safety is the only update governed by enabling the Swift 6 language mode, and all other updates are available by default when you update to the Swift 6 compiler.
Relevant Sessions
What’s new in Xcode 16
Discover the latest productivity and performance improvements in Xcode 16. Learn about enhancements to code completion, diagnostics, and Xcode Previews. Find out more about updates in builds and explore improvements in debugging and Instruments.
Platforms State of the Union
Discover the newest advancements on Apple platforms.
Migrate your app to Swift 6
Experience Swift 6 migration in action as we update an existing sample app. Learn how to migrate incrementally, module by module, and how the compiler helps you identify code that’s at risk of data races. Discover different techniques for ensuring clear isolation boundaries and eliminating concurrent access to shared mutable state.
What’s new in Swift
Join us for an update on Swift. We’ll briefly go through a history of Swift over the past decade, and show you how the community has grown through workgroups, expanded the package ecosystem, and increased platform support. We’ll introduce you to a new language mode that achieves data-race safety by default, and a language subset that lets you run Swift on highly constrained systems. We’ll also explore some language updates including noncopyable types, typed throws, and improved C++ interoperability.