mirror of
https://github.com/rust-lang/rust.git
synced 2025-02-09 21:42:44 +00:00
Use let else here
This commit is contained in:
parent
9c076f3f90
commit
ba8b4a4f82
@ -387,7 +387,10 @@ fn resolve_negative_obligation<'cx, 'tcx>(
|
|||||||
) -> bool {
|
) -> bool {
|
||||||
let tcx = infcx.tcx;
|
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();
|
let mut fulfillment_cx = FulfillmentContext::new();
|
||||||
fulfillment_cx.register_predicate_obligation(infcx, o);
|
fulfillment_cx.register_predicate_obligation(infcx, o);
|
||||||
|
|
||||||
@ -419,10 +422,7 @@ fn resolve_negative_obligation<'cx, 'tcx>(
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
true
|
||||||
}
|
|
||||||
|
|
||||||
false
|
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn trait_ref_is_knowable<'tcx>(
|
pub fn trait_ref_is_knowable<'tcx>(
|
||||||
|
Loading…
Reference in New Issue
Block a user