@@ -353,10 +353,10 @@ pub trait Visitor<'v> : Sized {
353353 fn visit_lifetime ( & mut self , lifetime : & ' v Lifetime ) {
354354 walk_lifetime ( self , lifetime)
355355 }
356- fn visit_qpath ( & mut self , qpath : & ' v QPath , id : NodeId , span : Span ) {
356+ fn visit_qpath ( & mut self , qpath : & ' v QPath , id : HirId , span : Span ) {
357357 walk_qpath ( self , qpath, id, span)
358358 }
359- fn visit_path ( & mut self , path : & ' v Path , _id : NodeId ) {
359+ fn visit_path ( & mut self , path : & ' v Path , _id : HirId ) {
360360 walk_path ( self , path)
361361 }
362362 fn visit_path_segment ( & mut self , path_span : Span , path_segment : & ' v PathSegment ) {
@@ -456,7 +456,7 @@ pub fn walk_trait_ref<'v, V>(visitor: &mut V, trait_ref: &'v TraitRef)
456456 where V : Visitor < ' v >
457457{
458458 visitor. visit_id ( trait_ref. ref_id ) ;
459- visitor. visit_path ( & trait_ref. path , trait_ref. ref_id )
459+ visitor. visit_path ( & trait_ref. path , trait_ref. hir_ref_id )
460460}
461461
462462pub fn walk_item < ' v , V : Visitor < ' v > > ( visitor : & mut V , item : & ' v Item ) {
@@ -471,7 +471,7 @@ pub fn walk_item<'v, V: Visitor<'v>>(visitor: &mut V, item: &'v Item) {
471471 }
472472 ItemKind :: Use ( ref path, _) => {
473473 visitor. visit_id ( item. id ) ;
474- visitor. visit_path ( path, item. id ) ;
474+ visitor. visit_path ( path, item. hir_id ) ;
475475 }
476476 ItemKind :: Static ( ref typ, _, body) |
477477 ItemKind :: Const ( ref typ, body) => {
@@ -602,7 +602,7 @@ pub fn walk_ty<'v, V: Visitor<'v>>(visitor: &mut V, typ: &'v Ty) {
602602 visitor. visit_fn_decl ( & function_declaration. decl ) ;
603603 }
604604 TyKind :: Path ( ref qpath) => {
605- visitor. visit_qpath ( qpath, typ. id , typ. span ) ;
605+ visitor. visit_qpath ( qpath, typ. hir_id , typ. span ) ;
606606 }
607607 TyKind :: Array ( ref ty, ref length) => {
608608 visitor. visit_ty ( ty) ;
@@ -621,7 +621,7 @@ pub fn walk_ty<'v, V: Visitor<'v>>(visitor: &mut V, typ: &'v Ty) {
621621 }
622622}
623623
624- pub fn walk_qpath < ' v , V : Visitor < ' v > > ( visitor : & mut V , qpath : & ' v QPath , id : NodeId , span : Span ) {
624+ pub fn walk_qpath < ' v , V : Visitor < ' v > > ( visitor : & mut V , qpath : & ' v QPath , id : HirId , span : Span ) {
625625 match * qpath {
626626 QPath :: Resolved ( ref maybe_qself, ref path) => {
627627 if let Some ( ref qself) = * maybe_qself {
@@ -670,14 +670,14 @@ pub fn walk_pat<'v, V: Visitor<'v>>(visitor: &mut V, pattern: &'v Pat) {
670670 visitor. visit_id ( pattern. id ) ;
671671 match pattern. node {
672672 PatKind :: TupleStruct ( ref qpath, ref children, _) => {
673- visitor. visit_qpath ( qpath, pattern. id , pattern. span ) ;
673+ visitor. visit_qpath ( qpath, pattern. hir_id , pattern. span ) ;
674674 walk_list ! ( visitor, visit_pat, children) ;
675675 }
676676 PatKind :: Path ( ref qpath) => {
677- visitor. visit_qpath ( qpath, pattern. id , pattern. span ) ;
677+ visitor. visit_qpath ( qpath, pattern. hir_id , pattern. span ) ;
678678 }
679679 PatKind :: Struct ( ref qpath, ref fields, _) => {
680- visitor. visit_qpath ( qpath, pattern. id , pattern. span ) ;
680+ visitor. visit_qpath ( qpath, pattern. hir_id , pattern. span ) ;
681681 for field in fields {
682682 visitor. visit_id ( field. node . id ) ;
683683 visitor. visit_ident ( field. node . ident ) ;
@@ -985,7 +985,7 @@ pub fn walk_expr<'v, V: Visitor<'v>>(visitor: &mut V, expression: &'v Expr) {
985985 visitor. visit_anon_const ( count)
986986 }
987987 ExprKind :: Struct ( ref qpath, ref fields, ref optional_base) => {
988- visitor. visit_qpath ( qpath, expression. id , expression. span ) ;
988+ visitor. visit_qpath ( qpath, expression. hir_id , expression. span ) ;
989989 for field in fields {
990990 visitor. visit_id ( field. id ) ;
991991 visitor. visit_ident ( field. ident ) ;
@@ -1062,7 +1062,7 @@ pub fn walk_expr<'v, V: Visitor<'v>>(visitor: &mut V, expression: &'v Expr) {
10621062 visitor. visit_expr ( index_expression)
10631063 }
10641064 ExprKind :: Path ( ref qpath) => {
1065- visitor. visit_qpath ( qpath, expression. id , expression. span ) ;
1065+ visitor. visit_qpath ( qpath, expression. hir_id , expression. span ) ;
10661066 }
10671067 ExprKind :: Break ( ref destination, ref opt_expr) => {
10681068 if let Some ( ref label) = destination. label {
@@ -1108,9 +1108,9 @@ pub fn walk_arm<'v, V: Visitor<'v>>(visitor: &mut V, arm: &'v Arm) {
11081108}
11091109
11101110pub fn walk_vis < ' v , V : Visitor < ' v > > ( visitor : & mut V , vis : & ' v Visibility ) {
1111- if let VisibilityKind :: Restricted { ref path, id } = vis. node {
1111+ if let VisibilityKind :: Restricted { ref path, id, hir_id } = vis. node {
11121112 visitor. visit_id ( id) ;
1113- visitor. visit_path ( path, id )
1113+ visitor. visit_path ( path, hir_id )
11141114 }
11151115}
11161116
0 commit comments