diff options
author | Kirill Bulatov <[email protected]> | 2020-12-04 14:03:22 +0000 |
---|---|---|
committer | Kirill Bulatov <[email protected]> | 2020-12-07 21:41:08 +0000 |
commit | deda74edd89affb3f77d274776d2a672bc11db90 (patch) | |
tree | e9c7dac6df4fd06012ca6b6e628223e925998f1e /crates/completion/src/completions/unqualified_path.rs | |
parent | 93bc009a5968c964693299263689b50b2efe9abc (diff) |
Use stateless completion resolve
Diffstat (limited to 'crates/completion/src/completions/unqualified_path.rs')
-rw-r--r-- | crates/completion/src/completions/unqualified_path.rs | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/crates/completion/src/completions/unqualified_path.rs b/crates/completion/src/completions/unqualified_path.rs index 81691cd7f..26a2b7a1b 100644 --- a/crates/completion/src/completions/unqualified_path.rs +++ b/crates/completion/src/completions/unqualified_path.rs | |||
@@ -9,7 +9,7 @@ use test_utils::mark; | |||
9 | 9 | ||
10 | use crate::{ | 10 | use crate::{ |
11 | render::{render_resolution_with_import, RenderContext}, | 11 | render::{render_resolution_with_import, RenderContext}, |
12 | CompletionContext, Completions, | 12 | CompletionContext, Completions, ImportEdit, |
13 | }; | 13 | }; |
14 | 14 | ||
15 | pub(crate) fn complete_unqualified_path(acc: &mut Completions, ctx: &CompletionContext) { | 15 | pub(crate) fn complete_unqualified_path(acc: &mut Completions, ctx: &CompletionContext) { |
@@ -103,9 +103,11 @@ fn fuzzy_completion(acc: &mut Completions, ctx: &CompletionContext) -> Option<() | |||
103 | .filter_map(|(import_path, definition)| { | 103 | .filter_map(|(import_path, definition)| { |
104 | render_resolution_with_import( | 104 | render_resolution_with_import( |
105 | RenderContext::new(ctx), | 105 | RenderContext::new(ctx), |
106 | import_path.clone(), | 106 | ImportEdit { |
107 | import_scope.clone(), | 107 | import_path: import_path.clone(), |
108 | ctx.config.merge, | 108 | import_scope: import_scope.clone(), |
109 | merge_behaviour: ctx.config.merge, | ||
110 | }, | ||
109 | &definition, | 111 | &definition, |
110 | ) | 112 | ) |
111 | }); | 113 | }); |