3 // Regression test for #21726: an issue arose around the rules for
4 // subtyping of projection types that resulted in an unconstrained
5 // region, yielding region inference failures.
7 // pretty-expanded FIXME #23616
11 fn foo<'a>(s: &'a str) {
12 let b: B<()> = B::new(s, ());
18 fn into_ref(self, _: &'a str) -> Self::T;
21 impl<'a> IntoRef<'a> for () {
23 fn into_ref(self, s: &'a str) -> &'a str {
28 struct B<'a, P: IntoRef<'a>>(P::T);
30 impl<'a, P: IntoRef<'a>> B<'a, P> {
31 fn new(s: &'a str, i: P) -> B<'a, P> {
35 fn get_short(&self) -> P::T {