fn func_takes_arg_by_double_ref(&self, parent_expr: &'tcx hir::Expr<'_>, cmt_hir_id: HirId) -> bool {
        let (call_args, inputs) = match parent_expr.kind {
            ExprKind::MethodCall(_, _, call_args, _) => {
                if let Some(method_did) = self.cx.typeck_results().type_dependent_def_id(parent_expr.hir_id) {
                    (call_args, self.cx.tcx.fn_sig(method_did).skip_binder().inputs())
                } else {
                    return false;
                }
            },
            ExprKind::Call(func, call_args) => {
                let typ = self.cx.typeck_results().expr_ty(func);
                (call_args, typ.fn_sig(self.cx.tcx).skip_binder().inputs())
            },
            _ => return false,
        };

        iter::zip(call_args, inputs)
            .any(|(arg, ty)| arg.hir_id == cmt_hir_id && matches!(ty.kind(), ty::Ref(_, inner, _) if inner.is_ref()))
    }
/// indicates whether the function from `parent_expr` takes its args by double reference
indicates whether the function from `parent_expr` takes its args by double reference
indicates whether the function from ` parent_expr ` takes its args by double reference
fn func_takes_arg_by_double_ref(&self, parent_expr: &'tcx hir::Expr<'_>, cmt_hir_id: HirId) -> bool {
        let (call_args, inputs) = match parent_expr.kind {
            ExprKind::MethodCall(_, _, call_args, _) => {
                if let Some(method_did) = self.cx.typeck_results().type_dependent_def_id(parent_expr.hir_id) {
                    (call_args, self.cx.tcx.fn_sig(method_did).skip_binder().inputs())
                } else {
                    return false;
                }
            },
            ExprKind::Call(func, call_args) => {
                let typ = self.cx.typeck_results().expr_ty(func);
                (call_args, typ.fn_sig(self.cx.tcx).skip_binder().inputs())
            },
            _ => return false,
        };
        iter::zip(call_args, inputs)
            .any(|(arg, ty)| arg.hir_id == cmt_hir_id && matches!(ty.kind(), ty::Ref(_, inner, _) if inner.is_ref()))
    }
fn func_takes_arg_by_double_ref ( & self , parent_expr : & ' tcx hir :: Expr < ' _ > , cmt_hir_id : HirId ) -> bool { let ( call_args , inputs ) = match parent_expr . kind { ExprKind :: MethodCall ( _ , _ , call_args , _ ) => { if let Some ( method_did ) = self . cx . typeck_results ( ) . type_dependent_def_id ( parent_expr . hir_id ) { ( call_args , self . cx . tcx . fn_sig ( method_did ) . skip_binder ( ) . inputs ( ) ) } else { return false ; } } , ExprKind :: Call ( func , call_args ) => { let typ = self . cx . typeck_results ( ) . expr_ty ( func ) ; ( call_args , typ . fn_sig ( self . cx . tcx ) . skip_binder ( ) . inputs ( ) ) } , _ => return false , } ; iter :: zip ( call_args , inputs ) . any ( | ( arg , ty ) | arg . hir_id == cmt_hir_id && matches ! ( ty kind ( ) ty Ref ( inner ) if inner is_ref ( ) ) ) }
indicates whether the function from `parent_expr` takes its args by double reference
indicates whether the function from ` parent_expr ` takes its args by double reference
&self
parent_expr
&'tcx hir::Expr<'_>
cmt_hir_id
HirId