Fix tools
This commit is contained in:
parent
2701a4175f
commit
6b371469bf
@ -11,7 +11,7 @@
|
|||||||
use rustc_middle::hir::nested_filter;
|
use rustc_middle::hir::nested_filter;
|
||||||
use rustc_middle::traits::Reveal;
|
use rustc_middle::traits::Reveal;
|
||||||
use rustc_middle::ty::{
|
use rustc_middle::ty::{
|
||||||
self, ClauseKind, GenericArgKind, GenericParamDefKind, ParamEnv, ToPredicate, TraitPredicate, Ty, TyCtxt,
|
self, ClauseKind, GenericArgKind, GenericParamDefKind, ParamEnv, Upcast, TraitPredicate, Ty, TyCtxt,
|
||||||
};
|
};
|
||||||
use rustc_session::declare_lint_pass;
|
use rustc_session::declare_lint_pass;
|
||||||
use rustc_span::def_id::LocalDefId;
|
use rustc_span::def_id::LocalDefId;
|
||||||
@ -503,7 +503,7 @@ fn param_env_for_derived_eq(tcx: TyCtxt<'_>, did: DefId, eq_trait_id: DefId) ->
|
|||||||
trait_ref: ty::TraitRef::new(tcx, eq_trait_id, [tcx.mk_param_from_def(param)]),
|
trait_ref: ty::TraitRef::new(tcx, eq_trait_id, [tcx.mk_param_from_def(param)]),
|
||||||
polarity: ty::PredicatePolarity::Positive,
|
polarity: ty::PredicatePolarity::Positive,
|
||||||
})
|
})
|
||||||
.to_predicate(tcx)
|
.upcast(tcx)
|
||||||
}),
|
}),
|
||||||
)),
|
)),
|
||||||
Reveal::UserFacing,
|
Reveal::UserFacing,
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
use rustc_middle::ty::layout::ValidityRequirement;
|
use rustc_middle::ty::layout::ValidityRequirement;
|
||||||
use rustc_middle::ty::{
|
use rustc_middle::ty::{
|
||||||
self, AdtDef, AliasTy, AssocKind, Binder, BoundRegion, FnSig, GenericArg, GenericArgKind, GenericArgsRef,
|
self, AdtDef, AliasTy, AssocKind, Binder, BoundRegion, FnSig, GenericArg, GenericArgKind, GenericArgsRef,
|
||||||
GenericParamDefKind, IntTy, ParamEnv, Region, RegionKind, ToPredicate, TraitRef, Ty, TyCtxt,
|
GenericParamDefKind, IntTy, ParamEnv, Region, RegionKind, Upcast, TraitRef, Ty, TyCtxt,
|
||||||
TypeSuperVisitable, TypeVisitable, TypeVisitableExt, TypeVisitor, UintTy, VariantDef, VariantDiscr,
|
TypeSuperVisitable, TypeVisitable, TypeVisitableExt, TypeVisitor, UintTy, VariantDef, VariantDiscr,
|
||||||
};
|
};
|
||||||
use rustc_span::symbol::Ident;
|
use rustc_span::symbol::Ident;
|
||||||
@ -311,7 +311,7 @@ pub fn implements_trait_with_env_from_iter<'tcx>(
|
|||||||
cause: ObligationCause::dummy(),
|
cause: ObligationCause::dummy(),
|
||||||
param_env,
|
param_env,
|
||||||
recursion_depth: 0,
|
recursion_depth: 0,
|
||||||
predicate: Binder::dummy(trait_ref).to_predicate(tcx),
|
predicate: Binder::dummy(trait_ref).upcast(tcx),
|
||||||
};
|
};
|
||||||
infcx
|
infcx
|
||||||
.evaluate_obligation(&obligation)
|
.evaluate_obligation(&obligation)
|
||||||
|
Loading…
Reference in New Issue
Block a user