remove unnecessary check

This commit is contained in:
lcnr
2022-04-29 15:55:54 +02:00
parent 209dd2cb0a
commit dc184b4e17
@@ -137,9 +137,7 @@ fn check_def_id(&mut self, item: &hir::Item<'_>, self_ty: Ty<'tcx>, def_id: DefI
return;
}
if self.tcx.features().rustc_attrs
&& self.tcx.has_attr(def_id, sym::rustc_has_incoherent_inherent_impls)
{
if self.tcx.has_attr(def_id, sym::rustc_has_incoherent_inherent_impls) {
let hir::ItemKind::Impl(hir::Impl { items, .. }) = item.kind else {
bug!("expected `impl` item: {:?}", item);
};