]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc/traits/mod.rs
Refactor away `inferred_obligations` from the trait selector
[rust.git] / src / librustc / traits / mod.rs
index b9ae4599d808ea1ce2d1ef1e944be169138ee588..26ff5756ba0bb5647a1385f59b202f8a9ff2ad18 100644 (file)
@@ -854,19 +854,6 @@ pub fn nested_obligations(self) -> Vec<N> {
         }
     }
 
-    fn nested_obligations_mut(&mut self) -> &mut Vec<N> {
-        match self {
-            &mut VtableImpl(ref mut i) => &mut i.nested,
-            &mut VtableParam(ref mut n) => n,
-            &mut VtableBuiltin(ref mut i) => &mut i.nested,
-            &mut VtableAutoImpl(ref mut d) => &mut d.nested,
-            &mut VtableGenerator(ref mut c) => &mut c.nested,
-            &mut VtableClosure(ref mut c) => &mut c.nested,
-            &mut VtableObject(ref mut d) => &mut d.nested,
-            &mut VtableFnPointer(ref mut d) => &mut d.nested,
-        }
-    }
-
     pub fn map<M, F>(self, f: F) -> Vtable<'tcx, M> where F: FnMut(N) -> M {
         match self {
             VtableImpl(i) => VtableImpl(VtableImplData {