stop using the closure_kinds query / table for anything

Closure Kind is now extracted from the closure substs exclusively.
This commit is contained in:
Niko Matsakis 2017-11-08 09:45:48 -05:00
parent 716f75b1b8
commit 2dff9a49e5
14 changed files with 107 additions and 109 deletions

View file

@ -19,7 +19,6 @@ struct A (B);
impl A {
pub fn matches<F: Fn()>(&self, f: &F) {
//~^ ERROR reached the recursion limit while instantiating `A::matches::<[closure
let &A(ref term) = self;
term.matches(f);
}
@ -59,6 +58,7 @@ struct D (Box<A>);
impl D {
pub fn matches<F: Fn()>(&self, f: &F) {
//~^ ERROR reached the type-length limit while instantiating `D::matches::<[closure
let &D(ref a) = self;
a.matches(f)
}