Bug 1973 – static on interfaces should be an error
Status
RESOLVED
Resolution
DUPLICATE
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2008-04-05T11:19:00Z
Last change time
2015-06-09T05:11:36Z
Keywords
accepts-invalid
Assigned to
nobody
Creator
benoit
Comments
Comment #0 by benoit — 2008-04-05T11:19:08Z
static interface Name{
}
makes all member functions to be static member functions without implementation. This will create linker errors and does not make sense. Or do i miss something?
On the other hand, in Java, all nested interfaces are implicit static and it is optional to list the static keyword.
To avoid problems here, the compiler could give an error if D source code has the static keyword in an interface declaration.
Comment #1 by yebblies — 2012-01-30T18:41:52Z
Static no longer propagates to the interface members. Asking for an error on this is a dup of issue 3934.
*** This issue has been marked as a duplicate of issue 2553 ***