1
Fork 0

rustc: Remove needless lifetimes

This commit is contained in:
Jeremy Stucki 2022-12-20 22:10:40 +01:00
parent 65bd2a6a73
commit 3dde32ca97
No known key found for this signature in database
GPG key ID: D2A1E19158A33812
109 changed files with 266 additions and 320 deletions

View file

@ -719,7 +719,7 @@ impl<'tcx> chalk_ir::UnificationDatabase<RustInterner<'tcx>> for RustIrDatabase<
/// var bound at index `0`. For types, we use a `BoundVar` index equal to
/// the type parameter index. For regions, we use the `BoundRegionKind::BrNamed`
/// variant (which has a `DefId`).
fn bound_vars_for_item<'tcx>(tcx: TyCtxt<'tcx>, def_id: DefId) -> SubstsRef<'tcx> {
fn bound_vars_for_item(tcx: TyCtxt<'_>, def_id: DefId) -> SubstsRef<'_> {
InternalSubsts::for_item(tcx, def_id, |param, substs| match param.kind {
ty::GenericParamDefKind::Type { .. } => tcx
.mk_ty(ty::Bound(

View file

@ -54,7 +54,7 @@ fn try_normalize_after_erasing_regions<'tcx, T: TypeFoldable<'tcx> + PartialEq +
}
}
fn not_outlives_predicate<'tcx>(p: ty::Predicate<'tcx>) -> bool {
fn not_outlives_predicate(p: ty::Predicate<'_>) -> bool {
match p.kind().skip_binder() {
ty::PredicateKind::Clause(ty::Clause::RegionOutlives(..))
| ty::PredicateKind::Clause(ty::Clause::TypeOutlives(..)) => false,