Bug 6760 – Disallow disabled overrides

Status
RESOLVED
Resolution
WORKSFORME
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2011-10-02T13:28:00Z
Last change time
2017-08-07T13:15:20Z
Keywords
accepts-invalid
Assigned to
nobody
Creator
timon.gehr

Comments

Comment #0 by timon.gehr — 2011-10-02T13:28:24Z
class C{ void foo(){} } class D: C{ @disable override void foo(){} // should be a compile-time error } Disabling an override does not make any sense and should be disallowed.
Comment #1 by yebblies — 2012-01-30T23:52:17Z
Same thing for deprecated overrides.
Comment #2 by yebblies — 2012-01-30T23:52:51Z
*** Issue 1449 has been marked as a duplicate of this issue. ***
Comment #3 by b2.temp — 2017-02-25T18:26:46Z
*** Issue 5171 has been marked as a duplicate of this issue. ***
Comment #4 by bugzilla — 2017-02-26T04:19:40Z
Comment #5 by github-bugzilla — 2017-02-26T04:21:05Z
Commits pushed to master at https://github.com/dlang/dmd https://github.com/dlang/dmd/commit/9441e5a68bf473d7780bb2cab0c993f6819dc9ad issue 6760 - deprecate `@disable` on overridden and deprecated functions https://github.com/dlang/dmd/commit/6d8409d2f7502506044de9e62fde082aebf6ca29 Merge pull request #6570 from BBasile/issue-6760 issue 6760 - deprecate `@disable` on overridden and deprecated functions
Comment #6 by dlang-bugzilla — 2017-07-02T17:56:28Z
6570 was merged, so this looks fixed.
Comment #7 by github-bugzilla — 2017-08-07T13:15:20Z
Commits pushed to newCTFE at https://github.com/dlang/dmd https://github.com/dlang/dmd/commit/9441e5a68bf473d7780bb2cab0c993f6819dc9ad issue 6760 - deprecate `@disable` on overridden and deprecated functions https://github.com/dlang/dmd/commit/6d8409d2f7502506044de9e62fde082aebf6ca29 Merge pull request #6570 from BBasile/issue-6760