[Issue 15390] New: 'abstract' should override final:
    via Digitalmars-d-bugs 
    digitalmars-d-bugs at puremagic.com
       
    Sun Nov 29 02:22:42 PST 2015
    
    
  
https://issues.dlang.org/show_bug.cgi?id=15390
          Issue ID: 15390
           Summary: 'abstract' should override final:
           Product: D
           Version: D2
          Hardware: x86_64
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: dmd
          Assignee: nobody at puremagic.com
          Reporter: turkeyman at gmail.com
class X
{
  final: // <- naturally, this is the first line in any D class
  ...
  abstract void f(); // <- error, can't be abstract and final!
}
I think abstract should override final in this case, and not be an error...?
Without the ability to do this, you have to use final { ... }, and have little
blocks littered throughout classes, which is really unpleasant. That causes an
extra indentation level, making it hard to follow; class members look like
they're in a function because they're indented an extra level.
--
    
    
More information about the Digitalmars-d-bugs
mailing list