diff options
author | Aleksey Kladov <[email protected]> | 2019-10-30 09:27:54 +0000 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2019-10-30 09:27:54 +0000 |
commit | a136cc0653d2b4133fb6387009cfdbaf3e2cf275 (patch) | |
tree | c7693867220abfefd90acb9965d91c6fe0023d38 /crates/ra_hir_def/src | |
parent | 56bc874f1d14922686b26afc8793b7e57a652990 (diff) |
introduce ra_hir_def
Diffstat (limited to 'crates/ra_hir_def/src')
-rw-r--r-- | crates/ra_hir_def/src/lib.rs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/crates/ra_hir_def/src/lib.rs b/crates/ra_hir_def/src/lib.rs new file mode 100644 index 000000000..f5dd2ae6f --- /dev/null +++ b/crates/ra_hir_def/src/lib.rs | |||
@@ -0,0 +1,14 @@ | |||
1 | use ra_arena::{impl_arena_id, RawId}; | ||
2 | use ra_db::CrateId; | ||
3 | |||
4 | #[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)] | ||
5 | pub struct ModuleId { | ||
6 | pub krate: CrateId, | ||
7 | pub module_id: CrateModuleId, | ||
8 | } | ||
9 | |||
10 | /// An ID of a module, **local** to a specific crate | ||
11 | // FIXME: rename to `LocalModuleId`. | ||
12 | #[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)] | ||
13 | pub struct CrateModuleId(RawId); | ||
14 | impl_arena_id!(CrateModuleId); | ||