Use let else here
This commit is contained in:
parent
9c076f3f90
commit
ba8b4a4f82
@ -387,7 +387,10 @@ fn resolve_negative_obligation<'cx, 'tcx>(
|
||||
) -> bool {
|
||||
let tcx = infcx.tcx;
|
||||
|
||||
if let Some(o) = o.flip_polarity(tcx) {
|
||||
let Some(o) = o.flip_polarity(tcx) else {
|
||||
return false;
|
||||
};
|
||||
|
||||
let mut fulfillment_cx = FulfillmentContext::new();
|
||||
fulfillment_cx.register_predicate_obligation(infcx, o);
|
||||
|
||||
@ -419,10 +422,7 @@ fn resolve_negative_obligation<'cx, 'tcx>(
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
false
|
||||
true
|
||||
}
|
||||
|
||||
pub fn trait_ref_is_knowable<'tcx>(
|
||||
|
Loading…
Reference in New Issue
Block a user