File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
idea/idea-analysis/src/org/jetbrains/kotlin/idea/caches Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -36,6 +36,7 @@ import org.jetbrains.kotlin.idea.stubindex.PackageIndexUtil
36
36
import org.jetbrains.kotlin.name.FqName
37
37
import org.jetbrains.kotlin.psi.KtFile
38
38
import org.jetbrains.kotlin.psi.KtPackageDirective
39
+ import org.jetbrains.kotlin.psi.psiUtil.getChildrenOfType
39
40
import org.jetbrains.kotlin.psi.psiUtil.getParentOfType
40
41
import java.util.concurrent.ConcurrentMap
41
42
@@ -73,6 +74,11 @@ class KotlinPackageStatementPsiTreeChangePreprocessor(private val project: Proje
73
74
if (child.getParentOfType<KtPackageDirective >(false ) != null )
74
75
project.service<PerModulePackageCacheService >().notifyPackageChange(file)
75
76
}
77
+ PsiTreeChangeEventImpl .PsiEventType .CHILDREN_CHANGED -> {
78
+ val parent = event.parent ? : return
79
+ if (parent.getChildrenOfType<KtPackageDirective >().any())
80
+ project.service<PerModulePackageCacheService >().notifyPackageChange(file)
81
+ }
76
82
else -> {
77
83
}
78
84
}
You can’t perform that action at this time.
0 commit comments