1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
|
error[E0312]: lifetime of reference outlives lifetime of borrowed content...
--> $DIR/wf-static-method.rs:21:9
|
LL | u
| ^
|
note: ...the reference is valid for the lifetime `'a` as defined here...
--> $DIR/wf-static-method.rs:18:6
|
LL | impl<'a, 'b> Foo<'a, 'b, Evil<'a, 'b>> for () {
| ^^
note: ...but the borrowed content is only valid for the lifetime `'b` as defined here
--> $DIR/wf-static-method.rs:18:10
|
LL | impl<'a, 'b> Foo<'a, 'b, Evil<'a, 'b>> for () {
| ^^
error[E0478]: lifetime bound not satisfied
--> $DIR/wf-static-method.rs:32:18
|
LL | let me = Self::make_me();
| ^^^^
|
note: lifetime parameter instantiated with the lifetime `'b` as defined here
--> $DIR/wf-static-method.rs:29:10
|
LL | impl<'a, 'b> Foo<'a, 'b, ()> for IndirectEvil<'a, 'b> {
| ^^
note: but lifetime parameter must outlive the lifetime `'a` as defined here
--> $DIR/wf-static-method.rs:29:6
|
LL | impl<'a, 'b> Foo<'a, 'b, ()> for IndirectEvil<'a, 'b> {
| ^^
error[E0312]: lifetime of reference outlives lifetime of borrowed content...
--> $DIR/wf-static-method.rs:41:9
|
LL | u
| ^
|
note: ...the reference is valid for the lifetime `'a` as defined here...
--> $DIR/wf-static-method.rs:39:6
|
LL | impl<'a, 'b> Evil<'a, 'b> {
| ^^
note: ...but the borrowed content is only valid for the lifetime `'b` as defined here
--> $DIR/wf-static-method.rs:39:10
|
LL | impl<'a, 'b> Evil<'a, 'b> {
| ^^
error[E0495]: cannot infer an appropriate lifetime for lifetime parameter `'b` due to conflicting requirements
--> $DIR/wf-static-method.rs:51:5
|
LL | <()>::static_evil(b)
| ^^^^^^^^^^^^^^^^^
|
note: first, the lifetime cannot outlive the lifetime `'b` as defined here...
--> $DIR/wf-static-method.rs:50:13
|
LL | fn evil<'a, 'b>(b: &'b u32) -> &'a u32 {
| ^^
note: ...so that reference does not outlive borrowed content
--> $DIR/wf-static-method.rs:51:23
|
LL | <()>::static_evil(b)
| ^
note: but, the lifetime must be valid for the lifetime `'a` as defined here...
--> $DIR/wf-static-method.rs:50:9
|
LL | fn evil<'a, 'b>(b: &'b u32) -> &'a u32 {
| ^^
note: ...so that reference does not outlive borrowed content
--> $DIR/wf-static-method.rs:51:5
|
LL | <()>::static_evil(b)
| ^^^^^^^^^^^^^^^^^^^^
error[E0495]: cannot infer an appropriate lifetime for lifetime parameter `'b` due to conflicting requirements
--> $DIR/wf-static-method.rs:57:5
|
LL | <IndirectEvil>::static_evil(b)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
note: first, the lifetime cannot outlive the lifetime `'b` as defined here...
--> $DIR/wf-static-method.rs:56:22
|
LL | fn indirect_evil<'a, 'b>(b: &'b u32) -> &'a u32 {
| ^^
note: ...so that reference does not outlive borrowed content
--> $DIR/wf-static-method.rs:57:33
|
LL | <IndirectEvil>::static_evil(b)
| ^
note: but, the lifetime must be valid for the lifetime `'a` as defined here...
--> $DIR/wf-static-method.rs:56:18
|
LL | fn indirect_evil<'a, 'b>(b: &'b u32) -> &'a u32 {
| ^^
note: ...so that reference does not outlive borrowed content
--> $DIR/wf-static-method.rs:57:5
|
LL | <IndirectEvil>::static_evil(b)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error[E0495]: cannot infer an appropriate lifetime for lifetime parameter `'b` due to conflicting requirements
--> $DIR/wf-static-method.rs:63:5
|
LL | <Evil>::inherent_evil(b)
| ^^^^^^^^^^^^^^^^^^^^^
|
note: first, the lifetime cannot outlive the lifetime `'b` as defined here...
--> $DIR/wf-static-method.rs:62:22
|
LL | fn inherent_evil<'a, 'b>(b: &'b u32) -> &'a u32 {
| ^^
note: ...so that reference does not outlive borrowed content
--> $DIR/wf-static-method.rs:63:27
|
LL | <Evil>::inherent_evil(b)
| ^
note: but, the lifetime must be valid for the lifetime `'a` as defined here...
--> $DIR/wf-static-method.rs:62:18
|
LL | fn inherent_evil<'a, 'b>(b: &'b u32) -> &'a u32 {
| ^^
note: ...so that reference does not outlive borrowed content
--> $DIR/wf-static-method.rs:63:5
|
LL | <Evil>::inherent_evil(b)
| ^^^^^^^^^^^^^^^^^^^^^^^^
error: aborting due to 6 previous errors
Some errors have detailed explanations: E0312, E0478, E0495.
For more information about an error, try `rustc --explain E0312`.
|