From 29e86c0c726c20cf1add94a322b9c147b67ca1f6 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Mon, 30 Dec 2019 14:53:43 +0100 Subject: More second command to Ctx --- editors/code/src/main.ts | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'editors/code/src/main.ts') diff --git a/editors/code/src/main.ts b/editors/code/src/main.ts index 048b9bbd4..9500219ca 100644 --- a/editors/code/src/main.ts +++ b/editors/code/src/main.ts @@ -15,11 +15,8 @@ let ctx!: Ctx; export async function activate(context: vscode.ExtensionContext) { ctx = new Ctx(context); - ctx.registerCommand( - 'analyzerStatus', - commands.analyzerStatus - ); - + ctx.registerCommand('analyzerStatus', commands.analyzerStatus); + ctx.registerCommand('collectGarbage', commands.collectGarbage); function disposeOnDeactivation(disposable: vscode.Disposable) { context.subscriptions.push(disposable); @@ -58,9 +55,6 @@ export async function activate(context: vscode.ExtensionContext) { } // Commands are requests from vscode to the language server - registerCommand('rust-analyzer.collectGarbage', () => - Server.client.sendRequest('rust-analyzer/collectGarbage', null), - ); registerCommand( 'rust-analyzer.matchingBrace', commands.matchingBrace.handle, -- cgit v1.2.3