We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5d85e22 commit 9ab91a5Copy full SHA for 9ab91a5
Sources/SwiftFormat/API/SwiftLinter.swift
@@ -97,7 +97,8 @@ public final class SwiftLinter {
97
// If the file or input string is completely empty, do nothing. This prevents even a trailing
98
// newline from being diagnosed for an empty file. (This is consistent with clang-format, which
99
// also does not touch an empty file even if the setting to add trailing newlines is enabled.)
100
- guard !source.isEmpty else { return }
+ guard !source.isEmpty else { return }
101
+
102
let sourceFile = try parseAndEmitDiagnostics(
103
source: source,
104
operatorTable: .standardOperators,
0 commit comments