From 557226348f9b5cc06931faf6c510114e2ccea55b Mon Sep 17 00:00:00 2001 From: Daniel del Castillo <52696601+CastilloDel@users.noreply.github.com> Date: Tue, 15 Nov 2022 00:50:16 +0100 Subject: [PATCH] Update compiler/rustc_ast_lowering/src/item.rs Co-authored-by: Camille Gillot --- compiler/rustc_ast_lowering/src/item.rs | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/compiler/rustc_ast_lowering/src/item.rs b/compiler/rustc_ast_lowering/src/item.rs index e43bec300bda9..ad865a6a0f2e7 100644 --- a/compiler/rustc_ast_lowering/src/item.rs +++ b/compiler/rustc_ast_lowering/src/item.rs @@ -94,13 +94,7 @@ impl<'a, 'hir> ItemLowerer<'a, 'hir> { for (def_id, info) in lctx.children { self.owners.ensure_contains_elem(def_id, || hir::MaybeOwner::Phantom); debug_assert!(matches!(self.owners[def_id], hir::MaybeOwner::Phantom)); - match (self.owners[def_id], info) { - (hir::MaybeOwner::Phantom, _) - | (hir::MaybeOwner::NonOwner(_), hir::MaybeOwner::Owner(_)) => { - self.owners[def_id] = info; - } - _ => unreachable!(), - } + self.owners[def_id] = info; } }