pub(super) fn expr_in_place(&self, mut expr_id: hir::HirId) -> bool {
        let mut contained_in_place = false;

        while let hir::Node::Expr(parent_expr) =
            self.tcx.hir().get(self.tcx.hir().get_parent_node(expr_id))
        {
            match &parent_expr.kind {
                hir::ExprKind::Assign(lhs, ..) | hir::ExprKind::AssignOp(_, lhs, ..) => {
                    if lhs.hir_id == expr_id {
                        contained_in_place = true;
                        break;
                    }
                }
                _ => (),
            }
            expr_id = parent_expr.hir_id;
        }

        contained_in_place
    }
/// Returns `true` if an expression is contained inside the LHS of an assignment expression.
Returns `true` if an expression is contained inside the LHS of an assignment expression.
Returns ` true ` if an expression is contained inside the LHS of an assignment expression .
pub(super) fn expr_in_place(&self, mut expr_id: hir::HirId) -> bool {
        let mut contained_in_place = false;
        while let hir::Node::Expr(parent_expr) =
            self.tcx.hir().get(self.tcx.hir().get_parent_node(expr_id))
        {
            match &parent_expr.kind {
                hir::ExprKind::Assign(lhs, ..) | hir::ExprKind::AssignOp(_, lhs, ..) => {
                    if lhs.hir_id == expr_id {
                        contained_in_place = true;
                        break;
                    }
                }
                _ => (),
            }
            expr_id = parent_expr.hir_id;
        }
        contained_in_place
    }
pub ( super ) fn expr_in_place ( & self , mut expr_id : hir :: HirId ) -> bool { let mut contained_in_place = false ; while let hir :: Node :: Expr ( parent_expr ) = self . tcx . hir ( ) . get ( self . tcx . hir ( ) . get_parent_node ( expr_id ) ) { match & parent_expr . kind { hir :: ExprKind :: Assign ( lhs , .. ) | hir :: ExprKind :: AssignOp ( _ , lhs , .. ) => { if lhs . hir_id == expr_id { contained_in_place = true ; break ; } } _ => ( ) , } expr_id = parent_expr . hir_id ; } contained_in_place }
Returns `true` if an expression is contained inside the LHS of an assignment expression.
Returns ` true ` if an expression is contained inside the LHS of an assignment expression .
&self
expr_id
hir::HirId
&self
expr_id
hir::HirId