diff options
Diffstat (limited to '')
-rw-r--r-- | compiler/rustc_passes/src/liveness.rs | 8 | ||||
-rw-r--r-- | compiler/rustc_passes/src/liveness/rwu_table.rs | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/compiler/rustc_passes/src/liveness.rs b/compiler/rustc_passes/src/liveness.rs index 6afdcc37f..df5c8f53e 100644 --- a/compiler/rustc_passes/src/liveness.rs +++ b/compiler/rustc_passes/src/liveness.rs @@ -145,7 +145,7 @@ fn check_liveness(tcx: TyCtxt<'_>, def_id: DefId) { // Don't run unused pass for #[derive()] let parent = tcx.local_parent(local_def_id); - if let DefKind::Impl = tcx.def_kind(parent) + if let DefKind::Impl { .. } = tcx.def_kind(parent) && tcx.has_attr(parent.to_def_id(), sym::automatically_derived) { return; @@ -475,7 +475,7 @@ impl<'tcx> Visitor<'tcx> for IrMaps<'tcx> { | hir::ExprKind::InlineAsm(..) | hir::ExprKind::Box(..) | hir::ExprKind::Type(..) - | hir::ExprKind::Err + | hir::ExprKind::Err(_) | hir::ExprKind::Path(hir::QPath::TypeRelative(..)) | hir::ExprKind::Path(hir::QPath::LangItem(..)) => { intravisit::walk_expr(self, expr); @@ -1129,7 +1129,7 @@ impl<'a, 'tcx> Liveness<'a, 'tcx> { hir::ExprKind::Lit(..) | hir::ExprKind::ConstBlock(..) - | hir::ExprKind::Err + | hir::ExprKind::Err(_) | hir::ExprKind::Path(hir::QPath::TypeRelative(..)) | hir::ExprKind::Path(hir::QPath::LangItem(..)) => succ, @@ -1427,7 +1427,7 @@ fn check_expr<'tcx>(this: &mut Liveness<'_, 'tcx>, expr: &'tcx Expr<'tcx>) { | hir::ExprKind::Yield(..) | hir::ExprKind::Box(..) | hir::ExprKind::Type(..) - | hir::ExprKind::Err => {} + | hir::ExprKind::Err(_) => {} } } diff --git a/compiler/rustc_passes/src/liveness/rwu_table.rs b/compiler/rustc_passes/src/liveness/rwu_table.rs index 6d5983f53..053bf5c23 100644 --- a/compiler/rustc_passes/src/liveness/rwu_table.rs +++ b/compiler/rustc_passes/src/liveness/rwu_table.rs @@ -9,7 +9,7 @@ pub(super) struct RWU { } /// Conceptually, this is like a `Vec<Vec<RWU>>`. But the number of -/// RWU`s can get very large, so it uses a more compact representation. +/// RWU's can get very large, so it uses a more compact representation. pub(super) struct RWUTable { /// Total number of live nodes. live_nodes: usize, |