]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc/ty/mod.rs
Minor doc improvements
[rust.git] / src / librustc / ty / mod.rs
index 45a70be5842fcab3818ae82f235ab89e35e91a61..6ea759dee2126ae7d583fad4c4bc57f15d824e0e 100644 (file)
@@ -36,7 +36,7 @@
 use ty::util::{IntTypeExt, Discr};
 use ty::walk::TypeWalker;
 use util::captures::Captures;
-use util::nodemap::{NodeSet, DefIdMap, FxHashMap, FxHashSet};
+use util::nodemap::{NodeSet, DefIdMap, FxHashMap};
 use arena::SyncDroplessArena;
 use session::DataTypeKind;
 
@@ -63,8 +63,8 @@
 
 use hir;
 
-pub use self::sty::{Binder, CanonicalVar, DebruijnIndex, INNERMOST};
-pub use self::sty::{FnSig, GenSig, PolyFnSig, PolyGenSig};
+pub use self::sty::{Binder, BoundTy, BoundTyIndex, DebruijnIndex, INNERMOST};
+pub use self::sty::{FnSig, GenSig, CanonicalPolyFnSig, PolyFnSig, PolyGenSig};
 pub use self::sty::{InferTy, ParamTy, ProjectionTy, ExistentialPredicate};
 pub use self::sty::{ClosureSubsts, GeneratorSubsts, UpvarSubsts, TypeAndMut};
 pub use self::sty::{TraitRef, TyKind, PolyTraitRef};
@@ -141,7 +141,9 @@ pub struct Resolutions {
     pub maybe_unused_trait_imports: NodeSet,
     pub maybe_unused_extern_crates: Vec<(NodeId, Span)>,
     pub export_map: ExportMap,
-    pub extern_prelude: FxHashSet<Name>,
+    /// Extern prelude entries. The value is `true` if the entry was introduced
+    /// via `extern crate` item and not `--extern` option or compiler built-in.
+    pub extern_prelude: FxHashMap<Name, bool>,
 }
 
 #[derive(Clone, Copy, PartialEq, Eq, Debug)]
@@ -1841,8 +1843,7 @@ fn hash_stable<W: StableHasherResult>(&self,
                                           hcx: &mut StableHashingContext<'a>,
                                           hasher: &mut StableHasher<W>) {
         thread_local! {
-            static CACHE: RefCell<FxHashMap<usize, Fingerprint>> =
-                RefCell::new(FxHashMap());
+            static CACHE: RefCell<FxHashMap<usize, Fingerprint>> = Default::default();
         }
 
         let hash: Fingerprint = CACHE.with(|cache| {