From 70a7cb34ec18d30a680a73727e1d87a0a786dc44 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Wed, 28 Nov 2018 21:03:30 +0300 Subject: switch to released id-arena --- crates/ra_db/Cargo.toml | 2 -- crates/ra_db/src/lib.rs | 7 ------- crates/ra_hir/Cargo.toml | 2 +- crates/ra_hir/src/arena.rs | 6 +++--- 4 files changed, 4 insertions(+), 13 deletions(-) (limited to 'crates') diff --git a/crates/ra_db/Cargo.toml b/crates/ra_db/Cargo.toml index 3bf2f635e..f316c0ab2 100644 --- a/crates/ra_db/Cargo.toml +++ b/crates/ra_db/Cargo.toml @@ -5,12 +5,10 @@ version = "0.1.0" authors = ["Aleksey Kladov "] [dependencies] -log = "0.4.5" relative-path = "0.4.0" salsa = "0.8.0" rustc-hash = "1.0" parking_lot = "0.6.4" -id-arena = { git = "https://github.com/fitzgen/id-arena/", rev = "43ecd67" } ra_syntax = { path = "../ra_syntax" } ra_editor = { path = "../ra_editor" } test_utils = { path = "../test_utils" } diff --git a/crates/ra_db/src/lib.rs b/crates/ra_db/src/lib.rs index 6a996c7f4..53805aada 100644 --- a/crates/ra_db/src/lib.rs +++ b/crates/ra_db/src/lib.rs @@ -1,11 +1,4 @@ //! ra_db defines basic database traits. Concrete DB is defined by ra_analysis. - -extern crate ra_editor; -extern crate ra_syntax; -extern crate relative_path; -extern crate rustc_hash; -extern crate salsa; - mod syntax_ptr; mod file_resolver; mod input; diff --git a/crates/ra_hir/Cargo.toml b/crates/ra_hir/Cargo.toml index 9bde289e7..1b9e148b2 100644 --- a/crates/ra_hir/Cargo.toml +++ b/crates/ra_hir/Cargo.toml @@ -10,7 +10,7 @@ relative-path = "0.4.0" salsa = "0.8.0" rustc-hash = "1.0" parking_lot = "0.6.4" -id-arena = { git = "https://github.com/fitzgen/id-arena/", rev = "43ecd67" } +id-arena = "2.0" ra_syntax = { path = "../ra_syntax" } ra_editor = { path = "../ra_editor" } ra_db = { path = "../ra_db" } diff --git a/crates/ra_hir/src/arena.rs b/crates/ra_hir/src/arena.rs index 8d67ab1c9..d4f9d9cb9 100644 --- a/crates/ra_hir/src/arena.rs +++ b/crates/ra_hir/src/arena.rs @@ -46,10 +46,10 @@ pub(crate) struct ArenaBehavior { impl id_arena::ArenaBehavior for ArenaBehavior { type Id = Id; - fn new_arena_id() -> usize { + fn new_arena_id() -> u32 { 0 } - fn new_id(_arena_id: usize, index: usize) -> Id { + fn new_id(_arena_id: u32, index: usize) -> Id { Id { idx: index as u32, _ty: PhantomData, @@ -58,7 +58,7 @@ impl id_arena::ArenaBehavior for ArenaBehavior { fn index(id: Id) -> usize { id.idx as usize } - fn arena_id(_id: Id) -> usize { + fn arena_id(_id: Id) -> u32 { 0 } } -- cgit v1.2.3