diff options
Diffstat (limited to 'crates/ide_helpers/src/lib.rs')
-rw-r--r-- | crates/ide_helpers/src/lib.rs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/crates/ide_helpers/src/lib.rs b/crates/ide_helpers/src/lib.rs index 069cb2bdd..ad4404b19 100644 --- a/crates/ide_helpers/src/lib.rs +++ b/crates/ide_helpers/src/lib.rs | |||
@@ -1,12 +1,14 @@ | |||
1 | //! A module with ide helpers for high-level ide features. | ||
1 | use hir::{Crate, Enum, Module, ScopeDef, Semantics, Trait}; | 2 | use hir::{Crate, Enum, Module, ScopeDef, Semantics, Trait}; |
2 | use ide_db::RootDatabase; | 3 | use ide_db::RootDatabase; |
3 | use syntax::ast::{self, make}; | 4 | use syntax::ast::{self, make}; |
4 | 5 | ||
5 | pub mod insert_use; | 6 | pub mod insert_use; |
6 | 7 | ||
8 | /// Converts the mod path struct into its ast representation. | ||
7 | pub fn mod_path_to_ast(path: &hir::ModPath) -> ast::Path { | 9 | pub fn mod_path_to_ast(path: &hir::ModPath) -> ast::Path { |
8 | let _p = profile::span("mod_path_to_ast"); | 10 | let _p = profile::span("mod_path_to_ast"); |
9 | 11 | ||
10 | let mut segments = Vec::new(); | 12 | let mut segments = Vec::new(); |
11 | let mut is_abs = false; | 13 | let mut is_abs = false; |
12 | match path.kind { | 14 | match path.kind { |