[FIR] Return K2 reference shortener result

This commit sets a list of `KtElement` as the return type of
`ShortenCommand::invokeShortening()`. It allows us to take the result
i.e., shortened PSIs. This can be used, for example, when we want to
run code-format only on the shortened PSI after running the reference
shortener.

^KT-57636 Fixed
This commit is contained in:
Jaebaek Seo
2023-03-23 18:19:51 -07:00
committed by Roman Golyshev
parent f810d435f4
commit 3fbd3d7e20
3 changed files with 13 additions and 8 deletions
@@ -16,6 +16,7 @@ import org.jetbrains.kotlin.analysis.api.lifetime.KtLifetimeToken
import org.jetbrains.kotlin.analysis.api.symbols.KtCallableSymbol
import org.jetbrains.kotlin.analysis.api.symbols.KtClassLikeSymbol
import org.jetbrains.kotlin.psi.KtDotQualifiedExpression
import org.jetbrains.kotlin.psi.KtElement
import org.jetbrains.kotlin.psi.KtFile
import org.jetbrains.kotlin.psi.KtUserType
@@ -41,7 +42,7 @@ internal class KtFe10ReferenceShortener(
override fun getQualifiersToShorten(): List<SmartPsiElementPointer<KtDotQualifiedExpression>> = emptyList()
override fun invokeShortening() {}
override fun invokeShortening(): List<KtElement> = emptyList()
}
}
}