mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-26 20:09:19 +00:00
fix: Fix import_map::search_dependencies
getting confused by assoc and non assoc items with the same name
This commit is contained in:
parent
3aa6306728
commit
ca995d765d
3 changed files with 66 additions and 36 deletions
|
@ -36,7 +36,8 @@ pub fn items_with_name<'a>(
|
|||
NameToImport::Prefix(exact_name, case_sensitive)
|
||||
| NameToImport::Exact(exact_name, case_sensitive) => {
|
||||
let mut local_query = symbol_index::Query::new(exact_name.clone());
|
||||
let mut external_query = import_map::Query::new(exact_name);
|
||||
let mut external_query =
|
||||
import_map::Query::new(exact_name).assoc_search_mode(assoc_item_search);
|
||||
if prefix {
|
||||
local_query.prefix();
|
||||
external_query = external_query.prefix();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue