//@ incremental trait Foo { type V; } trait Callback: Fn(&Bar<'_, T>, &T::V) {} struct Bar<'a, T> { callback: Box>>>, //~^ ERROR the trait bound `Bar<'a, T>: Foo` is not satisfied //~| ERROR the trait bound `(dyn Callback, Output = ()> + 'static): Foo` is not satisfied //~| ERROR the size for values of type `(dyn Callback, Output = ()> + 'static)` cannot be known at compilation time } impl Bar<'_, Bar<'_, T>> {} fn main() {}