Debug lens fix for a binary.

This commit is contained in:
vsrs 2020-05-20 09:42:00 +03:00
parent efac093093
commit d264d7b9f2

View file

@ -51,10 +51,14 @@ export class Cargo {
// arguments for a runnable from the quick pick should be updated.
// see crates\rust-analyzer\src\main_loop\handlers.rs, handle_code_lens
if (cargoArgs[0] === "run") {
cargoArgs[0] = "build";
} else if (cargoArgs.indexOf("--no-run") === -1) {
cargoArgs.push("--no-run");
switch (cargoArgs[0]) {
case "run": cargoArgs[0] = "build"; break;
case "test": {
if (cargoArgs.indexOf("--no-run") === -1) {
cargoArgs.push("--no-run");
}
break;
}
}
let artifacts = await this.artifactsFromArgs(cargoArgs);