]> git.lizzy.rs Git - rust.git/commitdiff
cleanup: Remove `DefIndexAddressSpace`
authorVadim Petrochenkov <vadim.petrochenkov@gmail.com>
Wed, 8 May 2019 19:07:12 +0000 (22:07 +0300)
committerVadim Petrochenkov <vadim.petrochenkov@gmail.com>
Wed, 8 May 2019 21:46:38 +0000 (00:46 +0300)
42 files changed:
src/librustc/hir/def_id.rs
src/librustc/hir/lowering.rs
src/librustc/hir/map/collector.rs
src/librustc/hir/map/def_collector.rs
src/librustc/hir/map/definitions.rs
src/librustc/hir/map/mod.rs
src/librustc/traits/specialize/mod.rs
src/librustc_driver/pretty.rs
src/librustc_metadata/decoder.rs
src/librustc_metadata/index.rs
src/librustc_metadata/index_builder.rs
src/librustc_mir/util/graphviz.rs
src/librustc_resolve/lib.rs
src/librustc_resolve/macros.rs
src/librustdoc/core.rs
src/test/mir-opt/graphviz.rs
src/test/mir-opt/inline-closure-borrows-arg.rs
src/test/mir-opt/inline-closure.rs
src/test/mir-opt/retag.rs
src/test/ui/nll/closure-requirements/escape-argument-callee.stderr
src/test/ui/nll/closure-requirements/escape-argument.stderr
src/test/ui/nll/closure-requirements/escape-upvar-nested.stderr
src/test/ui/nll/closure-requirements/escape-upvar-ref.stderr
src/test/ui/nll/closure-requirements/propagate-approximated-fail-no-postdom.stderr
src/test/ui/nll/closure-requirements/propagate-approximated-ref.stderr
src/test/ui/nll/closure-requirements/propagate-approximated-shorter-to-static-comparing-against-free.stderr
src/test/ui/nll/closure-requirements/propagate-approximated-shorter-to-static-no-bound.stderr
src/test/ui/nll/closure-requirements/propagate-approximated-shorter-to-static-wrong-bound.stderr
src/test/ui/nll/closure-requirements/propagate-approximated-val.stderr
src/test/ui/nll/closure-requirements/propagate-despite-same-free-region.stderr
src/test/ui/nll/closure-requirements/propagate-fail-to-approximate-longer-no-bounds.stderr
src/test/ui/nll/closure-requirements/propagate-fail-to-approximate-longer-wrong-bounds.stderr
src/test/ui/nll/closure-requirements/propagate-from-trait-match.stderr
src/test/ui/nll/closure-requirements/return-wrong-bound-region.stderr
src/test/ui/nll/ty-outlives/projection-no-regions-closure.stderr
src/test/ui/nll/ty-outlives/projection-one-region-closure.stderr
src/test/ui/nll/ty-outlives/projection-one-region-trait-bound-closure.stderr
src/test/ui/nll/ty-outlives/projection-one-region-trait-bound-static-closure.stderr
src/test/ui/nll/ty-outlives/projection-two-region-trait-bound-closure.stderr
src/test/ui/nll/ty-outlives/ty-param-closure-approximate-lower-bound.stderr
src/test/ui/nll/ty-outlives/ty-param-closure-outlives-from-return-type.stderr
src/test/ui/nll/ty-outlives/ty-param-closure-outlives-from-where-clause.stderr

index 8536f38e48c6d5e0b3483ff9aa65aee8a98b3518..b268a1a494d107cc92b1996b51374f89e61fd2e9 100644 (file)
@@ -1,5 +1,5 @@
 use crate::ty::{self, TyCtxt};
-use crate::hir::map::definitions::FIRST_FREE_HIGH_DEF_INDEX;
+use crate::hir::map::definitions::FIRST_FREE_DEF_INDEX;
 use rustc_data_structures::indexed_vec::Idx;
 use serialize;
 use std::fmt;
@@ -99,17 +99,6 @@ impl serialize::UseSpecializedDecodable for CrateNum {}
 /// A DefIndex is an index into the hir-map for a crate, identifying a
 /// particular definition. It should really be considered an interned
 /// shorthand for a particular DefPath.
-///
-/// At the moment we are allocating the numerical values of DefIndexes from two
-/// address spaces: DefIndexAddressSpace::Low and DefIndexAddressSpace::High.
-/// This allows us to allocate the DefIndexes of all item-likes
-/// (Items, TraitItems, and ImplItems) into one of these spaces and
-/// consequently use a simple array for lookup tables keyed by DefIndex and
-/// known to be densely populated. This is especially important for the HIR map.
-///
-/// Since the DefIndex is mostly treated as an opaque ID, you probably
-/// don't have to care about these address spaces.
-
 #[derive(Clone, PartialEq, Eq, PartialOrd, Ord, Hash, Copy)]
 pub struct DefIndex(u32);
 
@@ -119,33 +108,20 @@ impl serialize::UseSpecializedDecodable for CrateNum {}
 
 impl fmt::Debug for DefIndex {
     fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
-        write!(f,
-               "DefIndex({}:{})",
-               self.address_space().index(),
-               self.as_array_index())
+        write!(f, "DefIndex({})", self.as_array_index())
     }
 }
 
 impl DefIndex {
-    #[inline]
-    pub fn address_space(&self) -> DefIndexAddressSpace {
-        match self.0 & 1 {
-            0 => DefIndexAddressSpace::Low,
-            1 => DefIndexAddressSpace::High,
-            _ => unreachable!()
-        }
-    }
-
     /// Converts this DefIndex into a zero-based array index.
-    /// This index is the offset within the given DefIndexAddressSpace.
     #[inline]
     pub fn as_array_index(&self) -> usize {
-        (self.0 >> 1) as usize
+        self.0 as usize
     }
 
     #[inline]
-    pub fn from_array_index(i: usize, address_space: DefIndexAddressSpace) -> DefIndex {
-        DefIndex::from_raw_u32(((i << 1) | (address_space as usize)) as u32)
+    pub fn from_array_index(i: usize) -> DefIndex {
+        DefIndex(i as u32)
     }
 
     // Proc macros from a proc-macro crate have a kind of virtual DefIndex. This
@@ -153,33 +129,28 @@ pub fn from_array_index(i: usize, address_space: DefIndexAddressSpace) -> DefInd
     // index of the macro in the CrateMetadata::proc_macros array) to the
     // corresponding DefIndex.
     pub fn from_proc_macro_index(proc_macro_index: usize) -> DefIndex {
-        // DefIndex for proc macros start from FIRST_FREE_HIGH_DEF_INDEX,
-        // because the first FIRST_FREE_HIGH_DEF_INDEX indexes are reserved
+        // DefIndex for proc macros start from FIRST_FREE_DEF_INDEX,
+        // because the first FIRST_FREE_DEF_INDEX indexes are reserved
         // for internal use.
         let def_index = DefIndex::from_array_index(
-            proc_macro_index.checked_add(FIRST_FREE_HIGH_DEF_INDEX)
-                .expect("integer overflow adding `proc_macro_index`"),
-            DefIndexAddressSpace::High);
+            proc_macro_index.checked_add(FIRST_FREE_DEF_INDEX)
+                .expect("integer overflow adding `proc_macro_index`"));
         assert!(def_index != CRATE_DEF_INDEX);
         def_index
     }
 
     // This function is the reverse of from_proc_macro_index() above.
     pub fn to_proc_macro_index(self: DefIndex) -> usize {
-        assert_eq!(self.address_space(), DefIndexAddressSpace::High);
-
-        self.as_array_index().checked_sub(FIRST_FREE_HIGH_DEF_INDEX)
+        self.as_array_index().checked_sub(FIRST_FREE_DEF_INDEX)
             .unwrap_or_else(|| {
                 bug!("using local index {:?} as proc-macro index", self)
             })
     }
 
-    // Don't use this if you don't know about the DefIndex encoding.
     pub fn from_raw_u32(x: u32) -> DefIndex {
         DefIndex(x)
     }
 
-    // Don't use this if you don't know about the DefIndex encoding.
     pub fn as_raw_u32(&self) -> u32 {
         self.0
     }
@@ -188,19 +159,6 @@ pub fn as_raw_u32(&self) -> u32 {
 impl serialize::UseSpecializedEncodable for DefIndex {}
 impl serialize::UseSpecializedDecodable for DefIndex {}
 
-#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash)]
-pub enum DefIndexAddressSpace {
-    Low = 0,
-    High = 1,
-}
-
-impl DefIndexAddressSpace {
-    #[inline]
-    pub fn index(&self) -> usize {
-        *self as usize
-    }
-}
-
 /// A `DefId` identifies a particular *definition*, by combining a crate
 /// index and a def index.
 #[derive(Clone, PartialEq, Eq, PartialOrd, Ord, Hash, Copy)]
@@ -211,10 +169,7 @@ pub struct DefId {
 
 impl fmt::Debug for DefId {
     fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
-        write!(f, "DefId({}/{}:{}",
-               self.krate,
-               self.index.address_space().index(),
-               self.index.as_array_index())?;
+        write!(f, "DefId({}:{}", self.krate, self.index.as_array_index())?;
 
         ty::tls::with_opt(|opt_tcx| {
             if let Some(tcx) = opt_tcx {
index 20e016b8b5b1ea59fe1bca158c679d84d0dcfe3e..848e9ca58e59579e81af422549da9cc307d4743e 100644 (file)
@@ -36,7 +36,7 @@
 use crate::hir::{self, ParamName};
 use crate::hir::HirVec;
 use crate::hir::map::{DefKey, DefPathData, Definitions};
-use crate::hir::def_id::{DefId, DefIndex, DefIndexAddressSpace, CRATE_DEF_INDEX};
+use crate::hir::def_id::{DefId, DefIndex, CRATE_DEF_INDEX};
 use crate::hir::def::{Res, DefKind, PartialRes, PerNS};
 use crate::hir::{GenericArg, ConstArg};
 use crate::lint::builtin::{self, PARENTHESIZED_PARAMS_IN_TYPES_AND_MODULES,
@@ -418,7 +418,6 @@ fn allocate_use_tree_hir_id_counters(
                                 owner,
                                 id,
                                 DefPathData::Misc,
-                                DefIndexAddressSpace::High,
                                 Mark::root(),
                                 tree.prefix.span,
                             );
@@ -962,7 +961,6 @@ fn lifetime_to_generic_param(
             parent_index,
             node_id,
             DefPathData::LifetimeNs(str_name),
-            DefIndexAddressSpace::High,
             Mark::root(),
             span,
         );
@@ -1763,7 +1761,6 @@ fn visit_lifetime(&mut self, lifetime: &'v hir::Lifetime) {
                         self.parent,
                         def_node_id,
                         DefPathData::LifetimeNs(name.ident().as_interned_str()),
-                        DefIndexAddressSpace::High,
                         Mark::root(),
                         lifetime.span,
                     );
index 136d683e76b483abc2af87c4d7a7fa02d957ebb9..a1cf338bf12ea991e6199dc2363cafc34ffe6723 100644 (file)
@@ -145,15 +145,10 @@ pub(super) fn root(sess: &'a Session,
             );
         }
 
-        let (lo, hi) = definitions.def_index_counts_lo_hi();
-
         let mut collector = NodeCollector {
             krate,
             source_map: sess.source_map(),
-            map: [
-                repeat(None).take(lo).collect(),
-                repeat(None).take(hi).collect(),
-            ],
+            map: vec![None; definitions.def_index_count()],
             parent_node: hir::CRATE_HIR_ID,
             current_signature_dep_index: root_mod_sig_dep_index,
             current_full_dep_index: root_mod_full_dep_index,
@@ -231,7 +226,7 @@ pub(super) fn finalize_and_compute_crate_hash(mut self,
 
     fn insert_entry(&mut self, id: HirId, entry: Entry<'hir>) {
         debug!("hir_map: {:?} => {:?}", id, entry);
-        let local_map = &mut self.map[id.owner.address_space().index()][id.owner.as_array_index()];
+        let local_map = &mut self.map[id.owner.as_array_index()];
         let i = id.local_id.as_u32() as usize;
         if local_map.is_none() {
             *local_map = Some(IndexVec::with_capacity(i + 1));
index ddef64f27e810b72be40523e5d7ee3aa9a3d168b..6e7a8f5bc234f01c1049dc0c514b1a39abcb04f1 100644 (file)
@@ -1,5 +1,5 @@
 use crate::hir::map::definitions::*;
-use crate::hir::def_id::{CRATE_DEF_INDEX, DefIndex, DefIndexAddressSpace};
+use crate::hir::def_id::{CRATE_DEF_INDEX, DefIndex};
 use crate::session::CrateDisambiguator;
 
 use syntax::ast::*;
@@ -10,8 +10,6 @@
 use syntax::parse::token::{self, Token};
 use syntax_pos::Span;
 
-use crate::hir::map::{ITEM_LIKE_SPACE, REGULAR_SPACE};
-
 /// Creates `DefId`s for nodes in the AST.
 pub struct DefCollector<'a> {
     definitions: &'a mut Definitions,
@@ -47,13 +45,12 @@ pub fn collect_root(&mut self,
     fn create_def(&mut self,
                   node_id: NodeId,
                   data: DefPathData,
-                  address_space: DefIndexAddressSpace,
                   span: Span)
                   -> DefIndex {
         let parent_def = self.parent_def.unwrap();
         debug!("create_def(node_id={:?}, data={:?}, parent_def={:?})", node_id, data, parent_def);
         self.definitions
-            .create_def_with_parent(parent_def, node_id, data, address_space, self.expansion, span)
+            .create_def_with_parent(parent_def, node_id, data, self.expansion, span)
     }
 
     pub fn with_parent<F: FnOnce(&mut Self)>(&mut self, parent_def: DefIndex, f: F) {
@@ -85,9 +82,9 @@ fn visit_async_fn(
         // For async functions, we need to create their inner defs inside of a
         // closure to match their desugared representation.
         let fn_def_data = DefPathData::ValueNs(name.as_interned_str());
-        let fn_def = self.create_def(id, fn_def_data, ITEM_LIKE_SPACE, span);
+        let fn_def = self.create_def(id, fn_def_data, span);
         return self.with_parent(fn_def, |this| {
-            this.create_def(*return_impl_trait_id, DefPathData::ImplTrait, REGULAR_SPACE, span);
+            this.create_def(*return_impl_trait_id, DefPathData::ImplTrait, span);
 
             visit::walk_generics(this, generics);
 
@@ -106,7 +103,7 @@ fn visit_async_fn(
             visit::walk_fn_ret_ty(this, &decl.output);
 
             let closure_def = this.create_def(
-                *closure_id, DefPathData::ClosureExpr, REGULAR_SPACE, span,
+                *closure_id, DefPathData::ClosureExpr, span,
             );
             this.with_parent(closure_def, |this| {
                 use visit::Visitor;
@@ -173,14 +170,14 @@ fn visit_item(&mut self, i: &'a Item) {
                 return visit::walk_item(self, i);
             }
         };
-        let def = self.create_def(i.id, def_data, ITEM_LIKE_SPACE, i.span);
+        let def = self.create_def(i.id, def_data, i.span);
 
         self.with_parent(def, |this| {
             match i.node {
                 ItemKind::Struct(ref struct_def, _) | ItemKind::Union(ref struct_def, _) => {
                     // If this is a unit or tuple-like struct, register the constructor.
                     if let Some(ctor_hir_id) = struct_def.ctor_id() {
-                        this.create_def(ctor_hir_id, DefPathData::Ctor, REGULAR_SPACE, i.span);
+                        this.create_def(ctor_hir_id, DefPathData::Ctor, i.span);
                     }
                 }
                 _ => {}
@@ -190,7 +187,7 @@ fn visit_item(&mut self, i: &'a Item) {
     }
 
     fn visit_use_tree(&mut self, use_tree: &'a UseTree, id: NodeId, _nested: bool) {
-        self.create_def(id, DefPathData::Misc, ITEM_LIKE_SPACE, use_tree.span);
+        self.create_def(id, DefPathData::Misc, use_tree.span);
         visit::walk_use_tree(self, use_tree, id);
     }
 
@@ -201,7 +198,6 @@ fn visit_foreign_item(&mut self, foreign_item: &'a ForeignItem) {
 
         let def = self.create_def(foreign_item.id,
                                   DefPathData::ValueNs(foreign_item.ident.as_interned_str()),
-                                  REGULAR_SPACE,
                                   foreign_item.span);
 
         self.with_parent(def, |this| {
@@ -212,11 +208,10 @@ fn visit_foreign_item(&mut self, foreign_item: &'a ForeignItem) {
     fn visit_variant(&mut self, v: &'a Variant, g: &'a Generics, item_id: NodeId) {
         let def = self.create_def(v.node.id,
                                   DefPathData::TypeNs(v.node.ident.as_interned_str()),
-                                  REGULAR_SPACE,
                                   v.span);
         self.with_parent(def, |this| {
             if let Some(ctor_hir_id) = v.node.data.ctor_id() {
-                this.create_def(ctor_hir_id, DefPathData::Ctor, REGULAR_SPACE, v.span);
+                this.create_def(ctor_hir_id, DefPathData::Ctor, v.span);
             }
             visit::walk_variant(this, v, g, item_id)
         });
@@ -229,7 +224,6 @@ fn visit_variant_data(&mut self, data: &'a VariantData, _: Ident,
                 .unwrap_or_else(|| Symbol::intern(&index.to_string()));
             let def = self.create_def(field.id,
                                       DefPathData::ValueNs(name.as_interned_str()),
-                                      REGULAR_SPACE,
                                       field.span);
             self.with_parent(def, |this| this.visit_struct_field(field));
         }
@@ -242,7 +236,7 @@ fn visit_generic_param(&mut self, param: &'a GenericParam) {
             GenericParamKind::Type { .. } => DefPathData::TypeNs(name),
             GenericParamKind::Const { .. } => DefPathData::ValueNs(name),
         };
-        self.create_def(param.id, def_path_data, REGULAR_SPACE, param.ident.span);
+        self.create_def(param.id, def_path_data, param.ident.span);
 
         visit::walk_generic_param(self, param);
     }
@@ -257,7 +251,7 @@ fn visit_trait_item(&mut self, ti: &'a TraitItem) {
             TraitItemKind::Macro(..) => return self.visit_macro_invoc(ti.id),
         };
 
-        let def = self.create_def(ti.id, def_data, ITEM_LIKE_SPACE, ti.span);
+        let def = self.create_def(ti.id, def_data, ti.span);
         self.with_parent(def, |this| visit::walk_trait_item(this, ti));
     }
 
@@ -286,7 +280,7 @@ fn visit_impl_item(&mut self, ii: &'a ImplItem) {
             ImplItemKind::Macro(..) => return self.visit_macro_invoc(ii.id),
         };
 
-        let def = self.create_def(ii.id, def_data, ITEM_LIKE_SPACE, ii.span);
+        let def = self.create_def(ii.id, def_data, ii.span);
         self.with_parent(def, |this| visit::walk_impl_item(this, ii));
     }
 
@@ -300,7 +294,6 @@ fn visit_pat(&mut self, pat: &'a Pat) {
     fn visit_anon_const(&mut self, constant: &'a AnonConst) {
         let def = self.create_def(constant.id,
                                   DefPathData::AnonConst,
-                                  REGULAR_SPACE,
                                   constant.value.span);
         self.with_parent(def, |this| visit::walk_anon_const(this, constant));
     }
@@ -313,7 +306,6 @@ fn visit_expr(&mut self, expr: &'a Expr) {
             ExprKind::Closure(_, ref asyncness, ..) => {
                 let closure_def = self.create_def(expr.id,
                                           DefPathData::ClosureExpr,
-                                          REGULAR_SPACE,
                                           expr.span);
                 self.parent_def = Some(closure_def);
 
@@ -322,7 +314,6 @@ fn visit_expr(&mut self, expr: &'a Expr) {
                 if let IsAsync::Async { closure_id, .. } = asyncness {
                     let async_def = self.create_def(*closure_id,
                                                     DefPathData::ClosureExpr,
-                                                    REGULAR_SPACE,
                                                     expr.span);
                     self.parent_def = Some(async_def);
                 }
@@ -330,7 +321,6 @@ fn visit_expr(&mut self, expr: &'a Expr) {
             ExprKind::Async(_, async_id, _) => {
                 let async_def = self.create_def(async_id,
                                                 DefPathData::ClosureExpr,
-                                                REGULAR_SPACE,
                                                 expr.span);
                 self.parent_def = Some(async_def);
             }
@@ -345,7 +335,7 @@ fn visit_ty(&mut self, ty: &'a Ty) {
         match ty.node {
             TyKind::Mac(..) => return self.visit_macro_invoc(ty.id),
             TyKind::ImplTrait(node_id, _) => {
-                self.create_def(node_id, DefPathData::ImplTrait, REGULAR_SPACE, ty.span);
+                self.create_def(node_id, DefPathData::ImplTrait, ty.span);
             }
             _ => {}
         }
index fc9d6d86500ba36808299b96083d6c091843d651..dc6cddc89f9128e490dc49297553ffedae6916f5 100644 (file)
@@ -5,8 +5,7 @@
 //! expressions) that are mostly just leftovers.
 
 use crate::hir;
-use crate::hir::def_id::{CrateNum, DefId, DefIndex, LOCAL_CRATE, DefIndexAddressSpace,
-                  CRATE_DEF_INDEX};
+use crate::hir::def_id::{CrateNum, DefId, DefIndex, LOCAL_CRATE, CRATE_DEF_INDEX};
 use crate::ich::Fingerprint;
 use rustc_data_structures::fx::FxHashMap;
 use rustc_data_structures::indexed_vec::{IndexVec};
 /// Internally the DefPathTable holds a tree of DefKeys, where each DefKey
 /// stores the DefIndex of its parent.
 /// There is one DefPathTable for each crate.
-#[derive(Default)]
+#[derive(Clone, Default)]
 pub struct DefPathTable {
-    index_to_key: [Vec<DefKey>; 2],
-    def_path_hashes: [Vec<DefPathHash>; 2],
-}
-
-// Unfortunately we have to provide a manual impl of Clone because of the
-// fixed-sized array field.
-impl Clone for DefPathTable {
-    fn clone(&self) -> Self {
-        DefPathTable {
-            index_to_key: [self.index_to_key[0].clone(),
-                           self.index_to_key[1].clone()],
-            def_path_hashes: [self.def_path_hashes[0].clone(),
-                              self.def_path_hashes[1].clone()],
-        }
-    }
+    index_to_key: Vec<DefKey>,
+    def_path_hashes: Vec<DefPathHash>,
 }
 
 impl DefPathTable {
 
     fn allocate(&mut self,
                 key: DefKey,
-                def_path_hash: DefPathHash,
-                address_space: DefIndexAddressSpace)
+                def_path_hash: DefPathHash)
                 -> DefIndex {
         let index = {
-            let index_to_key = &mut self.index_to_key[address_space.index()];
-            let index = DefIndex::from_array_index(index_to_key.len(), address_space);
+            let index = DefIndex::from_array_index(self.index_to_key.len());
             debug!("DefPathTable::insert() - {:?} <-> {:?}", key, index);
-            index_to_key.push(key);
+            self.index_to_key.push(key);
             index
         };
-        self.def_path_hashes[address_space.index()].push(def_path_hash);
-        debug_assert!(self.def_path_hashes[address_space.index()].len() ==
-                      self.index_to_key[address_space.index()].len());
+        self.def_path_hashes.push(def_path_hash);
+        debug_assert!(self.def_path_hashes.len() == self.index_to_key.len());
         index
     }
 
-    pub fn next_id(&self, address_space: DefIndexAddressSpace) -> DefIndex {
-        DefIndex::from_array_index(self.index_to_key[address_space.index()].len(), address_space)
+    pub fn next_id(&self) -> DefIndex {
+        DefIndex::from_array_index(self.index_to_key.len())
     }
 
     #[inline(always)]
     pub fn def_key(&self, index: DefIndex) -> DefKey {
-        self.index_to_key[index.address_space().index()]
-                         [index.as_array_index()].clone()
+        self.index_to_key[index.as_array_index()].clone()
     }
 
     #[inline(always)]
     pub fn def_path_hash(&self, index: DefIndex) -> DefPathHash {
-        let ret = self.def_path_hashes[index.address_space().index()]
-                                      [index.as_array_index()];
+        let ret = self.def_path_hashes[index.as_array_index()];
         debug!("def_path_hash({:?}) = {:?}", index, ret);
         return ret
     }
@@ -86,24 +67,22 @@ pub fn def_path_hash(&self, index: DefIndex) -> DefPathHash {
     pub fn add_def_path_hashes_to(&self,
                                   cnum: CrateNum,
                                   out: &mut FxHashMap<DefPathHash, DefId>) {
-        for &address_space in &[DefIndexAddressSpace::Low, DefIndexAddressSpace::High] {
-            out.extend(
-                (&self.def_path_hashes[address_space.index()])
-                    .iter()
-                    .enumerate()
-                    .map(|(index, &hash)| {
-                        let def_id = DefId {
-                            krate: cnum,
-                            index: DefIndex::from_array_index(index, address_space),
-                        };
-                        (hash, def_id)
-                    })
-            );
-        }
+        out.extend(
+            self.def_path_hashes
+                .iter()
+                .enumerate()
+                .map(|(index, &hash)| {
+                    let def_id = DefId {
+                        krate: cnum,
+                        index: DefIndex::from_array_index(index),
+                    };
+                    (hash, def_id)
+                })
+        );
     }
 
     pub fn size(&self) -> usize {
-        self.index_to_key.iter().map(|v| v.len()).sum()
+        self.index_to_key.len()
     }
 }
 
@@ -111,12 +90,10 @@ pub fn size(&self) -> usize {
 impl Encodable for DefPathTable {
     fn encode<S: Encoder>(&self, s: &mut S) -> Result<(), S::Error> {
         // Index to key
-        self.index_to_key[DefIndexAddressSpace::Low.index()].encode(s)?;
-        self.index_to_key[DefIndexAddressSpace::High.index()].encode(s)?;
+        self.index_to_key.encode(s)?;
 
         // DefPath hashes
-        self.def_path_hashes[DefIndexAddressSpace::Low.index()].encode(s)?;
-        self.def_path_hashes[DefIndexAddressSpace::High.index()].encode(s)?;
+        self.def_path_hashes.encode(s)?;
 
         Ok(())
     }
@@ -124,18 +101,9 @@ fn encode<S: Encoder>(&self, s: &mut S) -> Result<(), S::Error> {
 
 impl Decodable for DefPathTable {
     fn decode<D: Decoder>(d: &mut D) -> Result<DefPathTable, D::Error> {
-        let index_to_key_lo: Vec<DefKey> = Decodable::decode(d)?;
-        let index_to_key_hi: Vec<DefKey> = Decodable::decode(d)?;
-
-        let def_path_hashes_lo: Vec<DefPathHash> = Decodable::decode(d)?;
-        let def_path_hashes_hi: Vec<DefPathHash> = Decodable::decode(d)?;
-
-        let index_to_key = [index_to_key_lo, index_to_key_hi];
-        let def_path_hashes = [def_path_hashes_lo, def_path_hashes_hi];
-
         Ok(DefPathTable {
-            index_to_key,
-            def_path_hashes,
+            index_to_key: Decodable::decode(d)?,
+            def_path_hashes : Decodable::decode(d)?,
         })
     }
 }
@@ -147,7 +115,7 @@ fn decode<D: Decoder>(d: &mut D) -> Result<DefPathTable, D::Error> {
 pub struct Definitions {
     table: DefPathTable,
     node_to_def_index: NodeMap<DefIndex>,
-    def_index_to_node: [Vec<ast::NodeId>; 2],
+    def_index_to_node: Vec<ast::NodeId>,
     pub(super) node_to_hir_id: IndexVec<ast::NodeId, hir::HirId>,
     /// If `Mark` is an ID of some macro expansion,
     /// then `DefId` is the normal module (`mod`) in which the expanded macro was defined.
@@ -374,30 +342,13 @@ fn borrow(&self) -> &Fingerprint {
 }
 
 impl Definitions {
-    /// Creates new empty definition map.
-    ///
-    /// The `DefIndex` returned from a new `Definitions` are as follows:
-    /// 1. At `DefIndexAddressSpace::Low`,
-    ///     CRATE_ROOT has index 0:0, and then new indexes are allocated in
-    ///     ascending order.
-    /// 2. At `DefIndexAddressSpace::High`,
-    ///     the first `FIRST_FREE_HIGH_DEF_INDEX` indexes are reserved for
-    ///     internal use, then `1:FIRST_FREE_HIGH_DEF_INDEX` are allocated in
-    ///     ascending order.
-    //
-    // FIXME: there is probably a better place to put this comment.
-    pub fn new() -> Self {
-        Self::default()
-    }
-
     pub fn def_path_table(&self) -> &DefPathTable {
         &self.table
     }
 
     /// Gets the number of definitions.
-    pub fn def_index_counts_lo_hi(&self) -> (usize, usize) {
-        (self.table.index_to_key[DefIndexAddressSpace::Low.index()].len(),
-         self.table.index_to_key[DefIndexAddressSpace::High.index()].len())
+    pub fn def_index_count(&self) -> usize {
+        self.table.index_to_key.len()
     }
 
     pub fn def_key(&self, index: DefIndex) -> DefKey {
@@ -436,17 +387,12 @@ pub fn local_def_id(&self, node: ast::NodeId) -> DefId {
     #[inline]
     pub fn as_local_node_id(&self, def_id: DefId) -> Option<ast::NodeId> {
         if def_id.krate == LOCAL_CRATE {
-            let space_index = def_id.index.address_space().index();
-            let array_index = def_id.index.as_array_index();
-            let node_id = self.def_index_to_node[space_index][array_index];
+            let node_id = self.def_index_to_node[def_id.index.as_array_index()];
             if node_id != ast::DUMMY_NODE_ID {
-                Some(node_id)
-            } else {
-                None
+                return Some(node_id);
             }
-        } else {
-            None
         }
+        None
     }
 
     // FIXME(@ljedrz): replace the NodeId variant
@@ -471,9 +417,7 @@ pub fn node_to_hir_id(&self, node_id: ast::NodeId) -> hir::HirId {
 
     #[inline]
     pub fn def_index_to_hir_id(&self, def_index: DefIndex) -> hir::HirId {
-        let space_index = def_index.address_space().index();
-        let array_index = def_index.as_array_index();
-        let node_id = self.def_index_to_node[space_index][array_index];
+        let node_id = self.def_index_to_node[def_index.as_array_index()];
         self.node_to_hir_id[node_id]
     }
 
@@ -488,7 +432,11 @@ pub fn opt_span(&self, def_id: DefId) -> Option<Span> {
         }
     }
 
-    /// Adds a root definition (no parent).
+    /// Adds a root definition (no parent) and a few other reserved definitions.
+    ///
+    /// After the initial definitions are created the first `FIRST_FREE_DEF_INDEX` indexes
+    /// are taken, so the "user" indexes will be allocated starting with `FIRST_FREE_DEF_INDEX`
+    /// in ascending order.
     pub fn create_root_def(&mut self,
                            crate_name: &str,
                            crate_disambiguator: CrateDisambiguator)
@@ -506,11 +454,10 @@ pub fn create_root_def(&mut self,
         let def_path_hash = key.compute_stable_hash(parent_hash);
 
         // Create the definition.
-        let address_space = super::ITEM_LIKE_SPACE;
-        let root_index = self.table.allocate(key, def_path_hash, address_space);
+        let root_index = self.table.allocate(key, def_path_hash);
         assert_eq!(root_index, CRATE_DEF_INDEX);
-        assert!(self.def_index_to_node[address_space.index()].is_empty());
-        self.def_index_to_node[address_space.index()].push(ast::CRATE_NODE_ID);
+        assert!(self.def_index_to_node.is_empty());
+        self.def_index_to_node.push(ast::CRATE_NODE_ID);
         self.node_to_def_index.insert(ast::CRATE_NODE_ID, root_index);
 
         // Allocate some other DefIndices that always must exist.
@@ -524,7 +471,6 @@ pub fn create_def_with_parent(&mut self,
                                   parent: DefIndex,
                                   node_id: ast::NodeId,
                                   data: DefPathData,
-                                  address_space: DefIndexAddressSpace,
                                   expansion: Mark,
                                   span: Span)
                                   -> DefIndex {
@@ -561,10 +507,9 @@ pub fn create_def_with_parent(&mut self,
         debug!("create_def_with_parent: after disambiguation, key = {:?}", key);
 
         // Create the definition.
-        let index = self.table.allocate(key, def_path_hash, address_space);
-        assert_eq!(index.as_array_index(),
-                   self.def_index_to_node[address_space.index()].len());
-        self.def_index_to_node[address_space.index()].push(node_id);
+        let index = self.table.allocate(key, def_path_hash);
+        assert_eq!(index.as_array_index(), self.def_index_to_node.len());
+        self.def_index_to_node.push(node_id);
 
         // Some things for which we allocate DefIndices don't correspond to
         // anything in the AST, so they don't have a NodeId. For these cases
@@ -673,8 +618,7 @@ pub enum GlobalMetaDataKind {
             $($variant),*
         }
 
-        const GLOBAL_MD_ADDRESS_SPACE: DefIndexAddressSpace = DefIndexAddressSpace::High;
-        pub const FIRST_FREE_HIGH_DEF_INDEX: usize = count!($($variant)*);
+        pub const FIRST_FREE_DEF_INDEX: usize = 1 + count!($($variant)*);
 
         impl GlobalMetaDataKind {
             fn allocate_def_indices(definitions: &mut Definitions) {
@@ -684,7 +628,6 @@ fn allocate_def_indices(definitions: &mut Definitions) {
                         CRATE_DEF_INDEX,
                         ast::DUMMY_NODE_ID,
                         DefPathData::GlobalMetaData(instance.name().as_interned_str()),
-                        GLOBAL_MD_ADDRESS_SPACE,
                         Mark::root(),
                         DUMMY_SP
                     );
@@ -705,12 +648,12 @@ pub fn def_index(&self, def_path_table: &DefPathTable) -> DefIndex {
 
                 // These DefKeys are all right after the root,
                 // so a linear search is fine.
-                let index = def_path_table.index_to_key[GLOBAL_MD_ADDRESS_SPACE.index()]
+                let index = def_path_table.index_to_key
                                           .iter()
                                           .position(|k| *k == def_key)
                                           .unwrap();
 
-                DefIndex::from_array_index(index, GLOBAL_MD_ADDRESS_SPACE)
+                DefIndex::from_array_index(index)
             }
 
             fn name(&self) -> Symbol {
index c2b513a39a8b7b520bc0f8e325dcde04eca3f6e6..9088d0c1656703f07c89991d5d89144f8417c1b9 100644 (file)
@@ -5,7 +5,7 @@
 
 use crate::dep_graph::{DepGraph, DepNode, DepKind, DepNodeIndex};
 
-use crate::hir::def_id::{CRATE_DEF_INDEX, DefId, LocalDefId, DefIndexAddressSpace};
+use crate::hir::def_id::{CRATE_DEF_INDEX, DefId, LocalDefId};
 
 use crate::middle::cstore::CrateStoreDyn;
 
@@ -34,9 +34,6 @@
 pub mod definitions;
 mod hir_id_validator;
 
-pub const ITEM_LIKE_SPACE: DefIndexAddressSpace = DefIndexAddressSpace::Low;
-pub const REGULAR_SPACE: DefIndexAddressSpace = DefIndexAddressSpace::High;
-
 /// Represents an entry and its parent `NodeId`.
 #[derive(Copy, Clone, Debug)]
 pub struct Entry<'hir> {
@@ -163,11 +160,10 @@ pub fn untracked_krate<'hir>(&'hir self) -> &'hir Crate {
 }
 
 /// This type is effectively a `HashMap<HirId, Entry<'hir>>`,
-/// but is implemented by 3 layers of arrays.
-/// - the outer layer is `[A; 2]` and correspond to the 2 address spaces `DefIndex`es can be in
-/// - then we have `A = Vec<Option<B>>` mapping a `DefIndex`'s index to a inner value
-/// - which is `B = IndexVec<ItemLocalId, Option<Entry<'hir>>` which finally gives you the `Entry`.
-pub(super) type HirEntryMap<'hir> = [Vec<Option<IndexVec<ItemLocalId, Option<Entry<'hir>>>>>; 2];
+/// but it is implemented as 2 layers of arrays.
+/// - first we have `A = Vec<Option<B>>` mapping a `DefIndex`'s index to an inner value
+/// - which is `B = IndexVec<ItemLocalId, Option<Entry<'hir>>` which gives you the `Entry`.
+pub(super) type HirEntryMap<'hir> = Vec<Option<IndexVec<ItemLocalId, Option<Entry<'hir>>>>>;
 
 /// Represents a mapping from `NodeId`s to AST elements and their parent `NodeId`s.
 #[derive(Clone)]
@@ -193,7 +189,7 @@ pub struct Map<'hir> {
 impl<'hir> Map<'hir> {
     #[inline]
     fn lookup(&self, id: HirId) -> Option<&Entry<'hir>> {
-        let local_map = self.map[id.owner.address_space().index()].get(id.owner.as_array_index())?;
+        let local_map = self.map.get(id.owner.as_array_index())?;
         local_map.as_ref()?.get(id.local_id)?.as_ref()
     }
 
@@ -1016,29 +1012,21 @@ pub fn attrs_by_hir_id(&self, id: HirId) -> &'hir [ast::Attribute] {
 
     /// Returns an iterator that yields all the hir ids in the map.
     fn all_ids<'a>(&'a self) -> impl Iterator<Item = HirId> + 'a {
-        // This code is a bit awkward because the map is implemented as 3 levels of arrays,
+        // This code is a bit awkward because the map is implemented as 2 levels of arrays,
         // see the comment on `HirEntryMap`.
-        let map = &self.map;
-
-        // Look at both the def index address spaces
-        let spaces = [DefIndexAddressSpace::Low, DefIndexAddressSpace::High].iter().cloned();
-        spaces.flat_map(move |space| {
-            // Iterate over all the indices in the address space and return a reference to
-            // local maps and their index given that they exist.
-            let local_maps = map[space.index()].iter().enumerate().filter_map(|(i, local_map)| {
-                local_map.as_ref().map(|m| (i, m))
-            });
-
-            local_maps.flat_map(move |(array_index, local_map)| {
-                // Iterate over each valid entry in the local map
-                local_map.iter_enumerated().filter_map(move |(i, entry)| entry.map(move |_| {
-                    // Reconstruct the HirId based on the 3 indices we used to find it
-                    HirId {
-                        owner: DefIndex::from_array_index(array_index, space),
-                        local_id: i,
-                    }
-                }))
-            })
+        // Iterate over all the indices and return a reference to
+        // local maps and their index given that they exist.
+        self.map.iter().enumerate().filter_map(|(i, local_map)| {
+            local_map.as_ref().map(|m| (i, m))
+        }).flat_map(move |(array_index, local_map)| {
+            // Iterate over each valid entry in the local map
+            local_map.iter_enumerated().filter_map(move |(i, entry)| entry.map(move |_| {
+                // Reconstruct the HirId based on the 3 indices we used to find it
+                HirId {
+                    owner: DefIndex::from_array_index(array_index),
+                    local_id: i,
+                }
+            }))
         })
     }
 
index 384a5862cde0cda4d1305d6a7c26dc0458f26038..2496419640c2e8e3a64e911add85efa14951f0dd 100644 (file)
@@ -298,9 +298,7 @@ pub(super) fn specialization_graph_provider<'a, 'tcx>(
     // negated `CrateNum` (so remote definitions are visited first) and then
     // by a flattened version of the `DefIndex`.
     trait_impls.sort_unstable_by_key(|def_id| {
-        (-(def_id.krate.as_u32() as i64),
-         def_id.index.address_space().index(),
-         def_id.index.as_array_index())
+        (-(def_id.krate.as_u32() as i64), def_id.index.as_array_index())
     });
 
     for impl_def_id in trait_impls {
index a339ec30a74f8b262a1ca9b402bfa060967937ad..fc8bf0baa99f6239e51177312d4f7554a35777ea 100644 (file)
@@ -647,8 +647,7 @@ fn print_flowgraph<'a, 'tcx, W: Write>(variants: Vec<borrowck_dot::Variant>,
     // alphanumeric. This does not appear in the rendered graph, so it does not
     // have to be user friendly.
     let name = format!(
-        "hir_id_{}_{}_{}",
-        hir_id.owner.address_space().index(),
+        "hir_id_{}_{}",
         hir_id.owner.as_array_index(),
         hir_id.local_id.index(),
     );
index 048acf56ea7a777bc2cdf4d39fcda0fad0807395..4b9db466da84307e4d4d55aca13032d5ddc47180 100644 (file)
@@ -9,8 +9,7 @@
 use rustc::middle::cstore::LinkagePreference;
 use rustc::middle::exported_symbols::{ExportedSymbol, SymbolExportLevel};
 use rustc::hir::def::{self, Res, DefKind, CtorOf, CtorKind};
-use rustc::hir::def_id::{CrateNum, DefId, DefIndex, DefIndexAddressSpace,
-                         CRATE_DEF_INDEX, LOCAL_CRATE, LocalDefId};
+use rustc::hir::def_id::{CrateNum, DefId, DefIndex, LocalDefId, CRATE_DEF_INDEX, LOCAL_CRATE};
 use rustc::hir::map::definitions::DefPathTable;
 use rustc_data_structures::fingerprint::Fingerprint;
 use rustc::middle::lang_items;
@@ -449,7 +448,7 @@ fn def_kind(&self) -> Option<DefKind> {
                                    proc_macros: &[(ast::Name, Lrc<SyntaxExtension>)])
                                    -> DefPathTable
 {
-    let mut definitions = Definitions::new();
+    let mut definitions = Definitions::default();
 
     let name = crate_root.name.as_str();
     let disambiguator = crate_root.disambiguator;
@@ -460,7 +459,6 @@ fn def_kind(&self) -> Option<DefKind> {
             crate_root,
             ast::DUMMY_NODE_ID,
             DefPathData::MacroNs(name.as_interned_str()),
-            DefIndexAddressSpace::High,
             Mark::root(),
             DUMMY_SP);
         debug!("definition for {:?} is {:?}", name, def_index);
index f9543a18c68a7729b4afbcb9f44dcee1de373550..4c1e39cd0a9e1a945c1ed3c18ebc8e8cdd1f0f45 100644 (file)
@@ -1,6 +1,6 @@
 use crate::schema::*;
 
-use rustc::hir::def_id::{DefId, DefIndex, DefIndexAddressSpace};
+use rustc::hir::def_id::{DefId, DefIndex};
 use rustc_serialize::opaque::Encoder;
 use std::u32;
 use log::debug;
@@ -75,14 +75,13 @@ fn write_to_bytes(self, b: &mut [u8]) {
 /// appropriate spot by calling `record_position`. We should never
 /// visit the same index twice.
 pub struct Index {
-    positions: [Vec<u8>; 2]
+    positions: Vec<u8>,
 }
 
 impl Index {
-    pub fn new((max_index_lo, max_index_hi): (usize, usize)) -> Index {
+    pub fn new(max_index: usize) -> Index {
         Index {
-            positions: [vec![0xff; max_index_lo * 4],
-                        vec![0xff; max_index_hi * 4]],
+            positions: vec![0xff; max_index * 4],
         }
     }
 
@@ -94,10 +93,9 @@ pub fn record(&mut self, def_id: DefId, entry: Lazy<Entry<'_>>) {
     pub fn record_index(&mut self, item: DefIndex, entry: Lazy<Entry<'_>>) {
         assert!(entry.position < (u32::MAX as usize));
         let position = entry.position as u32;
-        let space_index = item.address_space().index();
         let array_index = item.as_array_index();
 
-        let positions = &mut self.positions[space_index];
+        let positions = &mut self.positions;
         assert!(u32::read_from_bytes_at(positions, array_index) == u32::MAX,
                 "recorded position for item {:?} twice, first at {:?} and now at {:?}",
                 item,
@@ -111,13 +109,10 @@ pub fn write_index(&self, buf: &mut Encoder) -> LazySeq<Index> {
         let pos = buf.position();
 
         // First we write the length of the lower range ...
-        buf.emit_raw_bytes(&(self.positions[0].len() as u32 / 4).to_le_bytes());
-        // ... then the values in the lower range ...
-        buf.emit_raw_bytes(&self.positions[0]);
-        // ... then the values in the higher range.
-        buf.emit_raw_bytes(&self.positions[1]);
-        LazySeq::with_position_and_length(pos as usize,
-            (self.positions[0].len() + self.positions[1].len()) / 4 + 1)
+        buf.emit_raw_bytes(&(self.positions.len() as u32 / 4).to_le_bytes());
+        // ... then the values.
+        buf.emit_raw_bytes(&self.positions);
+        LazySeq::with_position_and_length(pos as usize, self.positions.len() / 4 + 1)
     }
 }
 
@@ -131,16 +126,7 @@ pub fn lookup(&self, bytes: &[u8], def_index: DefIndex) -> Option<Lazy<Entry<'tc
                def_index,
                self.len);
 
-        let i = def_index.as_array_index() + match def_index.address_space() {
-            DefIndexAddressSpace::Low => 0,
-            DefIndexAddressSpace::High => {
-                // This is a DefIndex in the higher range, so find out where
-                // that starts:
-                u32::read_from_bytes_at(bytes, 0) as usize
-            }
-        };
-
-        let position = u32::read_from_bytes_at(bytes, 1 + i);
+        let position = u32::read_from_bytes_at(bytes, 1 + def_index.as_array_index());
         if position == u32::MAX {
             debug!("Index::lookup: position=u32::MAX");
             None
index b77feeee06f577fa3ea3fdde1ff9fd5d4ca543b2..e780693a5a92dda349899727efea5fc4424fa8bf 100644 (file)
@@ -80,7 +80,7 @@ fn deref_mut(&mut self) -> &mut Self::Target {
 impl<'a, 'b, 'tcx> IndexBuilder<'a, 'b, 'tcx> {
     pub fn new(ecx: &'a mut EncodeContext<'b, 'tcx>) -> Self {
         IndexBuilder {
-            items: Index::new(ecx.tcx.hir().definitions().def_index_counts_lo_hi()),
+            items: Index::new(ecx.tcx.hir().definitions().def_index_count()),
             ecx,
         }
     }
index f87714b58c4423940affa94017ee041d2a5c25ae..04b0e16cd9a81b296db45c7a8142f636ba73cda5 100644 (file)
@@ -25,9 +25,8 @@ pub fn write_mir_graphviz<'tcx, W>(tcx: TyCtxt<'_, '_, 'tcx>,
 // it does not have to be user friendly.
 pub fn graphviz_safe_def_name(def_id: DefId) -> String {
     format!(
-        "{}_{}_{}",
+        "{}_{}",
         def_id.krate.index(),
-        def_id.index.address_space().index(),
         def_id.index.as_array_index(),
     )
 }
index f8f6e5b1cd012f2d338f9d891108e5ef1f7164cd..18da89b9099a5c3f0bdbd62c1c5d5dc1df7a6f66 100644 (file)
@@ -1970,7 +1970,7 @@ pub fn new(session: &'a Session,
         let mut module_map = FxHashMap::default();
         module_map.insert(DefId::local(CRATE_DEF_INDEX), graph_root);
 
-        let mut definitions = Definitions::new();
+        let mut definitions = Definitions::default();
         DefCollector::new(&mut definitions, Mark::root())
             .collect_root(crate_name, session.local_crate_disambiguator());
 
index f1706a4616b06b92103759bc7e1937df793a50b9..79a92d595c2edc9ebc64213e20ad8faf7b2ae9d4 100644 (file)
@@ -6,8 +6,7 @@
 use crate::Namespace::*;
 use crate::build_reduced_graph::{BuildReducedGraphVisitor, IsMacroExport};
 use crate::resolve_imports::ImportResolver;
-use rustc::hir::def_id::{DefId, CRATE_DEF_INDEX, DefIndex,
-                         CrateNum, DefIndexAddressSpace};
+use rustc::hir::def_id::{CrateNum, DefId, DefIndex, CRATE_DEF_INDEX};
 use rustc::hir::def::{self, DefKind, NonMacroAttrKind};
 use rustc::hir::map::{self, DefCollector};
 use rustc::{ty, lint};
@@ -173,8 +172,7 @@ fn visit_ast_fragment_with_placeholders(&mut self, mark: Mark, fragment: &AstFra
     fn add_builtin(&mut self, ident: ast::Ident, ext: Lrc<SyntaxExtension>) {
         let def_id = DefId {
             krate: CrateNum::BuiltinMacros,
-            index: DefIndex::from_array_index(self.macro_map.len(),
-                                              DefIndexAddressSpace::Low),
+            index: DefIndex::from_array_index(self.macro_map.len()),
         };
         let kind = ext.kind();
         self.macro_map.insert(def_id, ext);
index 5555ea302c96f1aa203c4710eaf5d6a39ad6ae3d..e91e3a029dacfe993d8af336c560bf271c1f2128 100644 (file)
@@ -1,6 +1,6 @@
 use rustc_lint;
 use rustc::session::{self, config};
-use rustc::hir::def_id::{DefId, DefIndex, DefIndexAddressSpace, CrateNum, LOCAL_CRATE};
+use rustc::hir::def_id::{DefId, DefIndex, CrateNum, LOCAL_CRATE};
 use rustc::hir::HirId;
 use rustc::middle::cstore::CrateStore;
 use rustc::middle::privacy::AccessLevels;
@@ -112,8 +112,8 @@ pub fn enter_alias<F, R>(&self,
     // registered after the AST is constructed would require storing the defid mapping in a
     // RefCell, decreasing the performance for normal compilation for very little gain.
     //
-    // Instead, we construct 'fake' def ids, which start immediately after the last DefId in
-    // DefIndexAddressSpace::Low. In the Debug impl for clean::Item, we explicitly check for fake
+    // Instead, we construct 'fake' def ids, which start immediately after the last DefId.
+    // In the Debug impl for clean::Item, we explicitly check for fake
     // def ids, as we'll end up with a panic if we use the DefId Debug impl for fake DefIds
     pub fn next_def_id(&self, crate_num: CrateNum) -> DefId {
         let start_def_id = {
@@ -122,11 +122,11 @@ pub fn next_def_id(&self, crate_num: CrateNum) -> DefId {
                     .hir()
                     .definitions()
                     .def_path_table()
-                    .next_id(DefIndexAddressSpace::Low)
+                    .next_id()
             } else {
                 self.cstore
                     .def_path_table(crate_num)
-                    .next_id(DefIndexAddressSpace::Low)
+                    .next_id()
             };
 
             DefId {
@@ -142,10 +142,7 @@ pub fn next_def_id(&self, crate_num: CrateNum) -> DefId {
             crate_num,
             DefId {
                 krate: crate_num,
-                index: DefIndex::from_array_index(
-                    def_id.index.as_array_index() + 1,
-                    def_id.index.address_space(),
-                ),
+                index: DefIndex::from_array_index(def_id.index.as_array_index() + 1),
             },
         );
 
index 660576996e5d42103cf1cca6b75d131eda1fb75e..67a6d1d263bf53f543fea3d30f186621d43364ef 100644 (file)
@@ -7,7 +7,7 @@ fn main() {}
 
 // END RUST SOURCE
 // START rustc.main.mir_map.0.dot
-// digraph Mir_0_0_3 { // The name here MUST be an ASCII identifier.
+// digraph Mir_0_12 { // The name here MUST be an ASCII identifier.
 //     graph [fontname="monospace"];
 //     node [fontname="monospace"];
 //     edge [fontname="monospace"];
index 84567e1b4b8f26cf9e17016210eca120315a1cc8..0e1db68f37255fb0be265cf82c74ec0c99531ff1 100644 (file)
@@ -20,7 +20,7 @@ fn foo<T: Copy>(_t: T, q: &i32) -> i32 {
 // ...
 // bb0: {
 //     ...
-//     _3 = [closure@HirId { owner: DefIndex(0:4), local_id: 31 }];
+//     _3 = [closure@HirId { owner: DefIndex(13), local_id: 31 }];
 //     ...
 //     _4 = &_3;
 //     ...
index 2be48927fd3b73b5828796064e4f5225ea8668ad..fa8557f3b38a7e9eca6e2d7b6f484685f54740f1 100644 (file)
@@ -16,7 +16,7 @@ fn foo<T: Copy>(_t: T, q: i32) -> i32 {
 // ...
 // bb0: {
 //     ...
-//     _3 = [closure@HirId { owner: DefIndex(0:4), local_id: 15 }];
+//     _3 = [closure@HirId { owner: DefIndex(13), local_id: 15 }];
 //     ...
 //     _4 = &_3;
 //     ...
index 6b7c863fcd43febb098d171fb4cbfc8b99b44546..33ee0fe61b288811efe073cee15441cb0e748471 100644 (file)
@@ -98,7 +98,7 @@ fn main() {
 // }
 // END rustc.main.EraseRegions.after.mir
 // START rustc.main-{{closure}}.EraseRegions.after.mir
-// fn main::{{closure}}#0(_1: &[closure@HirId { owner: DefIndex(0:7), local_id: 72 }], _2: &i32) -> &i32 {
+// fn main::{{closure}}#0(_1: &[closure@HirId { owner: DefIndex(20), local_id: 72 }], _2: &i32) -> &i32 {
 //     ...
 //     bb0: {
 //         Retag([fn entry] _1);
index 20041389b3c3813e3dd8761d16d751fa4dabb339..cc5ffca10475efa275c7c5184d3e5b0350981ad8 100644 (file)
@@ -4,9 +4,9 @@ note: No external requirements
 LL |         let mut closure = expect_sig(|p, y| *p = y);
    |                                      ^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:9 ~ escape_argument_callee[317d]::test[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:13 ~ escape_argument_callee[317d]::test[0]::{{closure}}[0]) with closure substs [
                i16,
-               for<'r, 's, 't0> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) mut &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) i32, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't0)) i32)),
+               for<'r, 's, 't0> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) mut &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) i32, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't0)) i32)),
            ]
 
 error: lifetime may not live long enough
@@ -30,7 +30,7 @@ LL | |     deref(p);
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:3 ~ escape_argument_callee[317d]::test[0]) with substs []
+   = note: defining type: DefId(0:12 ~ escape_argument_callee[317d]::test[0]) with substs []
 
 error: aborting due to previous error
 
index b08ec9539318ad878007182b084fc4a11b3cfaae..fdf95b8acebfc9c4ac004011f86d2db71a98845c 100644 (file)
@@ -4,9 +4,9 @@ note: No external requirements
 LL |         let mut closure = expect_sig(|p, y| *p = y);
    |                                      ^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:9 ~ escape_argument[317d]::test[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:13 ~ escape_argument[317d]::test[0]::{{closure}}[0]) with closure substs [
                i16,
-               for<'r, 's> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) mut &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) i32, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) i32)),
+               for<'r, 's> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) mut &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) i32, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) i32)),
            ]
 
 note: No external requirements
@@ -21,7 +21,7 @@ LL | |     deref(p);
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:3 ~ escape_argument[317d]::test[0]) with substs []
+   = note: defining type: DefId(0:12 ~ escape_argument[317d]::test[0]) with substs []
 
 error[E0597]: `y` does not live long enough
   --> $DIR/escape-argument.rs:27:25
index 7178b22bb5f2de7a7edb58be0884f3c1c1a12ff8..135de0445a79989d0c82d367e8443c800f42d342 100644 (file)
@@ -4,7 +4,7 @@ note: External requirements
 LL |             let mut closure1 = || p = &y;
    |                                ^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:10 ~ escape_upvar_nested[317d]::test[0]::{{closure}}[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:14 ~ escape_upvar_nested[317d]::test[0]::{{closure}}[0]::{{closure}}[0]) with closure substs [
                i16,
                extern "rust-call" fn(()),
                &'_#1r mut &'_#2r i32,
@@ -23,7 +23,7 @@ LL | |             closure1();
 LL | |         };
    | |_________^
    |
-   = note: defining type: DefId(0/1:9 ~ escape_upvar_nested[317d]::test[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:13 ~ escape_upvar_nested[317d]::test[0]::{{closure}}[0]) with closure substs [
                i16,
                extern "rust-call" fn(()),
                &'_#1r mut &'_#2r i32,
@@ -44,7 +44,7 @@ LL | |     deref(p);
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:3 ~ escape_upvar_nested[317d]::test[0]) with substs []
+   = note: defining type: DefId(0:12 ~ escape_upvar_nested[317d]::test[0]) with substs []
 
 error[E0597]: `y` does not live long enough
   --> $DIR/escape-upvar-nested.rs:21:40
index d129f945f252ad22f9c4c9d94075d3cd613e72ef..8c37ab7b768c3cc930fe1136427d31a9a20c73da 100644 (file)
@@ -4,7 +4,7 @@ note: External requirements
 LL |         let mut closure = || p = &y;
    |                           ^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:9 ~ escape_upvar_ref[317d]::test[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:13 ~ escape_upvar_ref[317d]::test[0]::{{closure}}[0]) with closure substs [
                i16,
                extern "rust-call" fn(()),
                &'_#1r mut &'_#2r i32,
@@ -25,7 +25,7 @@ LL | |     deref(p);
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:3 ~ escape_upvar_ref[317d]::test[0]) with substs []
+   = note: defining type: DefId(0:12 ~ escape_upvar_ref[317d]::test[0]) with substs []
 
 error[E0597]: `y` does not live long enough
   --> $DIR/escape-upvar-ref.rs:23:35
index 4db1f0407704334d5271e6c59d74e44ed5b15406..8916fdcfc88f145af2a77f7a3cf4041885a92f6d 100644 (file)
@@ -8,9 +8,9 @@ LL | |             demand_y(x, y, p)
 LL | |         },
    | |_________^
    |
-   = note: defining type: DefId(0/1:20 ~ propagate_approximated_fail_no_postdom[317d]::supply[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:27 ~ propagate_approximated_fail_no_postdom[317d]::supply[0]::{{closure}}[0]) with closure substs [
                i16,
-               for<'r, 's> extern "rust-call" fn((std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) u32>, std::cell::Cell<&'_#2r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) &'_#3r u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) u32>)),
+               for<'r, 's> extern "rust-call" fn((std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) u32>, std::cell::Cell<&'_#2r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) &'_#3r u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) u32>)),
            ]
    = note: late-bound region is '_#4r
    = note: late-bound region is '_#5r
@@ -39,7 +39,7 @@ LL | |     );
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ propagate_approximated_fail_no_postdom[317d]::supply[0]) with substs []
+   = note: defining type: DefId(0:23 ~ propagate_approximated_fail_no_postdom[317d]::supply[0]) with substs []
 
 error: aborting due to previous error
 
index 7dedae715bea06356883193f3f3693aebca5f86e..fa8384311ea578664a7e6b14817c1060c323abb4 100644 (file)
@@ -9,9 +9,9 @@ LL | |
 LL | |     });
    | |_____^
    |
-   = note: defining type: DefId(0/1:18 ~ propagate_approximated_ref[317d]::supply[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:25 ~ propagate_approximated_ref[317d]::supply[0]::{{closure}}[0]) with closure substs [
                i16,
-               for<'r, 's, 't0, 't1, 't2, 't3> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't0)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't1)) &'_#2r u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't2)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't3)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't1)) u32>)),
+               for<'r, 's, 't0, 't1, 't2, 't3> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't0)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't1)) &'_#2r u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't2)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't3)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't1)) u32>)),
            ]
    = note: late-bound region is '_#3r
    = note: late-bound region is '_#4r
@@ -30,7 +30,7 @@ LL | |     });
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ propagate_approximated_ref[317d]::supply[0]) with substs []
+   = note: defining type: DefId(0:22 ~ propagate_approximated_ref[317d]::supply[0]) with substs []
 
 error: lifetime may not live long enough
   --> $DIR/propagate-approximated-ref.rs:45:9
index 6d1baf9f827dbb0a4f8b619329a70c484d6c2034..cfaa75b8ef86169cb071e1535b56bcd88590fcd9 100644 (file)
@@ -8,9 +8,9 @@ LL | |
 LL | |     })
    | |_____^
    |
-   = note: defining type: DefId(0/1:12 ~ propagate_approximated_shorter_to_static_comparing_against_free[317d]::case1[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:18 ~ propagate_approximated_shorter_to_static_comparing_against_free[317d]::case1[0]::{{closure}}[0]) with closure substs [
                i32,
-               for<'r> extern "rust-call" fn((std::cell::Cell<&'_#1r u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) u32>)),
+               for<'r> extern "rust-call" fn((std::cell::Cell<&'_#1r u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) u32>)),
            ]
 
 error[E0521]: borrowed data escapes outside of closure
@@ -35,7 +35,7 @@ LL | |     })
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:5 ~ propagate_approximated_shorter_to_static_comparing_against_free[317d]::case1[0]) with substs []
+   = note: defining type: DefId(0:17 ~ propagate_approximated_shorter_to_static_comparing_against_free[317d]::case1[0]) with substs []
 
 note: External requirements
   --> $DIR/propagate-approximated-shorter-to-static-comparing-against-free.rs:35:15
@@ -46,9 +46,9 @@ LL | |         cell_x.set(cell_a.get()); // forces 'a: 'x, implies 'a = 'static
 LL | |     })
    | |_____^
    |
-   = note: defining type: DefId(0/1:13 ~ propagate_approximated_shorter_to_static_comparing_against_free[317d]::case2[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:20 ~ propagate_approximated_shorter_to_static_comparing_against_free[317d]::case2[0]::{{closure}}[0]) with closure substs [
                i32,
-               for<'r> extern "rust-call" fn((std::cell::Cell<&'_#1r u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) u32>)),
+               for<'r> extern "rust-call" fn((std::cell::Cell<&'_#1r u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) u32>)),
            ]
    = note: number of external vids: 2
    = note: where '_#1r: '_#0r
@@ -65,7 +65,7 @@ LL | |     })
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ propagate_approximated_shorter_to_static_comparing_against_free[317d]::case2[0]) with substs []
+   = note: defining type: DefId(0:19 ~ propagate_approximated_shorter_to_static_comparing_against_free[317d]::case2[0]) with substs []
 
 error[E0597]: `a` does not live long enough
   --> $DIR/propagate-approximated-shorter-to-static-comparing-against-free.rs:30:26
index ea04a47a4804b3542805439090d15a0bd56b7ae8..601b3577e0eec821abfc0775783873d9abf6e62f 100644 (file)
@@ -10,9 +10,9 @@ LL | |         demand_y(x, y, x.get())
 LL | |     });
    | |_____^
    |
-   = note: defining type: DefId(0/1:18 ~ propagate_approximated_shorter_to_static_no_bound[317d]::supply[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:25 ~ propagate_approximated_shorter_to_static_no_bound[317d]::supply[0]::{{closure}}[0]) with closure substs [
                i16,
-               for<'r, 's, 't0, 't1, 't2> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't0)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't1)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't2)) u32>)),
+               for<'r, 's, 't0, 't1, 't2> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't0)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't1)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't2)) u32>)),
            ]
    = note: late-bound region is '_#2r
    = note: late-bound region is '_#3r
@@ -31,7 +31,7 @@ LL | |     });
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ propagate_approximated_shorter_to_static_no_bound[317d]::supply[0]) with substs []
+   = note: defining type: DefId(0:22 ~ propagate_approximated_shorter_to_static_no_bound[317d]::supply[0]) with substs []
 
 error[E0521]: borrowed data escapes outside of function
   --> $DIR/propagate-approximated-shorter-to-static-no-bound.rs:32:5
index 033357b09fb2e3a3d889a7474be1abd19316bea0..5b5440e7a9641ac29197d49e226b7f35bb6b566f 100644 (file)
@@ -10,9 +10,9 @@ LL | |         demand_y(x, y, x.get())
 LL | |     });
    | |_____^
    |
-   = note: defining type: DefId(0/1:18 ~ propagate_approximated_shorter_to_static_wrong_bound[317d]::supply[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:25 ~ propagate_approximated_shorter_to_static_wrong_bound[317d]::supply[0]::{{closure}}[0]) with closure substs [
                i16,
-               for<'r, 's, 't0, 't1, 't2, 't3> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't0)) std::cell::Cell<&'_#2r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't1)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't2)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't3)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't1)) u32>)),
+               for<'r, 's, 't0, 't1, 't2, 't3> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't0)) std::cell::Cell<&'_#2r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't1)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't2)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't3)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't1)) u32>)),
            ]
    = note: late-bound region is '_#3r
    = note: late-bound region is '_#4r
@@ -31,7 +31,7 @@ LL | |     });
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ propagate_approximated_shorter_to_static_wrong_bound[317d]::supply[0]) with substs []
+   = note: defining type: DefId(0:22 ~ propagate_approximated_shorter_to_static_wrong_bound[317d]::supply[0]) with substs []
 
 error[E0521]: borrowed data escapes outside of function
   --> $DIR/propagate-approximated-shorter-to-static-wrong-bound.rs:35:5
index 223c29f596922d0e6bddffbc8d6481031bf7cbdd..a08cde2c9c6352e3238709afb018e563d730e20b 100644 (file)
@@ -9,9 +9,9 @@ LL | |
 LL | |     });
    | |_____^
    |
-   = note: defining type: DefId(0/1:18 ~ propagate_approximated_val[317d]::test[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:25 ~ propagate_approximated_val[317d]::test[0]::{{closure}}[0]) with closure substs [
                i16,
-               for<'r, 's> extern "rust-call" fn((std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) &'_#2r u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) u32>)),
+               for<'r, 's> extern "rust-call" fn((std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) &'_#2r u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) u32>)),
            ]
    = note: late-bound region is '_#3r
    = note: late-bound region is '_#4r
@@ -30,7 +30,7 @@ LL | |     });
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ propagate_approximated_val[317d]::test[0]) with substs []
+   = note: defining type: DefId(0:22 ~ propagate_approximated_val[317d]::test[0]) with substs []
 
 error: lifetime may not live long enough
   --> $DIR/propagate-approximated-val.rs:38:9
index d618b4d06a1d85eb2cf492f6998473966194539c..60847bb2e92905d8d34c143b40112f8eb630a03a 100644 (file)
@@ -8,9 +8,9 @@ LL | |             demand_y(x, y, p)
 LL | |         },
    | |_________^
    |
-   = note: defining type: DefId(0/1:16 ~ propagate_despite_same_free_region[317d]::supply[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:23 ~ propagate_despite_same_free_region[317d]::supply[0]::{{closure}}[0]) with closure substs [
                i16,
-               for<'r, 's> extern "rust-call" fn((std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) &'_#2r u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) u32>)),
+               for<'r, 's> extern "rust-call" fn((std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) &'_#2r u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) u32>, std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) u32>)),
            ]
    = note: late-bound region is '_#3r
    = note: number of external vids: 4
@@ -28,5 +28,5 @@ LL | |     );
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ propagate_despite_same_free_region[317d]::supply[0]) with substs []
+   = note: defining type: DefId(0:21 ~ propagate_despite_same_free_region[317d]::supply[0]) with substs []
 
index 07fb4d0d5e3ae177eb97f20e83bdcba9840a23ae..a660c763bff78bb780bbce53a7a6520a7f512ca1 100644 (file)
@@ -9,9 +9,9 @@ LL | |
 LL | |     });
    | |_____^
    |
-   = note: defining type: DefId(0/1:18 ~ propagate_fail_to_approximate_longer_no_bounds[317d]::supply[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:25 ~ propagate_fail_to_approximate_longer_no_bounds[317d]::supply[0]::{{closure}}[0]) with closure substs [
                i16,
-               for<'r, 's, 't0, 't1, 't2> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) &'_#1r u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't0)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't1)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't2)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) u32>)),
+               for<'r, 's, 't0, 't1, 't2> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) &'_#1r u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't0)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't1)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't2)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) u32>)),
            ]
    = note: late-bound region is '_#2r
    = note: late-bound region is '_#3r
@@ -39,7 +39,7 @@ LL | |     });
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ propagate_fail_to_approximate_longer_no_bounds[317d]::supply[0]) with substs []
+   = note: defining type: DefId(0:22 ~ propagate_fail_to_approximate_longer_no_bounds[317d]::supply[0]) with substs []
 
 error: aborting due to previous error
 
index a0744c27db72cf2682cc7a110891ff73419f93aa..9671b8ebff3a42ee6e825f0475579c882827fae3 100644 (file)
@@ -9,9 +9,9 @@ LL | |
 LL | |     });
    | |_____^
    |
-   = note: defining type: DefId(0/1:18 ~ propagate_fail_to_approximate_longer_wrong_bounds[317d]::supply[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:25 ~ propagate_fail_to_approximate_longer_wrong_bounds[317d]::supply[0]::{{closure}}[0]) with closure substs [
                i16,
-               for<'r, 's, 't0, 't1, 't2, 't3> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) &'_#1r u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't0)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't1)) &'_#2r u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't2)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't3)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 't1)) u32>)),
+               for<'r, 's, 't0, 't1, 't2, 't3> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) &'_#1r u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't0)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't1)) &'_#2r u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't2)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) u32>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't3)) std::cell::Cell<&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 't1)) u32>)),
            ]
    = note: late-bound region is '_#3r
    = note: late-bound region is '_#4r
@@ -39,7 +39,7 @@ LL | |     });
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ propagate_fail_to_approximate_longer_wrong_bounds[317d]::supply[0]) with substs []
+   = note: defining type: DefId(0:22 ~ propagate_fail_to_approximate_longer_wrong_bounds[317d]::supply[0]) with substs []
 
 error: aborting due to previous error
 
index 282246f81666bb966d771dfc0114e5642a653986..457b5950b7ff05dd2c51e7b7bb3d820e074b6e30 100644 (file)
@@ -11,7 +11,7 @@ LL | |         require(value);
 LL | |     });
    | |_____^
    |
-   = note: defining type: DefId(0/1:16 ~ propagate_from_trait_match[317d]::supply[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:23 ~ propagate_from_trait_match[317d]::supply[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -32,7 +32,7 @@ LL | |     });
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ propagate_from_trait_match[317d]::supply[0]) with substs [
+   = note: defining type: DefId(0:20 ~ propagate_from_trait_match[317d]::supply[0]) with substs [
                '_#1r,
                T,
            ]
index c5645413c77cd066a94fc7f056242726f8822b8b..8aff6d5b892798086ff739f2cfca360d2423b688 100644 (file)
@@ -4,9 +4,9 @@ note: No external requirements
 LL |     expect_sig(|a, b| b); // ought to return `a`
    |                ^^^^^^^^
    |
-   = note: defining type: DefId(0/1:9 ~ return_wrong_bound_region[317d]::test[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:13 ~ return_wrong_bound_region[317d]::test[0]::{{closure}}[0]) with closure substs [
                i16,
-               for<'r, 's> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) i32, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) i32)) -> &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) i32,
+               for<'r, 's> extern "rust-call" fn((&ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) i32, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) i32)) -> &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) i32,
            ]
 
 error: lifetime may not live long enough
@@ -27,7 +27,7 @@ LL | |
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:3 ~ return_wrong_bound_region[317d]::test[0]) with substs []
+   = note: defining type: DefId(0:12 ~ return_wrong_bound_region[317d]::test[0]) with substs []
 
 error: aborting due to previous error
 
index cda1f7d36311cc973ed9b38cd7670c6e265c72aa..9fa54e83812f721cb9bc5927aaf1bc914d9f4704 100644 (file)
@@ -4,7 +4,7 @@ note: External requirements
 LL |     with_signature(x, |mut y| Box::new(y.next()))
    |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:15 ~ projection_no_regions_closure[317d]::no_region[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:22 ~ projection_no_regions_closure[317d]::no_region[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -25,7 +25,7 @@ LL | |
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ projection_no_regions_closure[317d]::no_region[0]) with substs [
+   = note: defining type: DefId(0:19 ~ projection_no_regions_closure[317d]::no_region[0]) with substs [
                '_#1r,
                T,
            ]
@@ -44,7 +44,7 @@ note: External requirements
 LL |     with_signature(x, |mut y| Box::new(y.next()))
    |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:18 ~ projection_no_regions_closure[317d]::correct_region[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:26 ~ projection_no_regions_closure[317d]::correct_region[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -64,7 +64,7 @@ LL | |     with_signature(x, |mut y| Box::new(y.next()))
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:7 ~ projection_no_regions_closure[317d]::correct_region[0]) with substs [
+   = note: defining type: DefId(0:23 ~ projection_no_regions_closure[317d]::correct_region[0]) with substs [
                '_#1r,
                T,
            ]
@@ -75,7 +75,7 @@ note: External requirements
 LL |     with_signature(x, |mut y| Box::new(y.next()))
    |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:22 ~ projection_no_regions_closure[317d]::wrong_region[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:31 ~ projection_no_regions_closure[317d]::wrong_region[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -97,7 +97,7 @@ LL | |
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:8 ~ projection_no_regions_closure[317d]::wrong_region[0]) with substs [
+   = note: defining type: DefId(0:27 ~ projection_no_regions_closure[317d]::wrong_region[0]) with substs [
                '_#1r,
                '_#2r,
                T,
@@ -117,7 +117,7 @@ note: External requirements
 LL |     with_signature(x, |mut y| Box::new(y.next()))
    |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:26 ~ projection_no_regions_closure[317d]::outlives_region[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:36 ~ projection_no_regions_closure[317d]::outlives_region[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -139,7 +139,7 @@ LL | |     with_signature(x, |mut y| Box::new(y.next()))
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:9 ~ projection_no_regions_closure[317d]::outlives_region[0]) with substs [
+   = note: defining type: DefId(0:32 ~ projection_no_regions_closure[317d]::outlives_region[0]) with substs [
                '_#1r,
                '_#2r,
                T,
index 9d716006500b779c15e91d1181baf3006e586a09..10b2bd1af47028e43d93d0f843ded2dffb4b7c1c 100644 (file)
@@ -4,7 +4,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:19 ~ projection_one_region_closure[317d]::no_relationships_late[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:28 ~ projection_one_region_closure[317d]::no_relationships_late[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -27,7 +27,7 @@ LL | |
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:8 ~ projection_one_region_closure[317d]::no_relationships_late[0]) with substs [
+   = note: defining type: DefId(0:24 ~ projection_one_region_closure[317d]::no_relationships_late[0]) with substs [
                '_#1r,
                T,
            ]
@@ -38,7 +38,7 @@ error[E0309]: the parameter type `T` may not live long enough
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = help: consider adding an explicit lifetime bound `T: ReFree(DefId(0/0:8 ~ projection_one_region_closure[317d]::no_relationships_late[0]), BrNamed(crate0:DefIndex(1:16), 'a))`...
+   = help: consider adding an explicit lifetime bound `T: ReFree(DefId(0:24 ~ projection_one_region_closure[317d]::no_relationships_late[0]), BrNamed(crate0:DefIndex(25), 'a))`...
 
 error: lifetime may not live long enough
   --> $DIR/projection-one-region-closure.rs:45:39
@@ -57,7 +57,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:23 ~ projection_one_region_closure[317d]::no_relationships_early[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:33 ~ projection_one_region_closure[317d]::no_relationships_early[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -80,7 +80,7 @@ LL | |
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:9 ~ projection_one_region_closure[317d]::no_relationships_early[0]) with substs [
+   = note: defining type: DefId(0:29 ~ projection_one_region_closure[317d]::no_relationships_early[0]) with substs [
                '_#1r,
                '_#2r,
                T,
@@ -111,7 +111,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:27 ~ projection_one_region_closure[317d]::projection_outlives[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:38 ~ projection_one_region_closure[317d]::projection_outlives[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -133,7 +133,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:10 ~ projection_one_region_closure[317d]::projection_outlives[0]) with substs [
+   = note: defining type: DefId(0:34 ~ projection_one_region_closure[317d]::projection_outlives[0]) with substs [
                '_#1r,
                '_#2r,
                T,
@@ -145,7 +145,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:31 ~ projection_one_region_closure[317d]::elements_outlive[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:43 ~ projection_one_region_closure[317d]::elements_outlive[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -168,7 +168,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:11 ~ projection_one_region_closure[317d]::elements_outlive[0]) with substs [
+   = note: defining type: DefId(0:39 ~ projection_one_region_closure[317d]::elements_outlive[0]) with substs [
                '_#1r,
                '_#2r,
                T,
index 0fa4060137a3f837969a7227ac5a001e771d0efa..b4b74bfc1284f25da7efbc1fffda08d6a9dd8e35 100644 (file)
@@ -4,7 +4,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:19 ~ projection_one_region_trait_bound_closure[317d]::no_relationships_late[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:28 ~ projection_one_region_trait_bound_closure[317d]::no_relationships_late[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -26,7 +26,7 @@ LL | |
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:8 ~ projection_one_region_trait_bound_closure[317d]::no_relationships_late[0]) with substs [
+   = note: defining type: DefId(0:24 ~ projection_one_region_trait_bound_closure[317d]::no_relationships_late[0]) with substs [
                '_#1r,
                T,
            ]
@@ -48,7 +48,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:23 ~ projection_one_region_trait_bound_closure[317d]::no_relationships_early[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:33 ~ projection_one_region_trait_bound_closure[317d]::no_relationships_early[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -70,7 +70,7 @@ LL | |
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:9 ~ projection_one_region_trait_bound_closure[317d]::no_relationships_early[0]) with substs [
+   = note: defining type: DefId(0:29 ~ projection_one_region_trait_bound_closure[317d]::no_relationships_early[0]) with substs [
                '_#1r,
                '_#2r,
                T,
@@ -93,7 +93,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:27 ~ projection_one_region_trait_bound_closure[317d]::projection_outlives[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:38 ~ projection_one_region_trait_bound_closure[317d]::projection_outlives[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -115,7 +115,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:10 ~ projection_one_region_trait_bound_closure[317d]::projection_outlives[0]) with substs [
+   = note: defining type: DefId(0:34 ~ projection_one_region_trait_bound_closure[317d]::projection_outlives[0]) with substs [
                '_#1r,
                '_#2r,
                T,
@@ -127,7 +127,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:31 ~ projection_one_region_trait_bound_closure[317d]::elements_outlive[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:43 ~ projection_one_region_trait_bound_closure[317d]::elements_outlive[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -149,7 +149,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:11 ~ projection_one_region_trait_bound_closure[317d]::elements_outlive[0]) with substs [
+   = note: defining type: DefId(0:39 ~ projection_one_region_trait_bound_closure[317d]::elements_outlive[0]) with substs [
                '_#1r,
                '_#2r,
                T,
@@ -161,7 +161,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:34 ~ projection_one_region_trait_bound_closure[317d]::one_region[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:47 ~ projection_one_region_trait_bound_closure[317d]::one_region[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -182,7 +182,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:12 ~ projection_one_region_trait_bound_closure[317d]::one_region[0]) with substs [
+   = note: defining type: DefId(0:44 ~ projection_one_region_trait_bound_closure[317d]::one_region[0]) with substs [
                '_#1r,
                T,
            ]
index f616a7feae3f01bf606554db66b82ff2069cc00b..a757a43499f4b7472dc80e6ad7cd847b363f0b58 100644 (file)
@@ -4,7 +4,7 @@ note: No external requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:19 ~ projection_one_region_trait_bound_static_closure[317d]::no_relationships_late[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:28 ~ projection_one_region_trait_bound_static_closure[317d]::no_relationships_late[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -23,7 +23,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:8 ~ projection_one_region_trait_bound_static_closure[317d]::no_relationships_late[0]) with substs [
+   = note: defining type: DefId(0:24 ~ projection_one_region_trait_bound_static_closure[317d]::no_relationships_late[0]) with substs [
                '_#1r,
                T,
            ]
@@ -34,7 +34,7 @@ note: No external requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:23 ~ projection_one_region_trait_bound_static_closure[317d]::no_relationships_early[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:33 ~ projection_one_region_trait_bound_static_closure[317d]::no_relationships_early[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -54,7 +54,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:9 ~ projection_one_region_trait_bound_static_closure[317d]::no_relationships_early[0]) with substs [
+   = note: defining type: DefId(0:29 ~ projection_one_region_trait_bound_static_closure[317d]::no_relationships_early[0]) with substs [
                '_#1r,
                '_#2r,
                T,
@@ -66,7 +66,7 @@ note: No external requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:27 ~ projection_one_region_trait_bound_static_closure[317d]::projection_outlives[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:38 ~ projection_one_region_trait_bound_static_closure[317d]::projection_outlives[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -86,7 +86,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:10 ~ projection_one_region_trait_bound_static_closure[317d]::projection_outlives[0]) with substs [
+   = note: defining type: DefId(0:34 ~ projection_one_region_trait_bound_static_closure[317d]::projection_outlives[0]) with substs [
                '_#1r,
                '_#2r,
                T,
@@ -98,7 +98,7 @@ note: No external requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:31 ~ projection_one_region_trait_bound_static_closure[317d]::elements_outlive[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:43 ~ projection_one_region_trait_bound_static_closure[317d]::elements_outlive[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -118,7 +118,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:11 ~ projection_one_region_trait_bound_static_closure[317d]::elements_outlive[0]) with substs [
+   = note: defining type: DefId(0:39 ~ projection_one_region_trait_bound_static_closure[317d]::elements_outlive[0]) with substs [
                '_#1r,
                '_#2r,
                T,
@@ -130,7 +130,7 @@ note: No external requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:34 ~ projection_one_region_trait_bound_static_closure[317d]::one_region[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:47 ~ projection_one_region_trait_bound_static_closure[317d]::one_region[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -149,7 +149,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:12 ~ projection_one_region_trait_bound_static_closure[317d]::one_region[0]) with substs [
+   = note: defining type: DefId(0:44 ~ projection_one_region_trait_bound_static_closure[317d]::one_region[0]) with substs [
                '_#1r,
                T,
            ]
index b761b031444dac454a1498112a55605f8e7c8a8b..a48766cd7340b578927cf1fd02f115e5eeb9dc6f 100644 (file)
@@ -4,7 +4,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:22 ~ projection_two_region_trait_bound_closure[317d]::no_relationships_late[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:31 ~ projection_two_region_trait_bound_closure[317d]::no_relationships_late[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -27,7 +27,7 @@ LL | |
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:8 ~ projection_two_region_trait_bound_closure[317d]::no_relationships_late[0]) with substs [
+   = note: defining type: DefId(0:26 ~ projection_two_region_trait_bound_closure[317d]::no_relationships_late[0]) with substs [
                '_#1r,
                '_#2r,
                T,
@@ -39,7 +39,7 @@ error[E0309]: the associated type `<T as Anything<'_#5r, '_#6r>>::AssocType` may
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = help: consider adding an explicit lifetime bound `<T as Anything<'_#5r, '_#6r>>::AssocType: ReFree(DefId(0/0:8 ~ projection_two_region_trait_bound_closure[317d]::no_relationships_late[0]), BrNamed(crate0:DefIndex(1:18), 'a))`...
+   = help: consider adding an explicit lifetime bound `<T as Anything<'_#5r, '_#6r>>::AssocType: ReFree(DefId(0:26 ~ projection_two_region_trait_bound_closure[317d]::no_relationships_late[0]), BrNamed(crate0:DefIndex(27), 'a))`...
 
 note: External requirements
   --> $DIR/projection-two-region-trait-bound-closure.rs:48:29
@@ -47,7 +47,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:27 ~ projection_two_region_trait_bound_closure[317d]::no_relationships_early[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:37 ~ projection_two_region_trait_bound_closure[317d]::no_relationships_early[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                '_#3r,
@@ -70,7 +70,7 @@ LL | |
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:9 ~ projection_two_region_trait_bound_closure[317d]::no_relationships_early[0]) with substs [
+   = note: defining type: DefId(0:32 ~ projection_two_region_trait_bound_closure[317d]::no_relationships_early[0]) with substs [
                '_#1r,
                '_#2r,
                '_#3r,
@@ -91,7 +91,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:32 ~ projection_two_region_trait_bound_closure[317d]::projection_outlives[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:43 ~ projection_two_region_trait_bound_closure[317d]::projection_outlives[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                '_#3r,
@@ -114,7 +114,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:10 ~ projection_two_region_trait_bound_closure[317d]::projection_outlives[0]) with substs [
+   = note: defining type: DefId(0:38 ~ projection_two_region_trait_bound_closure[317d]::projection_outlives[0]) with substs [
                '_#1r,
                '_#2r,
                '_#3r,
@@ -127,7 +127,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:37 ~ projection_two_region_trait_bound_closure[317d]::elements_outlive1[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:49 ~ projection_two_region_trait_bound_closure[317d]::elements_outlive1[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                '_#3r,
@@ -150,7 +150,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:11 ~ projection_two_region_trait_bound_closure[317d]::elements_outlive1[0]) with substs [
+   = note: defining type: DefId(0:44 ~ projection_two_region_trait_bound_closure[317d]::elements_outlive1[0]) with substs [
                '_#1r,
                '_#2r,
                '_#3r,
@@ -163,7 +163,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:42 ~ projection_two_region_trait_bound_closure[317d]::elements_outlive2[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:55 ~ projection_two_region_trait_bound_closure[317d]::elements_outlive2[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                '_#3r,
@@ -186,7 +186,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:12 ~ projection_two_region_trait_bound_closure[317d]::elements_outlive2[0]) with substs [
+   = note: defining type: DefId(0:50 ~ projection_two_region_trait_bound_closure[317d]::elements_outlive2[0]) with substs [
                '_#1r,
                '_#2r,
                '_#3r,
@@ -199,7 +199,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:46 ~ projection_two_region_trait_bound_closure[317d]::two_regions[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:60 ~ projection_two_region_trait_bound_closure[317d]::two_regions[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -221,7 +221,7 @@ LL | |
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:13 ~ projection_two_region_trait_bound_closure[317d]::two_regions[0]) with substs [
+   = note: defining type: DefId(0:56 ~ projection_two_region_trait_bound_closure[317d]::two_regions[0]) with substs [
                '_#1r,
                T,
            ]
@@ -243,7 +243,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:50 ~ projection_two_region_trait_bound_closure[317d]::two_regions_outlive[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:65 ~ projection_two_region_trait_bound_closure[317d]::two_regions_outlive[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -265,7 +265,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:14 ~ projection_two_region_trait_bound_closure[317d]::two_regions_outlive[0]) with substs [
+   = note: defining type: DefId(0:61 ~ projection_two_region_trait_bound_closure[317d]::two_regions_outlive[0]) with substs [
                '_#1r,
                '_#2r,
                T,
@@ -277,7 +277,7 @@ note: External requirements
 LL |     with_signature(cell, t, |cell, t| require(cell, t));
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:53 ~ projection_two_region_trait_bound_closure[317d]::one_region[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:69 ~ projection_two_region_trait_bound_closure[317d]::one_region[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -298,7 +298,7 @@ LL | |     with_signature(cell, t, |cell, t| require(cell, t));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:15 ~ projection_two_region_trait_bound_closure[317d]::one_region[0]) with substs [
+   = note: defining type: DefId(0:66 ~ projection_two_region_trait_bound_closure[317d]::one_region[0]) with substs [
                '_#1r,
                T,
            ]
index 6f3071becfd0e75584db0f2df36ffb2634bd49a4..2ed94df1f347850648fa2a0fa088a2dd16cbf990 100644 (file)
@@ -4,10 +4,10 @@ note: External requirements
 LL |     twice(cell, value, |a, b| invoke(a, b));
    |                        ^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:14 ~ ty_param_closure_approximate_lower_bound[317d]::generic[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:20 ~ ty_param_closure_approximate_lower_bound[317d]::generic[0]::{{closure}}[0]) with closure substs [
                T,
                i16,
-               for<'r, 's> extern "rust-call" fn((std::option::Option<std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) ()>>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) T)),
+               for<'r, 's> extern "rust-call" fn((std::option::Option<std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) ()>>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) T)),
            ]
    = note: number of external vids: 2
    = note: where T: '_#1r
@@ -21,7 +21,7 @@ LL | |     twice(cell, value, |a, b| invoke(a, b));
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:5 ~ ty_param_closure_approximate_lower_bound[317d]::generic[0]) with substs [
+   = note: defining type: DefId(0:18 ~ ty_param_closure_approximate_lower_bound[317d]::generic[0]) with substs [
                T,
            ]
 
@@ -31,10 +31,10 @@ note: External requirements
 LL |     twice(cell, value, |a, b| invoke(a, b));
    |                        ^^^^^^^^^^^^^^^^^^^
    |
-   = note: defining type: DefId(0/1:17 ~ ty_param_closure_approximate_lower_bound[317d]::generic_fail[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:24 ~ ty_param_closure_approximate_lower_bound[317d]::generic_fail[0]::{{closure}}[0]) with closure substs [
                T,
                i16,
-               for<'r, 's> extern "rust-call" fn((std::option::Option<std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 'r)) ()>>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0:0), 's)) T)),
+               for<'r, 's> extern "rust-call" fn((std::option::Option<std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) ()>>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) T)),
            ]
    = note: late-bound region is '_#2r
    = note: number of external vids: 3
@@ -49,7 +49,7 @@ LL | |
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ ty_param_closure_approximate_lower_bound[317d]::generic_fail[0]) with substs [
+   = note: defining type: DefId(0:21 ~ ty_param_closure_approximate_lower_bound[317d]::generic_fail[0]) with substs [
                T,
            ]
 
@@ -59,7 +59,7 @@ error[E0309]: the parameter type `T` may not live long enough
 LL |     twice(cell, value, |a, b| invoke(a, b));
    |                        ^^^^^^^^^^^^^^^^^^^
    |
-   = help: consider adding an explicit lifetime bound `T: ReFree(DefId(0/0:6 ~ ty_param_closure_approximate_lower_bound[317d]::generic_fail[0]), BrNamed(crate0:DefIndex(1:15), 'a))`...
+   = help: consider adding an explicit lifetime bound `T: ReFree(DefId(0:21 ~ ty_param_closure_approximate_lower_bound[317d]::generic_fail[0]), BrNamed(crate0:DefIndex(22), 'a))`...
 
 error: aborting due to previous error
 
index cdb715762031fbf1dea2ac7f6be858c659f8f256..d689949969d7ed58a6db35014ae4a3f0323c3ad4 100644 (file)
@@ -4,7 +4,7 @@ note: External requirements
 LL |     with_signature(x, |y| y)
    |                       ^^^^^
    |
-   = note: defining type: DefId(0/1:14 ~ ty_param_closure_outlives_from_return_type[317d]::no_region[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:20 ~ ty_param_closure_outlives_from_return_type[317d]::no_region[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -25,7 +25,7 @@ LL | |
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:5 ~ ty_param_closure_outlives_from_return_type[317d]::no_region[0]) with substs [
+   = note: defining type: DefId(0:17 ~ ty_param_closure_outlives_from_return_type[317d]::no_region[0]) with substs [
                '_#1r,
                T,
            ]
index 68798a335f9df52760e0b6bf078c0f42980c61f8..11444c9f72bef6bf3333734e2defdf0446d7dcc9 100644 (file)
@@ -11,7 +11,7 @@ LL | |         require(&x, &y)
 LL | |     })
    | |_____^
    |
-   = note: defining type: DefId(0/1:16 ~ ty_param_closure_outlives_from_where_clause[317d]::no_region[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:23 ~ ty_param_closure_outlives_from_where_clause[317d]::no_region[0]::{{closure}}[0]) with closure substs [
                T,
                i32,
                extern "rust-call" fn((std::cell::Cell<&'_#1r ()>, T)),
@@ -32,7 +32,7 @@ LL | |     })
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:6 ~ ty_param_closure_outlives_from_where_clause[317d]::no_region[0]) with substs [
+   = note: defining type: DefId(0:20 ~ ty_param_closure_outlives_from_where_clause[317d]::no_region[0]) with substs [
                T,
            ]
 
@@ -49,7 +49,7 @@ LL | |         require(&x, &y)
 LL | |     })
    | |_____^
    |
-   = help: consider adding an explicit lifetime bound `T: ReFree(DefId(0/0:6 ~ ty_param_closure_outlives_from_where_clause[317d]::no_region[0]), BrNamed(crate0:DefIndex(1:14), 'a))`...
+   = help: consider adding an explicit lifetime bound `T: ReFree(DefId(0:20 ~ ty_param_closure_outlives_from_where_clause[317d]::no_region[0]), BrNamed(crate0:DefIndex(21), 'a))`...
 
 note: External requirements
   --> $DIR/ty-param-closure-outlives-from-where-clause.rs:43:26
@@ -64,7 +64,7 @@ LL | |         require(&x, &y)
 LL | |     })
    | |_____^
    |
-   = note: defining type: DefId(0/1:19 ~ ty_param_closure_outlives_from_where_clause[317d]::correct_region[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:27 ~ ty_param_closure_outlives_from_where_clause[317d]::correct_region[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -85,7 +85,7 @@ LL | |     })
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:7 ~ ty_param_closure_outlives_from_where_clause[317d]::correct_region[0]) with substs [
+   = note: defining type: DefId(0:24 ~ ty_param_closure_outlives_from_where_clause[317d]::correct_region[0]) with substs [
                '_#1r,
                T,
            ]
@@ -101,7 +101,7 @@ LL | |         require(&x, &y)
 LL | |     })
    | |_____^
    |
-   = note: defining type: DefId(0/1:23 ~ ty_param_closure_outlives_from_where_clause[317d]::wrong_region[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:32 ~ ty_param_closure_outlives_from_where_clause[317d]::wrong_region[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                T,
                i32,
@@ -123,7 +123,7 @@ LL | |     })
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:8 ~ ty_param_closure_outlives_from_where_clause[317d]::wrong_region[0]) with substs [
+   = note: defining type: DefId(0:28 ~ ty_param_closure_outlives_from_where_clause[317d]::wrong_region[0]) with substs [
                '_#1r,
                T,
            ]
@@ -139,7 +139,7 @@ LL | |         require(&x, &y)
 LL | |     })
    | |_____^
    |
-   = help: consider adding an explicit lifetime bound `T: ReFree(DefId(0/0:8 ~ ty_param_closure_outlives_from_where_clause[317d]::wrong_region[0]), BrNamed(crate0:DefIndex(1:20), 'a))`...
+   = help: consider adding an explicit lifetime bound `T: ReFree(DefId(0:28 ~ ty_param_closure_outlives_from_where_clause[317d]::wrong_region[0]), BrNamed(crate0:DefIndex(29), 'a))`...
 
 note: External requirements
   --> $DIR/ty-param-closure-outlives-from-where-clause.rs:77:26
@@ -151,7 +151,7 @@ LL | |         require(&x, &y)
 LL | |     })
    | |_____^
    |
-   = note: defining type: DefId(0/1:27 ~ ty_param_closure_outlives_from_where_clause[317d]::outlives_region[0]::{{closure}}[0]) with closure substs [
+   = note: defining type: DefId(0:37 ~ ty_param_closure_outlives_from_where_clause[317d]::outlives_region[0]::{{closure}}[0]) with closure substs [
                '_#1r,
                '_#2r,
                T,
@@ -173,7 +173,7 @@ LL | |     })
 LL | | }
    | |_^
    |
-   = note: defining type: DefId(0/0:9 ~ ty_param_closure_outlives_from_where_clause[317d]::outlives_region[0]) with substs [
+   = note: defining type: DefId(0:33 ~ ty_param_closure_outlives_from_where_clause[317d]::outlives_region[0]) with substs [
                '_#1r,
                '_#2r,
                T,