]> git.lizzy.rs Git - rust.git/commitdiff
remove support method for synthetic default method ids
authorNiko Matsakis <niko@alum.mit.edu>
Thu, 1 Oct 2015 15:10:30 +0000 (11:10 -0400)
committerNiko Matsakis <niko@alum.mit.edu>
Thu, 1 Oct 2015 15:10:30 +0000 (11:10 -0400)
src/librustc/front/map/mod.rs

index aba6429abaefd08d7f54a04bff0c16abac340490..825d5da0c999dbc67805d6738672c27074f89f7f 100644 (file)
@@ -305,22 +305,6 @@ pub fn as_local_node_id(&self, def_id: DefId) -> Option<NodeId> {
         self.definitions.borrow().as_local_node_id(def_id)
     }
 
-    /// for default methods, we create a fake node-id; this method
-    /// adds that fake node-id to the def-id tables
-    pub fn synthesize_default_method_def_id(&self,
-                                            impl_def_id: DefId,
-                                            new_method_id: NodeId,
-                                            method_name: Name)
-                                            -> DefId {
-        assert!(impl_def_id.is_local());
-        let index =
-            self.definitions.borrow_mut()
-                            .create_def_with_parent(Some(impl_def_id.index),
-                                                    new_method_id,
-                                                    DefPathData::Value(method_name));
-        DefId::local(index)
-    }
-
     fn entry_count(&self) -> usize {
         self.map.borrow().len()
     }