Skip to content

Commit

Permalink
Merge pull request #74013 from hborla/swift-6-release-note
Browse files Browse the repository at this point in the history
[Change Log] Add a change log entry for the Swift 6 language mode.
  • Loading branch information
DougGregor committed May 31, 2024
2 parents 2d0b194 + d311b7e commit ab898c0
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,23 @@
## Swift 6.0


* Swift 6 comes with a new language mode that prevents the risk of data races
at compile time. This guarantee is accomplished through _data isolation_; the
compiler will validate that data passed over a boundary between concurrently
executing code is either safe to reference concurrently, or mutually
exclusive access to the value is enforced.

The data-race safety checks were previously available in Swift 5.10 through
the `-strict-concurrency=complete` compiler flag. Complete concurrency
checking in Swift 5.10 was overly restrictive, and Swift 6 removes many
false-positive data-race warnings through better `Sendable` inference,
new analysis that proves mutually exclusive access when passing values with
non-`Sendable` type over isolation boundaries, and more.

You can enable the Swift 6 language mode using the `-swift-version 6`
compiler flag.

* [SE-0431][]:
You can now require a function value to carry its actor isolation
dynamically in a way that can be directly read by clients:
Expand Down

0 comments on commit ab898c0

Please sign in to comment.