1 // Regression test for issue #57611
2 // Ensures that we don't ICE
3 // FIXME: This should compile, but it currently doesn't
7 // ignore-compare-mode-nll
8 //[nll] compile-flags: -Z borrowck=mir
10 #![feature(trait_alias)]
11 #![feature(type_alias_impl_trait)]
14 type Bar: Baz<Self, Self>;
16 fn bar(&self) -> Self::Bar;
22 type Bar = impl Baz<Self, Self>;
24 fn bar(&self) -> Self::Bar {
29 trait Baz<A: ?Sized, B: ?Sized> = Fn(&A) -> &B;