Duplicate :
|
|
Duplicate :
|
|
Relates :
|
|
Relates :
|
|
Relates :
|
JDK-8184946 :
|
Oracle's implementation returns "static" for anonymous classes, which contradicts the spec. Java 7 spec: An anonymous class is always implicitly final (8.1.1.2). An anonymous class is always an inner class (8.1.3); it is never static (8.1.1, 8.5.1). The modifier static pertains only to member classes (8.5.1), not to top level or local or anonymous classes.
|