Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Cargo.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4858,6 +4858,7 @@ dependencies = [
"rustc_data_structures",
"rustc_errors",
"rustc_hir",
"rustc_index",
"rustc_infer",
"rustc_macros",
"rustc_middle",
Expand Down
4 changes: 2 additions & 2 deletions compiler/rustc_metadata/src/rmeta/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -482,8 +482,8 @@ define_tables! {
anon_const_kind: Table<DefIndex, LazyValue<ty::AnonConstKind>>,
const_of_item: Table<DefIndex, LazyValue<ty::EarlyBinder<'static, ty::Const<'static>>>>,
associated_types_for_impl_traits_in_trait_or_impl: Table<DefIndex, LazyValue<DefIdMap<Vec<DefId>>>>,
live_args_for_alias_from_outlives_bounds: Table<DefIndex, LazyValue<Option<ty::EarlyBinder<'static, Vec<ty::GenericArg<'static>>>>>>,
args_known_to_outlive_alias_params: Table<DefIndex, LazyValue<ty::EarlyBinder<'static, Vec<(ty::Region<'static>, Vec<ty::GenericArg<'static>>)>>>>,
live_args_for_alias_from_outlives_bounds: Table<DefIndex, LazyValue<Option<DenseBitSet<usize>>>>,
args_known_to_outlive_alias_params: Table<DefIndex, LazyValue<Vec<(usize, DenseBitSet<usize>)>>>,
mut_restriction: Table<DefIndex, LazyValue<ty::RestrictionKind>>,
}

Expand Down
1 change: 1 addition & 0 deletions compiler/rustc_metadata/src/rmeta/parameterized.rs
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ trivially_parameterized_over_tcx! {
rustc_hir::def_id::DefIndex,
rustc_hir::definitions::DefKey,
rustc_index::bit_set::DenseBitSet<u32>,
rustc_index::bit_set::DenseBitSet<usize>,
rustc_middle::metadata::AmbigModChild,
rustc_middle::metadata::ModChild,
rustc_middle::middle::codegen_fn_attrs::CodegenFnAttrs,
Expand Down
12 changes: 6 additions & 6 deletions compiler/rustc_middle/src/queries.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2140,9 +2140,9 @@ rustc_queries! {
desc { "listing captured lifetimes for opaque `{}`", tcx.def_path_str(def_id) }
}

/// For an opaque type or trait associated type, return the list of potentially live
/// (identity) generic args from the set of outlives bounds on that alias. Callers should
/// instantiate the returned args with the concrete args of the alias.
/// For an opaque type or trait associated type, return the indices of potentially live
/// generic args from the set of outlives bounds on that alias. Callers should use the
/// indices with the concrete args of the alias.
/// ```ignore (illustrative)
/// // Edition 2024: all args are captured
/// fn foo<'a, 'b, T: 'static>(&'a &'b T) -> impl Sized + 'a {}
Expand All @@ -2155,16 +2155,16 @@ rustc_queries! {
/// (and so is `T`, since `T: 'static` implies `T: 'a`)
/// - `bar` outlives `'static`, so we know that no args are potentially live and we can return an empty set
/// - `baz` has no outlives bound, so return `None` and let the caller decide what to do
query live_args_for_alias_from_outlives_bounds(kind: ty::AliasTyKind<'tcx>) -> &'tcx Option<ty::EarlyBinder<'tcx, Vec<ty::GenericArg<'tcx>>>> {
query live_args_for_alias_from_outlives_bounds(kind: ty::AliasTyKind<'tcx>) -> &'tcx Option<rustc_index::bit_set::DenseBitSet<usize>> {
arena_cache
desc { "identifying live args for alias `{:?}`", kind }
}

/// For each region param of an alias, the identity args that are known to
/// For each region param of an alias, the indices of the identity args that are known to
/// outlive it given only the alias's declared where-clauses. Used for liveness:
/// these are the only args whose regions the underlying type of the alias
/// could capture while satisfying an outlives bound on that param.
query args_known_to_outlive_alias_params(def_id: DefId) -> &'tcx ty::EarlyBinder<'tcx, Vec<(ty::Region<'tcx>, Vec<ty::GenericArg<'tcx>>)>> {
query args_known_to_outlive_alias_params(def_id: DefId) -> &'tcx Vec<(usize, rustc_index::bit_set::DenseBitSet<usize>)> {
arena_cache
desc { "computing the args known to outlive each region param of alias `{}`", tcx.def_path_str(def_id) }
separate_provide_extern
Expand Down
1 change: 1 addition & 0 deletions compiler/rustc_trait_selection/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ rustc_ast = { path = "../rustc_ast" }
rustc_data_structures = { path = "../rustc_data_structures" }
rustc_errors = { path = "../rustc_errors" }
rustc_hir = { path = "../rustc_hir" }
rustc_index = { path = "../rustc_index" }
rustc_infer = { path = "../rustc_infer" }
rustc_macros = { path = "../rustc_macros" }
rustc_middle = { path = "../rustc_middle" }
Expand Down
Loading
Loading