mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-05-01 02:38:59 +07:00
java create class from new: don't create non-static inner if new expression can't be used afterwards (IDEA-97433)
GitOrigin-RevId: 89616c077ca5141db53b624ae08bc54b04d53cae
This commit is contained in:
committed by
intellij-monorepo-bot
parent
f535bd830e
commit
1c6857ec2d
@@ -2,7 +2,7 @@
|
||||
import java.util.*;
|
||||
|
||||
public class Test {
|
||||
public static void main() {
|
||||
public void main() {
|
||||
Collection c = new Test.MyCollection(1);
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
// "Create class 'MyCollection'" "true"
|
||||
import java.util.*;
|
||||
|
||||
class Test extends Foo {
|
||||
public void main() {
|
||||
Collection c = new Foo.MyCollection(1);
|
||||
}
|
||||
}
|
||||
|
||||
class Foo {
|
||||
public class MyCollection implements Collection {
|
||||
public MyCollection(int i) {
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -2,7 +2,7 @@
|
||||
import java.util.*;
|
||||
|
||||
public class Test {
|
||||
public static void main() {
|
||||
public void main() {
|
||||
Collection c = new Test.My<caret>Collection(1);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
// "Create class 'MyCollection'" "true"
|
||||
import java.util.*;
|
||||
|
||||
class Test extends Foo {
|
||||
public void main() {
|
||||
Collection c = new Foo.My<caret>Collection(1);
|
||||
}
|
||||
}
|
||||
|
||||
class Foo {}
|
||||
@@ -0,0 +1,10 @@
|
||||
// "Create class 'MyCollection'" "false"
|
||||
import java.util.*;
|
||||
|
||||
public class Test {
|
||||
public static void main() {
|
||||
Collection c = new Foo.My<caret>Collection(1);
|
||||
}
|
||||
}
|
||||
|
||||
class Foo {}
|
||||
Reference in New Issue
Block a user