508.0.0
This release is compatible with Swift 5.8.
Significant changes since the last release:
- The
spacesAroundRangeFormationOperators
configuration option has been added to force a space around range formation operators like...
and..<
. - A new rule,
NoAssignmentInExpressions
, has been added that emits a linter finding if an assignment expression is found in another expression context (for example,return x = y
). - Format and Lint plug-ins have been added that can be used from Swift Package Manager and Xcode.
- Detection of "files that contain
XCTest
s" has been improved to include cases whereXCTest
is imported conditionally in a#if
block. - Primary associated type clauses in
protocol
declarations are formatted correctly. - When a closure literal contains both a leading attribute and a capture list (e.g.,
{ @MainActor [weak self] in ...
), a space is guaranteed between the attribute and capture list. Optional<T>
will not be automatically converted to the shorthandT?
in positions where it would cause a performance issue due to subtle Swift initialization characteristics, like in member variable declarations.