What’s new in Swift

Discover updates to Swift and related tools and frameworks.


Swift 6.4

Swift 6.4 delivers improvements designed for developers at every level. A set of ergonomic refinements remove everyday friction, including simplified availability syntax with anyAppleOS and finer-grained control over warnings with the @diagnose attribute. Asynchronous code is now supported in defer statements, guaranteeing cleanup runs whether a function returns or throws. A new iteration protocol extends for-in loops to noncopyable types like Span and InlineArray, letting performance-critical code iterate without unnecessary copying. Foundation sees major performance gains, with URL parsing up to 4x faster. And Swift Testing gains XCTest interoperability for smoother incremental migration.


Features are subject to change. Some capabilities and services may not be available in all regions or all languages; some feature availability may vary due to local laws and regulations.