diff --git a/crates/ra_hir_expand/src/ast_id_map.rs b/crates/ra_hir_expand/src/ast_id_map.rs index 919ede0a03d..cb464c3ff17 100644 --- a/crates/ra_hir_expand/src/ast_id_map.rs +++ b/crates/ra_hir_expand/src/ast_id_map.rs @@ -50,7 +50,7 @@ pub struct AstIdMap { } impl AstIdMap { - pub fn from_source(node: &SyntaxNode) -> AstIdMap { + pub(crate) fn from_source(node: &SyntaxNode) -> AstIdMap { assert!(node.parent().is_none()); let mut res = AstIdMap { arena: Arena::default() }; // By walking the tree in bread-first order we make sure that parents @@ -83,7 +83,7 @@ fn erased_ast_id(&self, item: &SyntaxNode) -> ErasedFileAstId { } } - pub fn get(&self, id: FileAstId) -> AstPtr { + pub(crate) fn get(&self, id: FileAstId) -> AstPtr { self.arena[id.raw].cast::().unwrap() }