1
1
error: lifetime may not live long enough
2
- --> $DIR/normalization-2.rs:32 :12
2
+ --> $DIR/normalization-2.rs:33 :12
3
3
|
4
4
LL | fn test_local<'a>() {
5
5
| -- lifetime `'a` defined here
6
6
LL | let _: Ty<'a> = MyTy::Unit;
7
7
| ^^^^^^ requires that `'a` must outlive `'static`
8
8
9
9
error: lifetime may not live long enough
10
- --> $DIR/normalization-2.rs:37 :6
10
+ --> $DIR/normalization-2.rs:38 :6
11
11
|
12
12
LL | fn test_closure_sig<'a, 'b>() {
13
13
| -- lifetime `'a` defined here
14
14
LL | |_: Ty<'a>| {};
15
15
| ^ requires that `'a` must outlive `'static`
16
16
17
17
error: lifetime may not live long enough
18
- --> $DIR/normalization-2.rs:39 :11
18
+ --> $DIR/normalization-2.rs:40 :11
19
19
|
20
20
LL | fn test_closure_sig<'a, 'b>() {
21
21
| -- lifetime `'b` defined here
@@ -29,37 +29,47 @@ help: the following changes may resolve your lifetime errors
29
29
= help: replace `'b` with `'static`
30
30
31
31
error: lifetime may not live long enough
32
- --> $DIR/normalization-2.rs:44 :5
32
+ --> $DIR/normalization-2.rs:45 :5
33
33
|
34
34
LL | fn test_path<'a, 'b, 'c, 'd>() {
35
35
| -- lifetime `'a` defined here
36
36
LL | <Ty<'a>>::method::<Ty<'static>>;
37
37
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
38
38
39
39
error: lifetime may not live long enough
40
- --> $DIR/normalization-2.rs:46 :5
40
+ --> $DIR/normalization-2.rs:47 :5
41
41
|
42
42
LL | fn test_path<'a, 'b, 'c, 'd>() {
43
43
| -- lifetime `'b` defined here
44
44
...
45
45
LL | <Ty<'static>>::method::<Ty<'b>>;
46
46
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ requires that `'b` must outlive `'static`
47
47
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
+
48
57
help: the following changes may resolve your lifetime errors
49
58
|
50
59
= help: replace `'a` with `'static`
51
60
= help: replace `'b` with `'static`
61
+ = help: replace `'c` with `'static`
52
62
53
63
error: lifetime may not live long enough
54
- --> $DIR/normalization-2.rs:51 :5
64
+ --> $DIR/normalization-2.rs:55 :5
55
65
|
56
66
LL | fn test_call<'a, 'b, 'c>() {
57
67
| -- lifetime `'a` defined here
58
68
LL | <Ty<'a>>::method::<Ty<'static>>();
59
69
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
60
70
61
71
error: lifetime may not live long enough
62
- --> $DIR/normalization-2.rs:53 :5
72
+ --> $DIR/normalization-2.rs:57 :5
63
73
|
64
74
LL | fn test_call<'a, 'b, 'c>() {
65
75
| -- lifetime `'b` defined here
@@ -73,15 +83,15 @@ help: the following changes may resolve your lifetime errors
73
83
= help: replace `'b` with `'static`
74
84
75
85
error: lifetime may not live long enough
76
- --> $DIR/normalization-2.rs:58 :5
86
+ --> $DIR/normalization-2.rs:62 :5
77
87
|
78
88
LL | fn test_variants<'a, 'b, 'c>() {
79
89
| -- lifetime `'a` defined here
80
- LL | <Ty<'a>>::Struct {}; //TODO
90
+ LL | <Ty<'a>>::Struct {};
81
91
| ^^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
82
92
83
93
error: lifetime may not live long enough
84
- --> $DIR/normalization-2.rs:60 :5
94
+ --> $DIR/normalization-2.rs:64 :5
85
95
|
86
96
LL | fn test_variants<'a, 'b, 'c>() {
87
97
| -- lifetime `'b` defined here
@@ -90,7 +100,7 @@ LL | <Ty<'b>>::Tuple();
90
100
| ^^^^^^^^^^^^^^^ requires that `'b` must outlive `'static`
91
101
92
102
error: lifetime may not live long enough
93
- --> $DIR/normalization-2.rs:62 :5
103
+ --> $DIR/normalization-2.rs:66 :5
94
104
|
95
105
LL | fn test_variants<'a, 'b, 'c>() {
96
106
| -- lifetime `'c` defined here
@@ -105,7 +115,50 @@ help: the following changes may resolve your lifetime errors
105
115
= help: replace `'c` with `'static`
106
116
107
117
error: 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
109
162
|
110
163
LL | fn test_pattern<'a, 'b, 'c>() {
111
164
| -- lifetime `'a` defined here
@@ -114,7 +167,7 @@ LL | Struct::<Ty<'a>> {..} => {},
114
167
| ^^^^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
115
168
116
169
error: lifetime may not live long enough
117
- --> $DIR/normalization-2.rs:71 :9
170
+ --> $DIR/normalization-2.rs:105 :9
118
171
|
119
172
LL | fn test_pattern<'a, 'b, 'c>() {
120
173
| -- lifetime `'b` defined here
@@ -123,7 +176,7 @@ LL | Tuple::<Ty<'b>> (..) => {},
123
176
| ^^^^^^^^^^^^^^^^^^^^ requires that `'b` must outlive `'static`
124
177
125
178
error: lifetime may not live long enough
126
- --> $DIR/normalization-2.rs:73 :9
179
+ --> $DIR/normalization-2.rs:107 :9
127
180
|
128
181
LL | fn test_pattern<'a, 'b, 'c>() {
129
182
| -- lifetime `'c` defined here
@@ -137,5 +190,5 @@ help: the following changes may resolve your lifetime errors
137
190
= help: replace `'b` with `'static`
138
191
= help: replace `'c` with `'static`
139
192
140
- error: aborting due to 13 previous errors
193
+ error: aborting due to 18 previous errors
141
194
0 commit comments