diff options
author | Piotr Szpetkowski <[email protected]> | 2020-03-27 16:28:25 +0000 |
---|---|---|
committer | Piotr Szpetkowski <[email protected]> | 2020-03-27 16:28:25 +0000 |
commit | f016d8b900792c8ae4fce268920edea3035b6559 (patch) | |
tree | 9afc05a20e5e51f757317a71906dc45a97861415 /crates/ra_syntax/src/ast/edit.rs | |
parent | 75f6ab208a2b3e5fea9e8b6362df3fad7308a0d5 (diff) |
Fix merge-imports assist for wildcard imports
Diffstat (limited to 'crates/ra_syntax/src/ast/edit.rs')
-rw-r--r-- | crates/ra_syntax/src/ast/edit.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/crates/ra_syntax/src/ast/edit.rs b/crates/ra_syntax/src/ast/edit.rs index bdaecdc43..2304e00cf 100644 --- a/crates/ra_syntax/src/ast/edit.rs +++ b/crates/ra_syntax/src/ast/edit.rs | |||
@@ -302,9 +302,10 @@ impl ast::UseTree { | |||
302 | Some(it) => it, | 302 | Some(it) => it, |
303 | None => return self.clone(), | 303 | None => return self.clone(), |
304 | }; | 304 | }; |
305 | let use_tree = make::use_tree(suffix.clone(), self.use_tree_list(), self.alias()); | 305 | let use_tree = |
306 | make::use_tree(suffix.clone(), self.use_tree_list(), self.alias(), self.has_star()); | ||
306 | let nested = make::use_tree_list(iter::once(use_tree)); | 307 | let nested = make::use_tree_list(iter::once(use_tree)); |
307 | return make::use_tree(prefix.clone(), Some(nested), None); | 308 | return make::use_tree(prefix.clone(), Some(nested), None, false); |
308 | 309 | ||
309 | fn split_path_prefix(prefix: &ast::Path) -> Option<ast::Path> { | 310 | fn split_path_prefix(prefix: &ast::Path) -> Option<ast::Path> { |
310 | let parent = prefix.parent_path()?; | 311 | let parent = prefix.parent_path()?; |