Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-ty/src/inhabitedness.rs')
| -rw-r--r-- | crates/hir-ty/src/inhabitedness.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/hir-ty/src/inhabitedness.rs b/crates/hir-ty/src/inhabitedness.rs index 56b549436c..d6039c548b 100644 --- a/crates/hir-ty/src/inhabitedness.rs +++ b/crates/hir-ty/src/inhabitedness.rs @@ -139,7 +139,7 @@ impl UninhabitedFrom<'_> { ty: &Binders<Ty>, subst: &Substitution, ) -> ControlFlow<VisiblyUninhabited> { - if vis.map_or(true, |it| it.is_visible_from(self.db.upcast(), self.target_mod)) { + if vis.is_none_or(|it| it.is_visible_from(self.db.upcast(), self.target_mod)) { let ty = ty.clone().substitute(Interner, subst); ty.visit_with(self, DebruijnIndex::INNERMOST) } else { |