11error: lifetime may not live long enough
2- --> $DIR/normalization-2.rs:32 :12
2+ --> $DIR/normalization-2.rs:33 :12
33 |
44LL | fn test_local<'a>() {
55 | -- lifetime `'a` defined here
66LL | let _: Ty<'a> = MyTy::Unit;
77 | ^^^^^^ requires that `'a` must outlive `'static`
88
99error: lifetime may not live long enough
10- --> $DIR/normalization-2.rs:37 :6
10+ --> $DIR/normalization-2.rs:38 :6
1111 |
1212LL | fn test_closure_sig<'a, 'b>() {
1313 | -- lifetime `'a` defined here
1414LL | |_: Ty<'a>| {};
1515 | ^ requires that `'a` must outlive `'static`
1616
1717error: lifetime may not live long enough
18- --> $DIR/normalization-2.rs:39 :11
18+ --> $DIR/normalization-2.rs:40 :11
1919 |
2020LL | fn test_closure_sig<'a, 'b>() {
2121 | -- lifetime `'b` defined here
@@ -29,37 +29,47 @@ help: the following changes may resolve your lifetime errors
2929 = help: replace `'b` with `'static`
3030
3131error: lifetime may not live long enough
32- --> $DIR/normalization-2.rs:44 :5
32+ --> $DIR/normalization-2.rs:45 :5
3333 |
3434LL | fn test_path<'a, 'b, 'c, 'd>() {
3535 | -- lifetime `'a` defined here
3636LL | <Ty<'a>>::method::<Ty<'static>>;
3737 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
3838
3939error: lifetime may not live long enough
40- --> $DIR/normalization-2.rs:46 :5
40+ --> $DIR/normalization-2.rs:47 :5
4141 |
4242LL | fn test_path<'a, 'b, 'c, 'd>() {
4343 | -- lifetime `'b` defined here
4444...
4545LL | <Ty<'static>>::method::<Ty<'b>>;
4646 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ requires that `'b` must outlive `'static`
4747
48+ error: lifetime may not live long enough
49+ --> $DIR/normalization-2.rs:50:5
50+ |
51+ LL | fn test_path<'a, 'b, 'c, 'd>() {
52+ | -- lifetime `'c` defined here
53+ ...
54+ LL | MyTy::Unit::<Ty<'c>>;
55+ | ^^^^^^^^^^^^^^^^^^^^ requires that `'c` must outlive `'static`
56+
4857help: the following changes may resolve your lifetime errors
4958 |
5059 = help: replace `'a` with `'static`
5160 = help: replace `'b` with `'static`
61+ = help: replace `'c` with `'static`
5262
5363error: lifetime may not live long enough
54- --> $DIR/normalization-2.rs:51 :5
64+ --> $DIR/normalization-2.rs:55 :5
5565 |
5666LL | fn test_call<'a, 'b, 'c>() {
5767 | -- lifetime `'a` defined here
5868LL | <Ty<'a>>::method::<Ty<'static>>();
5969 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
6070
6171error: lifetime may not live long enough
62- --> $DIR/normalization-2.rs:53 :5
72+ --> $DIR/normalization-2.rs:57 :5
6373 |
6474LL | fn test_call<'a, 'b, 'c>() {
6575 | -- lifetime `'b` defined here
@@ -73,15 +83,15 @@ help: the following changes may resolve your lifetime errors
7383 = help: replace `'b` with `'static`
7484
7585error: lifetime may not live long enough
76- --> $DIR/normalization-2.rs:58 :5
86+ --> $DIR/normalization-2.rs:62 :5
7787 |
7888LL | fn test_variants<'a, 'b, 'c>() {
7989 | -- lifetime `'a` defined here
80- LL | <Ty<'a>>::Struct {}; //TODO
90+ LL | <Ty<'a>>::Struct {};
8191 | ^^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
8292
8393error: lifetime may not live long enough
84- --> $DIR/normalization-2.rs:60 :5
94+ --> $DIR/normalization-2.rs:64 :5
8595 |
8696LL | fn test_variants<'a, 'b, 'c>() {
8797 | -- lifetime `'b` defined here
@@ -90,7 +100,7 @@ LL | <Ty<'b>>::Tuple();
90100 | ^^^^^^^^^^^^^^^ requires that `'b` must outlive `'static`
91101
92102error: lifetime may not live long enough
93- --> $DIR/normalization-2.rs:62 :5
103+ --> $DIR/normalization-2.rs:66 :5
94104 |
95105LL | fn test_variants<'a, 'b, 'c>() {
96106 | -- lifetime `'c` defined here
@@ -105,7 +115,50 @@ help: the following changes may resolve your lifetime errors
105115 = help: replace `'c` with `'static`
106116
107117error: lifetime may not live long enough
108- --> $DIR/normalization-2.rs:69:9
118+ --> $DIR/normalization-2.rs:88:5
119+ |
120+ LL | fn test_struct_path<'a, 'b, 'c, 'd>() {
121+ | -- lifetime `'a` defined here
122+ ...
123+ LL | MyTy::<Ty<'a>>::Struct {}; // without SelfTy
124+ | ^^^^^^^^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
125+
126+ error: lifetime may not live long enough
127+ --> $DIR/normalization-2.rs:90:5
128+ |
129+ LL | fn test_struct_path<'a, 'b, 'c, 'd>() {
130+ | -- lifetime `'b` defined here
131+ ...
132+ LL | <Ty<'b> as Project>::Enum::Struct {}; // with SelfTy
133+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ requires that `'b` must outlive `'static`
134+
135+ error: lifetime may not live long enough
136+ --> $DIR/normalization-2.rs:94:5
137+ |
138+ LL | fn test_struct_path<'a, 'b, 'c, 'd>() {
139+ | -- lifetime `'c` defined here
140+ ...
141+ LL | Struct::<Ty<'c>> { x: None, }; // without SelfTy
142+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ requires that `'c` must outlive `'static`
143+
144+ error: lifetime may not live long enough
145+ --> $DIR/normalization-2.rs:96:5
146+ |
147+ LL | fn test_struct_path<'a, 'b, 'c, 'd>() {
148+ | -- lifetime `'d` defined here
149+ ...
150+ LL | <Ty<'d> as Project>::Struct { x: None, }; // with SelfTy
151+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ requires that `'d` must outlive `'static`
152+
153+ help: the following changes may resolve your lifetime errors
154+ |
155+ = help: replace `'a` with `'static`
156+ = help: replace `'b` with `'static`
157+ = help: replace `'c` with `'static`
158+ = help: replace `'d` with `'static`
159+
160+ error: lifetime may not live long enough
161+ --> $DIR/normalization-2.rs:103:9
109162 |
110163LL | fn test_pattern<'a, 'b, 'c>() {
111164 | -- lifetime `'a` defined here
@@ -114,7 +167,7 @@ LL | Struct::<Ty<'a>> {..} => {},
114167 | ^^^^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
115168
116169error: lifetime may not live long enough
117- --> $DIR/normalization-2.rs:71 :9
170+ --> $DIR/normalization-2.rs:105 :9
118171 |
119172LL | fn test_pattern<'a, 'b, 'c>() {
120173 | -- lifetime `'b` defined here
@@ -123,7 +176,7 @@ LL | Tuple::<Ty<'b>> (..) => {},
123176 | ^^^^^^^^^^^^^^^^^^^^ requires that `'b` must outlive `'static`
124177
125178error: lifetime may not live long enough
126- --> $DIR/normalization-2.rs:73 :9
179+ --> $DIR/normalization-2.rs:107 :9
127180 |
128181LL | fn test_pattern<'a, 'b, 'c>() {
129182 | -- lifetime `'c` defined here
@@ -137,5 +190,5 @@ help: the following changes may resolve your lifetime errors
137190 = help: replace `'b` with `'static`
138191 = help: replace `'c` with `'static`
139192
140- error: aborting due to 13 previous errors
193+ error: aborting due to 18 previous errors
141194
0 commit comments