Rollup merge of #113084 - WaffleLapkin:less_map_or, r=Nilstrieb
Simplify some conditions r? `@Nilstrieb` Some things taken out of my `is_none_or` pr.
This commit is contained in:
commit
d505582ce2
11 changed files with 35 additions and 45 deletions
|
@ -140,7 +140,7 @@ impl<'tcx> InherentOverlapChecker<'tcx> {
|
|||
impl1_def_id: DefId,
|
||||
impl2_def_id: DefId,
|
||||
) {
|
||||
traits::overlapping_impls(
|
||||
let maybe_overlap = traits::overlapping_impls(
|
||||
self.tcx,
|
||||
impl1_def_id,
|
||||
impl2_def_id,
|
||||
|
@ -148,11 +148,11 @@ impl<'tcx> InherentOverlapChecker<'tcx> {
|
|||
// inherent impls without warning.
|
||||
SkipLeakCheck::Yes,
|
||||
overlap_mode,
|
||||
)
|
||||
.map_or(true, |overlap| {
|
||||
);
|
||||
|
||||
if let Some(overlap) = maybe_overlap {
|
||||
self.check_for_common_items_in_impls(impl1_def_id, impl2_def_id, overlap);
|
||||
false
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
fn check_item(&mut self, id: hir::ItemId) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue