@@ -56,7 +56,7 @@ impl<'hir> Entry<'hir> {
56
56
} ,
57
57
58
58
Node :: ImplItem ( ref item) => match item. kind {
59
- ImplItemKind :: Method ( ref sig, _) => Some ( & sig. decl ) ,
59
+ ImplItemKind :: Fn ( ref sig, _) => Some ( & sig. decl ) ,
60
60
_ => None ,
61
61
} ,
62
62
@@ -82,7 +82,7 @@ impl<'hir> Entry<'hir> {
82
82
} ,
83
83
84
84
Node :: ImplItem ( item) => match & item. kind {
85
- ImplItemKind :: Method ( sig, _) => Some ( sig) ,
85
+ ImplItemKind :: Fn ( sig, _) => Some ( sig) ,
86
86
_ => None ,
87
87
} ,
88
88
@@ -101,12 +101,12 @@ impl<'hir> Entry<'hir> {
101
101
102
102
Node :: TraitItem ( item) => match item. kind {
103
103
TraitItemKind :: Const ( _, Some ( body) )
104
- | TraitItemKind :: Fn ( _, TraitMethod :: Provided ( body) ) => Some ( body) ,
104
+ | TraitItemKind :: Fn ( _, TraitFn :: Provided ( body) ) => Some ( body) ,
105
105
_ => None ,
106
106
} ,
107
107
108
108
Node :: ImplItem ( item) => match item. kind {
109
- ImplItemKind :: Const ( _, body) | ImplItemKind :: Method ( _, body) => Some ( body) ,
109
+ ImplItemKind :: Const ( _, body) | ImplItemKind :: Fn ( _, body) => Some ( body) ,
110
110
_ => None ,
111
111
} ,
112
112
@@ -331,7 +331,7 @@ impl<'hir> Map<'hir> {
331
331
} ,
332
332
Node :: ImplItem ( item) => match item. kind {
333
333
ImplItemKind :: Const ( ..) => DefKind :: AssocConst ,
334
- ImplItemKind :: Method ( ..) => DefKind :: AssocFn ,
334
+ ImplItemKind :: Fn ( ..) => DefKind :: AssocFn ,
335
335
ImplItemKind :: TyAlias ( ..) => DefKind :: AssocTy ,
336
336
ImplItemKind :: OpaqueTy ( ..) => DefKind :: AssocOpaqueTy ,
337
337
} ,
@@ -473,7 +473,7 @@ impl<'hir> Map<'hir> {
473
473
Node :: Ctor ( ..)
474
474
| Node :: Item ( & Item { kind : ItemKind :: Fn ( ..) , .. } )
475
475
| Node :: TraitItem ( & TraitItem { kind : TraitItemKind :: Fn ( ..) , .. } )
476
- | Node :: ImplItem ( & ImplItem { kind : ImplItemKind :: Method ( ..) , .. } ) => BodyOwnerKind :: Fn ,
476
+ | Node :: ImplItem ( & ImplItem { kind : ImplItemKind :: Fn ( ..) , .. } ) => BodyOwnerKind :: Fn ,
477
477
Node :: Item ( & Item { kind : ItemKind :: Static ( _, m, _) , .. } ) => BodyOwnerKind :: Static ( m) ,
478
478
Node :: Expr ( & Expr { kind : ExprKind :: Closure ( ..) , .. } ) => BodyOwnerKind :: Closure ,
479
479
node => bug ! ( "{:#?} is not a body node" , node) ,
@@ -804,7 +804,7 @@ impl<'hir> Map<'hir> {
804
804
_ => false ,
805
805
} ,
806
806
Node :: ImplItem ( ii) => match ii. kind {
807
- ImplItemKind :: Method ( ..) => true ,
807
+ ImplItemKind :: Fn ( ..) => true ,
808
808
_ => false ,
809
809
} ,
810
810
Node :: Block ( _) => true ,
@@ -1300,7 +1300,7 @@ fn hir_id_to_string(map: &Map<'_>, id: HirId, include_id: bool) -> String {
1300
1300
ImplItemKind :: Const ( ..) => {
1301
1301
format ! ( "assoc const {} in {}{}" , ii. ident, path_str( ) , id_str)
1302
1302
}
1303
- ImplItemKind :: Method ( ..) => format ! ( "method {} in {}{}" , ii. ident, path_str( ) , id_str) ,
1303
+ ImplItemKind :: Fn ( ..) => format ! ( "method {} in {}{}" , ii. ident, path_str( ) , id_str) ,
1304
1304
ImplItemKind :: TyAlias ( _) => {
1305
1305
format ! ( "assoc type {} in {}{}" , ii. ident, path_str( ) , id_str)
1306
1306
}
0 commit comments