aboutsummaryrefslogtreecommitdiff
path: root/editors/code/src/main.ts
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2019-12-30 18:58:44 +0000
committerAleksey Kladov <[email protected]>2019-12-30 18:58:44 +0000
commit6b118c9b8de3c3ed84a16aba2e71fa5a9ada6e74 (patch)
treec3c537d5b953374e1108edbfb2b4fcda2cc96b91 /editors/code/src/main.ts
parent237abb85c40672e8cdafa423db6187c107369a09 (diff)
Refactor runables
Diffstat (limited to 'editors/code/src/main.ts')
-rw-r--r--editors/code/src/main.ts6
1 files changed, 2 insertions, 4 deletions
diff --git a/editors/code/src/main.ts b/editors/code/src/main.ts
index b8e3396a6..7ad5e6934 100644
--- a/editors/code/src/main.ts
+++ b/editors/code/src/main.ts
@@ -20,6 +20,8 @@ export async function activate(context: vscode.ExtensionContext) {
20 ctx.registerCommand('parentModule', commands.parentModule); 20 ctx.registerCommand('parentModule', commands.parentModule);
21 ctx.registerCommand('syntaxTree', commands.syntaxTree); 21 ctx.registerCommand('syntaxTree', commands.syntaxTree);
22 ctx.registerCommand('expandMacro', commands.expandMacro); 22 ctx.registerCommand('expandMacro', commands.expandMacro);
23 ctx.registerCommand('run', commands.run);
24 ctx.registerCommand('runSingle', commands.runSingle); // Internal action for lenses
23 25
24 function disposeOnDeactivation(disposable: vscode.Disposable) { 26 function disposeOnDeactivation(disposable: vscode.Disposable) {
25 context.subscriptions.push(disposable); 27 context.subscriptions.push(disposable);
@@ -29,10 +31,6 @@ export async function activate(context: vscode.ExtensionContext) {
29 disposeOnDeactivation(vscode.commands.registerCommand(name, f)); 31 disposeOnDeactivation(vscode.commands.registerCommand(name, f));
30 } 32 }
31 33
32 // Commands are requests from vscode to the language server
33 registerCommand('rust-analyzer.run', commands.runnables.handle);
34 // Unlike the above this does not send requests to the language server
35 registerCommand('rust-analyzer.runSingle', commands.runnables.handleSingle);
36 registerCommand( 34 registerCommand(
37 'rust-analyzer.showReferences', 35 'rust-analyzer.showReferences',
38 (uri: string, position: lc.Position, locations: lc.Location[]) => { 36 (uri: string, position: lc.Position, locations: lc.Location[]) => {