@@ -384,7 +384,7 @@ impl<'hir> Map<'hir> {
384
384
DefKind :: Ctor ( ctor_of, def:: CtorKind :: from_hir ( variant_data) )
385
385
}
386
386
Node :: AnonConst ( _) |
387
- Node :: Field ( _) |
387
+ Node :: StructField ( _) |
388
388
Node :: Expr ( _) |
389
389
Node :: Stmt ( _) |
390
390
Node :: PathSegment ( _) |
@@ -990,7 +990,7 @@ impl<'hir> Map<'hir> {
990
990
Node :: ImplItem ( ii) => ii. ident . name ,
991
991
Node :: TraitItem ( ti) => ti. ident . name ,
992
992
Node :: Variant ( v) => v. ident . name ,
993
- Node :: Field ( f) => f. ident . name ,
993
+ Node :: StructField ( f) => f. ident . name ,
994
994
Node :: Lifetime ( lt) => lt. name . ident ( ) . name ,
995
995
Node :: GenericParam ( param) => param. name . ident ( ) . name ,
996
996
Node :: Binding ( & Pat { kind : PatKind :: Binding ( _, _, l, _) , .. } ) => l. name ,
@@ -1011,7 +1011,7 @@ impl<'hir> Map<'hir> {
1011
1011
Some ( Node :: TraitItem ( ref ti) ) => Some ( & ti. attrs [ ..] ) ,
1012
1012
Some ( Node :: ImplItem ( ref ii) ) => Some ( & ii. attrs [ ..] ) ,
1013
1013
Some ( Node :: Variant ( ref v) ) => Some ( & v. attrs [ ..] ) ,
1014
- Some ( Node :: Field ( ref f) ) => Some ( & f. attrs [ ..] ) ,
1014
+ Some ( Node :: StructField ( ref f) ) => Some ( & f. attrs [ ..] ) ,
1015
1015
Some ( Node :: Expr ( ref e) ) => Some ( & * e. attrs ) ,
1016
1016
Some ( Node :: Stmt ( ref s) ) => Some ( s. kind . attrs ( ) ) ,
1017
1017
Some ( Node :: Arm ( ref a) ) => Some ( & * a. attrs ) ,
@@ -1072,7 +1072,7 @@ impl<'hir> Map<'hir> {
1072
1072
Some ( Node :: TraitItem ( trait_method) ) => trait_method. span ,
1073
1073
Some ( Node :: ImplItem ( impl_item) ) => impl_item. span ,
1074
1074
Some ( Node :: Variant ( variant) ) => variant. span ,
1075
- Some ( Node :: Field ( field) ) => field. span ,
1075
+ Some ( Node :: StructField ( field) ) => field. span ,
1076
1076
Some ( Node :: AnonConst ( constant) ) => self . body ( constant. body ) . value . span ,
1077
1077
Some ( Node :: Expr ( expr) ) => expr. span ,
1078
1078
Some ( Node :: Stmt ( stmt) ) => stmt. span ,
@@ -1195,7 +1195,7 @@ impl<'a> NodesMatchingSuffix<'a> {
1195
1195
Some ( Node :: TraitItem ( n) ) => n. name ( ) ,
1196
1196
Some ( Node :: ImplItem ( n) ) => n. name ( ) ,
1197
1197
Some ( Node :: Variant ( n) ) => n. name ( ) ,
1198
- Some ( Node :: Field ( n) ) => n. name ( ) ,
1198
+ Some ( Node :: StructField ( n) ) => n. name ( ) ,
1199
1199
_ => return false ,
1200
1200
} ;
1201
1201
self . matches_names ( self . map . get_parent_item ( hir) , name)
@@ -1304,7 +1304,7 @@ impl<'a> print::State<'a> {
1304
1304
Node :: Lifetime ( a) => self . print_lifetime ( & a) ,
1305
1305
Node :: Visibility ( a) => self . print_visibility ( & a) ,
1306
1306
Node :: GenericParam ( _) => bug ! ( "cannot print Node::GenericParam" ) ,
1307
- Node :: Field ( _) => bug ! ( "cannot print StructField" ) ,
1307
+ Node :: StructField ( _) => bug ! ( "cannot print StructField" ) ,
1308
1308
// These cases do not carry enough information in the
1309
1309
// `hir_map` to reconstruct their full structure for pretty
1310
1310
// printing.
@@ -1392,8 +1392,8 @@ fn hir_id_to_string(map: &Map<'_>, id: HirId, include_id: bool) -> String {
1392
1392
variant. ident,
1393
1393
path_str( ) , id_str)
1394
1394
}
1395
- Some ( Node :: Field ( ref field) ) => {
1396
- format ! ( "field {} in {}{}" ,
1395
+ Some ( Node :: StructField ( ref field) ) => {
1396
+ format ! ( "struct field {} in {}{}" ,
1397
1397
field. ident,
1398
1398
path_str( ) , id_str)
1399
1399
}
0 commit comments