Skip to content

Commit 3cd3865

Browse files
authored
Merge pull request #2065 from ahoppen/refresh-diags-sourcekitd-restored
Refresh diagnostics when sourcekitd has been restored
2 parents 23780ca + 6c74631 commit 3cd3865

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Sources/SourceKitLSP/Swift/SwiftLanguageService.swift

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -333,6 +333,9 @@ package actor SwiftLanguageService: LanguageService, Sendable {
333333
await sourceKitLSPServer.sourcekitdCrashedWorkDoneProgress.start()
334334
case (.connectionInterrupted, .connected), (.semanticFunctionalityDisabled, .connected):
335335
await sourceKitLSPServer.sourcekitdCrashedWorkDoneProgress.end()
336+
// We can provide diagnostics again now. Send a diagnostic refresh request to prompt the editor to reload
337+
// diagnostics.
338+
await refreshDiagnosticsDebouncer.scheduleCall()
336339
case (.connected, .connected),
337340
(.connectionInterrupted, .connectionInterrupted),
338341
(.connectionInterrupted, .semanticFunctionalityDisabled),

0 commit comments

Comments
 (0)