diff options
| author | Nadrieril <nadrieril+git@gmail.com> | 2024-02-06 03:50:22 +0100 |
|---|---|---|
| committer | Nadrieril <nadrieril+git@gmail.com> | 2024-02-28 17:47:19 +0100 |
| commit | ea381663900b90c0f78c6a64cd5e0b1876047714 (patch) | |
| tree | 4c439cc3a38a71e85c67c8f8c23b5ee2e6ab3b2e /compiler/rustc_pattern_analysis/src/pat.rs | |
| parent | 4f7f06777bf67212aa960017ced0b911ab54bbf8 (diff) | |
| download | rust-ea381663900b90c0f78c6a64cd5e0b1876047714.tar.gz rust-ea381663900b90c0f78c6a64cd5e0b1876047714.zip | |
Don't filter out skipped fields
Diffstat (limited to 'compiler/rustc_pattern_analysis/src/pat.rs')
| -rw-r--r-- | compiler/rustc_pattern_analysis/src/pat.rs | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/compiler/rustc_pattern_analysis/src/pat.rs b/compiler/rustc_pattern_analysis/src/pat.rs index 642ab74b8b9..8e1c22b92c8 100644 --- a/compiler/rustc_pattern_analysis/src/pat.rs +++ b/compiler/rustc_pattern_analysis/src/pat.rs @@ -23,11 +23,6 @@ impl PatId { /// Values and patterns can be represented as a constructor applied to some fields. This represents /// a pattern in this form. A `DeconstructedPat` will almost always come from user input; the only /// exception are some `Wildcard`s introduced during pattern lowering. -/// -/// Note that the number of fields may not match the fields declared in the original struct/variant. -/// This happens if a private or `non_exhaustive` field is uninhabited, because the code mustn't -/// observe that it is uninhabited. In that case that field is not included in `fields`. Care must -/// be taken when converting to/from `thir::Pat`. pub struct DeconstructedPat<Cx: TypeCx> { ctor: Constructor<Cx>, fields: Vec<DeconstructedPat<Cx>>, |
