]> git.lizzy.rs Git - rust.git/blob - tests/ui/suggestions/missing-lifetime-specifier.stderr
Rollup merge of #107477 - GuillaumeGomez:css-var, r=notriddle
[rust.git] / tests / ui / suggestions / missing-lifetime-specifier.stderr
1 error[E0106]: missing lifetime specifiers
2   --> $DIR/missing-lifetime-specifier.rs:18:44
3    |
4 LL |     static a: RefCell<HashMap<i32, Vec<Vec<Foo>>>> = RefCell::new(HashMap::new());
5    |                                            ^^^ expected 2 lifetime parameters
6    |
7    = help: this function's return type contains a borrowed value, but there is no value for it to be borrowed from
8 help: consider using the `'static` lifetime
9    |
10 LL |     static a: RefCell<HashMap<i32, Vec<Vec<Foo<'static, 'static>>>>> = RefCell::new(HashMap::new());
11    |                                               ++++++++++++++++++
12
13 error[E0106]: missing lifetime specifiers
14   --> $DIR/missing-lifetime-specifier.rs:18:44
15    |
16 LL | / thread_local! {
17 LL | |     static a: RefCell<HashMap<i32, Vec<Vec<Foo>>>> = RefCell::new(HashMap::new());
18    | |                                            ^^^ expected 2 lifetime parameters
19 LL | |
20 LL | |
21 LL | | }
22    | |_-
23    |
24    = help: this function's return type contains a borrowed value, but the signature does not say which one of `init`'s 3 lifetimes it is borrowed from
25
26 error[E0106]: missing lifetime specifiers
27   --> $DIR/missing-lifetime-specifier.rs:23:44
28    |
29 LL |     static b: RefCell<HashMap<i32, Vec<Vec<&Bar>>>> = RefCell::new(HashMap::new());
30    |                                            ^^^^ expected 2 lifetime parameters
31    |                                            |
32    |                                            expected named lifetime parameter
33    |
34    = help: this function's return type contains a borrowed value, but there is no value for it to be borrowed from
35 help: consider using the `'static` lifetime
36    |
37 LL |     static b: RefCell<HashMap<i32, Vec<Vec<&'static Bar<'static, 'static>>>>> = RefCell::new(HashMap::new());
38    |                                             +++++++    ++++++++++++++++++
39
40 error[E0106]: missing lifetime specifiers
41   --> $DIR/missing-lifetime-specifier.rs:23:44
42    |
43 LL | / thread_local! {
44 LL | |     static b: RefCell<HashMap<i32, Vec<Vec<&Bar>>>> = RefCell::new(HashMap::new());
45    | |                                            ^^^^ expected 2 lifetime parameters
46    | |                                            |
47    | |                                            expected named lifetime parameter
48 LL | |
49 LL | |
50 LL | | }
51    | |_-
52    |
53    = help: this function's return type contains a borrowed value, but the signature does not say which one of `init`'s 4 lifetimes it is borrowed from
54
55 error[E0106]: missing lifetime specifiers
56   --> $DIR/missing-lifetime-specifier.rs:28:47
57    |
58 LL |     static c: RefCell<HashMap<i32, Vec<Vec<Qux<i32>>>>> = RefCell::new(HashMap::new());
59    |                                               ^ expected 2 lifetime parameters
60    |
61    = help: this function's return type contains a borrowed value, but there is no value for it to be borrowed from
62 help: consider using the `'static` lifetime
63    |
64 LL |     static c: RefCell<HashMap<i32, Vec<Vec<Qux<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
65    |                                                +++++++++++++++++
66
67 error[E0106]: missing lifetime specifiers
68   --> $DIR/missing-lifetime-specifier.rs:28:47
69    |
70 LL | / thread_local! {
71 LL | |     static c: RefCell<HashMap<i32, Vec<Vec<Qux<i32>>>>> = RefCell::new(HashMap::new());
72    | |                                               ^ expected 2 lifetime parameters
73 LL | |
74 LL | |
75 LL | | }
76    | |_-
77    |
78    = help: this function's return type contains a borrowed value, but the signature does not say which one of `init`'s 3 lifetimes it is borrowed from
79
80 error[E0106]: missing lifetime specifiers
81   --> $DIR/missing-lifetime-specifier.rs:33:44
82    |
83 LL |     static d: RefCell<HashMap<i32, Vec<Vec<&Tar<i32>>>>> = RefCell::new(HashMap::new());
84    |                                            ^   ^ expected 2 lifetime parameters
85    |                                            |
86    |                                            expected named lifetime parameter
87    |
88    = help: this function's return type contains a borrowed value, but there is no value for it to be borrowed from
89 help: consider using the `'static` lifetime
90    |
91 LL |     static d: RefCell<HashMap<i32, Vec<Vec<&'static Tar<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
92    |                                             +++++++     +++++++++++++++++
93
94 error[E0106]: missing lifetime specifiers
95   --> $DIR/missing-lifetime-specifier.rs:33:44
96    |
97 LL | / thread_local! {
98 LL | |     static d: RefCell<HashMap<i32, Vec<Vec<&Tar<i32>>>>> = RefCell::new(HashMap::new());
99    | |                                            ^   ^ expected 2 lifetime parameters
100    | |                                            |
101    | |                                            expected named lifetime parameter
102 LL | |
103 LL | |
104 LL | | }
105    | |_-
106    |
107    = help: this function's return type contains a borrowed value, but the signature does not say which one of `init`'s 4 lifetimes it is borrowed from
108
109 error[E0106]: missing lifetime specifier
110   --> $DIR/missing-lifetime-specifier.rs:47:44
111    |
112 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
113    |                                            ^ expected named lifetime parameter
114    |
115    = help: this function's return type contains a borrowed value, but there is no value for it to be borrowed from
116 help: consider using the `'static` lifetime
117    |
118 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&'static Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
119    |                                             +++++++
120
121 error[E0106]: missing lifetime specifier
122   --> $DIR/missing-lifetime-specifier.rs:47:44
123    |
124 LL | / thread_local! {
125 LL | |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
126    | |                                            ^ expected named lifetime parameter
127 LL | |
128 LL | |
129 ...  |
130 LL | |
131 LL | | }
132    | |_-
133    |
134    = help: this function's return type contains a borrowed value, but the signature does not say which one of `init`'s 3 lifetimes it is borrowed from
135
136 error[E0107]: this union takes 2 lifetime arguments but 1 lifetime argument was supplied
137   --> $DIR/missing-lifetime-specifier.rs:39:44
138    |
139 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, i32>>>>> = RefCell::new(HashMap::new());
140    |                                            ^^^ ------- supplied 1 lifetime argument
141    |                                            |
142    |                                            expected 2 lifetime arguments
143    |
144 note: union defined here, with 2 lifetime parameters: `'t`, `'k`
145   --> $DIR/missing-lifetime-specifier.rs:11:11
146    |
147 LL | pub union Qux<'t, 'k, I> {
148    |           ^^^ --  --
149 help: add missing lifetime argument
150    |
151 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
152    |                                                       +++++++++
153
154 error[E0107]: this union takes 2 lifetime arguments but 1 lifetime argument was supplied
155   --> $DIR/missing-lifetime-specifier.rs:39:44
156    |
157 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, i32>>>>> = RefCell::new(HashMap::new());
158    |                                            ^^^ ------- supplied 1 lifetime argument
159    |                                            |
160    |                                            expected 2 lifetime arguments
161    |
162 note: union defined here, with 2 lifetime parameters: `'t`, `'k`
163   --> $DIR/missing-lifetime-specifier.rs:11:11
164    |
165 LL | pub union Qux<'t, 'k, I> {
166    |           ^^^ --  --
167 help: add missing lifetime argument
168    |
169 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
170    |                                                       +++++++++
171
172 error[E0107]: this union takes 2 lifetime arguments but 1 lifetime argument was supplied
173   --> $DIR/missing-lifetime-specifier.rs:39:44
174    |
175 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, i32>>>>> = RefCell::new(HashMap::new());
176    |                                            ^^^ ------- supplied 1 lifetime argument
177    |                                            |
178    |                                            expected 2 lifetime arguments
179    |
180 note: union defined here, with 2 lifetime parameters: `'t`, `'k`
181   --> $DIR/missing-lifetime-specifier.rs:11:11
182    |
183 LL | pub union Qux<'t, 'k, I> {
184    |           ^^^ --  --
185 help: add missing lifetime argument
186    |
187 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
188    |                                                       +++++++++
189
190 error[E0107]: this union takes 2 lifetime arguments but 1 lifetime argument was supplied
191   --> $DIR/missing-lifetime-specifier.rs:39:44
192    |
193 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, i32>>>>> = RefCell::new(HashMap::new());
194    |                                            ^^^ ------- supplied 1 lifetime argument
195    |                                            |
196    |                                            expected 2 lifetime arguments
197    |
198 note: union defined here, with 2 lifetime parameters: `'t`, `'k`
199   --> $DIR/missing-lifetime-specifier.rs:11:11
200    |
201 LL | pub union Qux<'t, 'k, I> {
202    |           ^^^ --  --
203 help: add missing lifetime argument
204    |
205 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
206    |                                                       +++++++++
207
208 error[E0107]: this union takes 2 lifetime arguments but 1 lifetime argument was supplied
209   --> $DIR/missing-lifetime-specifier.rs:39:44
210    |
211 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, i32>>>>> = RefCell::new(HashMap::new());
212    |                                            ^^^ ------- supplied 1 lifetime argument
213    |                                            |
214    |                                            expected 2 lifetime arguments
215    |
216 note: union defined here, with 2 lifetime parameters: `'t`, `'k`
217   --> $DIR/missing-lifetime-specifier.rs:11:11
218    |
219 LL | pub union Qux<'t, 'k, I> {
220    |           ^^^ --  --
221 help: add missing lifetime argument
222    |
223 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
224    |                                                       +++++++++
225
226 error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
227   --> $DIR/missing-lifetime-specifier.rs:47:45
228    |
229 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
230    |                                             ^^^ ------- supplied 1 lifetime argument
231    |                                             |
232    |                                             expected 2 lifetime arguments
233    |
234 note: trait defined here, with 2 lifetime parameters: `'t`, `'k`
235   --> $DIR/missing-lifetime-specifier.rs:15:7
236    |
237 LL | trait Tar<'t, 'k, I> {}
238    |       ^^^ --  --
239 help: add missing lifetime argument
240    |
241 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
242    |                                                        +++++++++
243
244 error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
245   --> $DIR/missing-lifetime-specifier.rs:47:45
246    |
247 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
248    |                                             ^^^ ------- supplied 1 lifetime argument
249    |                                             |
250    |                                             expected 2 lifetime arguments
251    |
252 note: trait defined here, with 2 lifetime parameters: `'t`, `'k`
253   --> $DIR/missing-lifetime-specifier.rs:15:7
254    |
255 LL | trait Tar<'t, 'k, I> {}
256    |       ^^^ --  --
257 help: add missing lifetime argument
258    |
259 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
260    |                                                        +++++++++
261
262 error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
263   --> $DIR/missing-lifetime-specifier.rs:47:45
264    |
265 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
266    |                                             ^^^ ------- supplied 1 lifetime argument
267    |                                             |
268    |                                             expected 2 lifetime arguments
269    |
270 note: trait defined here, with 2 lifetime parameters: `'t`, `'k`
271   --> $DIR/missing-lifetime-specifier.rs:15:7
272    |
273 LL | trait Tar<'t, 'k, I> {}
274    |       ^^^ --  --
275 help: add missing lifetime argument
276    |
277 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
278    |                                                        +++++++++
279
280 error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
281   --> $DIR/missing-lifetime-specifier.rs:47:45
282    |
283 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
284    |                                             ^^^ ------- supplied 1 lifetime argument
285    |                                             |
286    |                                             expected 2 lifetime arguments
287    |
288 note: trait defined here, with 2 lifetime parameters: `'t`, `'k`
289   --> $DIR/missing-lifetime-specifier.rs:15:7
290    |
291 LL | trait Tar<'t, 'k, I> {}
292    |       ^^^ --  --
293 help: add missing lifetime argument
294    |
295 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
296    |                                                        +++++++++
297
298 error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
299   --> $DIR/missing-lifetime-specifier.rs:47:45
300    |
301 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
302    |                                             ^^^ ------- supplied 1 lifetime argument
303    |                                             |
304    |                                             expected 2 lifetime arguments
305    |
306 note: trait defined here, with 2 lifetime parameters: `'t`, `'k`
307   --> $DIR/missing-lifetime-specifier.rs:15:7
308    |
309 LL | trait Tar<'t, 'k, I> {}
310    |       ^^^ --  --
311 help: add missing lifetime argument
312    |
313 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
314    |                                                        +++++++++
315
316 error: aborting due to 20 previous errors
317
318 Some errors have detailed explanations: E0106, E0107.
319 For more information about an error, try `rustc --explain E0106`.