trait Baz {} fn foo(x: T) { fn bfnr, W: Fn()>(y: T) { //~ ERROR E0401 } fn baz, W: Fn()> (y: T) { //~ ERROR E0401 } bfnr(x); //~^ ERROR type annotations needed //~| ERROR type annotations needed } struct A { inner: T, } impl Iterator for A { type Item = u8; fn next(&mut self) -> Option { fn helper(sel: &Self) -> u8 { //~ ERROR E0401 unimplemented!(); } Some(helper(self)) } } fn main() { }