blob: 616368d25cf463913d8b6a9359e89c649dbd02bf (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
//@ check-pass
// Ensure that we skip uncaptured args from RPITITs when collecting the regions
// to enforce member constraints in opaque type inference.
struct Invariant<T>(*mut T);
trait Foo {
fn hello<'s: 's>(&'s self) -> Invariant<impl Sized + use<Self>>;
}
fn hello<'s, T: Foo>(x: &'s T) -> Invariant<impl Sized> {
x.hello()
}
fn main() {}
|