Skip to content

Commit 2868901

Browse files
authored
Merge pull request #1040 from AnthonyLatsis/jepa
Enable some nice-to-have code formatting rules
2 parents 24c7446 + 9feb350 commit 2868901

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

.swift-format

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@
1313
"NoBlockComments": false,
1414
"OrderedImports": true,
1515
"UseLetInEveryBoundCaseVariable": false,
16-
"UseSynthesizedInitializer": false
16+
"UseSynthesizedInitializer": false,
17+
"ReturnVoidInsteadOfEmptyTuple": true,
18+
"NoVoidReturnOnFunctionSignature": true,
1719
}
1820
}

Sources/swift-format/Frontend/FormatFrontend.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ class FormatFrontend: Frontend {
4040
return
4141
}
4242

43-
let diagnosticHandler: (SwiftDiagnostics.Diagnostic, SourceLocation) -> () = {
43+
let diagnosticHandler: (SwiftDiagnostics.Diagnostic, SourceLocation) -> Void = {
4444
(diagnostic, location) in
4545
guard !self.lintFormatOptions.ignoreUnparsableFiles else {
4646
// No diagnostics should be emitted in this mode.

0 commit comments

Comments
 (0)