@@ -55,7 +55,7 @@ use rustc::util::nodemap::{NodeMap, NodeSet, FnvHashMap, FnvHashSet};
5555
5656use syntax:: ext:: hygiene:: Mark ;
5757use syntax:: ast:: { self , FloatTy } ;
58- use syntax:: ast:: { CRATE_NODE_ID , Name , NodeId , IntTy , UintTy } ;
58+ use syntax:: ast:: { CRATE_NODE_ID , Name , NodeId , Ident , IntTy , UintTy } ;
5959use syntax:: ext:: base:: SyntaxExtension ;
6060use syntax:: parse:: token:: { self , keywords} ;
6161use syntax:: util:: lev_distance:: find_best_match_for_name;
@@ -509,7 +509,7 @@ struct BindingInfo {
509509}
510510
511511// Map from the name in a pattern to its binding mode.
512- type BindingMap = FnvHashMap < ast :: Ident , BindingInfo > ;
512+ type BindingMap = FnvHashMap < Ident , BindingInfo > ;
513513
514514#[ derive( Copy , Clone , PartialEq , Eq , Debug ) ]
515515enum PatternSource {
@@ -714,7 +714,7 @@ enum ModulePrefixResult<'a> {
714714/// One local scope.
715715#[ derive( Debug ) ]
716716struct Rib < ' a > {
717- bindings : FnvHashMap < ast :: Ident , Def > ,
717+ bindings : FnvHashMap < Ident , Def > ,
718718 kind : RibKind < ' a > ,
719719}
720720
@@ -1479,7 +1479,7 @@ impl<'a> Resolver<'a> {
14791479 // This is not a crate-relative path. We resolve the
14801480 // first component of the path in the current lexical
14811481 // scope and then proceed to resolve below that.
1482- let ident = ast :: Ident :: with_empty_ctxt ( module_path[ 0 ] ) ;
1482+ let ident = Ident :: with_empty_ctxt ( module_path[ 0 ] ) ;
14831483 let lexical_binding =
14841484 self . resolve_ident_in_lexical_scope ( ident, TypeNS , span) ;
14851485 if let Some ( binding) = lexical_binding. and_then ( LexicalScopeBinding :: item) {
@@ -1525,12 +1525,12 @@ impl<'a> Resolver<'a> {
15251525 /// Invariant: This must only be called during main resolution, not during
15261526 /// import resolution.
15271527 fn resolve_ident_in_lexical_scope ( & mut self ,
1528- mut ident : ast :: Ident ,
1528+ mut ident : Ident ,
15291529 ns : Namespace ,
15301530 record_used : Option < Span > )
15311531 -> Option < LexicalScopeBinding < ' a > > {
15321532 if ns == TypeNS {
1533- ident = ast :: Ident :: with_empty_ctxt ( ident. name ) ;
1533+ ident = Ident :: with_empty_ctxt ( ident. name ) ;
15341534 }
15351535
15361536 // Walk backwards up the ribs in scope.
@@ -1649,7 +1649,7 @@ impl<'a> Resolver<'a> {
16491649
16501650 /// Searches the current set of local scopes for labels.
16511651 /// Stops after meeting a closure.
1652- fn search_label ( & self , mut ident : ast :: Ident ) -> Option < Def > {
1652+ fn search_label ( & self , mut ident : Ident ) -> Option < Def > {
16531653 for rib in self . label_ribs . iter ( ) . rev ( ) {
16541654 match rib. kind {
16551655 NormalRibKind => {
@@ -1813,7 +1813,7 @@ impl<'a> Resolver<'a> {
18131813 // plain insert (no renaming)
18141814 let def_id = self . definitions . local_def_id ( type_parameter. id ) ;
18151815 let def = Def :: TyParam ( def_id) ;
1816- function_type_rib. bindings . insert ( ast :: Ident :: with_empty_ctxt ( name) , def) ;
1816+ function_type_rib. bindings . insert ( Ident :: with_empty_ctxt ( name) , def) ;
18171817 self . record_def ( type_parameter. id , PathResolution :: new ( def) ) ;
18181818 }
18191819 self . type_ribs . push ( function_type_rib) ;
@@ -2271,7 +2271,7 @@ impl<'a> Resolver<'a> {
22712271 pat_id : NodeId ,
22722272 outer_pat_id : NodeId ,
22732273 pat_src : PatternSource ,
2274- bindings : & mut FnvHashMap < ast :: Ident , NodeId > )
2274+ bindings : & mut FnvHashMap < Ident , NodeId > )
22752275 -> PathResolution {
22762276 // Add the binding to the local ribs, if it
22772277 // doesn't already exist in the bindings map. (We
@@ -2372,7 +2372,7 @@ impl<'a> Resolver<'a> {
23722372 pat_src : PatternSource ,
23732373 // Maps idents to the node ID for the
23742374 // outermost pattern that binds them.
2375- bindings : & mut FnvHashMap < ast :: Ident , NodeId > ) {
2375+ bindings : & mut FnvHashMap < Ident , NodeId > ) {
23762376 // Visit all direct subpatterns of this pattern.
23772377 let outer_pat_id = pat. id ;
23782378 pat. walk ( & mut |pat| {
@@ -2573,7 +2573,7 @@ impl<'a> Resolver<'a> {
25732573
25742574 // Resolve a single identifier
25752575 fn resolve_identifier ( & mut self ,
2576- identifier : ast :: Ident ,
2576+ identifier : Ident ,
25772577 namespace : Namespace ,
25782578 record_used : Option < Span > )
25792579 -> Option < LocalDef > {
@@ -2835,7 +2835,7 @@ impl<'a> Resolver<'a> {
28352835 } SuggestionType :: NotFound
28362836 }
28372837
2838- fn resolve_labeled_block ( & mut self , label : Option < ast :: Ident > , id : NodeId , block : & Block ) {
2838+ fn resolve_labeled_block ( & mut self , label : Option < Ident > , id : NodeId , block : & Block ) {
28392839 if let Some ( label) = label {
28402840 let def = Def :: Label ( id) ;
28412841 self . with_label_rib ( |this| {
@@ -3237,7 +3237,7 @@ impl<'a> Resolver<'a> {
32373237 if name == lookup_name && ns == namespace {
32383238 if filter_fn ( name_binding. def ( ) ) {
32393239 // create the path
3240- let ident = ast :: Ident :: with_empty_ctxt ( name) ;
3240+ let ident = Ident :: with_empty_ctxt ( name) ;
32413241 let params = PathParameters :: none ( ) ;
32423242 let segment = PathSegment {
32433243 identifier : ident,
@@ -3271,7 +3271,7 @@ impl<'a> Resolver<'a> {
32713271 _ if module. parent . is_none ( ) => path_segments. clone ( ) ,
32723272 ModuleKind :: Def ( _, name) => {
32733273 let mut paths = path_segments. clone ( ) ;
3274- let ident = ast :: Ident :: with_empty_ctxt ( name) ;
3274+ let ident = Ident :: with_empty_ctxt ( name) ;
32753275 let params = PathParameters :: none ( ) ;
32763276 let segm = PathSegment {
32773277 identifier : ident,
0 commit comments