SwiftSyntaxCorrectableRule
public protocol SwiftSyntaxCorrectableRule : CorrectableRule, SwiftSyntaxRule
A SwiftLint CorrectableRule that performs its corrections using a SwiftSyntax SyntaxRewriter
.
-
Produce a
ViolationsSyntaxRewriter
for the given file.Declaration
Swift
func makeRewriter(file: SwiftLintFile) -> ViolationsSyntaxRewriter?
Parameters
file
The file for which to produce the rewriter.
Return Value
A
ViolationsSyntaxRewriter
for the given file. -
correct(file:
Extension method) Declaration
Swift
func correct(file: SwiftLintFile) -> [Correction]