Commit 37ff5d3
committed
Auto merge of rust-lang#59445 - alexreg:ban-multi-trait-objects-via-aliases, r=oli-obk
Ban multi-trait objects via trait aliases
Obviously, multi-trait objects are not normally supported, so they should not be supported via trait aliases.
This has been factored out from the previous PR rust-lang#55994 (see point 1).
r? @Centril
CC @nikomatsakis
------------------
### RELNOTES:
We now allow `dyn Send + fmt::Debug` with equivalent semantics to `dyn fmt::Debug + Send`.
That is, the order of the mentioned traits does not matter wrt. principal/not-principal traits.
This is a small change that might deserve a mention in the blog post because it is a language change but most likely not.
See https://github.com/rust-lang/rust/blob/ce2ee305f9165c037ecddddb5792588a15ff6c37/src/test/ui/traits/wf-trait-object-reverse-order.rs.
// @CentrilFile tree
57 files changed
+2032
-294
lines changed- src
- liballoc
- librustc_mir/borrow_check
- librustc_save_analysis
- librustc_typeck
- check
- method
- librustc
- hir
- map
- query
- traits
- ty
- query
- libsyntax
- test/ui
- associated-types
- bad
- error-codes
- issues
- parser
- traits
- trait-alias
- auxiliary
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
57 files changed
+2032
-294
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
123 | 123 | | |
124 | 124 | | |
125 | 125 | | |
126 | | - | |
| 126 | + | |
127 | 127 | | |
128 | 128 | | |
129 | 129 | | |
130 | 130 | | |
131 | | - | |
| 131 | + | |
132 | 132 | | |
133 | 133 | | |
134 | 134 | | |
| |||
376 | 376 | | |
377 | 377 | | |
378 | 378 | | |
379 | | - | |
| 379 | + | |
380 | 380 | | |
381 | 381 | | |
382 | 382 | | |
| |||
397 | 397 | | |
398 | 398 | | |
399 | 399 | | |
400 | | - | |
| 400 | + | |
401 | 401 | | |
402 | 402 | | |
403 | 403 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
957 | 957 | | |
958 | 958 | | |
959 | 959 | | |
960 | | - | |
| 960 | + | |
961 | 961 | | |
962 | 962 | | |
963 | 963 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2143 | 2143 | | |
2144 | 2144 | | |
2145 | 2145 | | |
2146 | | - | |
| 2146 | + | |
2147 | 2147 | | |
2148 | | - | |
2149 | | - | |
2150 | | - | |
| 2148 | + | |
| 2149 | + | |
| 2150 | + | |
2151 | 2151 | | |
2152 | 2152 | | |
2153 | 2153 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
168 | 168 | | |
169 | 169 | | |
170 | 170 | | |
171 | | - | |
| 171 | + | |
172 | 172 | | |
173 | 173 | | |
174 | 174 | | |
| |||
216 | 216 | | |
217 | 217 | | |
218 | 218 | | |
219 | | - | |
220 | | - | |
221 | | - | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
222 | 222 | | |
223 | 223 | | |
224 | 224 | | |
225 | 225 | | |
226 | 226 | | |
227 | 227 | | |
228 | 228 | | |
229 | | - | |
| 229 | + | |
230 | 230 | | |
231 | 231 | | |
232 | 232 | | |
| |||
237 | 237 | | |
238 | 238 | | |
239 | 239 | | |
240 | | - | |
| 240 | + | |
241 | 241 | | |
242 | 242 | | |
243 | 243 | | |
244 | 244 | | |
245 | 245 | | |
246 | | - | |
247 | | - | |
| 246 | + | |
248 | 247 | | |
249 | 248 | | |
250 | 249 | | |
251 | 250 | | |
252 | | - | |
253 | | - | |
| 251 | + | |
254 | 252 | | |
255 | 253 | | |
256 | 254 | | |
257 | 255 | | |
258 | | - | |
| 256 | + | |
259 | 257 | | |
260 | 258 | | |
261 | 259 | | |
262 | 260 | | |
263 | 261 | | |
264 | 262 | | |
265 | 263 | | |
266 | | - | |
| 264 | + | |
267 | 265 | | |
268 | 266 | | |
269 | | - | |
| 267 | + | |
270 | 268 | | |
271 | 269 | | |
272 | 270 | | |
| |||
276 | 274 | | |
277 | 275 | | |
278 | 276 | | |
279 | | - | |
| 277 | + | |
280 | 278 | | |
281 | 279 | | |
282 | 280 | | |
| |||
300 | 298 | | |
301 | 299 | | |
302 | 300 | | |
303 | | - | |
| 301 | + | |
304 | 302 | | |
305 | 303 | | |
306 | 304 | | |
| |||
309 | 307 | | |
310 | 308 | | |
311 | 309 | | |
312 | | - | |
| 310 | + | |
313 | 311 | | |
314 | 312 | | |
315 | 313 | | |
| |||
338 | 336 | | |
339 | 337 | | |
340 | 338 | | |
341 | | - | |
| 339 | + | |
342 | 340 | | |
343 | 341 | | |
344 | 342 | | |
| |||
375 | 373 | | |
376 | 374 | | |
377 | 375 | | |
378 | | - | |
| 376 | + | |
379 | 377 | | |
380 | 378 | | |
381 | 379 | | |
| |||
401 | 399 | | |
402 | 400 | | |
403 | 401 | | |
404 | | - | |
| 402 | + | |
405 | 403 | | |
406 | 404 | | |
407 | 405 | | |
408 | | - | |
| 406 | + | |
409 | 407 | | |
410 | 408 | | |
411 | 409 | | |
| |||
660 | 658 | | |
661 | 659 | | |
662 | 660 | | |
663 | | - | |
| 661 | + | |
664 | 662 | | |
665 | 663 | | |
666 | 664 | | |
667 | 665 | | |
668 | | - | |
| 666 | + | |
669 | 667 | | |
670 | 668 | | |
671 | 669 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
63 | | - | |
64 | | - | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
65 | 67 | | |
66 | 68 | | |
67 | 69 | | |
| |||
1043 | 1045 | | |
1044 | 1046 | | |
1045 | 1047 | | |
1046 | | - | |
| 1048 | + | |
1047 | 1049 | | |
1048 | 1050 | | |
1049 | 1051 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1772 | 1772 | | |
1773 | 1773 | | |
1774 | 1774 | | |
1775 | | - | |
| 1775 | + | |
| 1776 | + | |
1776 | 1777 | | |
1777 | 1778 | | |
1778 | 1779 | | |
| |||
0 commit comments