@@ -8,11 +8,10 @@ use rustc_arena::DroplessArena;
8
8
use rustc_ast:: ast:: LitKind ;
9
9
use rustc_errors:: Applicability ;
10
10
use rustc_hir:: def_id:: DefId ;
11
- use rustc_hir:: { Arm , Expr , ExprKind , HirId , HirIdMap , HirIdSet , Pat , PatKind , RangeEnd } ;
11
+ use rustc_hir:: { Arm , Expr , ExprKind , HirId , HirIdMap , HirIdMapEntry , HirIdSet , Pat , PatKind , RangeEnd } ;
12
12
use rustc_lint:: LateContext ;
13
13
use rustc_middle:: ty;
14
14
use rustc_span:: Symbol ;
15
- use std:: collections:: hash_map:: Entry ;
16
15
17
16
use super :: MATCH_SAME_ARMS ;
18
17
@@ -71,9 +70,9 @@ pub(super) fn check<'tcx>(cx: &LateContext<'tcx>, arms: &'tcx [Arm<'_>]) {
71
70
if let Some ( a_id) = path_to_local( a) ;
72
71
if let Some ( b_id) = path_to_local( b) ;
73
72
let entry = match local_map. entry( a_id) {
74
- Entry :: Vacant ( entry) => entry,
73
+ HirIdMapEntry :: Vacant ( entry) => entry,
75
74
// check if using the same bindings as before
76
- Entry :: Occupied ( entry) => return * entry. get( ) == b_id,
75
+ HirIdMapEntry :: Occupied ( entry) => return * entry. get( ) == b_id,
77
76
} ;
78
77
// the names technically don't have to match; this makes the lint more conservative
79
78
if cx. tcx. hir( ) . name( a_id) == cx. tcx. hir( ) . name( b_id) ;
0 commit comments