mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
KTIJ-33154 [kotlin] Explicitly call checkCancelled before isAcceptable in places where this does not already happen
GitOrigin-RevId: 4e89b2aac9c9f7fcab41717e90118f235cb4fc34
This commit is contained in:
committed by
intellij-monorepo-bot
parent
e235b7aae5
commit
da086aac5b
+12
-6
@@ -185,8 +185,10 @@ class KtSymbolFromIndexProvider(
|
||||
|
||||
return getNonKotlinNamesCaches(useSiteModule.project).flatMap { cache ->
|
||||
cache.getClassesByName(nameString, scope).asSequence()
|
||||
}.filter { it.isAcceptable(psiFilter) }
|
||||
.mapNotNull { it.namedClassSymbol }
|
||||
}.filter {
|
||||
ProgressManager.checkCanceled()
|
||||
it.isAcceptable(psiFilter)
|
||||
}.mapNotNull { it.namedClassSymbol }
|
||||
}
|
||||
|
||||
context(KaSession)
|
||||
@@ -264,8 +266,10 @@ class KtSymbolFromIndexProvider(
|
||||
psiFilter: (PsiMethod) -> Boolean = { true },
|
||||
): Sequence<KaCallableSymbol> = getNonKotlinNamesCaches(useSiteModule.project).flatMap {
|
||||
it.getMethodsByName(name.asString(), scope).asSequence()
|
||||
}.filter { it.isAcceptable(psiFilter) }
|
||||
.mapNotNull { it.callableSymbol }
|
||||
}.filter {
|
||||
ProgressManager.checkCanceled()
|
||||
it.isAcceptable(psiFilter)
|
||||
}.mapNotNull { it.callableSymbol }
|
||||
|
||||
context(KaSession)
|
||||
fun getJavaFieldsByName(
|
||||
@@ -274,8 +278,10 @@ class KtSymbolFromIndexProvider(
|
||||
psiFilter: (PsiField) -> Boolean = { true },
|
||||
): Sequence<KaCallableSymbol> = getNonKotlinNamesCaches(useSiteModule.project).flatMap {
|
||||
it.getFieldsByName(name.asString(), scope).asSequence()
|
||||
}.filter { it.isAcceptable(psiFilter) }
|
||||
.mapNotNull { it.callableSymbol }
|
||||
}.filter {
|
||||
ProgressManager.checkCanceled()
|
||||
it.isAcceptable(psiFilter)
|
||||
}.mapNotNull { it.callableSymbol }
|
||||
|
||||
/**
|
||||
* Returns top-level callables, excluding extensions. To obtain extensions use [getExtensionCallableSymbolsByNameFilter].
|
||||
|
||||
Reference in New Issue
Block a user