// check-pass trait Foo { fn do_stuff() -> Self; } trait Bar { type Output; } impl Foo for dyn Bar where Self: Sized, { fn do_stuff() -> Self { todo!() } } fn main() {}