From 3fe6f422f9ef13b9171dbeab0c5c427f729f9983 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Fri, 4 Jan 2019 16:15:50 +0300 Subject: remove id arena --- crates/ra_hir/src/function/scope.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'crates/ra_hir/src/function') diff --git a/crates/ra_hir/src/function/scope.rs b/crates/ra_hir/src/function/scope.rs index 3e4cfad0c..42bfe4f32 100644 --- a/crates/ra_hir/src/function/scope.rs +++ b/crates/ra_hir/src/function/scope.rs @@ -5,19 +5,19 @@ use ra_syntax::{ algo::generate, ast::{self, ArgListOwner, LoopBodyOwner, NameOwner}, }; +use ra_arena::{Arena, RawId, impl_arena_id}; use ra_db::LocalSyntaxPtr; -use crate::{ - arena::{Arena, Id}, - Name, AsName, -}; +use crate::{Name, AsName}; -pub(crate) type ScopeId = Id; +#[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)] +pub struct ScopeId(RawId); +impl_arena_id!(ScopeId); #[derive(Debug, PartialEq, Eq)] pub struct FnScopes { pub self_param: Option, - scopes: Arena, + scopes: Arena, scope_for: FxHashMap, } -- cgit v1.2.3