Commit f10ddb4
committed
Fix #23241 - duplicate deprecation message for enum member accessed by name
A deprecated enum member accessed by its unqualified name (an anonymous
enum member, a member found via `with`, or an ImportC enumerator) reported
the deprecation twice: once during name resolution and again in getVarExp(),
which already performs the deprecated/disabled checks itself. Skip the
redundant check for enum members in the two name-resolution paths so the
diagnostic is emitted exactly once.1 parent 940287b commit f10ddb4
2 files changed
Lines changed: 33 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2703 | 2703 | | |
2704 | 2704 | | |
2705 | 2705 | | |
2706 | | - | |
| 2706 | + | |
| 2707 | + | |
| 2708 | + | |
2707 | 2709 | | |
2708 | 2710 | | |
2709 | 2711 | | |
| |||
2715 | 2717 | | |
2716 | 2718 | | |
2717 | 2719 | | |
2718 | | - | |
| 2720 | + | |
2719 | 2721 | | |
2720 | 2722 | | |
2721 | 2723 | | |
| |||
16006 | 16008 | | |
16007 | 16009 | | |
16008 | 16010 | | |
16009 | | - | |
16010 | | - | |
16011 | | - | |
16012 | | - | |
16013 | 16011 | | |
16014 | 16012 | | |
| 16013 | + | |
| 16014 | + | |
| 16015 | + | |
16015 | 16016 | | |
16016 | 16017 | | |
| 16018 | + | |
| 16019 | + | |
| 16020 | + | |
| 16021 | + | |
| 16022 | + | |
16017 | 16023 | | |
16018 | 16024 | | |
16019 | 16025 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
0 commit comments