@@ -15,7 +15,7 @@ use hir as ast;
15
15
use hir:: map;
16
16
use hir:: { Expr , FnDecl , Node } ;
17
17
use hir:: intravisit:: FnKind ;
18
- use syntax:: ast:: { Attribute , Ident , Name , NodeId } ;
18
+ use syntax:: ast:: { Attribute , Ident , NodeId } ;
19
19
use syntax_pos:: Span ;
20
20
21
21
/// An FnLikeNode is a Node that is like a fn, in that it has a decl
@@ -98,7 +98,7 @@ impl<'a> Code<'a> {
98
98
/// These are all the components one can extract from a fn item for
99
99
/// use when implementing FnLikeNode operations.
100
100
struct ItemFnParts < ' a > {
101
- name : Name ,
101
+ ident : Ident ,
102
102
decl : & ' a ast:: FnDecl ,
103
103
header : ast:: FnHeader ,
104
104
vis : & ' a ast:: Visibility ,
@@ -200,7 +200,7 @@ impl<'a> FnLikeNode<'a> {
200
200
201
201
pub fn kind ( self ) -> FnKind < ' a > {
202
202
let item = |p : ItemFnParts < ' a > | -> FnKind < ' a > {
203
- FnKind :: ItemFn ( p. name , p. generics , p. header , p. vis , p. attrs )
203
+ FnKind :: ItemFn ( p. ident , p. generics , p. header , p. vis , p. attrs )
204
204
} ;
205
205
let closure = |c : ClosureParts < ' a > | {
206
206
FnKind :: Closure ( c. attrs )
@@ -228,7 +228,7 @@ impl<'a> FnLikeNode<'a> {
228
228
ast:: ItemKind :: Fn ( ref decl, header, ref generics, block) =>
229
229
item_fn ( ItemFnParts {
230
230
id : i. id ,
231
- name : i. ident . name ,
231
+ ident : i. ident ,
232
232
decl : & decl,
233
233
body : block,
234
234
vis : & i. vis ,
0 commit comments