Adopt let_else in even more places
This commit is contained in:
parent
3cfa4def7c
commit
60f969a4f2
26 changed files with 50 additions and 104 deletions
|
@ -1241,9 +1241,7 @@ impl<'tcx> MirPass<'tcx> for StateTransform {
|
|||
}
|
||||
|
||||
fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
|
||||
let yield_ty = if let Some(yield_ty) = body.yield_ty() {
|
||||
yield_ty
|
||||
} else {
|
||||
let Some(yield_ty) = body.yield_ty() else {
|
||||
// This only applies to generators
|
||||
return;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue