1 error[E0310]: the associated type `<impl Iterator as Iterator>::Item` may not live long enough
2 --> $DIR/closure-in-projection-issue-97405.rs:24:5
4 LL | assert_static(opaque(async move { t; }).next());
5 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
7 = help: consider adding an explicit lifetime bound `<impl Iterator as Iterator>::Item: 'static`...
8 = note: ...so that the type `<impl Iterator as Iterator>::Item` will meet its required lifetime bounds
10 error[E0310]: the associated type `<impl Iterator as Iterator>::Item` may not live long enough
11 --> $DIR/closure-in-projection-issue-97405.rs:26:5
13 LL | assert_static(opaque(move || { t; }).next());
14 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
16 = help: consider adding an explicit lifetime bound `<impl Iterator as Iterator>::Item: 'static`...
17 = note: ...so that the type `<impl Iterator as Iterator>::Item` will meet its required lifetime bounds
19 error[E0310]: the associated type `<impl Iterator as Iterator>::Item` may not live long enough
20 --> $DIR/closure-in-projection-issue-97405.rs:28:5
22 LL | assert_static(opaque(opaque(async move { t; }).next()).next());
23 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
25 = help: consider adding an explicit lifetime bound `<impl Iterator as Iterator>::Item: 'static`...
26 = note: ...so that the type `<impl Iterator as Iterator>::Item` will meet its required lifetime bounds
28 error: aborting due to 3 previous errors
30 For more information about this error, try `rustc --explain E0310`.