FE10 analysis API: create receiver parameter symbols for 'this'
This commit is contained in:
+5
@@ -89,6 +89,7 @@ internal fun DeclarationDescriptor.toKtSymbol(analysisContext: Fe10AnalysisConte
|
||||
|
||||
return when (this) {
|
||||
is ClassifierDescriptor -> toKtClassifierSymbol(analysisContext)
|
||||
is ReceiverParameterDescriptor -> toKtReceiverParameterSymbol(analysisContext)
|
||||
is CallableDescriptor -> toKtCallableSymbol(analysisContext)
|
||||
is PackageViewDescriptor -> toKtPackageSymbol(analysisContext)
|
||||
else -> null
|
||||
@@ -116,6 +117,10 @@ internal fun PackageViewDescriptor.toKtPackageSymbol(analysisContext: Fe10Analys
|
||||
return KtFe10PackageSymbol(fqName, analysisContext)
|
||||
}
|
||||
|
||||
internal fun ReceiverParameterDescriptor.toKtReceiverParameterSymbol(analysisContext: Fe10AnalysisContext): KtReceiverParameterSymbol {
|
||||
return KtFe10ReceiverParameterSymbol(this, analysisContext)
|
||||
}
|
||||
|
||||
internal fun KtSymbol.getDescriptor(): DeclarationDescriptor? {
|
||||
return when (this) {
|
||||
is KtFe10PsiSymbol<*, *> -> descriptor
|
||||
|
||||
Reference in New Issue
Block a user