Bug 23824 – No warnings printed for aliases to deprecated enum members

Status
NEW
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2023-04-05T05:59:45Z
Last change time
2024-12-13T19:28:11Z
Keywords
accepts-invalid
Assigned to
No Owner
Creator
elpenguino+D
Moved to GitHub: dmd#18162 →

Comments

Comment #0 by elpenguino+D — 2023-04-05T05:59:45Z
This code produces no deprecation warnings: ``` struct S { deprecated enum value1 = 5; } alias shouldWarn = S.value1; ``` The shouldWarn alias should produce a warning. Referencing the alias does produce a deprecation warning, however. Aliases to deprecated non-member enums also produce warnings as expected.
Comment #1 by robert.schadek — 2024-12-13T19:28:11Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/18162 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB