@@ -65,7 +65,7 @@ impl AssigningClones {
65
65
impl_lint_pass ! ( AssigningClones => [ ASSIGNING_CLONES ] ) ;
66
66
67
67
impl < ' tcx > LateLintPass < ' tcx > for AssigningClones {
68
- fn check_expr ( & mut self , cx : & LateContext < ' tcx > , assign_expr : & ' tcx hir :: Expr < ' _ > ) {
68
+ fn check_expr ( & mut self , cx : & LateContext < ' tcx > , assign_expr : & ' tcx Expr < ' _ > ) {
69
69
// Do not fire the lint in macros
70
70
let expn_data = assign_expr. span ( ) . ctxt ( ) . outer_expn_data ( ) ;
71
71
match expn_data. kind {
@@ -205,12 +205,7 @@ fn is_ok_to_suggest<'tcx>(cx: &LateContext<'tcx>, lhs: &Expr<'tcx>, call: &CallC
205
205
implemented_fns. contains_key ( & provided_fn. def_id )
206
206
}
207
207
208
- fn suggest < ' tcx > (
209
- cx : & LateContext < ' tcx > ,
210
- assign_expr : & hir:: Expr < ' tcx > ,
211
- lhs : & hir:: Expr < ' tcx > ,
212
- call : & CallCandidate < ' tcx > ,
213
- ) {
208
+ fn suggest < ' tcx > ( cx : & LateContext < ' tcx > , assign_expr : & Expr < ' tcx > , lhs : & Expr < ' tcx > , call : & CallCandidate < ' tcx > ) {
214
209
span_lint_and_then ( cx, ASSIGNING_CLONES , assign_expr. span , call. message ( ) , |diag| {
215
210
let mut applicability = Applicability :: MachineApplicable ;
216
211
@@ -263,7 +258,7 @@ impl<'tcx> CallCandidate<'tcx> {
263
258
fn suggested_replacement (
264
259
& self ,
265
260
cx : & LateContext < ' tcx > ,
266
- lhs : & hir :: Expr < ' tcx > ,
261
+ lhs : & Expr < ' tcx > ,
267
262
applicability : & mut Applicability ,
268
263
) -> String {
269
264
match self . target {
0 commit comments