mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
KotlinHighLevelFunctionParameterInfoHandler: Strikeout deprecated candidates.
GitOrigin-RevId: b607b385cfa25958c4090d819e4654e04221632a
This commit is contained in:
committed by
intellij-monorepo-bot
parent
424cb252d2
commit
77c2ee6c5b
+3
-3
@@ -115,7 +115,7 @@ abstract class KotlinHighLevelParameterInfoWithCallHandlerBase<TArgumentList : K
|
||||
}
|
||||
|
||||
val candidates = resolvedCall?.targetFunction?.candidates ?: return null
|
||||
context.itemsToShow = candidates.map { CandidateInfo(it.createPointer()) }.toTypedArray()
|
||||
context.itemsToShow = candidates.map { CandidateInfo(it.createPointer(), it.deprecationStatus != null) }.toTypedArray()
|
||||
|
||||
argumentList
|
||||
}
|
||||
@@ -409,8 +409,7 @@ abstract class KotlinHighLevelParameterInfoWithCallHandlerBase<TArgumentList : K
|
||||
}
|
||||
|
||||
val backgroundColor = if (isCallResolvedToCandidate) GREEN_BACKGROUND else context.defaultParameterColor
|
||||
// TODO: Strikeout if deprecated. Deprecation status not currently in HL API
|
||||
val strikeout = false
|
||||
val strikeout = itemToShow.isDeprecated
|
||||
|
||||
// Disabled when there are too many arguments.
|
||||
val allParametersUsed = usedParameterIndices.size == valueParameterCount
|
||||
@@ -449,6 +448,7 @@ abstract class KotlinHighLevelParameterInfoWithCallHandlerBase<TArgumentList : K
|
||||
|
||||
data class CandidateInfo(
|
||||
val candidate: KtSymbolPointer<KtFunctionLikeSymbol>,
|
||||
val isDeprecated: Boolean,
|
||||
var callInfo: CallInfo? = null // Populated in updateParameterInfo()
|
||||
)
|
||||
}
|
||||
-1
@@ -1,4 +1,3 @@
|
||||
// IGNORE_FIR
|
||||
@Suppress("DEPRECATED_SINCE_KOTLIN_OUTSIDE_KOTLIN_SUBPACKAGE")
|
||||
@Deprecated("")
|
||||
@DeprecatedSinceKotlin(warningSince = "1.0")
|
||||
|
||||
Reference in New Issue
Block a user