Skip to content

Commit d4914a7

Browse files
committed
replace one .map_or(true, ...) with .is_none_or(...)
1 parent 942db67 commit d4914a7

File tree

1 file changed

+1
-1
lines changed
  • compiler/rustc_next_trait_solver/src/solve/eval_ctxt

1 file changed

+1
-1
lines changed

Diff for: compiler/rustc_next_trait_solver/src/solve/eval_ctxt/canonical.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ where
142142
// Remove any trivial region constraints once we've resolved regions
143143
external_constraints
144144
.region_constraints
145-
.retain(|outlives| outlives.0.as_region().map_or(true, |re| re != outlives.1));
145+
.retain(|outlives| outlives.0.as_region().is_none_or(|re| re != outlives.1));
146146

147147
let canonical = Canonicalizer::canonicalize_response(
148148
self.delegate,

0 commit comments

Comments
 (0)