diff options
Diffstat (limited to 'crates/ra_lsp_server/src/cargo_target_spec.rs')
-rw-r--r-- | crates/ra_lsp_server/src/cargo_target_spec.rs | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/crates/ra_lsp_server/src/cargo_target_spec.rs b/crates/ra_lsp_server/src/cargo_target_spec.rs index db9496bbe..e011eab7c 100644 --- a/crates/ra_lsp_server/src/cargo_target_spec.rs +++ b/crates/ra_lsp_server/src/cargo_target_spec.rs | |||
@@ -64,10 +64,7 @@ impl CargoTargetSpec { | |||
64 | None => return Ok(None), | 64 | None => return Ok(None), |
65 | }; | 65 | }; |
66 | let file_id = world.analysis().crate_root(crate_id)?; | 66 | let file_id = world.analysis().crate_root(crate_id)?; |
67 | let path = world | 67 | let path = world.vfs.read().file2path(ra_vfs::VfsFile(file_id.0.into())); |
68 | .vfs | ||
69 | .read() | ||
70 | .file2path(ra_vfs::VfsFile(file_id.0.into())); | ||
71 | let res = world.workspaces.iter().find_map(|ws| { | 68 | let res = world.workspaces.iter().find_map(|ws| { |
72 | let tgt = ws.cargo.target_by_root(&path)?; | 69 | let tgt = ws.cargo.target_by_root(&path)?; |
73 | let res = CargoTargetSpec { | 70 | let res = CargoTargetSpec { |