1 note: external requirements
2 --> $DIR/projection-no-regions-closure.rs:25:23
4 LL | with_signature(x, |mut y| Box::new(y.next()))
5 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
7 = note: defining type: no_region::<'_#1r, T>::{closure#0} with closure substs [
9 extern "rust-call" fn((std::boxed::Box<T, std::alloc::Global>,)) -> std::boxed::Box<(dyn Anything + '_#2r), std::alloc::Global>,
12 = note: number of external vids: 3
13 = note: where <T as std::iter::Iterator>::Item: '_#2r
15 note: no external requirements
16 --> $DIR/projection-no-regions-closure.rs:21:1
18 LL | / fn no_region<'a, T>(x: Box<T>) -> Box<dyn Anything + 'a>
22 LL | | with_signature(x, |mut y| Box::new(y.next()))
27 = note: defining type: no_region::<'_#1r, T>
29 error[E0309]: the associated type `<T as Iterator>::Item` may not live long enough
30 --> $DIR/projection-no-regions-closure.rs:25:23
32 LL | with_signature(x, |mut y| Box::new(y.next()))
33 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
35 = help: consider adding an explicit lifetime bound `<T as Iterator>::Item: 'a`...
37 note: external requirements
38 --> $DIR/projection-no-regions-closure.rs:34:23
40 LL | with_signature(x, |mut y| Box::new(y.next()))
41 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
43 = note: defining type: correct_region::<'_#1r, T>::{closure#0} with closure substs [
45 extern "rust-call" fn((std::boxed::Box<T, std::alloc::Global>,)) -> std::boxed::Box<(dyn Anything + '_#2r), std::alloc::Global>,
48 = note: number of external vids: 3
49 = note: where <T as std::iter::Iterator>::Item: '_#2r
51 note: no external requirements
52 --> $DIR/projection-no-regions-closure.rs:30:1
54 LL | / fn correct_region<'a, T>(x: Box<T>) -> Box<dyn Anything + 'a>
56 LL | | T: 'a + Iterator,
58 LL | | with_signature(x, |mut y| Box::new(y.next()))
62 = note: defining type: correct_region::<'_#1r, T>
64 note: external requirements
65 --> $DIR/projection-no-regions-closure.rs:42:23
67 LL | with_signature(x, |mut y| Box::new(y.next()))
68 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
70 = note: defining type: wrong_region::<'_#1r, '_#2r, T>::{closure#0} with closure substs [
72 extern "rust-call" fn((std::boxed::Box<T, std::alloc::Global>,)) -> std::boxed::Box<(dyn Anything + '_#3r), std::alloc::Global>,
75 = note: number of external vids: 4
76 = note: where <T as std::iter::Iterator>::Item: '_#3r
78 note: no external requirements
79 --> $DIR/projection-no-regions-closure.rs:38:1
81 LL | / fn wrong_region<'a, 'b, T>(x: Box<T>) -> Box<dyn Anything + 'a>
83 LL | | T: 'b + Iterator,
85 LL | | with_signature(x, |mut y| Box::new(y.next()))
90 = note: defining type: wrong_region::<'_#1r, '_#2r, T>
92 error[E0309]: the associated type `<T as Iterator>::Item` may not live long enough
93 --> $DIR/projection-no-regions-closure.rs:42:23
95 LL | with_signature(x, |mut y| Box::new(y.next()))
96 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
98 = help: consider adding an explicit lifetime bound `<T as Iterator>::Item: 'a`...
100 note: external requirements
101 --> $DIR/projection-no-regions-closure.rs:52:23
103 LL | with_signature(x, |mut y| Box::new(y.next()))
104 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
106 = note: defining type: outlives_region::<'_#1r, '_#2r, T>::{closure#0} with closure substs [
108 extern "rust-call" fn((std::boxed::Box<T, std::alloc::Global>,)) -> std::boxed::Box<(dyn Anything + '_#3r), std::alloc::Global>,
111 = note: number of external vids: 4
112 = note: where <T as std::iter::Iterator>::Item: '_#3r
114 note: no external requirements
115 --> $DIR/projection-no-regions-closure.rs:47:1
117 LL | / fn outlives_region<'a, 'b, T>(x: Box<T>) -> Box<dyn Anything + 'a>
119 LL | | T: 'b + Iterator,
122 LL | | with_signature(x, |mut y| Box::new(y.next()))
126 = note: defining type: outlives_region::<'_#1r, '_#2r, T>
128 error: aborting due to 2 previous errors
130 For more information about this error, try `rustc --explain E0309`.