Repository navigation
0.50300.0
This release is compatible with Swift 5.3.
Significant changes since the last release:
- Support is added for rules to be opt-in rather than on-by-default. (40bab4e)
- The following rules have been made opt-in, because they are either too strict for many real-world use cases or are not yet correct enough to enable universally. Existing configuration files will not be affected, but when using the default configuration, these rules will be off by default: (1c2a5a2, 642c2d1)
AllPublicDeclarationsHaveDocumentationNeverForceUnwrapNeverUseForceTryNeverUseImplicitlyUnwrappedOptionalsNoLeadingUnderscoresValidateDocumentationComments
- Improvements to
AlwaysUseLowerCamelCase:- It is now applied to closure arguments and variables bound in
if/guard letpatterns. (7867cda) - Diagnostics are now clearer about the kind of declaration affected. (97628a8)
- Functions that look like test case methods are excluded; for example, to support common naming schemes like
testSomeObject_inSomeState_actsSomeWay. (9080762)
- It is now applied to closure arguments and variables bound in
- Improvements to
ValidateDocumentationComments: - Multiple trailing closures are formatted. (e286081)
- Fix a crash when linting a collection literal with single element and a trailing comma. (483580f)
- Fixed invalid locations in some diagnostics. (ea02880)
- Keep
trykeyword next to the expression following it whenever possible, only breaking between them when necessary. (35fdb4f) - Recursively apply
NoParensAroundConditionto pick up nested occurrences. (ed45527) - Do not remove semicolons between a
doblock and awhileblock. (cb4e621) - Fix some situations where
OneVariableDeclarationPerLinewould incorrectly break declarations. (2b4364b) - Add a
indentSwitchCaseLabelsconfiguration option to control whethercasestatements inside aswitchare indented. (2107603) - Speed and memory usage improvements when formatting and linting.