@@ -15,7 +15,7 @@ use hir as ast;
1515use hir:: map;
1616use hir:: { Expr , FnDecl , Node } ;
1717use hir:: intravisit:: FnKind ;
18- use syntax:: ast:: { Attribute , Ident , Name , NodeId } ;
18+ use syntax:: ast:: { Attribute , Ident , NodeId } ;
1919use syntax_pos:: Span ;
2020
2121/// An FnLikeNode is a Node that is like a fn, in that it has a decl
@@ -98,7 +98,7 @@ impl<'a> Code<'a> {
9898/// These are all the components one can extract from a fn item for
9999/// use when implementing FnLikeNode operations.
100100struct ItemFnParts < ' a > {
101- name : Name ,
101+ ident : Ident ,
102102 decl : & ' a ast:: FnDecl ,
103103 header : ast:: FnHeader ,
104104 vis : & ' a ast:: Visibility ,
@@ -200,7 +200,7 @@ impl<'a> FnLikeNode<'a> {
200200
201201 pub fn kind ( self ) -> FnKind < ' a > {
202202 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 )
204204 } ;
205205 let closure = |c : ClosureParts < ' a > | {
206206 FnKind :: Closure ( c. attrs )
@@ -228,7 +228,7 @@ impl<'a> FnLikeNode<'a> {
228228 ast:: ItemKind :: Fn ( ref decl, header, ref generics, block) =>
229229 item_fn ( ItemFnParts {
230230 id : i. id ,
231- name : i. ident . name ,
231+ ident : i. ident ,
232232 decl : & decl,
233233 body : block,
234234 vis : & i. vis ,
0 commit comments