From 20fdd14c62aa9c5327f1e6afc04f01a5af6763fb Mon Sep 17 00:00:00 2001 From: vsrs Date: Thu, 14 May 2020 16:02:01 +0300 Subject: Multiple binaries support for launch.json. Generate unique names on the LSP side. --- editors/code/src/debug.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'editors/code/src/debug.ts') diff --git a/editors/code/src/debug.ts b/editors/code/src/debug.ts index 966019883..1f93a2b7e 100644 --- a/editors/code/src/debug.ts +++ b/editors/code/src/debug.ts @@ -88,8 +88,9 @@ export async function getDebugConfiguration(ctx: Ctx, config: ra.Runnable): Prom } if (debugConfig.name === "run binary") { - // A workaround for multiple binaries. It would be better to get proper names on the LSP side. - debugConfig.name = `run binary [${path.basename(executable)}]`; + // The LSP side: crates\rust-analyzer\src\main_loop\handlers.rs, + // fn to_lsp_runnable(...) with RunnableKind::Bin + debugConfig.name = `run binary '${path.basename(executable)}'`; } if (debugConfig.cwd) { -- cgit v1.2.3