mirror of
https://github.com/apple/sourcekit-lsp.git
synced 2026-03-02 18:23:24 +01:00
Don’t cancel build when closing a document
In SourceKit-LSP, we can get into the following situation: 1. We open A.swift 2. We issue a request for A.swift, the request takes a while to execute 3. The dependencies of A.swift are updated, which causes us to reopen the document in sourcekitd, so that the AST is rebuilt 4. This shouldn’t cause the request from (2) to be cancelled. We should continue executing it and only re-open the document after the request from (2) has finished rdar://127475366
This commit is contained in:
@@ -382,6 +382,7 @@ extension SwiftLanguageService {
|
||||
keys.enableDiagnostics: 0,
|
||||
keys.syntacticOnly: 1,
|
||||
keys.compilerArgs: compileCommand?.compilerArgs as [SKDRequestValue]?,
|
||||
keys.cancelBuilds: 0,
|
||||
])
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user