@@ -18,6 +18,7 @@ import Foundation
18
18
package import LanguageServerProtocol
19
19
import Markdown
20
20
import SKUtilities
21
+ import SourceKitLSP
21
22
import SemanticIndex
22
23
23
24
extension DocumentationLanguageService {
@@ -63,9 +64,13 @@ extension DocumentationLanguageService {
63
64
ofDocCSymbolLink: symbolLink,
64
65
fetchSymbolGraph: { location in
65
66
guard let symbolWorkspace = try await workspaceForDocument ( uri: location. documentUri) ,
66
- let languageService = try await languageService ( for: location. documentUri, . swift, in: symbolWorkspace)
67
+ let languageService = await sourceKitLSPServer. languageService (
68
+ for: location. documentUri,
69
+ . swift,
70
+ in: symbolWorkspace
71
+ )
67
72
else {
68
- throw ResponseError . internalError ( " Unable to find Swift language service for \( location. documentUri) " )
73
+ throw ResponseError . internalError ( " Unable to find language service for \( location. documentUri) " )
69
74
}
70
75
return try await languageService. symbolGraph ( forOnDiskContentsOf: location. documentUri, at: location)
71
76
}
@@ -76,9 +81,13 @@ extension DocumentationLanguageService {
76
81
let symbolDocumentUri = symbolOccurrence. location. documentUri
77
82
guard
78
83
let symbolWorkspace = try await workspaceForDocument ( uri: symbolDocumentUri) ,
79
- let languageService = try await languageService ( for: symbolDocumentUri, . swift, in: symbolWorkspace)
84
+ let languageService = await sourceKitLSPServer. languageService (
85
+ for: symbolDocumentUri,
86
+ . swift,
87
+ in: symbolWorkspace
88
+ )
80
89
else {
81
- throw ResponseError . internalError ( " Unable to find Swift language service for \( symbolDocumentUri) " )
90
+ throw ResponseError . internalError ( " Unable to find language service for \( symbolDocumentUri) " )
82
91
}
83
92
let symbolGraph = try await languageService. symbolGraph (
84
93
forOnDiskContentsOf: symbolDocumentUri,
0 commit comments