aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_analysis/src/imp.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_analysis/src/imp.rs')
-rw-r--r--crates/ra_analysis/src/imp.rs5
1 files changed, 2 insertions, 3 deletions
diff --git a/crates/ra_analysis/src/imp.rs b/crates/ra_analysis/src/imp.rs
index 1b7e16ff4..347d44638 100644
--- a/crates/ra_analysis/src/imp.rs
+++ b/crates/ra_analysis/src/imp.rs
@@ -20,8 +20,7 @@ use crate::{
20 completion::{completions, CompletionItem}, 20 completion::{completions, CompletionItem},
21 db::{self, FileSyntaxQuery, SyntaxDatabase}, 21 db::{self, FileSyntaxQuery, SyntaxDatabase},
22 hir::{ 22 hir::{
23 FunctionDescriptor, ModuleDescriptor, 23 FnDescriptor, FunctionDescriptor, ModuleDescriptor,
24 function::FnDescriptor,
25 Problem, 24 Problem,
26 DeclarationDescriptor, 25 DeclarationDescriptor,
27 }, 26 },
@@ -590,7 +589,7 @@ fn resolve_local_name(
590 let fn_def = name_ref.syntax().ancestors().find_map(ast::FnDef::cast)?; 589 let fn_def = name_ref.syntax().ancestors().find_map(ast::FnDef::cast)?;
591 let function = FunctionDescriptor::guess_from_source(db, file_id, fn_def); 590 let function = FunctionDescriptor::guess_from_source(db, file_id, fn_def);
592 let scopes = function.scope(db); 591 let scopes = function.scope(db);
593 let scope_entry = crate::hir::function::resolve_local_name(name_ref, &scopes)?; 592 let scope_entry = scopes.resolve_local_name(name_ref)?;
594 let syntax = db.resolve_syntax_ptr(scope_entry.ptr().into_global(file_id)); 593 let syntax = db.resolve_syntax_ptr(scope_entry.ptr().into_global(file_id));
595 Some((scope_entry.name().clone(), syntax.range())) 594 Some((scope_entry.name().clone(), syntax.range()))
596} 595}