diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2019-11-28 10:02:46 +0000 |
---|---|---|
committer | GitHub <[email protected]> | 2019-11-28 10:02:46 +0000 |
commit | 16030528b53d38e24c1e5733aa4cc46058d0bbd1 (patch) | |
tree | e878f88aebf11c0e54eff2e107dfaa4d192ab272 /crates/ra_ide/src/runnables.rs | |
parent | 2702fa1c5d6d8ad504c0d7703b6363ea09ba5570 (diff) | |
parent | ccd1b0800a5de5e046e6e9a4b6f49030c1ce3639 (diff) |
Merge #2440
2440: Rename Source -> InFile r=matklad a=matklad
Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'crates/ra_ide/src/runnables.rs')
-rw-r--r-- | crates/ra_ide/src/runnables.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/ra_ide/src/runnables.rs b/crates/ra_ide/src/runnables.rs index 8039a5164..e213e1a06 100644 --- a/crates/ra_ide/src/runnables.rs +++ b/crates/ra_ide/src/runnables.rs | |||
@@ -1,6 +1,6 @@ | |||
1 | //! FIXME: write short doc here | 1 | //! FIXME: write short doc here |
2 | 2 | ||
3 | use hir::Source; | 3 | use hir::InFile; |
4 | use itertools::Itertools; | 4 | use itertools::Itertools; |
5 | use ra_db::SourceDatabase; | 5 | use ra_db::SourceDatabase; |
6 | use ra_syntax::{ | 6 | use ra_syntax::{ |
@@ -66,8 +66,8 @@ fn runnable_mod(db: &RootDatabase, file_id: FileId, module: ast::Module) -> Opti | |||
66 | return None; | 66 | return None; |
67 | } | 67 | } |
68 | let range = module.syntax().text_range(); | 68 | let range = module.syntax().text_range(); |
69 | let src = hir::ModuleSource::from_child_node(db, Source::new(file_id.into(), &module.syntax())); | 69 | let src = hir::ModuleSource::from_child_node(db, InFile::new(file_id.into(), &module.syntax())); |
70 | let module = hir::Module::from_definition(db, Source::new(file_id.into(), src))?; | 70 | let module = hir::Module::from_definition(db, InFile::new(file_id.into(), src))?; |
71 | 71 | ||
72 | let path = module.path_to_root(db).into_iter().rev().filter_map(|it| it.name(db)).join("::"); | 72 | let path = module.path_to_root(db).into_iter().rev().filter_map(|it| it.name(db)).join("::"); |
73 | Some(Runnable { range, kind: RunnableKind::TestMod { path } }) | 73 | Some(Runnable { range, kind: RunnableKind::TestMod { path } }) |