1
1
error[E0310]: the parameter type `T` may not live long enough
2
- --> $DIR/static-lifetime-tip-with-default-type.rs:7 :24
2
+ --> $DIR/static-lifetime-tip-with-default-type.rs:3 :24
3
3
|
4
4
LL | struct Foo<T, K = i32>(&'static T, &'static K);
5
5
| ^^^^^^^^^^
@@ -13,7 +13,7 @@ LL | struct Foo<T: 'static, K = i32>(&'static T, &'static K);
13
13
| +++++++++
14
14
15
15
error[E0310]: the parameter type `K` may not live long enough
16
- --> $DIR/static-lifetime-tip-with-default-type.rs:7 :36
16
+ --> $DIR/static-lifetime-tip-with-default-type.rs:3 :36
17
17
|
18
18
LL | struct Foo<T, K = i32>(&'static T, &'static K);
19
19
| ^^^^^^^^^^
@@ -27,7 +27,7 @@ LL | struct Foo<T, K: 'static = i32>(&'static T, &'static K);
27
27
| +++++++++
28
28
29
29
error[E0310]: the parameter type `T` may not live long enough
30
- --> $DIR/static-lifetime-tip-with-default-type.rs:11 :28
30
+ --> $DIR/static-lifetime-tip-with-default-type.rs:7 :28
31
31
|
32
32
LL | struct Bar<r#T, r#K = i32>(&'static r#T, &'static r#K);
33
33
| ^^^^^^^^^^^^
@@ -41,7 +41,7 @@ LL | struct Bar<r#T: 'static, r#K = i32>(&'static r#T, &'static r#K);
41
41
| +++++++++
42
42
43
43
error[E0310]: the parameter type `K` may not live long enough
44
- --> $DIR/static-lifetime-tip-with-default-type.rs:11 :42
44
+ --> $DIR/static-lifetime-tip-with-default-type.rs:7 :42
45
45
|
46
46
LL | struct Bar<r#T, r#K = i32>(&'static r#T, &'static r#K);
47
47
| ^^^^^^^^^^^^
@@ -55,7 +55,7 @@ LL | struct Bar<r#T, r#K: 'static = i32>(&'static r#T, &'static r#K);
55
55
| +++++++++
56
56
57
57
error[E0310]: the parameter type `T` may not live long enough
58
- --> $DIR/static-lifetime-tip-with-default-type.rs:15 :20
58
+ --> $DIR/static-lifetime-tip-with-default-type.rs:11 :20
59
59
|
60
60
LL | struct Boo<T= i32>(&'static T);
61
61
| ^^^^^^^^^^
@@ -69,7 +69,7 @@ LL | struct Boo<T: 'static= i32>(&'static T);
69
69
| +++++++++
70
70
71
71
error[E0310]: the parameter type `T` may not live long enough
72
- --> $DIR/static-lifetime-tip-with-default-type.rs:19 :8
72
+ --> $DIR/static-lifetime-tip-with-default-type.rs:15 :8
73
73
|
74
74
LL | = i32>(&'static T);
75
75
| ^^^^^^^^^^
@@ -83,15 +83,15 @@ LL | struct Far<T: 'static
83
83
| +++++++++
84
84
85
85
error[E0392]: lifetime parameter `'a` is never used
86
- --> $DIR/static-lifetime-tip-with-default-type.rs:22 :10
86
+ --> $DIR/static-lifetime-tip-with-default-type.rs:18 :10
87
87
|
88
88
LL | struct S<'a, K: 'a = i32>(&'static K);
89
89
| ^^ unused lifetime parameter
90
90
|
91
91
= help: consider removing `'a`, referring to it in a field, or using a marker such as `PhantomData`
92
92
93
93
error[E0310]: the parameter type `K` may not live long enough
94
- --> $DIR/static-lifetime-tip-with-default-type.rs:22 :27
94
+ --> $DIR/static-lifetime-tip-with-default-type.rs:18 :27
95
95
|
96
96
LL | struct S<'a, K: 'a = i32>(&'static K);
97
97
| ^^^^^^^^^^
0 commit comments