Update handlers.rs to handlers/requests.rs

This commit is contained in:
Noah Bright 2024-09-28 06:17:22 -04:00
parent 546339a7be
commit 01aaa53ef2
4 changed files with 5 additions and 3 deletions

View file

@ -173,6 +173,8 @@ async function getDebugConfiguration(
if (debugConfig.name === "run binary") {
// The LSP side: crates\rust-analyzer\src\main_loop\handlers.rs,
// fn to_lsp_runnable(...) with RunnableKind::Bin
// FIXME: Neither crates\rust-analyzer\src\main_loop\handlers.rs
// nor to_lsp_runnable exist anymore
debugConfig.name = `run ${path.basename(executable)}`;
}

View file

@ -36,7 +36,7 @@ export async function selectRunnable(
if (runnables.length === 0) {
// it is the debug case, run always has at least 'cargo check ...'
// see crates\rust-analyzer\src\main_loop\handlers.rs, handle_runnables
// see crates\rust-analyzer\src\handlers\request.rs, handle_runnables
await vscode.window.showErrorMessage("There's no debug target!");
quickPick.dispose();
return;

View file

@ -29,7 +29,7 @@ export class Cargo {
static artifactSpec(cargoArgs: string[], executableArgs?: string[]): ArtifactSpec {
cargoArgs = [...cargoArgs, "--message-format=json"];
// arguments for a runnable from the quick pick should be updated.
// see crates\rust-analyzer\src\main_loop\handlers.rs, handle_code_lens
// see crates\rust-analyzer\src\handlers\request.rs, handle_code_lens
switch (cargoArgs[0]) {
case "run":
cargoArgs[0] = "build";