1 error[E0700]: hidden type for `impl Trait` captures lifetime that does not appear in bounds
2 --> $DIR/arbitrary_self_types_pin_lifetime_mismatch-async.rs:8:45
4 LL | async fn a(self: Pin<&Foo>, f: &Foo) -> &Foo { f }
7 = note: hidden type `impl std::future::Future` captures lifetime '_#15r
9 error: lifetime may not live long enough
10 --> $DIR/arbitrary_self_types_pin_lifetime_mismatch-async.rs:8:52
12 LL | async fn a(self: Pin<&Foo>, f: &Foo) -> &Foo { f }
13 | - ^ function was supposed to return data with lifetime `'_` but it is returning data with lifetime `'_`
15 | lifetime `'_` defined here
16 | lifetime `'_` defined here
18 error: lifetime may not live long enough
19 --> $DIR/arbitrary_self_types_pin_lifetime_mismatch-async.rs:11:75
21 LL | async fn c(self: Pin<&Self>, f: &Foo, g: &Foo) -> (Pin<&Foo>, &Foo) { (self, f) }
22 | - ^^^^^^^^^ function was supposed to return data with lifetime `'_` but it is returning data with lifetime `'_`
24 | lifetime `'_` defined here
25 | lifetime `'_` defined here
27 error[E0700]: hidden type for `impl Trait` captures lifetime that does not appear in bounds
28 --> $DIR/arbitrary_self_types_pin_lifetime_mismatch-async.rs:17:58
30 LL | async fn bar<'a>(self: Alias<&Self>, arg: &'a ()) -> &() { arg }
33 = note: hidden type `impl std::future::Future` captures lifetime '_#15r
35 error: lifetime may not live long enough
36 --> $DIR/arbitrary_self_types_pin_lifetime_mismatch-async.rs:17:64
38 LL | async fn bar<'a>(self: Alias<&Self>, arg: &'a ()) -> &() { arg }
39 | -- - lifetime `'_` defined here ^^^ function was supposed to return data with lifetime `'_` but it is returning data with lifetime `'a`
41 | lifetime `'a` defined here
43 error: aborting due to 5 previous errors
45 For more information about this error, try `rustc --explain E0700`.