aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_lsp_server/src/main_loop
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2018-12-19 12:04:15 +0000
committerAleksey Kladov <[email protected]>2018-12-20 09:15:38 +0000
commita5ef8ad05b7c1f7148c59814b55d641fd75aff75 (patch)
treedf6c46378d81dc7cb3242ff7f57d836353bde5ed /crates/ra_lsp_server/src/main_loop
parent6a755ed83a583d1f70a5fbcff2d4933b52628cfe (diff)
swtich lsp server to vfs
Diffstat (limited to 'crates/ra_lsp_server/src/main_loop')
-rw-r--r--crates/ra_lsp_server/src/main_loop/handlers.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/ra_lsp_server/src/main_loop/handlers.rs b/crates/ra_lsp_server/src/main_loop/handlers.rs
index acca480c7..572ae7fb5 100644
--- a/crates/ra_lsp_server/src/main_loop/handlers.rs
+++ b/crates/ra_lsp_server/src/main_loop/handlers.rs
@@ -326,9 +326,9 @@ pub fn handle_runnables(
326 None => return Ok(None), 326 None => return Ok(None),
327 }; 327 };
328 let file_id = world.analysis().crate_root(crate_id)?; 328 let file_id = world.analysis().crate_root(crate_id)?;
329 let path = world.path_map.get_path(file_id); 329 let path = world.vfs.read().file2path(ra_vfs::VfsFile(file_id.0));
330 let res = world.workspaces.iter().find_map(|ws| { 330 let res = world.workspaces.iter().find_map(|ws| {
331 let tgt = ws.target_by_root(path)?; 331 let tgt = ws.target_by_root(&path)?;
332 let res = CargoTargetSpec { 332 let res = CargoTargetSpec {
333 package: tgt.package(ws).name(ws).to_string(), 333 package: tgt.package(ws).name(ws).to_string(),
334 target: tgt.name(ws).to_string(), 334 target: tgt.name(ws).to_string(),