aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2019-10-30 14:40:13 +0000
committerAleksey Kladov <[email protected]>2019-10-30 15:04:24 +0000
commitc1ed9ccc4ed7dfff3abb6eb01d7c311c8e31108c (patch)
treedc95229fc0863b46fe3d60cf25c2a56cdc4c8b39
parente5300ad3baf80c9903235a98a12b6cfd409e9f10 (diff)
fix compilation
-rw-r--r--crates/ra_hir/src/db.rs7
-rw-r--r--crates/ra_hir/src/either.rs1
-rw-r--r--crates/ra_hir/src/lib.rs3
-rw-r--r--crates/ra_hir/src/mock.rs2
-rw-r--r--crates/ra_hir_def/src/nameres.rs2
-rw-r--r--crates/ra_hir_def/src/nameres/raw.rs4
-rw-r--r--crates/ra_ide_api/src/db.rs1
7 files changed, 12 insertions, 8 deletions
diff --git a/crates/ra_hir/src/db.rs b/crates/ra_hir/src/db.rs
index 142d7338d..ebfd970eb 100644
--- a/crates/ra_hir/src/db.rs
+++ b/crates/ra_hir/src/db.rs
@@ -23,7 +23,10 @@ use crate::{
23 Struct, StructField, Trait, TypeAlias, 23 Struct, StructField, Trait, TypeAlias,
24}; 24};
25 25
26pub use hir_def::db::{InternDatabase, InternDatabaseStorage}; 26pub use hir_def::db::{
27 DefDatabase2, DefDatabase2Storage, InternDatabase, InternDatabaseStorage, RawItemsQuery,
28 RawItemsWithSourceMapQuery,
29};
27pub use hir_expand::db::{ 30pub use hir_expand::db::{
28 AstDatabase, AstDatabaseStorage, AstIdMapQuery, MacroArgQuery, MacroDefQuery, MacroExpandQuery, 31 AstDatabase, AstDatabaseStorage, AstIdMapQuery, MacroArgQuery, MacroDefQuery, MacroExpandQuery,
29 ParseMacroQuery, 32 ParseMacroQuery,
@@ -32,7 +35,7 @@ pub use hir_expand::db::{
32// This database uses `AstDatabase` internally, 35// This database uses `AstDatabase` internally,
33#[salsa::query_group(DefDatabaseStorage)] 36#[salsa::query_group(DefDatabaseStorage)]
34#[salsa::requires(AstDatabase)] 37#[salsa::requires(AstDatabase)]
35pub trait DefDatabase: HirDebugDatabase + hir_def::db::DefDatabase2 { 38pub trait DefDatabase: HirDebugDatabase + DefDatabase2 {
36 #[salsa::invoke(crate::adt::StructData::struct_data_query)] 39 #[salsa::invoke(crate::adt::StructData::struct_data_query)]
37 fn struct_data(&self, s: Struct) -> Arc<StructData>; 40 fn struct_data(&self, s: Struct) -> Arc<StructData>;
38 41
diff --git a/crates/ra_hir/src/either.rs b/crates/ra_hir/src/either.rs
deleted file mode 100644
index 44498dd38..000000000
--- a/crates/ra_hir/src/either.rs
+++ /dev/null
@@ -1 +0,0 @@
1pub use hir_def::either::*;
diff --git a/crates/ra_hir/src/lib.rs b/crates/ra_hir/src/lib.rs
index 4dd99c74f..fabe6eff6 100644
--- a/crates/ra_hir/src/lib.rs
+++ b/crates/ra_hir/src/lib.rs
@@ -26,7 +26,6 @@ macro_rules! impl_froms {
26 } 26 }
27} 27}
28 28
29mod either;
30pub mod debug; 29pub mod debug;
31 30
32pub mod db; 31pub mod db;
@@ -62,7 +61,6 @@ use crate::{ids::MacroFileKind, resolve::Resolver};
62 61
63pub use crate::{ 62pub use crate::{
64 adt::VariantDef, 63 adt::VariantDef,
65 either::Either,
66 expr::ExprScopes, 64 expr::ExprScopes,
67 from_source::FromSource, 65 from_source::FromSource,
68 generics::{GenericDef, GenericParam, GenericParams, HasGenericParams}, 66 generics::{GenericDef, GenericParam, GenericParams, HasGenericParams},
@@ -85,6 +83,7 @@ pub use self::code_model::{
85}; 83};
86 84
87pub use hir_def::{ 85pub use hir_def::{
86 either::Either,
88 name::Name, 87 name::Name,
89 path::{Path, PathKind}, 88 path::{Path, PathKind},
90 type_ref::Mutability, 89 type_ref::Mutability,
diff --git a/crates/ra_hir/src/mock.rs b/crates/ra_hir/src/mock.rs
index bb2d78abe..35dfaf3ba 100644
--- a/crates/ra_hir/src/mock.rs
+++ b/crates/ra_hir/src/mock.rs
@@ -17,12 +17,12 @@ use crate::{db, debug::HirDebugHelper, diagnostics::DiagnosticSink};
17pub const WORKSPACE: SourceRootId = SourceRootId(0); 17pub const WORKSPACE: SourceRootId = SourceRootId(0);
18 18
19#[salsa::database( 19#[salsa::database(
20 hir_def::db::DefDatabase2Storage,
21 ra_db::SourceDatabaseExtStorage, 20 ra_db::SourceDatabaseExtStorage,
22 ra_db::SourceDatabaseStorage, 21 ra_db::SourceDatabaseStorage,
23 db::InternDatabaseStorage, 22 db::InternDatabaseStorage,
24 db::AstDatabaseStorage, 23 db::AstDatabaseStorage,
25 db::DefDatabaseStorage, 24 db::DefDatabaseStorage,
25 db::DefDatabase2Storage,
26 db::HirDatabaseStorage 26 db::HirDatabaseStorage
27)] 27)]
28#[derive(Debug)] 28#[derive(Debug)]
diff --git a/crates/ra_hir_def/src/nameres.rs b/crates/ra_hir_def/src/nameres.rs
index 1a3f7667d..5893708e8 100644
--- a/crates/ra_hir_def/src/nameres.rs
+++ b/crates/ra_hir_def/src/nameres.rs
@@ -1 +1,3 @@
1//! FIXME: write short doc here
2
1pub mod raw; 3pub mod raw;
diff --git a/crates/ra_hir_def/src/nameres/raw.rs b/crates/ra_hir_def/src/nameres/raw.rs
index 13b9fbf48..86b4fef96 100644
--- a/crates/ra_hir_def/src/nameres/raw.rs
+++ b/crates/ra_hir_def/src/nameres/raw.rs
@@ -8,7 +8,6 @@ use ra_syntax::{
8 ast::{self, AttrsOwner, NameOwner}, 8 ast::{self, AttrsOwner, NameOwner},
9 AstNode, AstPtr, SourceFile, 9 AstNode, AstPtr, SourceFile,
10}; 10};
11use test_utils::tested_by;
12 11
13use crate::{ 12use crate::{
14 attr::Attr, 13 attr::Attr,
@@ -301,7 +300,8 @@ impl<DB: AstDatabase> RawItemsCollector<&DB> {
301 self.push_item(current_module, attrs, RawItemKind::Module(item)); 300 self.push_item(current_module, attrs, RawItemKind::Module(item));
302 return; 301 return;
303 } 302 }
304 tested_by!(name_res_works_for_broken_modules); 303 // FIXME: restore this mark once we complete hir splitting
304 // tested_by!(name_res_works_for_broken_modules);
305 } 305 }
306 306
307 fn add_use_item(&mut self, current_module: Option<Module>, use_item: ast::UseItem) { 307 fn add_use_item(&mut self, current_module: Option<Module>, use_item: ast::UseItem) {
diff --git a/crates/ra_ide_api/src/db.rs b/crates/ra_ide_api/src/db.rs
index 9146b647a..785e71808 100644
--- a/crates/ra_ide_api/src/db.rs
+++ b/crates/ra_ide_api/src/db.rs
@@ -23,6 +23,7 @@ use crate::{
23 hir::db::InternDatabaseStorage, 23 hir::db::InternDatabaseStorage,
24 hir::db::AstDatabaseStorage, 24 hir::db::AstDatabaseStorage,
25 hir::db::DefDatabaseStorage, 25 hir::db::DefDatabaseStorage,
26 hir::db::DefDatabase2Storage,
26 hir::db::HirDatabaseStorage 27 hir::db::HirDatabaseStorage
27)] 28)]
28#[derive(Debug)] 29#[derive(Debug)]