aboutsummaryrefslogtreecommitdiff
path: root/crates/ide_db/src
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ide_db/src')
-rw-r--r--crates/ide_db/src/helpers/import_assets.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/crates/ide_db/src/helpers/import_assets.rs b/crates/ide_db/src/helpers/import_assets.rs
index 3d9df463d..e03ccd351 100644
--- a/crates/ide_db/src/helpers/import_assets.rs
+++ b/crates/ide_db/src/helpers/import_assets.rs
@@ -5,7 +5,7 @@ use hir::{
5}; 5};
6use itertools::Itertools; 6use itertools::Itertools;
7use rustc_hash::FxHashSet; 7use rustc_hash::FxHashSet;
8use syntax::{ast, AstNode, SyntaxNode}; 8use syntax::{ast, utils::path_to_string_stripping_turbo_fish, AstNode, SyntaxNode};
9 9
10use crate::{ 10use crate::{
11 items_locator::{self, AssocItemSearch, DEFAULT_QUERY_SEARCH_LIMIT}, 11 items_locator::{self, AssocItemSearch, DEFAULT_QUERY_SEARCH_LIMIT},
@@ -57,7 +57,7 @@ pub struct PathImportCandidate {
57#[derive(Debug)] 57#[derive(Debug)]
58pub struct FirstSegmentUnresolved { 58pub struct FirstSegmentUnresolved {
59 fist_segment: ast::NameRef, 59 fist_segment: ast::NameRef,
60 full_qualifier: ModPath, 60 full_qualifier: ast::Path,
61} 61}
62 62
63/// A name that will be used during item lookups. 63/// A name that will be used during item lookups.
@@ -310,7 +310,7 @@ fn path_applicable_imports(
310 } 310 }
311 Some(first_segment_unresolved) => ( 311 Some(first_segment_unresolved) => (
312 first_segment_unresolved.fist_segment.to_string(), 312 first_segment_unresolved.fist_segment.to_string(),
313 first_segment_unresolved.full_qualifier.to_string(), 313 path_to_string_stripping_turbo_fish(&first_segment_unresolved.full_qualifier),
314 ), 314 ),
315 }; 315 };
316 316
@@ -583,7 +583,7 @@ fn path_import_candidate(
583 ImportCandidate::Path(PathImportCandidate { 583 ImportCandidate::Path(PathImportCandidate {
584 qualifier: Some(FirstSegmentUnresolved { 584 qualifier: Some(FirstSegmentUnresolved {
585 fist_segment: qualifier_start, 585 fist_segment: qualifier_start,
586 full_qualifier: ModPath::from_src_unhygienic(qualifier)?, 586 full_qualifier: qualifier,
587 }), 587 }),
588 name, 588 name,
589 }) 589 })