From 9526c198f6b38438f2eae37b23a7426dff5e4341 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Tue, 22 Jun 2021 16:47:34 +0300 Subject: intenral: dont export impl details --- crates/hir/src/lib.rs | 8 +++----- crates/hir/src/semantics/source_to_def.rs | 4 ++-- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/crates/hir/src/lib.rs b/crates/hir/src/lib.rs index 30cc34403..9c56fe1a6 100644 --- a/crates/hir/src/lib.rs +++ b/crates/hir/src/lib.rs @@ -51,7 +51,7 @@ use hir_def::{ LocalEnumVariantId, LocalFieldId, Lookup, ModuleId, StaticId, StructId, TraitId, TypeAliasId, TypeParamId, UnionId, }; -use hir_expand::{name::name, MacroCallKind, MacroDefKind}; +use hir_expand::{name::name, MacroCallKind, MacroDefId, MacroDefKind}; use hir_ty::{ autoderef, consteval::ConstExt, @@ -106,10 +106,9 @@ pub use { hir_def::{ adt::StructKind, attr::{Attr, Attrs, AttrsWithOwner, Documentation}, - body::scope::ExprScopes, find_path::PrefixKind, import_map, - item_scope::ItemInNs, + item_scope::ItemInNs, // FIXME: don't re-export ItemInNs, as it uses raw ids. nameres::ModuleSource, path::{ModPath, PathKind}, type_ref::{Mutability, TypeRef}, @@ -117,8 +116,7 @@ pub use { }, hir_expand::{ name::{known, Name}, - ExpandResult, HirFileId, InFile, MacroCallId, MacroCallLoc, /* FIXME */ MacroDefId, - MacroFile, Origin, + ExpandResult, HirFileId, InFile, MacroFile, Origin, }, hir_ty::display::HirDisplay, }; diff --git a/crates/hir/src/semantics/source_to_def.rs b/crates/hir/src/semantics/source_to_def.rs index 0c5ba3a8f..12e5d65fa 100644 --- a/crates/hir/src/semantics/source_to_def.rs +++ b/crates/hir/src/semantics/source_to_def.rs @@ -95,7 +95,7 @@ use hir_def::{ ImplId, LifetimeParamId, ModuleId, StaticId, StructId, TraitId, TypeAliasId, TypeParamId, UnionId, VariantId, }; -use hir_expand::{name::AsName, AstId, MacroCallId, MacroDefKind}; +use hir_expand::{name::AsName, AstId, MacroCallId, MacroDefId, MacroDefKind}; use rustc_hash::FxHashMap; use smallvec::SmallVec; use stdx::impl_from; @@ -104,7 +104,7 @@ use syntax::{ match_ast, AstNode, SyntaxNode, }; -use crate::{db::HirDatabase, InFile, MacroDefId}; +use crate::{db::HirDatabase, InFile}; pub(super) type SourceToDefCache = FxHashMap; -- cgit v1.2.3