@@ -39,7 +39,6 @@ use rustc::hir::map::definitions::{DefKey, DefPathData, Definitions};
3939use rustc:: hir:: map:: Map ;
4040use rustc:: lint;
4141use rustc:: lint:: builtin;
42- use rustc:: middle:: cstore:: CrateStore ;
4342use rustc:: { bug, span_bug} ;
4443use rustc_data_structures:: captures:: Captures ;
4544use rustc_data_structures:: fx:: FxHashSet ;
@@ -172,7 +171,9 @@ struct LoweringContext<'a, 'hir: 'a> {
172171}
173172
174173pub trait Resolver {
175- fn cstore ( & self ) -> & dyn CrateStore ;
174+ fn def_key ( & mut self , id : DefId ) -> DefKey ;
175+
176+ fn item_generics_cloned_untracked_liftimes ( & self , def : DefId , sess : & Session ) -> usize ;
176177
177178 /// Obtains resolution for a `NodeId` with a single resolution.
178179 fn get_partial_res ( & mut self , id : NodeId ) -> Option < PartialRes > ;
@@ -936,14 +937,6 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
936937 ret
937938 }
938939
939- fn def_key ( & mut self , id : DefId ) -> DefKey {
940- if id. is_local ( ) {
941- self . resolver . definitions ( ) . def_key ( id. index )
942- } else {
943- self . resolver . cstore ( ) . def_key ( id)
944- }
945- }
946-
947940 fn lower_attrs ( & mut self , attrs : & [ Attribute ] ) -> & ' hir [ Attribute ] {
948941 self . arena . alloc_from_iter ( attrs. iter ( ) . map ( |a| self . lower_attr ( a) ) )
949942 }
0 commit comments