canonicalize FxHash{Map,Set} imports

This commit is contained in:
Mazdak Farrokhzad 2019-12-24 05:02:53 +01:00
parent 66f5bf1b8b
commit 7901c7f707
81 changed files with 113 additions and 118 deletions

View File

@ -8,7 +8,7 @@ use crate::ich::Fingerprint;
use crate::middle::cstore::CrateStore;
use crate::session::CrateDisambiguator;
use crate::session::Session;
use crate::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::svh::Svh;
use rustc_index::vec::IndexVec;
use rustc_span::source_map::SourceMap;

View File

@ -12,8 +12,8 @@ use crate::hir::*;
use crate::middle::cstore::CrateStoreDyn;
use crate::ty::query::Providers;
use crate::util::common::time;
use crate::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::svh::Svh;
use rustc_index::vec::IndexVec;
use rustc_span::hygiene::MacroKind;

View File

@ -11,9 +11,10 @@ pub use self::UnsafeSource::*;
use crate::hir::def::{DefKind, Res};
use crate::hir::def_id::{DefId, DefIndex, LocalDefId, CRATE_DEF_INDEX};
use crate::ty::query::Providers;
use crate::util::nodemap::{FxHashSet, NodeMap};
use crate::util::nodemap::NodeMap;
use errors::FatalError;
use rustc_data_structures::fx::FxHashSet;
use rustc_data_structures::sync::{par_for_each_in, Send, Sync};
use rustc_macros::HashStable;
use rustc_serialize::{self, Decodable, Decoder, Encodable, Encoder};

View File

@ -33,7 +33,8 @@
use crate::ty::fold::TypeFolder;
use crate::ty::{self, Ty, TyCtxt, TypeFoldable};
use crate::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use std::collections::hash_map::Entry;

View File

@ -15,7 +15,7 @@ use crate::infer::SubregionOrigin;
use crate::middle::free_region::RegionRelations;
use crate::middle::region;
use crate::ty;
use crate::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use std::borrow::Cow;
use std::collections::btree_map::BTreeMap;

View File

@ -22,9 +22,9 @@ use crate::ty::relate::RelateResult;
use crate::ty::subst::{GenericArg, InternalSubsts, SubstsRef};
use crate::ty::{self, GenericParamDefKind, InferConst, Ty, TyCtxt};
use crate::ty::{ConstVid, FloatVid, IntVid, TyVid};
use crate::util::nodemap::{FxHashMap, FxHashSet};
use errors::DiagnosticBuilder;
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_data_structures::sync::Lrc;
use rustc_data_structures::unify as ut;
use rustc_span::symbol::Symbol;

View File

@ -27,9 +27,8 @@ use crate::middle::privacy::AccessLevels;
use crate::session::Session;
use crate::ty::layout::{LayoutError, LayoutOf, TyLayout};
use crate::ty::{self, print::Printer, subst::GenericArg, Ty, TyCtxt};
use crate::util::nodemap::FxHashMap;
use errors::DiagnosticBuilder;
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::sync;
use rustc_span::{symbol::Symbol, MultiSpan, Span};
use std::slice;

View File

@ -6,8 +6,8 @@ use crate::lint::builtin;
use crate::lint::context::{CheckLintNameResult, LintStore};
use crate::lint::{self, Level, Lint, LintId, LintSource};
use crate::session::Session;
use crate::util::nodemap::FxHashMap;
use errors::{Applicability, DiagnosticBuilder};
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::stable_hasher::{HashStable, StableHasher};
use rustc_span::source_map::MultiSpan;
use rustc_span::symbol::{sym, Symbol};

View File

@ -9,15 +9,15 @@
pub use self::LangItem::*;
use crate::hir;
use crate::hir::check_attr::Target;
use crate::hir::def_id::DefId;
use crate::hir::itemlikevisit::ItemLikeVisitor;
use crate::middle::cstore::ExternCrate;
use crate::middle::weak_lang_items;
use crate::ty::{self, TyCtxt};
use crate::util::nodemap::FxHashMap;
use crate::hir;
use crate::hir::itemlikevisit::ItemLikeVisitor;
use rustc_data_structures::fx::FxHashMap;
use rustc_macros::HashStable;
use rustc_span::symbol::{sym, Symbol};
use rustc_span::Span;

View File

@ -3,8 +3,9 @@
//! which are available for use externally when compiled as a library.
use crate::hir::HirId;
use crate::util::nodemap::{DefIdSet, FxHashMap};
use crate::util::nodemap::DefIdSet;
use rustc_data_structures::fx::FxHashMap;
use rustc_macros::HashStable;
use std::fmt;
use std::hash::Hash;

View File

@ -11,8 +11,8 @@ use crate::hir::def_id::DefId;
use crate::hir::Node;
use crate::ich::{NodeIdHashingMode, StableHashingContext};
use crate::ty::{self, DefIdTree, TyCtxt};
use crate::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::stable_hasher::{HashStable, StableHasher};
use rustc_index::vec::Idx;
use rustc_macros::HashStable;

View File

@ -5,7 +5,7 @@ use crate::hir::{GenericParam, ItemLocalId};
use crate::hir::{GenericParamKind, LifetimeParamKind};
use crate::ty;
use crate::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_macros::HashStable;
/// The origin of a named lifetime definition.

View File

@ -10,8 +10,9 @@ use crate::lint::builtin::BuiltinLintDiagnostics;
use crate::lint::{self, in_derive_expansion, Lint};
use crate::session::{DiagnosticMessageId, Session};
use crate::ty::{self, TyCtxt};
use crate::util::nodemap::{FxHashMap, FxHashSet};
use errors::DiagnosticBuilder;
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_feature::GateIssue;
use rustc_span::symbol::{sym, Symbol};
use rustc_span::{MultiSpan, Span};

View File

@ -5,8 +5,8 @@ use crate::ich::{Fingerprint, NodeIdHashingMode, StableHashingContext};
use crate::session::config::OptLevel;
use crate::ty::print::obsolete::DefPathBasedNames;
use crate::ty::{subst::InternalSubsts, Instance, InstanceDef, SymbolName, TyCtxt};
use crate::util::nodemap::FxHashMap;
use rustc_data_structures::base_n;
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::stable_hasher::{HashStable, StableHasher};
use rustc_span::source_map::Span;
use rustc_span::symbol::Symbol;

View File

@ -21,10 +21,10 @@ use crate::ty::GenericParamDefKind;
use crate::ty::SubtypePredicate;
use crate::ty::TypeckTables;
use crate::ty::{self, AdtKind, DefIdTree, ToPolyTraitRef, ToPredicate, Ty, TyCtxt, TypeFoldable};
use crate::util::nodemap::{FxHashMap, FxHashSet};
use errors::{pluralize, Applicability, DiagnosticBuilder, Style};
use rustc::hir::def_id::LOCAL_CRATE;
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_span::source_map::SourceMap;
use rustc_span::symbol::{kw, sym};
use rustc_span::{ExpnKind, MultiSpan, Span, DUMMY_SP};

View File

@ -3,8 +3,8 @@ use fmt_macros::{Parser, Piece, Position};
use crate::hir::def_id::DefId;
use crate::ty::{self, GenericParamDefKind, TyCtxt};
use crate::util::common::ErrorReported;
use crate::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_span::symbol::{kw, sym, Symbol};
use rustc_span::Span;
use syntax::ast::{MetaItem, NestedMetaItem};

View File

@ -39,7 +39,7 @@ use crate::ty::subst::{Subst, SubstsRef};
use crate::ty::{self, ToPolyTraitRef, ToPredicate, Ty, TyCtxt, TypeFoldable};
use crate::hir;
use crate::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_data_structures::sync::Lock;
use rustc_index::bit_set::GrowableBitSet;
use rustc_span::symbol::sym;

View File

@ -5,7 +5,8 @@ use crate::ich::{self, StableHashingContext};
use crate::traits;
use crate::ty::fast_reject::{self, SimplifiedType};
use crate::ty::{self, TyCtxt, TypeFoldable};
use crate::util::nodemap::{DefIdMap, FxHashMap};
use crate::util::nodemap::DefIdMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::stable_hasher::{HashStable, StableHasher};
use syntax::ast::Ident;

View File

@ -7,7 +7,7 @@ use crate::hir::def_id::DefId;
use crate::ty::outlives::Component;
use crate::ty::subst::{GenericArg, Subst, SubstsRef};
use crate::ty::{self, ToPolyTraitRef, ToPredicate, Ty, TyCtxt};
use crate::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use super::{Normalized, Obligation, ObligationCause, PredicateObligation, SelectionContext};

View File

@ -47,10 +47,10 @@ use crate::ty::{InferConst, ParamConst};
use crate::ty::{List, TyKind, TyS};
use crate::util::common::ErrorReported;
use crate::util::nodemap::{DefIdMap, DefIdSet, ItemLocalMap, ItemLocalSet, NodeMap};
use crate::util::nodemap::{FxHashMap, FxHashSet};
use arena::SyncDroplessArena;
use errors::DiagnosticBuilder;
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_data_structures::profiling::SelfProfilerRef;
use rustc_data_structures::sharded::ShardedHashMap;
use rustc_data_structures::stable_hasher::{

View File

@ -34,7 +34,7 @@
use crate::hir::def_id::DefId;
use crate::ty::{self, flags::FlagComputation, Binder, Ty, TyCtxt, TypeFlags};
use crate::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use std::collections::BTreeMap;
use std::fmt;

View File

@ -28,8 +28,9 @@ use crate::ty::subst::{InternalSubsts, Subst, SubstsRef};
use crate::ty::util::{Discr, IntTypeExt};
use crate::ty::walk::TypeWalker;
use crate::util::captures::Captures;
use crate::util::nodemap::{DefIdMap, FxHashMap, NodeMap, NodeSet};
use crate::util::nodemap::{DefIdMap, NodeMap, NodeSet};
use arena::SyncDroplessArena;
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::svh::Svh;
use rustc_macros::HashStable;

View File

@ -4,13 +4,10 @@ use crate::hir::def_id::DefId;
use crate::hir::{HirId, ItemLocalId};
use syntax::ast;
pub use rustc_data_structures::fx::FxHashMap;
pub use rustc_data_structures::fx::FxHashSet;
macro_rules! define_id_collections {
($map_name:ident, $set_name:ident, $key:ty) => {
pub type $map_name<T> = FxHashMap<$key, T>;
pub type $set_name = FxHashSet<$key>;
pub type $map_name<T> = rustc_data_structures::fx::FxHashMap<$key, T>;
pub type $set_name = rustc_data_structures::fx::FxHashSet<$key>;
};
}

View File

@ -19,10 +19,10 @@ use rustc::ty::layout::{
FnAbiExt, HasParamEnv, LayoutError, LayoutOf, PointeeInfo, Size, TyLayout, VariantIdx,
};
use rustc::ty::{self, Instance, Ty, TyCtxt};
use rustc::util::nodemap::FxHashMap;
use rustc_codegen_ssa::base::wants_msvc_seh;
use rustc_data_structures::base_n;
use rustc_data_structures::const_cstr;
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::small_c_str::SmallCStr;
use rustc_target::spec::{HasTargetSpec, Target};

View File

@ -33,11 +33,11 @@ use rustc::ty::layout::{
use rustc::ty::subst::{GenericArgKind, SubstsRef};
use rustc::ty::Instance;
use rustc::ty::{self, AdtKind, ParamEnv, Ty, TyCtxt};
use rustc::util::nodemap::FxHashMap;
use rustc::{bug, span_bug};
use rustc_codegen_ssa::traits::*;
use rustc_data_structures::const_cstr;
use rustc_data_structures::fingerprint::Fingerprint;
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::small_c_str::SmallCStr;
use rustc_data_structures::stable_hasher::{HashStable, StableHasher};
use rustc_fs_util::path_to_c_string;

View File

@ -24,9 +24,10 @@ use crate::value::Value;
use rustc::mir;
use rustc::session::config::{self, DebugInfo};
use rustc::ty::{self, Instance, InstanceDef, ParamEnv, Ty};
use rustc::util::nodemap::{DefIdMap, FxHashMap, FxHashSet};
use rustc::util::nodemap::DefIdMap;
use rustc_codegen_ssa::debuginfo::type_names;
use rustc_codegen_ssa::mir::debuginfo::{DebugScope, FunctionDebugContext, VariableKind};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_data_structures::small_c_str::SmallCStr;
use rustc_index::vec::IndexVec;

View File

@ -11,8 +11,9 @@ use rustc::ty::query::Providers;
use rustc::ty::subst::SubstsRef;
use rustc::ty::Instance;
use rustc::ty::{SymbolName, TyCtxt};
use rustc::util::nodemap::{DefIdMap, FxHashMap};
use rustc::util::nodemap::DefIdMap;
use rustc_data_structures::fingerprint::Fingerprint;
use rustc_data_structures::fx::FxHashMap;
use rustc_index::vec::IndexVec;
use syntax::expand::allocator::ALLOCATOR_METHODS;

View File

@ -19,7 +19,7 @@ use rustc::session::config::{
use rustc::session::Session;
use rustc::ty::TyCtxt;
use rustc::util::common::{print_time_passes_entry, set_time_depth, time_depth};
use rustc::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::profiling::SelfProfilerRef;
use rustc_data_structures::svh::Svh;
use rustc_data_structures::sync::Lrc;

View File

@ -40,8 +40,8 @@ use rustc::ty::layout::{FAT_PTR_ADDR, FAT_PTR_EXTRA};
use rustc::ty::query::Providers;
use rustc::ty::{self, Instance, Ty, TyCtxt};
use rustc::util::common::{print_time_passes_entry, set_time_depth, time, time_depth};
use rustc::util::nodemap::FxHashMap;
use rustc_codegen_utils::{check_for_rustc_errors_attr, symbol_names_test};
use rustc_data_structures::fx::FxHashMap;
use rustc_index::vec::Idx;
use rustc_session::cgu_reuse_tracker::CguReuse;
use rustc_span::Span;

View File

@ -2,7 +2,7 @@ use super::BackendTypes;
use rustc::mir::mono::CodegenUnit;
use rustc::session::Session;
use rustc::ty::{self, Instance, Ty};
use rustc::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use std::cell::RefCell;
use std::sync::Arc;

View File

@ -33,7 +33,7 @@ use rustc::ty::{self, layout::VariantIdx, Ty, TyCtxt};
use rustc::{lint, util};
use util::nodemap::HirIdSet;
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_feature::Stability;
use rustc_feature::{deprecated_attributes, AttributeGate, AttributeTemplate, AttributeType};

View File

@ -5,11 +5,12 @@ use lint::{LateContext, LintArray, LintContext};
use lint::{LateLintPass, LintPass};
use rustc::hir;
use rustc::hir::{is_range_literal, ExprKind, Node};
use rustc::lint;
use rustc::mir::interpret::{sign_extend, truncate};
use rustc::ty::layout::{self, IntegerExt, LayoutOf, SizeSkeleton, VariantIdx};
use rustc::ty::subst::SubstsRef;
use rustc::ty::{self, AdtKind, ParamEnv, Ty, TyCtxt};
use rustc::{lint, util::nodemap::FxHashSet};
use rustc_data_structures::fx::FxHashSet;
use rustc_index::vec::Idx;
use rustc_span::source_map;
use rustc_span::symbol::sym;

View File

@ -59,7 +59,7 @@ use rustc::middle::cstore::{self, DepKind};
use rustc::middle::dependency_format::{Dependencies, DependencyList, Linkage};
use rustc::session::config;
use rustc::ty::TyCtxt;
use rustc::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_target::spec::PanicStrategy;
crate fn calculate(tcx: TyCtxt<'_>) -> Dependencies {

View File

@ -219,8 +219,7 @@ use rustc::middle::cstore::{CrateSource, MetadataLoader};
use rustc::session::filesearch::{FileDoesntMatch, FileMatches, FileSearch};
use rustc::session::search_paths::PathKind;
use rustc::session::{config, CrateDisambiguator, Session};
use rustc::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashSet;
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_data_structures::svh::Svh;
use rustc_data_structures::sync::MetadataRef;

View File

@ -3,7 +3,7 @@ use rustc::hir::itemlikevisit::ItemLikeVisitor;
use rustc::middle::cstore::{self, NativeLibrary};
use rustc::session::Session;
use rustc::ty::TyCtxt;
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_span::source_map::Span;
use rustc_span::symbol::{kw, sym, Symbol};
use rustc_target::spec::abi::Abi;

View File

@ -18,8 +18,7 @@ use rustc_data_structures::fingerprint::Fingerprint;
use rustc_index::vec::Idx;
use rustc::session::config::{self, CrateType};
use rustc::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::stable_hasher::StableHasher;
use rustc_data_structures::sync::Lrc;
use rustc_serialize::{opaque, Encodable, Encoder, SpecializedEncoder};

View File

@ -7,7 +7,7 @@ use rustc::mir::traversal;
use rustc::mir::visit::{MutatingUseContext, NonUseContext, PlaceContext, Visitor};
use rustc::mir::{self, Body, Local, Location, ReadOnlyBodyAndCache};
use rustc::ty::{RegionVid, TyCtxt};
use rustc::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_index::bit_set::BitSet;
use rustc_index::vec::IndexVec;
use std::fmt;

View File

@ -20,7 +20,7 @@ use rustc::middle::lang_items;
use rustc::ty::fold::TypeFoldable;
use rustc::ty::subst::{InternalSubsts, Subst, SubstsRef};
use rustc::ty::{self, RegionVid, Ty, TyCtxt};
use rustc::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_errors::DiagnosticBuilder;
use rustc_index::vec::{Idx, IndexVec};
use std::iter;

View File

@ -1,7 +1,7 @@
use core::slice::Iter;
use rustc::mir::*;
use rustc::ty::{ParamEnv, Ty, TyCtxt};
use rustc::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_index::vec::{Enumerated, Idx, IndexVec};
use rustc_span::Span;
use smallvec::SmallVec;

View File

@ -192,8 +192,8 @@ use rustc::ty::print::obsolete::DefPathBasedNames;
use rustc::ty::subst::{InternalSubsts, Subst, SubstsRef};
use rustc::ty::{self, GenericParamDefKind, Instance, Ty, TyCtxt, TypeFoldable};
use rustc::util::common::time;
use rustc::util::nodemap::{DefIdMap, FxHashMap, FxHashSet};
use rustc::util::nodemap::DefIdMap;
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_data_structures::sync::{par_iter, MTLock, MTRef, ParallelIterator};
use rustc_index::bit_set::GrowableBitSet;

View File

@ -106,7 +106,8 @@ use rustc::ty::print::characteristic_def_id_of_type;
use rustc::ty::query::Providers;
use rustc::ty::{self, DefIdTree, InstanceDef, TyCtxt};
use rustc::util::common::time;
use rustc::util::nodemap::{DefIdSet, FxHashMap, FxHashSet};
use rustc::util::nodemap::DefIdSet;
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_span::symbol::Symbol;
use crate::monomorphize::collector::InliningMap;

View File

@ -13,7 +13,7 @@ use rustc::hir;
use rustc::mir::*;
use rustc::ty::layout::VariantIdx;
use rustc::ty::{self, TyCtxt};
use rustc::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_index::bit_set::BitSet;
use rustc_span::Span;
use std::fmt;

View File

@ -7,7 +7,7 @@ use rustc::mir::{
ProjectionElem, Rvalue,
};
use rustc::ty::{self, TyCtxt};
use rustc::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_index::vec::Idx;
use std::mem;

View File

@ -13,9 +13,7 @@ use rustc::lint;
use rustc::middle::codegen_fn_attrs::CodegenFnAttrFlags;
use rustc::middle::privacy;
use rustc::ty::{self, DefIdTree, TyCtxt};
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashMap;
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_span;
use rustc_span::symbol::sym;

View File

@ -9,13 +9,12 @@
//!
//! * Compiler internal types like `Ty` and `TyCtxt`
use rustc::hir;
use rustc::hir::def_id::{DefId, LOCAL_CRATE};
use rustc::hir::itemlikevisit::ItemLikeVisitor;
use rustc::ty::query::Providers;
use rustc::ty::TyCtxt;
use rustc::util::nodemap::FxHashMap;
use rustc::hir;
use rustc::hir::itemlikevisit::ItemLikeVisitor;
use rustc_data_structures::fx::FxHashMap;
use rustc_span::symbol::{sym, Symbol};
use syntax::ast;

View File

@ -5,7 +5,7 @@
use rustc::hir::intravisit as hir_visit;
use rustc::hir::{self, HirId};
use rustc::util::common::to_readable_str;
use rustc::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_span::Span;
use syntax::ast::{self, AttrId, NodeId};
use syntax::visit as ast_visit;

View File

@ -18,7 +18,8 @@ use rustc::middle::privacy;
use rustc::session::config;
use rustc::ty::query::Providers;
use rustc::ty::{self, TyCtxt};
use rustc::util::nodemap::{FxHashSet, HirIdSet};
use rustc::util::nodemap::HirIdSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_data_structures::sync::Lrc;
use rustc_target::spec::abi::Abi;

View File

@ -14,8 +14,7 @@ use rustc::hir::{Arm, Block, Expr, Local, Pat, PatKind, Stmt};
use rustc::middle::region::*;
use rustc::ty::query::Providers;
use rustc::ty::TyCtxt;
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_index::vec::Idx;
use rustc_span::source_map;
use rustc_span::Span;

View File

@ -11,7 +11,7 @@ use rustc::middle::stability::{DeprecationEntry, Index};
use rustc::session::Session;
use rustc::ty::query::Providers;
use rustc::ty::TyCtxt;
use rustc::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_span::symbol::{sym, Symbol};
use rustc_span::Span;
use syntax::ast::Attribute;

View File

@ -8,7 +8,7 @@ use rustc::hir::def::{self, DefKind, NonMacroAttrKind};
use rustc::hir::def_id::{DefId, CRATE_DEF_INDEX};
use rustc::session::Session;
use rustc::ty::{self, DefIdTree};
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_feature::BUILTIN_ATTRIBUTES;
use rustc_span::hygiene::MacroKind;
use rustc_span::source_map::SourceMap;

View File

@ -19,10 +19,9 @@ use rustc::lint::builtin::BuiltinLintDiagnostics;
use rustc::lint::builtin::{PUB_USE_OF_PRIVATE_EXTERN_CRATE, UNUSED_IMPORTS};
use rustc::session::DiagnosticMessageId;
use rustc::ty;
use rustc::util::nodemap::FxHashSet;
use rustc::{bug, span_bug};
use rustc_data_structures::fx::FxHashSet;
use rustc_data_structures::ptr_key::PtrKey;
use rustc_span::hygiene::ExpnId;
use rustc_span::symbol::kw;
use rustc_span::{MultiSpan, Span};

View File

@ -16,8 +16,8 @@ use rustc::hir::def::Namespace::{self, *};
use rustc::hir::def::{self, CtorKind, DefKind, PartialRes, PerNS};
use rustc::hir::def_id::{DefId, CRATE_DEF_INDEX};
use rustc::hir::TraitCandidate;
use rustc::util::nodemap::{FxHashMap, FxHashSet};
use rustc::{bug, lint, span_bug};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_span::symbol::{kw, sym};
use rustc_span::Span;
use smallvec::{smallvec, SmallVec};

View File

@ -11,7 +11,7 @@ use rustc::hir::def::{self, CtorKind, DefKind};
use rustc::hir::def_id::{DefId, CRATE_DEF_INDEX};
use rustc::hir::PrimTy;
use rustc::session::config::nightly_options;
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_span::hygiene::MacroKind;
use rustc_span::symbol::kw;
use rustc_span::Span;

View File

@ -20,6 +20,7 @@ pub use rustc::hir::def::{Namespace, PerNS};
use Determinacy::*;
use errors::{Applicability, DiagnosticBuilder};
use rustc::hir::def::Namespace::*;
use rustc::hir::def::{self, CtorKind, CtorOf, DefKind, ExportMap, NonMacroAttrKind, PartialRes};
use rustc::hir::def_id::{CrateNum, DefId, CRATE_DEF_INDEX, LOCAL_CRATE};
@ -32,12 +33,12 @@ use rustc::session::Session;
use rustc::span_bug;
use rustc::ty::query::Providers;
use rustc::ty::{self, DefIdTree, ResolverOutputs};
use rustc::util::nodemap::{DefIdMap, FxHashMap, FxHashSet, NodeMap, NodeSet};
use rustc_metadata::creader::{CStore, CrateLoader};
use errors::{Applicability, DiagnosticBuilder};
use rustc::util::nodemap::{DefIdMap, NodeMap, NodeSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet, FxIndexMap};
use rustc_data_structures::ptr_key::PtrKey;
use rustc_data_structures::sync::Lrc;
use rustc_expand::base::SyntaxExtension;
use rustc_metadata::creader::{CStore, CrateLoader};
use rustc_span::hygiene::{ExpnId, ExpnKind, MacroKind, SyntaxContext, Transparency};
use rustc_span::source_map::Spanned;
use rustc_span::symbol::{kw, sym};
@ -51,10 +52,6 @@ use syntax::visit::{self, Visitor};
use syntax::{struct_span_err, unwrap_or};
use log::debug;
use rustc_data_structures::fx::FxIndexMap;
use rustc_data_structures::ptr_key::PtrKey;
use rustc_data_structures::sync::Lrc;
use std::cell::{Cell, RefCell};
use std::collections::BTreeSet;
use std::{cmp, fmt, iter, ptr};

View File

@ -5,16 +5,20 @@
//! used between functions, and they operate in a purely top-down
//! way. Therefore, we break lifetime name resolution into a separate pass.
use errors::{pluralize, Applicability, DiagnosticBuilder};
use rustc::hir::def::{DefKind, Res};
use rustc::hir::def_id::{CrateNum, DefId, LocalDefId, LOCAL_CRATE};
use rustc::hir::intravisit::{self, NestedVisitorMap, Visitor};
use rustc::hir::map::Map;
use rustc::hir::{self, GenericParamKind, LifetimeParamKind};
use rustc::hir::{GenericArg, GenericParam, LifetimeName, Node, ParamName, QPath};
use rustc::ty::{self, DefIdTree, GenericParamDefKind, TyCtxt};
use errors::{pluralize, Applicability, DiagnosticBuilder};
use rustc::lint;
use rustc::middle::resolve_lifetime::*;
use rustc::session::Session;
use rustc::util::nodemap::{DefIdMap, FxHashMap, FxHashSet, HirIdMap, HirIdSet};
use rustc::ty::{self, DefIdTree, GenericParamDefKind, TyCtxt};
use rustc::util::nodemap::{DefIdMap, HirIdMap, HirIdSet};
use rustc::{bug, span_bug};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_span::symbol::{kw, sym};
use rustc_span::Span;
use std::borrow::Cow;
@ -22,15 +26,10 @@ use std::cell::Cell;
use std::mem::{replace, take};
use syntax::ast;
use syntax::attr;
use rustc::hir::intravisit::{self, NestedVisitorMap, Visitor};
use rustc::hir::{self, GenericParamKind, LifetimeParamKind};
use log::debug;
use rustc::{bug, span_bug};
use syntax::{help, span_err, struct_span_err, walk_list};
use rustc::middle::resolve_lifetime::*;
use log::debug;
use rustc_error_codes::*;
// This counts the no of times a lifetime is used

View File

@ -10,8 +10,8 @@ use rustc::hir::def::{self, DefKind, NonMacroAttrKind};
use rustc::hir::def_id;
use rustc::middle::stability;
use rustc::session::Session;
use rustc::util::nodemap::FxHashSet;
use rustc::{lint, span_bug, ty};
use rustc_data_structures::fx::FxHashSet;
use rustc_expand::base::SyntaxExtension;
use rustc_expand::base::{self, Indeterminate, InvocationRes};
use rustc_expand::compile_declarative_macro;

View File

@ -7,7 +7,7 @@ use rustc::traits::{Normalized, ObligationCause, TraitEngine, TraitEngineExt};
use rustc::ty::query::Providers;
use rustc::ty::subst::{InternalSubsts, Subst};
use rustc::ty::{self, ParamEnvAnd, Ty, TyCtxt};
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_span::source_map::{Span, DUMMY_SP};
crate fn provide(p: &mut Providers<'_>) {

View File

@ -14,7 +14,6 @@ use crate::middle::resolve_lifetime as rl;
use crate::namespace::Namespace;
use crate::require_c_abi_if_c_variadic;
use crate::util::common::ErrorReported;
use crate::util::nodemap::FxHashMap;
use errors::{Applicability, DiagnosticId};
use rustc::lint::builtin::AMBIGUOUS_ASSOCIATED_ITEMS;
use rustc::traits;
@ -22,6 +21,7 @@ use rustc::ty::subst::{self, InternalSubsts, Subst, SubstsRef};
use rustc::ty::wf::object_region_bounds;
use rustc::ty::{self, Const, DefIdTree, ToPredicate, Ty, TyCtxt, TypeFoldable};
use rustc::ty::{GenericParamDef, GenericParamDefKind};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_span::symbol::sym;
use rustc_span::{MultiSpan, Span, DUMMY_SP};
use rustc_target::spec::abi;
@ -35,8 +35,6 @@ use std::collections::BTreeSet;
use std::iter;
use std::slice;
use rustc_data_structures::fx::FxHashSet;
use rustc_error_codes::*;
#[derive(Debug)]

View File

@ -15,7 +15,6 @@ use crate::check::FnCtxt;
use crate::check::Needs;
use crate::check::TupleArgumentsFlag::DontTupleArguments;
use crate::util::common::ErrorReported;
use crate::util::nodemap::FxHashMap;
use errors::{pluralize, Applicability, DiagnosticBuilder, DiagnosticId};
use rustc::hir;
@ -31,6 +30,7 @@ use rustc::ty::adjustment::{Adjust, Adjustment, AllowTwoPhase, AutoBorrow, AutoB
use rustc::ty::Ty;
use rustc::ty::TypeFoldable;
use rustc::ty::{AdtKind, Visibility};
use rustc_data_structures::fx::FxHashMap;
use rustc_span::hygiene::DesugaringKind;
use rustc_span::source_map::Span;
use rustc_span::symbol::{kw, sym, Symbol};

View File

@ -4,13 +4,13 @@
//! types computed here.
use super::FnCtxt;
use crate::util::nodemap::FxHashMap;
use rustc::hir::def::{CtorKind, DefKind, Res};
use rustc::hir::def_id::DefId;
use rustc::hir::intravisit::{self, NestedVisitorMap, Visitor};
use rustc::hir::{self, Expr, ExprKind, Pat, PatKind};
use rustc::middle::region::{self, YieldData};
use rustc::ty::{self, Ty};
use rustc_data_structures::fx::FxHashMap;
use rustc_span::Span;
struct InteriorVisitor<'a, 'tcx> {

View File

@ -27,7 +27,7 @@ use rustc::ty::GenericParamDefKind;
use rustc::ty::{
self, ParamEnvAnd, ToPolyTraitRef, ToPredicate, TraitRef, Ty, TyCtxt, TypeFoldable,
};
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_data_structures::sync::Lrc;
use rustc_span::{symbol::Symbol, Span, DUMMY_SP};
use std::cmp::max;

View File

@ -4,7 +4,6 @@
use crate::check::FnCtxt;
use crate::middle::lang_items::FnOnceTraitLangItem;
use crate::namespace::Namespace;
use crate::util::nodemap::FxHashSet;
use errors::{pluralize, Applicability, DiagnosticBuilder};
use rustc::hir::def::{DefKind, Res};
use rustc::hir::def_id::{DefId, CRATE_DEF_INDEX, LOCAL_CRATE};
@ -14,6 +13,7 @@ use rustc::infer::type_variable::{TypeVariableOrigin, TypeVariableOriginKind};
use rustc::traits::Obligation;
use rustc::ty::print::with_crate_prefix;
use rustc::ty::{self, ToPolyTraitRef, ToPredicate, Ty, TyCtxt, TypeFoldable};
use rustc_data_structures::fx::FxHashSet;
use rustc_span::{source_map, FileName, Span};
use syntax::ast;
use syntax::util::lev_distance;

View File

@ -117,6 +117,7 @@ use rustc::ty::{
self, AdtKind, CanonicalUserType, Const, GenericParamDefKind, RegionKind, ToPolyTraitRef,
ToPredicate, Ty, TyCtxt, UserType,
};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_index::vec::Idx;
use rustc_span::hygiene::DesugaringKind;
use rustc_span::source_map::{original_sp, DUMMY_SP};
@ -144,7 +145,7 @@ use crate::session::config::EntryFnType;
use crate::session::Session;
use crate::util::captures::Captures;
use crate::util::common::{indenter, ErrorReported};
use crate::util::nodemap::{DefIdMap, DefIdSet, FxHashMap, FxHashSet, HirIdMap};
use crate::util::nodemap::{DefIdMap, DefIdSet, HirIdMap};
use crate::TypeAndSubsts;
use self::autoderef::Autoderef;

View File

@ -1,5 +1,4 @@
use crate::check::FnCtxt;
use crate::util::nodemap::FxHashMap;
use errors::{pluralize, Applicability, DiagnosticBuilder};
use rustc::hir::def::{CtorKind, DefKind, Res};
use rustc::hir::pat_util::EnumerateAndAdjustIterator;
@ -9,6 +8,7 @@ use rustc::infer::type_variable::{TypeVariableOrigin, TypeVariableOriginKind};
use rustc::traits::Pattern;
use rustc::ty::subst::GenericArg;
use rustc::ty::{self, BindingMode, Ty, TypeFoldable};
use rustc_data_structures::fx::FxHashMap;
use rustc_span::hygiene::DesugaringKind;
use rustc_span::Span;
use syntax::ast;

View File

@ -8,7 +8,7 @@ use rustc::middle::lang_items;
use rustc::traits::{self, ObligationCause, ObligationCauseCode};
use rustc::ty::subst::{InternalSubsts, Subst};
use rustc::ty::{self, AdtKind, GenericParamDefKind, ToPredicate, Ty, TyCtxt, TypeFoldable};
use rustc::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use errors::DiagnosticBuilder;
use rustc_span::symbol::sym;

View File

@ -30,7 +30,7 @@ use rustc::ty::util::IntTypeExt;
use rustc::ty::{self, AdtKind, Const, DefIdTree, ToPolyTraitRef, Ty, TyCtxt};
use rustc::ty::{ReprOptions, ToPredicate};
use rustc::util::captures::Captures;
use rustc::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_target::spec::abi;
use rustc_span::symbol::{kw, sym, Symbol};

View File

@ -1,6 +1,6 @@
use rustc::ty::fold::{TypeFoldable, TypeVisitor};
use rustc::ty::{self, Ty, TyCtxt};
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_span::source_map::Span;
#[derive(Clone, PartialEq, Eq, Hash, Debug)]

View File

@ -14,7 +14,7 @@ use rustc::hir::def_id::DefId;
use rustc::hir::itemlikevisit::ItemLikeVisitor;
use rustc::ty::query::Providers;
use rustc::ty::{self, TyCtxt, TypeFoldable};
use rustc::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use std::collections::hash_map::Entry::{Occupied, Vacant};
use rustc_span::Span;

View File

@ -1,6 +1,6 @@
use crate::util::nodemap::FxHashMap;
use rustc::hir::def_id::DefId;
use rustc::ty::{self, OutlivesPredicate, TyCtxt};
use rustc_data_structures::fx::FxHashMap;
use super::utils::*;

View File

@ -3,7 +3,7 @@ use rustc::hir::itemlikevisit::ItemLikeVisitor;
use rustc::hir::{self, Node};
use rustc::ty::subst::{GenericArg, GenericArgKind, Subst};
use rustc::ty::{self, Ty, TyCtxt};
use rustc::util::nodemap::FxHashMap;
use rustc_data_structures::fx::FxHashMap;
use rustc_span::Span;
use super::explicit::ExplicitPredicatesMap;

View File

@ -1,7 +1,7 @@
use rustc::hir;
use rustc::traits::auto_trait::{self, AutoTraitResult};
use rustc::ty::{self, Region, RegionVid, TypeFoldable};
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use std::fmt::Debug;

View File

@ -11,7 +11,7 @@ use rustc::hir::def::{CtorKind, DefKind, Res};
use rustc::hir::def_id::DefId;
use rustc::hir::{self, Mutability};
use rustc::ty;
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_metadata::creader::LoadedMacro;
use crate::clean::{self, GetDefId, ToSource, TypeKind};

View File

@ -19,7 +19,7 @@ use rustc::middle::stability;
use rustc::ty::fold::TypeFolder;
use rustc::ty::subst::InternalSubsts;
use rustc::ty::{self, AdtKind, Lift, Ty, TyCtxt};
use rustc::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_index::vec::{Idx, IndexVec};
use rustc_span::hygiene::MacroKind;
use rustc_span::symbol::{kw, sym};

View File

@ -14,7 +14,7 @@ use rustc::hir::{self, Mutability};
use rustc::middle::lang_items;
use rustc::middle::stability;
use rustc::ty::layout::VariantIdx;
use rustc::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_index::vec::IndexVec;
use rustc_span::hygiene::MacroKind;
use rustc_span::source_map::DUMMY_SP;

View File

@ -15,7 +15,7 @@ use rustc::hir::def_id::{DefId, LOCAL_CRATE};
use rustc::mir::interpret::{sign_extend, ConstValue, Scalar};
use rustc::ty::subst::{GenericArgKind, SubstsRef};
use rustc::ty::{self, DefIdTree, Ty};
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_span;
use rustc_span::symbol::{kw, sym, Symbol};
use std::mem;

View File

@ -8,7 +8,7 @@ use rustc::session::config::ErrorOutputType;
use rustc::session::DiagnosticOutput;
use rustc::session::{self, config};
use rustc::ty::{Ty, TyCtxt};
use rustc::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_driver::abort_on_err;
use rustc_feature::UnstableFeatures;
use rustc_interface::interface;

View File

@ -11,7 +11,7 @@ use std::fmt;
use rustc::hir;
use rustc::hir::def_id::DefId;
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_target::spec::abi::Abi;
use crate::clean::{self, PrimitiveType};

View File

@ -47,8 +47,8 @@ use rustc::hir::def_id::DefId;
use rustc::hir::{self, Mutability};
use rustc::middle::privacy::AccessLevels;
use rustc::middle::stability;
use rustc::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::flock;
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_feature::UnstableFeatures;
use rustc_span::edition::Edition;
use rustc_span::hygiene::MacroKind;

View File

@ -4,7 +4,7 @@ use crate::core::DocContext;
use crate::fold::DocFolder;
use rustc::hir::def_id::{DefId, LOCAL_CRATE};
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_span::symbol::sym;
pub const COLLECT_TRAIT_IMPLS: Pass = Pass {

View File

@ -6,7 +6,7 @@ use rustc::hir::def_id::{DefId, LOCAL_CRATE};
use rustc::hir::{self, Node};
use rustc::middle::privacy::AccessLevel;
use rustc::ty::TyCtxt;
use rustc::util::nodemap::{FxHashMap, FxHashSet};
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
use rustc_span::hygiene::MacroKind;
use rustc_span::source_map::Spanned;
use rustc_span::symbol::sym;

View File

@ -2,7 +2,7 @@ use rustc::hir::def::{DefKind, Res};
use rustc::hir::def_id::{CrateNum, DefId, CRATE_DEF_INDEX};
use rustc::middle::privacy::{AccessLevel, AccessLevels};
use rustc::ty::{TyCtxt, Visibility};
use rustc::util::nodemap::FxHashSet;
use rustc_data_structures::fx::FxHashSet;
use rustc_span::symbol::sym;
use crate::clean::{AttributesExt, NestedAttributesExt};