fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #71868 - Mark-Simulacrum:stable-1.43.1, r=pietroalbini8d69840ab92

1.43.1
18.3 KiB513 linesraw
1error[E0225]: only auto traits can be used as additional traits in a trait object
2  --> $DIR/trait-alias-no-extra-traits.rs:16:22
3   |
4LL | trait _0 = ObjA;
5   |            ---- first non-auto trait
6...
7LL | type _T00 = dyn _0 + ObjB;
8   |                 --   ^^^^
9   |                 |    |
10   |                 |    additional non-auto trait
11   |                 |    trait alias used in trait object type (additional use)
12   |                 trait alias used in trait object type (first use)
13
14error[E0225]: only auto traits can be used as additional traits in a trait object
15  --> $DIR/trait-alias-no-extra-traits.rs:19:24
16   |
17LL | trait _0 = ObjA;
18   |            ---- additional non-auto trait
19...
20LL | type _T01 = dyn ObjB + _0;
21   |                 ----   ^^ trait alias used in trait object type (additional use)
22   |                 |
23   |                 first non-auto trait
24   |                 trait alias used in trait object type (first use)
25
26error[E0225]: only auto traits can be used as additional traits in a trait object
27  --> $DIR/trait-alias-no-extra-traits.rs:22:24
28   |
29LL | trait _0 = ObjA;
30   |            ---- additional non-auto trait
31LL | trait _1 = _0;
32   |            -- referenced here (additional use)
33...
34LL | type _T02 = dyn ObjB + _1;
35   |                 ----   ^^ trait alias used in trait object type (additional use)
36   |                 |
37   |                 first non-auto trait
38   |                 trait alias used in trait object type (first use)
39
40error[E0225]: only auto traits can be used as additional traits in a trait object
41  --> $DIR/trait-alias-no-extra-traits.rs:25:22
42   |
43LL | trait _0 = ObjA;
44   |            ---- first non-auto trait
45LL | trait _1 = _0;
46   |            -- referenced here (first use)
47...
48LL | type _T03 = dyn _1 + ObjB;
49   |                 --   ^^^^
50   |                 |    |
51   |                 |    additional non-auto trait
52   |                 |    trait alias used in trait object type (additional use)
53   |                 trait alias used in trait object type (first use)
54
55error[E0225]: only auto traits can be used as additional traits in a trait object
56  --> $DIR/trait-alias-no-extra-traits.rs:34:22
57   |
58LL | trait _2 = ObjB;
59   |            ----
60   |            |
61   |            additional non-auto trait
62   |            first non-auto trait
63LL | trait _3 = _2;
64   |            -- referenced here (additional use)
65...
66LL | type _T10 = dyn _2 + _3;
67   |                 --   ^^ trait alias used in trait object type (additional use)
68   |                 |
69   |                 trait alias used in trait object type (first use)
70
71error[E0225]: only auto traits can be used as additional traits in a trait object
72  --> $DIR/trait-alias-no-extra-traits.rs:37:22
73   |
74LL | trait _2 = ObjB;
75   |            ----
76   |            |
77   |            additional non-auto trait
78   |            first non-auto trait
79LL | trait _3 = _2;
80   |            -- referenced here (first use)
81...
82LL | type _T11 = dyn _3 + _2;
83   |                 --   ^^ trait alias used in trait object type (additional use)
84   |                 |
85   |                 trait alias used in trait object type (first use)
86
87error[E0225]: only auto traits can be used as additional traits in a trait object
88  --> $DIR/trait-alias-no-extra-traits.rs:40:22
89   |
90LL | trait _2 = ObjB;
91   |            ----
92   |            |
93   |            additional non-auto trait
94   |            first non-auto trait
95LL | trait _3 = _2;
96   |            -- referenced here (additional use)
97LL | trait _4 = _3;
98   |            -- referenced here (additional use)
99...
100LL | type _T12 = dyn _2 + _4;
101   |                 --   ^^ trait alias used in trait object type (additional use)
102   |                 |
103   |                 trait alias used in trait object type (first use)
104
105error[E0225]: only auto traits can be used as additional traits in a trait object
106  --> $DIR/trait-alias-no-extra-traits.rs:43:22
107   |
108LL | trait _2 = ObjB;
109   |            ----
110   |            |
111   |            additional non-auto trait
112   |            first non-auto trait
113LL | trait _3 = _2;
114   |            -- referenced here (first use)
115LL | trait _4 = _3;
116   |            -- referenced here (first use)
117...
118LL | type _T13 = dyn _4 + _2;
119   |                 --   ^^ trait alias used in trait object type (additional use)
120   |                 |
121   |                 trait alias used in trait object type (first use)
122
123error[E0225]: only auto traits can be used as additional traits in a trait object
124  --> $DIR/trait-alias-no-extra-traits.rs:50:22
125   |
126LL | trait _0 = ObjA;
127   |            ---- additional non-auto trait
128LL | trait _1 = _0;
129   |            -- referenced here (additional use)
130...
131LL | trait _5 = Sync + ObjB + Send;
132   |                   ---- first non-auto trait
133LL | 
134LL | type _T20 = dyn _5 + _1;
135   |                 --   ^^ trait alias used in trait object type (additional use)
136   |                 |
137   |                 trait alias used in trait object type (first use)
138
139error[E0225]: only auto traits can be used as additional traits in a trait object
140  --> $DIR/trait-alias-no-extra-traits.rs:53:22
141   |
142LL | trait _0 = ObjA;
143   |            ---- first non-auto trait
144LL | trait _1 = _0;
145   |            -- referenced here (first use)
146...
147LL | trait _5 = Sync + ObjB + Send;
148   |                   ---- additional non-auto trait
149...
150LL | type _T21 = dyn _1 + _5;
151   |                 --   ^^ trait alias used in trait object type (additional use)
152   |                 |
153   |                 trait alias used in trait object type (first use)
154
155error[E0225]: only auto traits can be used as additional traits in a trait object
156  --> $DIR/trait-alias-no-extra-traits.rs:56:22
157   |
158LL | trait _5 = Sync + ObjB + Send;
159   |                   ---- first non-auto trait
160...
161LL | type _T22 = dyn _5 + ObjA;
162   |                 --   ^^^^
163   |                 |    |
164   |                 |    additional non-auto trait
165   |                 |    trait alias used in trait object type (additional use)
166   |                 trait alias used in trait object type (first use)
167
168error[E0225]: only auto traits can be used as additional traits in a trait object
169  --> $DIR/trait-alias-no-extra-traits.rs:59:24
170   |
171LL | trait _5 = Sync + ObjB + Send;
172   |                   ---- additional non-auto trait
173...
174LL | type _T23 = dyn ObjA + _5;
175   |                 ----   ^^ trait alias used in trait object type (additional use)
176   |                 |
177   |                 first non-auto trait
178   |                 trait alias used in trait object type (first use)
179
180error[E0225]: only auto traits can be used as additional traits in a trait object
181  --> $DIR/trait-alias-no-extra-traits.rs:62:29
182   |
183LL | trait _0 = ObjA;
184   |            ---- additional non-auto trait
185LL | trait _1 = _0;
186   |            -- referenced here (additional use)
187...
188LL | trait _5 = Sync + ObjB + Send;
189   |                   ---- first non-auto trait
190...
191LL | type _T24 = dyn Send + _5 + _1 + Sync;
192   |                        --   ^^ trait alias used in trait object type (additional use)
193   |                        |
194   |                        trait alias used in trait object type (first use)
195
196error[E0225]: only auto traits can be used as additional traits in a trait object
197  --> $DIR/trait-alias-no-extra-traits.rs:65:29
198   |
199LL | trait _0 = ObjA;
200   |            ---- first non-auto trait
201LL | trait _1 = _0;
202   |            -- referenced here (first use)
203...
204LL | trait _5 = Sync + ObjB + Send;
205   |                   ---- additional non-auto trait
206...
207LL | type _T25 = dyn _1 + Sync + _5 + Send;
208   |                 --          ^^ trait alias used in trait object type (additional use)
209   |                 |
210   |                 trait alias used in trait object type (first use)
211
212error[E0225]: only auto traits can be used as additional traits in a trait object
213  --> $DIR/trait-alias-no-extra-traits.rs:68:36
214   |
215LL | trait _5 = Sync + ObjB + Send;
216   |                   ---- first non-auto trait
217...
218LL | type _T26 = dyn Sync + Send + _5 + ObjA;
219   |                               --   ^^^^
220   |                               |    |
221   |                               |    additional non-auto trait
222   |                               |    trait alias used in trait object type (additional use)
223   |                               trait alias used in trait object type (first use)
224
225error[E0225]: only auto traits can be used as additional traits in a trait object
226  --> $DIR/trait-alias-no-extra-traits.rs:71:38
227   |
228LL | trait _5 = Sync + ObjB + Send;
229   |                   ---- additional non-auto trait
230...
231LL | type _T27 = dyn Send + Sync + ObjA + _5;
232   |                               ----   ^^ trait alias used in trait object type (additional use)
233   |                               |
234   |                               first non-auto trait
235   |                               trait alias used in trait object type (first use)
236
237error[E0225]: only auto traits can be used as additional traits in a trait object
238  --> $DIR/trait-alias-no-extra-traits.rs:80:17
239   |
240LL | trait _0 = ObjA;
241   |            ---- first non-auto trait
242LL | trait _1 = _0;
243   |            -- referenced here (first use)
244...
245LL | trait _5 = Sync + ObjB + Send;
246   |                   ---- additional non-auto trait
247...
248LL | trait _6 = _1 + _5;
249   |            --   -- referenced here (additional use)
250   |            |
251   |            referenced here (first use)
252...
253LL | type _T30 = dyn _6;
254   |                 ^^
255   |                 |
256   |                 trait alias used in trait object type (additional use)
257   |                 trait alias used in trait object type (first use)
258
259error[E0225]: only auto traits can be used as additional traits in a trait object
260  --> $DIR/trait-alias-no-extra-traits.rs:83:17
261   |
262LL | trait _0 = ObjA;
263   |            ---- first non-auto trait
264LL | trait _1 = _0;
265   |            -- referenced here (first use)
266...
267LL | trait _5 = Sync + ObjB + Send;
268   |                   ---- additional non-auto trait
269...
270LL | trait _6 = _1 + _5;
271   |            --   -- referenced here (additional use)
272   |            |
273   |            referenced here (first use)
274...
275LL | type _T31 = dyn _6 + Send;
276   |                 ^^
277   |                 |
278   |                 trait alias used in trait object type (additional use)
279   |                 trait alias used in trait object type (first use)
280
281error[E0225]: only auto traits can be used as additional traits in a trait object
282  --> $DIR/trait-alias-no-extra-traits.rs:86:24
283   |
284LL | trait _0 = ObjA;
285   |            ---- first non-auto trait
286LL | trait _1 = _0;
287   |            -- referenced here (first use)
288...
289LL | trait _5 = Sync + ObjB + Send;
290   |                   ---- additional non-auto trait
291...
292LL | trait _6 = _1 + _5;
293   |            --   -- referenced here (additional use)
294   |            |
295   |            referenced here (first use)
296...
297LL | type _T32 = dyn Send + _6;
298   |                        ^^
299   |                        |
300   |                        trait alias used in trait object type (additional use)
301   |                        trait alias used in trait object type (first use)
302
303error[E0225]: only auto traits can be used as additional traits in a trait object
304  --> $DIR/trait-alias-no-extra-traits.rs:89:17
305   |
306LL | trait _0 = ObjA;
307   |            ---- first non-auto trait
308LL | trait _1 = _0;
309   |            -- referenced here (first use)
310...
311LL | trait _5 = Sync + ObjB + Send;
312   |                   ---- additional non-auto trait
313...
314LL | trait _6 = _1 + _5;
315   |            --   -- referenced here (additional use)
316   |            |
317   |            referenced here (first use)
318LL | trait _7 = _6;
319   |            --
320   |            |
321   |            referenced here (additional use)
322   |            referenced here (first use)
323LL | trait _8 = _7;
324   |            --
325   |            |
326   |            referenced here (additional use)
327   |            referenced here (first use)
328...
329LL | type _T33 = dyn _8;
330   |                 ^^
331   |                 |
332   |                 trait alias used in trait object type (additional use)
333   |                 trait alias used in trait object type (first use)
334
335error[E0225]: only auto traits can be used as additional traits in a trait object
336  --> $DIR/trait-alias-no-extra-traits.rs:92:17
337   |
338LL | trait _0 = ObjA;
339   |            ---- first non-auto trait
340LL | trait _1 = _0;
341   |            -- referenced here (first use)
342...
343LL | trait _5 = Sync + ObjB + Send;
344   |                   ---- additional non-auto trait
345...
346LL | trait _6 = _1 + _5;
347   |            --   -- referenced here (additional use)
348   |            |
349   |            referenced here (first use)
350LL | trait _7 = _6;
351   |            --
352   |            |
353   |            referenced here (additional use)
354   |            referenced here (first use)
355LL | trait _8 = _7;
356   |            --
357   |            |
358   |            referenced here (additional use)
359   |            referenced here (first use)
360...
361LL | type _T34 = dyn _8 + Send;
362   |                 ^^
363   |                 |
364   |                 trait alias used in trait object type (additional use)
365   |                 trait alias used in trait object type (first use)
366
367error[E0225]: only auto traits can be used as additional traits in a trait object
368  --> $DIR/trait-alias-no-extra-traits.rs:95:24
369   |
370LL | trait _0 = ObjA;
371   |            ---- first non-auto trait
372LL | trait _1 = _0;
373   |            -- referenced here (first use)
374...
375LL | trait _5 = Sync + ObjB + Send;
376   |                   ---- additional non-auto trait
377...
378LL | trait _6 = _1 + _5;
379   |            --   -- referenced here (additional use)
380   |            |
381   |            referenced here (first use)
382LL | trait _7 = _6;
383   |            --
384   |            |
385   |            referenced here (additional use)
386   |            referenced here (first use)
387LL | trait _8 = _7;
388   |            --
389   |            |
390   |            referenced here (additional use)
391   |            referenced here (first use)
392...
393LL | type _T35 = dyn Send + _8;
394   |                        ^^
395   |                        |
396   |                        trait alias used in trait object type (additional use)
397   |                        trait alias used in trait object type (first use)
398
399error[E0225]: only auto traits can be used as additional traits in a trait object
400  --> $DIR/trait-alias-no-extra-traits.rs:103:23
401   |
402LL | trait _5 = Sync + ObjB + Send;
403   |                   ---- first non-auto trait
404...
405LL | trait _9 = _5 + Sync;
406   |            -- referenced here (first use)
407LL | trait _10 = Unpin + _9;
408   |                     -- referenced here (first use)
409LL | 
410LL | type _T40 = dyn _10 + ObjA;
411   |                 ---   ^^^^
412   |                 |     |
413   |                 |     additional non-auto trait
414   |                 |     trait alias used in trait object type (additional use)
415   |                 trait alias used in trait object type (first use)
416
417error[E0225]: only auto traits can be used as additional traits in a trait object
418  --> $DIR/trait-alias-no-extra-traits.rs:106:24
419   |
420LL | trait _5 = Sync + ObjB + Send;
421   |                   ---- additional non-auto trait
422...
423LL | trait _9 = _5 + Sync;
424   |            -- referenced here (additional use)
425LL | trait _10 = Unpin + _9;
426   |                     -- referenced here (additional use)
427...
428LL | type _T41 = dyn ObjA + _10;
429   |                 ----   ^^^ trait alias used in trait object type (additional use)
430   |                 |
431   |                 first non-auto trait
432   |                 trait alias used in trait object type (first use)
433
434error[E0225]: only auto traits can be used as additional traits in a trait object
435  --> $DIR/trait-alias-no-extra-traits.rs:109:23
436   |
437LL | trait _0 = ObjA;
438   |            ---- additional non-auto trait
439LL | trait _1 = _0;
440   |            -- referenced here (additional use)
441...
442LL | trait _5 = Sync + ObjB + Send;
443   |                   ---- first non-auto trait
444...
445LL | trait _9 = _5 + Sync;
446   |            -- referenced here (first use)
447LL | trait _10 = Unpin + _9;
448   |                     -- referenced here (first use)
449...
450LL | type _T42 = dyn _10 + _1;
451   |                 ---   ^^ trait alias used in trait object type (additional use)
452   |                 |
453   |                 trait alias used in trait object type (first use)
454
455error[E0225]: only auto traits can be used as additional traits in a trait object
456  --> $DIR/trait-alias-no-extra-traits.rs:112:37
457   |
458LL | trait _5 = Sync + ObjB + Send;
459   |                   ---- first non-auto trait
460...
461LL | trait _9 = _5 + Sync;
462   |            -- referenced here (first use)
463LL | trait _10 = Unpin + _9;
464   |                     -- referenced here (first use)
465...
466LL | type _T43 = dyn Send + _10 + Sync + ObjA;
467   |                        ---          ^^^^
468   |                        |            |
469   |                        |            additional non-auto trait
470   |                        |            trait alias used in trait object type (additional use)
471   |                        trait alias used in trait object type (first use)
472
473error[E0225]: only auto traits can be used as additional traits in a trait object
474  --> $DIR/trait-alias-no-extra-traits.rs:115:24
475   |
476LL | trait _5 = Sync + ObjB + Send;
477   |                   ---- additional non-auto trait
478...
479LL | trait _9 = _5 + Sync;
480   |            -- referenced here (additional use)
481LL | trait _10 = Unpin + _9;
482   |                     -- referenced here (additional use)
483...
484LL | type _T44 = dyn ObjA + _10 + Send + Sync;
485   |                 ----   ^^^ trait alias used in trait object type (additional use)
486   |                 |
487   |                 first non-auto trait
488   |                 trait alias used in trait object type (first use)
489
490error[E0225]: only auto traits can be used as additional traits in a trait object
491  --> $DIR/trait-alias-no-extra-traits.rs:118:37
492   |
493LL | trait _0 = ObjA;
494   |            ---- additional non-auto trait
495LL | trait _1 = _0;
496   |            -- referenced here (additional use)
497...
498LL | trait _5 = Sync + ObjB + Send;
499   |                   ---- first non-auto trait
500...
501LL | trait _9 = _5 + Sync;
502   |            -- referenced here (first use)
503LL | trait _10 = Unpin + _9;
504   |                     -- referenced here (first use)
505...
506LL | type _T45 = dyn Sync + Send + _10 + _1;
507   |                               ---   ^^ trait alias used in trait object type (additional use)
508   |                               |
509   |                               trait alias used in trait object type (first use)
510
511error: aborting due to 28 previous errors
512
513For more information about this error, try `rustc --explain E0225`.