Commit e4f60a4
committed
Ensure names used in signatures are stable
Signatures should not change before erasure, but some phases before
erasure can change the owner of a definition, which can change their
full name and therefore any signature which refers to these names.
This commit fixes this by ensuring we always use the initial symbol to
compute signatures before erasure. The check for
signature consistency in TreeChecker was also improved as it wasn't able
to catch this issue before due to signature caching hiding the issue.1 parent 31879e5 commit e4f60a4
File tree
4 files changed
+35
-8
lines changed- compiler/src/dotty/tools/dotc
- core
- transform
- tests/pos
4 files changed
+35
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
605 | 605 | | |
606 | 606 | | |
607 | 607 | | |
608 | | - | |
| 608 | + | |
| 609 | + | |
| 610 | + | |
| 611 | + | |
| 612 | + | |
| 613 | + | |
| 614 | + | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
609 | 618 | | |
610 | 619 | | |
611 | 620 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1900 | 1900 | | |
1901 | 1901 | | |
1902 | 1902 | | |
1903 | | - | |
| 1903 | + | |
1904 | 1904 | | |
1905 | 1905 | | |
1906 | 1906 | | |
| |||
3064 | 3064 | | |
3065 | 3065 | | |
3066 | 3066 | | |
3067 | | - | |
| 3067 | + | |
3068 | 3068 | | |
3069 | 3069 | | |
3070 | 3070 | | |
| |||
3357 | 3357 | | |
3358 | 3358 | | |
3359 | 3359 | | |
3360 | | - | |
| 3360 | + | |
3361 | 3361 | | |
3362 | 3362 | | |
3363 | 3363 | | |
| |||
3592 | 3592 | | |
3593 | 3593 | | |
3594 | 3594 | | |
3595 | | - | |
| 3595 | + | |
3596 | 3596 | | |
3597 | 3597 | | |
3598 | 3598 | | |
| |||
Lines changed: 11 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
92 | 92 | | |
93 | 93 | | |
94 | 94 | | |
95 | | - | |
96 | | - | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
97 | 104 | | |
98 | 105 | | |
99 | 106 | | |
100 | | - | |
| 107 | + | |
| 108 | + | |
101 | 109 | | |
102 | 110 | | |
103 | 111 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
0 commit comments