This repository was archived by the owner on May 28, 2025. It is now read-only.
Commit 632f804
committed
Auto merge of rust-lang#13750 - lowr:fix/rpit-in-projection, r=flodiebold
fix: normalize projection after discarding free `BoundVar`s in RPIT
Fixes rust-lang#13307
When we lower the return type of a function, it may contain free `BoundVar`s in `OpaqueType`'s substitution, which would cause panic during canonicalization as part of projection normalization. Those `BoundVar`s are irrelevant in this context and will be discarded, and we should defer projection normalization until then.2 files changed
+34
-20
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
503 | 503 | | |
504 | 504 | | |
505 | 505 | | |
506 | | - | |
| 506 | + | |
507 | 507 | | |
508 | 508 | | |
509 | 509 | | |
| |||
582 | 582 | | |
583 | 583 | | |
584 | 584 | | |
585 | | - | |
586 | | - | |
587 | 585 | | |
588 | | - | |
| 586 | + | |
| 587 | + | |
| 588 | + | |
| 589 | + | |
| 590 | + | |
| 591 | + | |
589 | 592 | | |
590 | 593 | | |
591 | | - | |
592 | | - | |
| 594 | + | |
| 595 | + | |
593 | 596 | | |
594 | 597 | | |
595 | 598 | | |
| |||
610 | 613 | | |
611 | 614 | | |
612 | 615 | | |
613 | | - | |
| 616 | + | |
614 | 617 | | |
615 | 618 | | |
616 | 619 | | |
617 | 620 | | |
618 | 621 | | |
619 | | - | |
620 | | - | |
| 622 | + | |
| 623 | + | |
| 624 | + | |
| 625 | + | |
| 626 | + | |
| 627 | + | |
621 | 628 | | |
622 | 629 | | |
623 | 630 | | |
| |||
652 | 659 | | |
653 | 660 | | |
654 | 661 | | |
655 | | - | |
656 | | - | |
657 | | - | |
658 | | - | |
659 | | - | |
| 662 | + | |
660 | 663 | | |
661 | | - | |
662 | | - | |
| 664 | + | |
663 | 665 | | |
664 | 666 | | |
665 | 667 | | |
666 | 668 | | |
667 | 669 | | |
668 | | - | |
669 | | - | |
670 | | - | |
671 | | - | |
672 | 670 | | |
673 | 671 | | |
674 | 672 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1388 | 1388 | | |
1389 | 1389 | | |
1390 | 1390 | | |
| 1391 | + | |
| 1392 | + | |
| 1393 | + | |
| 1394 | + | |
| 1395 | + | |
| 1396 | + | |
| 1397 | + | |
| 1398 | + | |
| 1399 | + | |
| 1400 | + | |
| 1401 | + | |
| 1402 | + | |
| 1403 | + | |
| 1404 | + | |
| 1405 | + | |
| 1406 | + | |
1391 | 1407 | | |
1392 | 1408 | | |
1393 | 1409 | | |
| |||
0 commit comments