[FIR] Fix IllegalStateException on broken import

#KT-55316 Fixed
This commit is contained in:
Kirill Rakhman
2023-03-29 13:51:39 +02:00
committed by Space Team
parent 691a1a683f
commit f18591ffef
8 changed files with 35 additions and 1 deletions
@@ -112,7 +112,7 @@ class JvmDependenciesIndexImpl(_roots: List<JavaRoot>) : JvmDependenciesIndex {
private fun <T : Any> search(request: SearchRequest, handler: (VirtualFile, JavaRoot.RootType) -> T?): T? {
// a list of package sub names, ["org", "jb", "kotlin"]
val packagesPath = request.packageFqName.pathSegments().map { it.identifier }
val packagesPath = request.packageFqName.pathSegments().map { it.identifierOrNullIfSpecial ?: return null }
// a list of caches corresponding to packages, [default, "org", "org.jb", "org.jb.kotlin"]
val caches = cachesPath(packagesPath)