@@ -61,10 +61,10 @@ use rustc_hir::def::{CtorKind, CtorOf, DefKind, Res};
61
61
use rustc_hir:: def_id:: { DefId , LOCAL_CRATE } ;
62
62
use rustc_hir:: intravisit:: { self , NestedVisitorMap , Visitor } ;
63
63
use rustc_hir:: {
64
- def, Arm , BindingAnnotation , Block , Body , Constness , CrateItem , Expr , ExprKind , FieldDef , FnDecl , ForeignItem ,
65
- GenericArgs , GenericParam , HirId , Impl , ImplItem , ImplItemKind , Item , ItemKind , LangItem , Lifetime , Local ,
66
- MacroDef , MatchSource , Node , Param , Pat , PatKind , Path , PathSegment , QPath , Stmt , TraitItem , TraitItemKind ,
67
- TraitRef , TyKind , Variant , Visibility ,
64
+ def, Arm , BindingAnnotation , Block , Body , Constness , Expr , ExprKind , FieldDef , FnDecl , ForeignItem , GenericArgs ,
65
+ GenericParam , HirId , Impl , ImplItem , ImplItemKind , Item , ItemKind , LangItem , Lifetime , Local , MacroDef ,
66
+ MatchSource , Mod , Node , Param , Pat , PatKind , Path , PathSegment , QPath , Stmt , TraitItem , TraitItemKind , TraitRef ,
67
+ TyKind , Variant , Visibility ,
68
68
} ;
69
69
use rustc_lint:: { LateContext , Level , Lint , LintContext } ;
70
70
use rustc_middle:: hir:: exports:: Export ;
@@ -743,7 +743,7 @@ pub fn get_node_span(node: Node<'_>) -> Option<Span> {
743
743
| Node :: Lifetime ( Lifetime { span, .. } )
744
744
| Node :: GenericParam ( GenericParam { span, .. } )
745
745
| Node :: Visibility ( Visibility { span, .. } )
746
- | Node :: Crate ( CrateItem { span, .. } ) => Some ( * span) ,
746
+ | Node :: Crate ( Mod { inner : span, .. } ) => Some ( * span) ,
747
747
Node :: Ctor ( _) | Node :: AnonConst ( _) => None ,
748
748
}
749
749
}
0 commit comments