mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-04-19 13:02:30 +07:00
IDEA-84428 Basic completion not working for methods from static imports
This commit is contained in:
@@ -459,7 +459,7 @@ public class JavaCompletionUtil {
|
||||
}
|
||||
}
|
||||
|
||||
if (javaReference instanceof PsiReferenceExpression && !((PsiReferenceExpression)javaReference).isQualified()) {
|
||||
if (javaReference instanceof PsiJavaCodeReferenceElement && !((PsiJavaCodeReferenceElement)javaReference).isQualified()) {
|
||||
final StaticMemberProcessor memberProcessor = JavaGlobalMemberNameCompletionContributor.completeStaticMembers(parameters);
|
||||
memberProcessor.processMembersOfRegisteredClasses(matcher, new PairConsumer<PsiMember, PsiClass>() {
|
||||
@Override
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
import static Foo.assertNotNull;
|
||||
|
||||
class Foo {
|
||||
static void assertNotNull() {}
|
||||
}
|
||||
|
||||
class Bar {
|
||||
{
|
||||
asnn<caret> lists.get(0).size() > 0);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
import static Foo.assertNotNull;
|
||||
|
||||
class Foo {
|
||||
static void assertNotNull() {}
|
||||
}
|
||||
|
||||
class Bar {
|
||||
{
|
||||
assertNotNull();<caret> lists.get(0).size() > 0);
|
||||
}
|
||||
}
|
||||
@@ -1328,5 +1328,6 @@ public class ListUtils {
|
||||
|
||||
public void testListArrayListCast() { doTest('\n') }
|
||||
public void testInterfaceImplementationNoCast() { doTest() }
|
||||
public void testStaticallyImportedMethodsBeforeExpression() { doTest() }
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user