@@ -255,7 +255,7 @@ fn check_hash_peq<'tcx>(
255
255
"you are deriving `Hash` but have implemented `PartialEq` explicitly" ,
256
256
|diag| {
257
257
if let Some ( local_def_id) = impl_id. as_local ( ) {
258
- let hir_id = cx. tcx . hir ( ) . local_def_id_to_hir_id ( local_def_id) ;
258
+ let hir_id = cx. tcx . local_def_id_to_hir_id ( local_def_id) ;
259
259
diag. span_note ( cx. tcx . hir ( ) . span ( hir_id) , "`PartialEq` implemented here" ) ;
260
260
}
261
261
} ,
@@ -299,7 +299,7 @@ fn check_ord_partial_ord<'tcx>(
299
299
300
300
span_lint_and_then ( cx, DERIVE_ORD_XOR_PARTIAL_ORD , span, mess, |diag| {
301
301
if let Some ( local_def_id) = impl_id. as_local ( ) {
302
- let hir_id = cx. tcx . hir ( ) . local_def_id_to_hir_id ( local_def_id) ;
302
+ let hir_id = cx. tcx . local_def_id_to_hir_id ( local_def_id) ;
303
303
diag. span_note ( cx. tcx . hir ( ) . span ( hir_id) , "`PartialOrd` implemented here" ) ;
304
304
}
305
305
} ) ;
@@ -381,7 +381,7 @@ fn check_unsafe_derive_deserialize<'tcx>(
381
381
&& match_def_path ( cx, trait_def_id, & paths:: SERDE_DESERIALIZE )
382
382
&& let ty:: Adt ( def, _) = ty. kind ( )
383
383
&& let Some ( local_def_id) = def. did ( ) . as_local ( )
384
- && let adt_hir_id = cx. tcx . hir ( ) . local_def_id_to_hir_id ( local_def_id)
384
+ && let adt_hir_id = cx. tcx . local_def_id_to_hir_id ( local_def_id)
385
385
&& !is_lint_allowed ( cx, UNSAFE_DERIVE_DESERIALIZE , adt_hir_id)
386
386
&& cx
387
387
. tcx
0 commit comments