mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-07 22:09:38 +07:00
There used to be a vague error message for enum constants that don't implement methods from an interface which refers to them as 'Anonymous class deriving from *Enum'. This patch makes the message clear displaying the real names of the enum constants in the error message. Signed-off-by: Nikita Eshkeev <nikita.eshkeev@jetbrains.com> GitOrigin-RevId: 700bc2b579e0c8552858ab881d9a3e4e8d81b1f8
25 lines
579 B
Java
25 lines
579 B
Java
<error descr="Modifier 'abstract' not allowed here">abstract</error> enum OurEnum {
|
|
<error descr="Enum constant 'A' must implement abstract method 'foo()' in 'OurEnum'">A</error> {
|
|
},
|
|
<error descr="'OurEnum' is abstract; cannot be instantiated">B</error>,
|
|
C {
|
|
void foo() {}
|
|
}
|
|
;
|
|
|
|
abstract void foo();
|
|
}
|
|
|
|
enum xxx {
|
|
<error descr="'xxx' is abstract; cannot be instantiated">X</error>,
|
|
<error descr="Enum constant 'Y' must implement abstract method 'f()' in 'xxx'">Y</error> {
|
|
};
|
|
|
|
abstract void f();
|
|
}
|
|
|
|
enum ok {
|
|
X { void f() {} };
|
|
abstract void f();
|
|
}
|