diff options
| author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2020-08-10 14:48:19 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-08-10 14:48:19 +0000 |
| commit | cef39c3efb98e5ece42bb72c14d96388380a308c (patch) | |
| tree | 1429b2dbc837de84c1ffcc8c31513e640d97080a /editors/code/src | |
| parent | f3336509e52187a7a70a8043557a7317872e3a2f (diff) | |
| parent | 58c97bdcbf6d7df218028f75373cfc4916043693 (diff) | |
| download | rust-cef39c3efb98e5ece42bb72c14d96388380a308c.tar.gz rust-cef39c3efb98e5ece42bb72c14d96388380a308c.zip | |
Merge #5697
5697: Remove workaround for semantic token flickering r=jonas-schievink a=kjeremy See: https://github.com/microsoft/vscode-languageserver-node/issues/576#issuecomment-593384479 This has been fixed since vscode 1.44 Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
Diffstat (limited to 'editors/code/src')
| -rw-r--r-- | editors/code/src/client.ts | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/editors/code/src/client.ts b/editors/code/src/client.ts index 18948cb3c4c..f5db55b8cc3 100644 --- a/editors/code/src/client.ts +++ b/editors/code/src/client.ts @@ -4,7 +4,7 @@ import * as ra from '../src/lsp_ext'; import * as Is from 'vscode-languageclient/lib/utils/is'; import { CallHierarchyFeature } from 'vscode-languageclient/lib/callHierarchy.proposed'; -import { SemanticTokensFeature, DocumentSemanticsTokensSignature } from 'vscode-languageclient/lib/semanticTokens.proposed'; +import { SemanticTokensFeature } from 'vscode-languageclient/lib/semanticTokens.proposed'; import { assert } from './util'; function renderCommand(cmd: ra.CommandLink) { @@ -44,12 +44,6 @@ export function createClient(serverPath: string, cwd: string): lc.LanguageClient diagnosticCollectionName: "rustc", traceOutputChannel, middleware: { - // Workaround for https://github.com/microsoft/vscode-languageserver-node/issues/576 - async provideDocumentSemanticTokens(document: vscode.TextDocument, token: vscode.CancellationToken, next: DocumentSemanticsTokensSignature) { - const res = await next(document, token); - if (res === undefined) throw new Error('busy'); - return res; - }, async provideHover(document: vscode.TextDocument, position: vscode.Position, token: vscode.CancellationToken, _next: lc.ProvideHoverSignature) { return client.sendRequest(lc.HoverRequest.type, client.code2ProtocolConverter.asTextDocumentPositionParams(document, position), token).then( (result) => { @@ -135,7 +129,7 @@ export function createClient(serverPath: string, cwd: string): lc.LanguageClient ); } - } as any + } }; const client = new lc.LanguageClient( |
