Skip to content

Commit 6525e6f

Browse files
committed
Rename implied_outlives_bounds to implied_outlives_bounds_compat
1 parent 8ef7369 commit 6525e6f

File tree

5 files changed

+11
-10
lines changed

5 files changed

+11
-10
lines changed

compiler/rustc_middle/src/arena.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ macro_rules! arena_types {
5353
rustc_middle::traits::query::NormalizationResult<'tcx>
5454
>
5555
>,
56-
[] implied_outlives_bounds:
56+
[] implied_outlives_bounds_compat:
5757
rustc_middle::infer::canonical::Canonical<'tcx,
5858
rustc_middle::infer::canonical::QueryResponse<'tcx,
5959
Vec<rustc_middle::traits::query::OutlivesBound<'tcx>>

compiler/rustc_middle/src/query/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1953,7 +1953,7 @@ rustc_queries! {
19531953
desc { "normalizing `{}`", goal.value }
19541954
}
19551955

1956-
query implied_outlives_bounds(
1956+
query implied_outlives_bounds_compat(
19571957
goal: CanonicalTyGoal<'tcx>
19581958
) -> Result<
19591959
&'tcx Canonical<'tcx, canonical::QueryResponse<'tcx, Vec<OutlivesBound<'tcx>>>>,

compiler/rustc_trait_selection/src/traits/outlives_bounds.rs

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ pub use rustc_middle::traits::query::OutlivesBound;
1111

1212
pub type Bounds<'a, 'tcx: 'a> = impl Iterator<Item = OutlivesBound<'tcx>> + 'a;
1313
pub trait InferCtxtExt<'a, 'tcx> {
14-
fn implied_outlives_bounds(
14+
fn implied_outlives_bounds_compat(
1515
&self,
1616
param_env: ty::ParamEnv<'tcx>,
1717
body_id: LocalDefId,
@@ -47,7 +47,7 @@ impl<'a, 'tcx: 'a> InferCtxtExt<'a, 'tcx> for InferCtxt<'tcx> {
4747
/// into the inference context with this body-id.
4848
/// - `ty`, the type that we are supposed to assume is WF.
4949
#[instrument(level = "debug", skip(self, param_env, body_id), ret)]
50-
fn implied_outlives_bounds(
50+
fn implied_outlives_bounds_compat(
5151
&self,
5252
param_env: ty::ParamEnv<'tcx>,
5353
body_id: LocalDefId,
@@ -67,7 +67,7 @@ impl<'a, 'tcx: 'a> InferCtxtExt<'a, 'tcx> for InferCtxt<'tcx> {
6767
let mut canonical_var_values = OriginalQueryValues::default();
6868
let canonical_ty =
6969
self.canonicalize_query_keep_static(param_env.and(ty), &mut canonical_var_values);
70-
let Ok(canonical_result) = self.tcx.implied_outlives_bounds(canonical_ty) else {
70+
let Ok(canonical_result) = self.tcx.implied_outlives_bounds_compat(canonical_ty) else {
7171
return vec![];
7272
};
7373

@@ -113,7 +113,7 @@ impl<'a, 'tcx: 'a> InferCtxtExt<'a, 'tcx> for InferCtxt<'tcx> {
113113
if !errors.is_empty() {
114114
self.tcx.sess.delay_span_bug(
115115
span,
116-
"implied_outlives_bounds failed to solve obligations from instantiation",
116+
"implied_outlives_bounds_compat failed to solve obligations from instantiation",
117117
);
118118
}
119119
};
@@ -127,6 +127,7 @@ impl<'a, 'tcx: 'a> InferCtxtExt<'a, 'tcx> for InferCtxt<'tcx> {
127127
body_id: LocalDefId,
128128
tys: FxIndexSet<Ty<'tcx>>,
129129
) -> Bounds<'a, 'tcx> {
130-
tys.into_iter().flat_map(move |ty| self.implied_outlives_bounds(param_env, body_id, ty))
130+
tys.into_iter()
131+
.flat_map(move |ty| self.implied_outlives_bounds_compat(param_env, body_id, ty))
131132
}
132133
}

compiler/rustc_trait_selection/src/traits/query/type_op/implied_outlives_bounds.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ impl<'tcx> super::QueryTypeOp<'tcx> for ImpliedOutlivesBounds<'tcx> {
4545
param_env.and(ty)
4646
});
4747

48-
tcx.implied_outlives_bounds(canonicalized)
48+
tcx.implied_outlives_bounds_compat(canonicalized)
4949
}
5050

5151
fn perform_locally_in_new_solver(

compiler/rustc_traits/src/implied_outlives_bounds.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@ use rustc_trait_selection::traits::query::type_op::implied_outlives_bounds::comp
1212
use rustc_trait_selection::traits::query::{CanonicalTyGoal, NoSolution};
1313

1414
pub(crate) fn provide(p: &mut Providers) {
15-
*p = Providers { implied_outlives_bounds, ..*p };
15+
*p = Providers { implied_outlives_bounds_compat, ..*p };
1616
}
1717

18-
fn implied_outlives_bounds<'tcx>(
18+
fn implied_outlives_bounds_compat<'tcx>(
1919
tcx: TyCtxt<'tcx>,
2020
goal: CanonicalTyGoal<'tcx>,
2121
) -> Result<

0 commit comments

Comments
 (0)