]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc_save_analysis/lib.rs
Add a sig module to save-analysis
[rust.git] / src / librustc_save_analysis / lib.rs
index b4d74cfb1608425410506352de5a2b2f60ce3972..655901aa8591cc9bba79574aea9678dbbefdce32 100644 (file)
@@ -44,6 +44,7 @@
 pub mod external_data;
 #[macro_use]
 pub mod span_utils;
+mod sig;
 
 use rustc::hir;
 use rustc::hir::def::Def;
@@ -617,7 +618,7 @@ pub fn get_path_def(&self, id: NodeId) -> Def {
                             if let ty::TyProjection(proj) = ty.sty {
                                 for item in self.tcx.associated_items(proj.trait_ref.def_id) {
                                     if item.kind == ty::AssociatedKind::Type {
-                                        if item.name == proj.item_name {
+                                        if item.name == proj.item_name(self.tcx) {
                                             return Def::AssociatedTy(item.def_id);
                                         }
                                     }