Commit c2bfb9c
committed
Auto merge of #24894 - bguiz:diagnostic-E0267, r=alexcrichton
This error indicates that a constant references itself.
All constants need to resolve to a value in an acyclic manner.
For example, neither of the following can be sensibly compiled:
```
const X: u32 = X;
```
```
const X: u32 = Y;
const Y: u32 = X;
```1 file changed
+16
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
355 | 355 | | |
356 | 356 | | |
357 | 357 | | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
358 | 374 | | |
359 | 375 | | |
360 | 376 | | |
| |||
500 | 516 | | |
501 | 517 | | |
502 | 518 | | |
503 | | - | |
504 | 519 | | |
505 | 520 | | |
506 | 521 | | |
| |||
0 commit comments