diff options
Diffstat (limited to 'editors/code/src/client.ts')
-rw-r--r-- | editors/code/src/client.ts | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/editors/code/src/client.ts b/editors/code/src/client.ts index f5db55b8c..1ba2352ee 100644 --- a/editors/code/src/client.ts +++ b/editors/code/src/client.ts | |||
@@ -1,10 +1,7 @@ | |||
1 | import * as lc from 'vscode-languageclient'; | 1 | import * as lc from 'vscode-languageclient/node'; |
2 | import * as vscode from 'vscode'; | 2 | import * as vscode from 'vscode'; |
3 | import * as ra from '../src/lsp_ext'; | 3 | import * as ra from '../src/lsp_ext'; |
4 | import * as Is from 'vscode-languageclient/lib/utils/is'; | 4 | import * as Is from 'vscode-languageclient/lib/common/utils/is'; |
5 | |||
6 | import { CallHierarchyFeature } from 'vscode-languageclient/lib/callHierarchy.proposed'; | ||
7 | import { SemanticTokensFeature } from 'vscode-languageclient/lib/semanticTokens.proposed'; | ||
8 | import { assert } from './util'; | 5 | import { assert } from './util'; |
9 | 6 | ||
10 | function renderCommand(cmd: ra.CommandLink) { | 7 | function renderCommand(cmd: ra.CommandLink) { |
@@ -57,7 +54,7 @@ export function createClient(serverPath: string, cwd: string): lc.LanguageClient | |||
57 | return hover; | 54 | return hover; |
58 | }, | 55 | }, |
59 | (error) => { | 56 | (error) => { |
60 | client.logFailedRequest(lc.HoverRequest.type, error); | 57 | client.handleFailedRequest(lc.HoverRequest.type, error, null); |
61 | return Promise.resolve(null); | 58 | return Promise.resolve(null); |
62 | }); | 59 | }); |
63 | }, | 60 | }, |
@@ -140,12 +137,6 @@ export function createClient(serverPath: string, cwd: string): lc.LanguageClient | |||
140 | ); | 137 | ); |
141 | 138 | ||
142 | // To turn on all proposed features use: client.registerProposedFeatures(); | 139 | // To turn on all proposed features use: client.registerProposedFeatures(); |
143 | // Here we want to enable CallHierarchyFeature and SemanticTokensFeature | ||
144 | // since they are available on stable. | ||
145 | // Note that while these features are stable in vscode their LSP protocol | ||
146 | // implementations are still in the "proposed" category for 3.16. | ||
147 | client.registerFeature(new CallHierarchyFeature(client)); | ||
148 | client.registerFeature(new SemanticTokensFeature(client)); | ||
149 | client.registerFeature(new ExperimentalFeatures()); | 140 | client.registerFeature(new ExperimentalFeatures()); |
150 | 141 | ||
151 | return client; | 142 | return client; |