about summary refs log tree commit diff
path: root/compiler/rustc_pattern_analysis/src/lib.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-02-07 00:03:50 +0000
committerbors <bors@rust-lang.org>2024-02-07 00:03:50 +0000
commit586893c7b0adabf5f0a4c155fd86e13cf470e74b (patch)
tree7ccc482fdb1247a50693fa04a614375452d7d7d4 /compiler/rustc_pattern_analysis/src/lib.rs
parent256b6fb19a2c018eaad4806d2369d1f6a71fc6ec (diff)
parent84114fea9e3270773b474e3d5534d5ff732db139 (diff)
downloadrust-586893c7b0adabf5f0a4c155fd86e13cf470e74b.tar.gz
rust-586893c7b0adabf5f0a4c155fd86e13cf470e74b.zip
Auto merge of #120722 - matthiaskrgr:rollup-9o32280, r=matthiaskrgr
Rollup of 9 pull requests

Successful merges:

 - #119939 (Improve 'generic param from outer item' error for `Self` and inside `static`/`const` items)
 - #120331 (pattern_analysis: use a plain `Vec` in `DeconstructedPat`)
 - #120396 (Account for unbounded type param receiver in suggestions)
 - #120423 (update indirect structural match lints to match RFC and to show up for dependencies)
 - #120435 (Suggest name value cfg when only value is used for check-cfg)
 - #120502 (Remove `ffi_returns_twice` feature)
 - #120507 (Account for non-overlapping unmet trait bounds in suggestion)
 - #120513 (Normalize type outlives obligations in NLL for new solver)
 - #120707 (Don't expect early-bound region to be local when reporting errors in RPITIT well-formedness)

r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_pattern_analysis/src/lib.rs')
-rw-r--r--compiler/rustc_pattern_analysis/src/lib.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/compiler/rustc_pattern_analysis/src/lib.rs b/compiler/rustc_pattern_analysis/src/lib.rs
index 8e16d4d7bf4..1a151e72488 100644
--- a/compiler/rustc_pattern_analysis/src/lib.rs
+++ b/compiler/rustc_pattern_analysis/src/lib.rs
@@ -119,7 +119,7 @@ pub trait TypeCx: Sized + fmt::Debug {
     /// `DeconstructedPat`. Only invoqued when `pat.ctor()` is `Struct | Variant(_) | UnionField`.
     fn write_variant_name(
         f: &mut fmt::Formatter<'_>,
-        pat: &crate::pat::DeconstructedPat<'_, Self>,
+        pat: &crate::pat::DeconstructedPat<Self>,
     ) -> fmt::Result;
 
     /// Raise a bug.
@@ -130,9 +130,9 @@ pub trait TypeCx: Sized + fmt::Debug {
     /// The default implementation does nothing.
     fn lint_overlapping_range_endpoints(
         &self,
-        _pat: &DeconstructedPat<'_, Self>,
+        _pat: &DeconstructedPat<Self>,
         _overlaps_on: IntRange,
-        _overlaps_with: &[&DeconstructedPat<'_, Self>],
+        _overlaps_with: &[&DeconstructedPat<Self>],
     ) {
     }
 }
@@ -140,7 +140,7 @@ pub trait TypeCx: Sized + fmt::Debug {
 /// The arm of a match expression.
 #[derive(Debug)]
 pub struct MatchArm<'p, Cx: TypeCx> {
-    pub pat: &'p DeconstructedPat<'p, Cx>,
+    pub pat: &'p DeconstructedPat<Cx>,
     pub has_guard: bool,
     pub arm_data: Cx::ArmData,
 }