Swift 6.4 Released
Swift 6.4 has just become available, offering a host of enhancements aimed at simplifying programming and expanding the language's reach. Designed to be versatile across various environments, including apps, servers, systems code, embedded devices, and browsers, Swift 6.4 streamlines everyday code writing by improving usability and developer experience.
Key updates include the ability to combine asynchronous calls within defer blocks and cancellation shields, ensuring that cleanup operations execute regardless of function return status. Enhancements to Foundation and the standard library facilitate the use of modern APIs with existing types. For instance, the ProgressManager now supports async/await (SF-0023), while @Observable types enable fine-grained and continuous change notifications (SE-0506).
The Subprocess library, an initial 0.1 release in 2025, has matured into version 1.0, providing a cross-platform solution for running and interacting with subprocesses using Swift concurrency. Migration to Swift Testing is now more seamless, with the capability to use XCTAssert in tests and customize failed expectation displays through the CustomTestReflectable protocol (ST-0021 and ST-0022).
Swift test runners can now repeat test cases to save time and record attachments conforming to the Transferable protocol on Apple platforms (ST-0023).
Swift 6.4 broadens interoperability with more areas of the technology stack. Performance improvements for JavaScriptKit when bridging to Wasm make safe bridging up to 40 times faster than previous implementations. The WebAssembly (Wasm) Software Development Kit is now accessible on the Swift.org Install Swift page, enabling Swift compilation for the browser without additional setup.
Foundation updates enhance FileManager support on WASI (WebAssembly System Interface), and Swift on Android has advanced with the new LTS NDK 30, offering Android availability attributes in the Swift runtime libraries and Swift packages.
Embedded Swift improvements include generalized support for existential types like any Protocol, enabling natural expression of heterogeneous collections and handling of any Error. An EmbeddedRestrictions warning helps users adhere to memory safety standards across targets. Swift 6.4 also emphasizes data handling efficiency by extending earlier work on Span, non-copyable types, and InlineArray to minimize unnecessary data copies while maintaining safety.
The release underscores the collaborative efforts of the Swift community, with contributions from developers, proposals, forum discussions, and feedback playing a crucial role. To explore Swift 6.4, users can download the new 6.4 toolchain via the Install Swift page, marking a significant step forward in Swift's development and applicability.
Written by urgent.news from Lobsters's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.
This story
This is one outlet's version. Read the fullest account.
- Swift 6.4 Released swift.org