disable create enum constant when not applicable (IDEA-154293)

This commit is contained in:
Anna.Kozlova
2016-04-08 18:44:25 +02:00
parent 3f384a290c
commit 572b7d8e7e
3 changed files with 69 additions and 3 deletions
@@ -0,0 +1,19 @@
// "Create enum constant 'CRIME'" "false"
import java.util.Arrays;
import java.util.List;
class AutomaticTypeInference {
AutomaticTypeInference(List<E> gs) {
}
public static void main(String[] args) {
new AutomaticTypeInference(Arrays.asList(E.ACTION, CRI<caret>ME));
}
enum E {
ACTION;
}
}
@@ -0,0 +1,19 @@
// "Create enum constant 'CRIME'" "false"
import java.util.Arrays;
import java.util.List;
class AutomaticTypeInference {
AutomaticTypeInference(List<E> gs) {
}
{
new AutomaticTypeInference(Arrays.asList(E.ACTION, this.CRI<caret>ME));
}
enum E {
ACTION;
}
}