Swift 5.10 can enforce full data isolation in concurrent code, preventing threads from reading and writing to the same memory at the same time. Credit: monticello / Shutterstock Apple has released Swift 5.10, an update to the company’s open-source programming language that reaches a major milestone: providing safety against data races via full data isolation in the concurrency model. The improvement prepares the way for the planned Swift 6 release. Binaries for Swift 5.10, introduced March 5, can be found at swift.org for Windows, macOS, and Linux. In explaining the milestone, Apple Swift engineer Holly Borla said an increasingly important source of undefined behavior is concurrent code that inadvertently accesses memory from one thread at the same time that another thread is writing to the same memory. This unsafety is called a data race, which makes concurrent programs exceptionally difficult to write, Borla noted. Swift 5.10 finally accomplishes full data isolation for concurrency after years of active development. The concurrency model was introduced in Swift 5.5 in September 2021. Swift 5.10 enforces full data isolation at compile time when the complete concurrency checking option is enabled, Borla said. This sets the stage for Swift 6, which will offer an opt-in Swift 6 language mode that enforces full data isolation by default. In the meantime, Swift 5.10 will produce data-race warnings in some circumstances where code could be proven safe with additional compiler analysis. A key focus of language development for Swift 6 is improving the usability of strict concurrency checking by mitigating false positive concurrency errors in common patterns proven to be safe, Borla said. Structured concurrency has been cited as a server-side goal for the Swift language. Related content feature What is Rust? Safe, fast, and easy software development Unlike most programming languages, Rust doesn't make you choose between speed, safety, and ease of use. Find out how Rust delivers better code with fewer compromises, and a few downsides to consider before learning Rust. By Serdar Yegulalp Nov 20, 2024 11 mins Rust Programming Languages Software Development how-to Kotlin for Java developers: Classes and coroutines Kotlin was designed to bring more flexibility and flow to programming in the JVM. Here's an in-depth look at how Kotlin makes working with classes and objects easier and introduces coroutines to modernize concurrency. By Matthew Tyson Nov 20, 2024 9 mins Java Kotlin Programming Languages analysis Azure AI Foundry tools for changes in AI applications Microsoft’s launch of Azure AI Foundry at Ignite 2024 signals a welcome shift from chatbots to agents and to using AI for business process automation. By Simon Bisson Nov 20, 2024 7 mins Microsoft Azure Generative AI Development Tools news Microsoft unveils imaging APIs for Windows Copilot Runtime Generative AI-backed APIs will allow developers to build image super resolution, image segmentation, object erase, and OCR capabilities into Windows applications. By Paul Krill Nov 19, 2024 2 mins Generative AI APIs Development Libraries and Frameworks Resources Videos