Fix for EA-38626 - can't find class delegate for JetLightClass constructed for kotlin enum entry.
This commit is contained in:
@@ -136,11 +136,15 @@ public class JavaElementFinder extends PsiElementFinder implements JavaPsiFacade
|
||||
if (localName != null) {
|
||||
FqName fqn = QualifiedNamesUtil.combine(containerFqn, Name.identifier(localName));
|
||||
if (qualifiedName.equals(fqn)) {
|
||||
answer.add(new JetLightClass(psiManager, file, qualifiedName));
|
||||
if (!(declaration instanceof JetEnumEntry)) {
|
||||
answer.add(new JetLightClass(psiManager, file, qualifiedName));
|
||||
}
|
||||
}
|
||||
else {
|
||||
for (JetDeclaration child : ((JetClassOrObject) declaration).getDeclarations()) {
|
||||
scanClasses(answer, child, qualifiedName, fqn, file);
|
||||
else if (QualifiedNamesUtil.isSubpackageOf(qualifiedName, fqn)) {
|
||||
if (!(declaration instanceof JetEnumEntry)) {
|
||||
for (JetDeclaration child : ((JetClassOrObject) declaration).getDeclarations()) {
|
||||
scanClasses(answer, child, qualifiedName, fqn, file);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user