@@ -312,7 +312,7 @@ impl<'l, 'tcx> SaveContext<'l, 'tcx> {
312312 let impl_id = self . next_impl_id ( ) ;
313313 let span = self . span_from_span ( sub_span) ;
314314
315- let type_data = self . lookup_ref_id ( typ. id ) ;
315+ let type_data = self . lookup_def_id ( typ. id ) ;
316316 type_data. map ( |type_data| {
317317 Data :: RelationData ( Relation {
318318 kind : RelationKind :: Impl {
@@ -322,7 +322,7 @@ impl<'l, 'tcx> SaveContext<'l, 'tcx> {
322322 from : id_from_def_id ( type_data) ,
323323 to : trait_ref
324324 . as_ref ( )
325- . and_then ( |t| self . lookup_ref_id ( t. ref_id ) )
325+ . and_then ( |t| self . lookup_def_id ( t. ref_id ) )
326326 . map ( id_from_def_id)
327327 . unwrap_or_else ( || null_id ( ) ) ,
328328 } ,
@@ -495,7 +495,7 @@ impl<'l, 'tcx> SaveContext<'l, 'tcx> {
495495 }
496496
497497 pub fn get_trait_ref_data ( & self , trait_ref : & ast:: TraitRef ) -> Option < Ref > {
498- self . lookup_ref_id ( trait_ref. ref_id ) . and_then ( |def_id| {
498+ self . lookup_def_id ( trait_ref. ref_id ) . and_then ( |def_id| {
499499 let span = trait_ref. path . span ;
500500 if generated_code ( span) {
501501 return None ;
@@ -870,7 +870,7 @@ impl<'l, 'tcx> SaveContext<'l, 'tcx> {
870870 } )
871871 }
872872
873- fn lookup_ref_id ( & self , ref_id : NodeId ) -> Option < DefId > {
873+ fn lookup_def_id ( & self , ref_id : NodeId ) -> Option < DefId > {
874874 match self . get_path_res ( ref_id) {
875875 Res :: PrimTy ( _) | Res :: SelfTy ( ..) | Res :: Err => None ,
876876 def => Some ( def. def_id ( ) ) ,
0 commit comments