Skip to content

Commit 4fba0fd

Browse files
authored
Merge pull request #871 from ahoppen/ahoppen/no-queue-hopping
Don't hop on background queue to run `onExit`
2 parents fbd0cd1 + 0b8611b commit 4fba0fd

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

Sources/SourceKitLSP/SourceKitServer.swift

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -967,11 +967,7 @@ extension SourceKitServer {
967967
await prepareForExit()
968968

969969
// Call onExit only once, and hop off queue to allow the handler to call us back.
970-
let onExit = self.onExit
971-
self.onExit = {}
972-
DispatchQueue.global().async {
973-
onExit()
974-
}
970+
self.onExit()
975971
}
976972

977973
// MARK: - Text synchronization

0 commit comments

Comments
 (0)