Dont stop find loop node at struct field node

This commit is contained in:
Lzu Tao 2024-07-15 15:56:17 +00:00
parent 4264548283
commit dcee2e8a0f
4 changed files with 14 additions and 12 deletions

View file

@ -1407,7 +1407,7 @@ pub fn get_enclosing_loop_or_multi_call_closure<'tcx>(
ExprKind::Closure { .. } | ExprKind::Loop(..) => return Some(e),
_ => (),
},
Node::Stmt(_) | Node::Block(_) | Node::LetStmt(_) | Node::Arm(_) => (),
Node::Stmt(_) | Node::Block(_) | Node::LetStmt(_) | Node::Arm(_) | Node::ExprField(_) => (),
_ => break,
}
}