mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-08-04 18:58:41 +00:00
Remove last use of rustc_pat_analysis::Captures
It's not necessary anymore due to Rust 2024 lifetime capture rules.
This commit is contained in:
parent
6df12139bc
commit
0eb3ee8eb1
1 changed files with 5 additions and 5 deletions
|
@ -6,7 +6,7 @@ use std::fmt;
|
|||
use hir_def::{DefWithBodyId, EnumId, EnumVariantId, HasModule, LocalFieldId, ModuleId, VariantId};
|
||||
use intern::sym;
|
||||
use rustc_pattern_analysis::{
|
||||
Captures, IndexVec, PatCx, PrivateUninhabitedField,
|
||||
IndexVec, PatCx, PrivateUninhabitedField,
|
||||
constructor::{Constructor, ConstructorSet, VariantVisibility},
|
||||
usefulness::{PlaceValidity, UsefulnessReport, compute_match_usefulness},
|
||||
};
|
||||
|
@ -138,11 +138,11 @@ impl<'db> MatchCheckCtx<'db> {
|
|||
}
|
||||
|
||||
// This lists the fields of a variant along with their types.
|
||||
fn list_variant_fields<'a>(
|
||||
&'a self,
|
||||
ty: &'a Ty,
|
||||
fn list_variant_fields(
|
||||
&self,
|
||||
ty: &Ty,
|
||||
variant: VariantId,
|
||||
) -> impl Iterator<Item = (LocalFieldId, Ty)> + Captures<'a> + Captures<'db> {
|
||||
) -> impl Iterator<Item = (LocalFieldId, Ty)> {
|
||||
let (_, substs) = ty.as_adt().unwrap();
|
||||
|
||||
let field_tys = self.db.field_types(variant);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue