Skip to content

Commit

Permalink
typo
Browse files Browse the repository at this point in the history
  • Loading branch information
Nadrieril committed May 17, 2020
1 parent 079400c commit 4f7a378
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/librustc_mir_build/hair/pattern/_match.rs
Expand Up @@ -963,11 +963,12 @@ impl<'p, 'tcx> FilteredField<'p, 'tcx> {
///
/// If a private or `non_exhaustive` field is uninhabited, the code mustn't observe that it is
/// uninhabited. For that, we filter these fields out of the matrix. This is subtle because we
/// still need to have those fields back when going to/from a `Pat`. Mot of this is handled
/// automatically in `Fields`, but when constructing or deconstructing fields you need to use the
/// correct method. As a rule, when going to/from the matrix, use the filtered field list; when
/// going to/from `Pat`, use the full field list.
/// This filtering is uncommon in practice, because uninhabited fields are rarely used.
/// still need to have those fields back when going to/from a `Pat`. Most of this is handled
/// automatically in `Fields`, but when constructing or deconstructing `Fields` you need to be
/// careful. As a rule, when going to/from the matrix, use the filtered field list; when going
/// to/from `Pat`, use the full field list.
/// This filtering is uncommon in practice, because uninhabited fields are rarely used, so we avoid
/// it when possible to preserve performance.
#[derive(Debug, Clone)]
enum Fields<'p, 'tcx> {
/// Lists of patterns that don't contain any filtered fields.
Expand Down

0 comments on commit 4f7a378

Please sign in to comment.