diff options
| author | b-naber <bn263@gmx.de> | 2022-09-22 12:34:23 +0200 |
|---|---|---|
| committer | b-naber <bn263@gmx.de> | 2022-09-23 14:27:34 +0200 |
| commit | a705e65605868adb0879734a984b445d3c40fd6f (patch) | |
| tree | efcbcf22d56aca46f73d412079f2f9bfa3fe7f8b /compiler/rustc_trait_selection/src | |
| parent | efb908991b2c2cd43c40c8e62f563fdd17d84204 (diff) | |
| download | rust-a705e65605868adb0879734a984b445d3c40fd6f.tar.gz rust-a705e65605868adb0879734a984b445d3c40fd6f.zip | |
rename Unevaluated to UnevaluatedConst
Diffstat (limited to 'compiler/rustc_trait_selection/src')
4 files changed, 6 insertions, 6 deletions
diff --git a/compiler/rustc_trait_selection/src/errors.rs b/compiler/rustc_trait_selection/src/errors.rs index 5e1b80eae39..61793468594 100644 --- a/compiler/rustc_trait_selection/src/errors.rs +++ b/compiler/rustc_trait_selection/src/errors.rs @@ -1,6 +1,6 @@ use rustc_errors::{fluent, ErrorGuaranteed, Handler, IntoDiagnostic}; use rustc_macros::Diagnostic; -use rustc_middle::ty::{PolyTraitRef, Ty, Unevaluated}; +use rustc_middle::ty::{self, PolyTraitRef, Ty}; use rustc_session::Limit; use rustc_span::{Span, Symbol}; @@ -18,7 +18,7 @@ pub struct DumpVTableEntries<'a> { pub struct UnableToConstructConstantValue<'a> { #[primary_span] pub span: Span, - pub unevaluated: Unevaluated<'a>, + pub unevaluated: ty::UnevaluatedConst<'a>, } #[derive(Diagnostic)] diff --git a/compiler/rustc_trait_selection/src/traits/const_evaluatable.rs b/compiler/rustc_trait_selection/src/traits/const_evaluatable.rs index 37a0278f0b1..dc585fca34f 100644 --- a/compiler/rustc_trait_selection/src/traits/const_evaluatable.rs +++ b/compiler/rustc_trait_selection/src/traits/const_evaluatable.rs @@ -138,7 +138,7 @@ impl<'tcx> ConstUnifyCtxt<'tcx> { #[instrument(skip(tcx), level = "debug")] pub fn try_unify_abstract_consts<'tcx>( tcx: TyCtxt<'tcx>, - (a, b): (ty::Unevaluated<'tcx>, ty::Unevaluated<'tcx>), + (a, b): (ty::UnevaluatedConst<'tcx>, ty::UnevaluatedConst<'tcx>), param_env: ty::ParamEnv<'tcx>, ) -> bool { (|| { @@ -161,7 +161,7 @@ pub fn try_unify_abstract_consts<'tcx>( #[instrument(skip(infcx), level = "debug")] pub fn is_const_evaluatable<'cx, 'tcx>( infcx: &InferCtxt<'cx, 'tcx>, - uv: ty::Unevaluated<'tcx>, + uv: ty::UnevaluatedConst<'tcx>, param_env: ty::ParamEnv<'tcx>, span: Span, ) -> Result<(), NotConstEvaluatable> { diff --git a/compiler/rustc_trait_selection/src/traits/object_safety.rs b/compiler/rustc_trait_selection/src/traits/object_safety.rs index 163c5f2c089..2773b61e9ba 100644 --- a/compiler/rustc_trait_selection/src/traits/object_safety.rs +++ b/compiler/rustc_trait_selection/src/traits/object_safety.rs @@ -840,7 +840,7 @@ fn contains_illegal_self_type_reference<'tcx, T: TypeVisitable<'tcx>>( fn visit_ty_unevaluated( &mut self, - uv: ty::Unevaluated<'tcx>, + uv: ty::UnevaluatedConst<'tcx>, ) -> ControlFlow<Self::BreakTy> { // Constants can only influence object safety if they reference `Self`. // This is only possible for unevaluated constants, so we walk these here. diff --git a/compiler/rustc_trait_selection/src/traits/project.rs b/compiler/rustc_trait_selection/src/traits/project.rs index 6f41cbeb7af..3befd4b6ffb 100644 --- a/compiler/rustc_trait_selection/src/traits/project.rs +++ b/compiler/rustc_trait_selection/src/traits/project.rs @@ -2141,7 +2141,7 @@ fn confirm_impl_candidate<'cx, 'tcx>( let identity_substs = crate::traits::InternalSubsts::identity_for_item(tcx, assoc_ty.item.def_id); let did = ty::WithOptConstParam::unknown(assoc_ty.item.def_id); - let kind = ty::ConstKind::Unevaluated(ty::Unevaluated::new(did, identity_substs)); + let kind = ty::ConstKind::Unevaluated(ty::UnevaluatedConst::new(did, identity_substs)); ty.map_bound(|ty| tcx.mk_const(ty::ConstS { ty, kind }).into()) } else { ty.map_bound(|ty| ty.into()) |
