aboutsummaryrefslogtreecommitdiff
path: root/crates/ide_completion
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ide_completion')
-rw-r--r--crates/ide_completion/src/completions/flyimport.rs2
-rw-r--r--crates/ide_completion/src/lib.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/crates/ide_completion/src/completions/flyimport.rs b/crates/ide_completion/src/completions/flyimport.rs
index 8e211ae1e..9d5b61562 100644
--- a/crates/ide_completion/src/completions/flyimport.rs
+++ b/crates/ide_completion/src/completions/flyimport.rs
@@ -132,7 +132,7 @@ pub(crate) fn import_on_the_fly(acc: &mut Completions, ctx: &CompletionContext)
132 132
133 let user_input_lowercased = potential_import_name.to_lowercase(); 133 let user_input_lowercased = potential_import_name.to_lowercase();
134 let import_assets = import_assets(ctx, potential_import_name)?; 134 let import_assets = import_assets(ctx, potential_import_name)?;
135 let import_scope = ImportScope::find_insert_use_container( 135 let import_scope = ImportScope::find_insert_use_container_with_macros(
136 position_for_import(ctx, Some(import_assets.import_candidate()))?, 136 position_for_import(ctx, Some(import_assets.import_candidate()))?,
137 &ctx.sema, 137 &ctx.sema,
138 )?; 138 )?;
diff --git a/crates/ide_completion/src/lib.rs b/crates/ide_completion/src/lib.rs
index 6f3d5c5c5..e32633565 100644
--- a/crates/ide_completion/src/lib.rs
+++ b/crates/ide_completion/src/lib.rs
@@ -179,7 +179,7 @@ pub fn resolve_completion_edits(
179) -> Option<Vec<TextEdit>> { 179) -> Option<Vec<TextEdit>> {
180 let ctx = CompletionContext::new(db, position, config)?; 180 let ctx = CompletionContext::new(db, position, config)?;
181 let position_for_import = position_for_import(&ctx, None)?; 181 let position_for_import = position_for_import(&ctx, None)?;
182 let scope = ImportScope::find_insert_use_container(position_for_import, &ctx.sema)?; 182 let scope = ImportScope::find_insert_use_container_with_macros(position_for_import, &ctx.sema)?;
183 183
184 let current_module = ctx.sema.scope(position_for_import).module()?; 184 let current_module = ctx.sema.scope(position_for_import).module()?;
185 let current_crate = current_module.krate(); 185 let current_crate = current_module.krate();