aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_lsp_server/src/main_loop
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_lsp_server/src/main_loop')
-rw-r--r--crates/ra_lsp_server/src/main_loop/handlers.rs5
1 files changed, 2 insertions, 3 deletions
diff --git a/crates/ra_lsp_server/src/main_loop/handlers.rs b/crates/ra_lsp_server/src/main_loop/handlers.rs
index ffca3f51c..1baed73ad 100644
--- a/crates/ra_lsp_server/src/main_loop/handlers.rs
+++ b/crates/ra_lsp_server/src/main_loop/handlers.rs
@@ -207,12 +207,11 @@ pub fn handle_goto_definition(
207 params: req::TextDocumentPositionParams, 207 params: req::TextDocumentPositionParams,
208) -> Result<Option<req::GotoDefinitionResponse>> { 208) -> Result<Option<req::GotoDefinitionResponse>> {
209 let position = params.try_conv_with(&world)?; 209 let position = params.try_conv_with(&world)?;
210 let rr = match world.analysis().approximately_resolve_symbol(position)? { 210 let navs = match world.analysis().goto_defenition(position)? {
211 None => return Ok(None), 211 None => return Ok(None),
212 Some(it) => it, 212 Some(it) => it,
213 }; 213 };
214 let res = rr 214 let res = navs
215 .resolves_to
216 .into_iter() 215 .into_iter()
217 .map(|nav| nav.try_conv_with(&world)) 216 .map(|nav| nav.try_conv_with(&world))
218 .collect::<Result<Vec<_>>>()?; 217 .collect::<Result<Vec<_>>>()?;