[FIR] JavaTypeParameterStack: allow nullable return from get
It is not always possible to have the correct mapping, at least on the Analysis API side ^KT-66530 Fixed
This commit is contained in:
committed by
Space Team
parent
eb8054ac1e
commit
675bf36049
+30
@@ -57,6 +57,24 @@ public class FirIdeDependentAnalysisSourceModuleAnalysisApiKtTypeByPsiTypeProvid
|
|||||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/extends.kt");
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/extends.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("methodTypeParameterWithKotlinUseSite.kt")
|
||||||
|
public void testMethodTypeParameterWithKotlinUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/methodTypeParameterWithKotlinUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("methodTypeParameterWithMethodUseSite.kt")
|
||||||
|
public void testMethodTypeParameterWithMethodUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/methodTypeParameterWithMethodUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("methodTypeParameterWithTypeParameterUseSite.kt")
|
||||||
|
public void testMethodTypeParameterWithTypeParameterUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/methodTypeParameterWithTypeParameterUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@TestMetadata("methodTypeParameters.kt")
|
@TestMetadata("methodTypeParameters.kt")
|
||||||
public void testMethodTypeParameters() {
|
public void testMethodTypeParameters() {
|
||||||
@@ -81,6 +99,18 @@ public class FirIdeDependentAnalysisSourceModuleAnalysisApiKtTypeByPsiTypeProvid
|
|||||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/primitive.kt");
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/primitive.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("typeParameterWithKotlinUseSite.kt")
|
||||||
|
public void testTypeParameterWithKotlinUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/typeParameterWithKotlinUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("typeParameterWithMethodUseSite.kt")
|
||||||
|
public void testTypeParameterWithMethodUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/typeParameterWithMethodUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@TestMetadata("typeParameters.kt")
|
@TestMetadata("typeParameters.kt")
|
||||||
public void testTypeParameters() {
|
public void testTypeParameters() {
|
||||||
|
|||||||
+30
@@ -57,6 +57,24 @@ public class FirIdeNormalAnalysisSourceModuleAnalysisApiKtTypeByPsiTypeProviderT
|
|||||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/extends.kt");
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/extends.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("methodTypeParameterWithKotlinUseSite.kt")
|
||||||
|
public void testMethodTypeParameterWithKotlinUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/methodTypeParameterWithKotlinUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("methodTypeParameterWithMethodUseSite.kt")
|
||||||
|
public void testMethodTypeParameterWithMethodUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/methodTypeParameterWithMethodUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("methodTypeParameterWithTypeParameterUseSite.kt")
|
||||||
|
public void testMethodTypeParameterWithTypeParameterUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/methodTypeParameterWithTypeParameterUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@TestMetadata("methodTypeParameters.kt")
|
@TestMetadata("methodTypeParameters.kt")
|
||||||
public void testMethodTypeParameters() {
|
public void testMethodTypeParameters() {
|
||||||
@@ -81,6 +99,18 @@ public class FirIdeNormalAnalysisSourceModuleAnalysisApiKtTypeByPsiTypeProviderT
|
|||||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/primitive.kt");
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/primitive.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("typeParameterWithKotlinUseSite.kt")
|
||||||
|
public void testTypeParameterWithKotlinUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/typeParameterWithKotlinUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("typeParameterWithMethodUseSite.kt")
|
||||||
|
public void testTypeParameterWithMethodUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/typeParameterWithMethodUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@TestMetadata("typeParameters.kt")
|
@TestMetadata("typeParameters.kt")
|
||||||
public void testTypeParameters() {
|
public void testTypeParameters() {
|
||||||
|
|||||||
+30
-9
@@ -5,13 +5,13 @@
|
|||||||
|
|
||||||
package org.jetbrains.kotlin.analysis.api.impl.base.test.cases.components.psiTypeProvider
|
package org.jetbrains.kotlin.analysis.api.impl.base.test.cases.components.psiTypeProvider
|
||||||
|
|
||||||
import com.intellij.psi.PsiJavaFile
|
import com.intellij.psi.PsiElement
|
||||||
import com.intellij.psi.PsiMethod
|
import com.intellij.psi.PsiMethod
|
||||||
import com.intellij.psi.util.PsiTreeUtil
|
|
||||||
import org.jetbrains.kotlin.analysis.test.framework.base.AbstractAnalysisApiBasedTest
|
import org.jetbrains.kotlin.analysis.test.framework.base.AbstractAnalysisApiBasedTest
|
||||||
import org.jetbrains.kotlin.analysis.test.framework.project.structure.ktModuleProvider
|
import org.jetbrains.kotlin.analysis.test.framework.project.structure.ktModuleProvider
|
||||||
import org.jetbrains.kotlin.analysis.test.framework.services.expressionMarkerProvider
|
import org.jetbrains.kotlin.analysis.test.framework.services.expressionMarkerProvider
|
||||||
import org.jetbrains.kotlin.analysis.test.framework.utils.executeOnPooledThreadInReadAction
|
import org.jetbrains.kotlin.analysis.test.framework.utils.executeOnPooledThreadInReadAction
|
||||||
|
import org.jetbrains.kotlin.analysis.utils.printer.parentOfType
|
||||||
import org.jetbrains.kotlin.psi.KtFile
|
import org.jetbrains.kotlin.psi.KtFile
|
||||||
import org.jetbrains.kotlin.test.model.TestModule
|
import org.jetbrains.kotlin.test.model.TestModule
|
||||||
import org.jetbrains.kotlin.test.services.TestServices
|
import org.jetbrains.kotlin.test.services.TestServices
|
||||||
@@ -21,19 +21,14 @@ import org.jetbrains.kotlin.types.Variance
|
|||||||
|
|
||||||
abstract class AbstractAnalysisApiKtTypeByPsiTypeProviderTest : AbstractAnalysisApiBasedTest() {
|
abstract class AbstractAnalysisApiKtTypeByPsiTypeProviderTest : AbstractAnalysisApiBasedTest() {
|
||||||
override fun doTestByMainFile(mainFile: KtFile, mainModule: TestModule, testServices: TestServices) {
|
override fun doTestByMainFile(mainFile: KtFile, mainModule: TestModule, testServices: TestServices) {
|
||||||
val psiMethod = testServices.moduleStructure.modules.map { module ->
|
val (psiMethod, useSitePosition) = getTestDataContext(testServices)
|
||||||
val psiFiles = testServices.ktModuleProvider.getModuleFiles(module).filterIsInstance<PsiJavaFile>()
|
|
||||||
val javaFile = psiFiles.first()
|
|
||||||
val offset = testServices.expressionMarkerProvider.getCaretPosition(javaFile)
|
|
||||||
PsiTreeUtil.getParentOfType(javaFile.findElementAt(offset), PsiMethod::class.java)
|
|
||||||
}.single()!!
|
|
||||||
|
|
||||||
val actual = buildString {
|
val actual = buildString {
|
||||||
executeOnPooledThreadInReadAction {
|
executeOnPooledThreadInReadAction {
|
||||||
analyseForTest(mainFile) {
|
analyseForTest(mainFile) {
|
||||||
val returnType = psiMethod.returnType
|
val returnType = psiMethod.returnType
|
||||||
testServices.assertions.assertNotNull(returnType)
|
testServices.assertions.assertNotNull(returnType)
|
||||||
val asKtTypeSuper = returnType!!.asKtType(psiMethod)!!
|
val asKtTypeSuper = returnType!!.asKtType(useSitePosition ?: psiMethod)!!
|
||||||
appendLine("PsiType: $returnType")
|
appendLine("PsiType: $returnType")
|
||||||
appendLine("KtType: ${asKtTypeSuper.render(position = Variance.OUT_VARIANCE)}")
|
appendLine("KtType: ${asKtTypeSuper.render(position = Variance.OUT_VARIANCE)}")
|
||||||
}
|
}
|
||||||
@@ -43,3 +38,29 @@ abstract class AbstractAnalysisApiKtTypeByPsiTypeProviderTest : AbstractAnalysis
|
|||||||
testServices.assertions.assertEqualsToTestDataFileSibling(actual)
|
testServices.assertions.assertEqualsToTestDataFileSibling(actual)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private data class TestDataContext(val targetMethod: PsiMethod, val useSitePosition: PsiElement?)
|
||||||
|
|
||||||
|
private fun getTestDataContext(testServices: TestServices): TestDataContext {
|
||||||
|
var psiMethod: PsiMethod? = null
|
||||||
|
var useSitePosition: PsiElement? = null
|
||||||
|
|
||||||
|
testServices.moduleStructure.modules.forEach { module ->
|
||||||
|
val psiFiles = testServices.ktModuleProvider.getModuleFiles(module)
|
||||||
|
for (psiFile in psiFiles) {
|
||||||
|
val targetOffset = testServices.expressionMarkerProvider.getCaretPositionOrNull(psiFile)
|
||||||
|
if (targetOffset != null) {
|
||||||
|
if (psiMethod != null) error("Only one target method is expected")
|
||||||
|
psiMethod = psiFile.findElementAt(targetOffset)?.parentOfType<PsiMethod>(withSelf = true)
|
||||||
|
}
|
||||||
|
|
||||||
|
val useSiteOffset = testServices.expressionMarkerProvider.getCaretPositionOrNull(psiFile, caretTag = "useSite")
|
||||||
|
if (useSiteOffset != null) {
|
||||||
|
if (useSitePosition != null) error("Only one target method is expected")
|
||||||
|
useSitePosition = psiFile.findElementAt(useSiteOffset)?.parentOfType<PsiElement>(withSelf = true)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return TestDataContext(psiMethod ?: error("Target method is not found"), useSitePosition)
|
||||||
|
}
|
||||||
|
|||||||
+30
@@ -57,6 +57,24 @@ public class FirStandaloneNormalAnalysisSourceModuleAnalysisApiKtTypeByPsiTypePr
|
|||||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/extends.kt");
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/extends.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("methodTypeParameterWithKotlinUseSite.kt")
|
||||||
|
public void testMethodTypeParameterWithKotlinUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/methodTypeParameterWithKotlinUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("methodTypeParameterWithMethodUseSite.kt")
|
||||||
|
public void testMethodTypeParameterWithMethodUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/methodTypeParameterWithMethodUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("methodTypeParameterWithTypeParameterUseSite.kt")
|
||||||
|
public void testMethodTypeParameterWithTypeParameterUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/methodTypeParameterWithTypeParameterUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@TestMetadata("methodTypeParameters.kt")
|
@TestMetadata("methodTypeParameters.kt")
|
||||||
public void testMethodTypeParameters() {
|
public void testMethodTypeParameters() {
|
||||||
@@ -81,6 +99,18 @@ public class FirStandaloneNormalAnalysisSourceModuleAnalysisApiKtTypeByPsiTypePr
|
|||||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/primitive.kt");
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/primitive.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("typeParameterWithKotlinUseSite.kt")
|
||||||
|
public void testTypeParameterWithKotlinUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/typeParameterWithKotlinUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
@TestMetadata("typeParameterWithMethodUseSite.kt")
|
||||||
|
public void testTypeParameterWithMethodUseSite() {
|
||||||
|
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/asKtType/typeParameterWithMethodUseSite.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@TestMetadata("typeParameters.kt")
|
@TestMetadata("typeParameters.kt")
|
||||||
public void testTypeParameters() {
|
public void testTypeParameters() {
|
||||||
|
|||||||
+9
@@ -0,0 +1,9 @@
|
|||||||
|
// FILE: KotlinClass.kt
|
||||||
|
class Kotlin<caret_useSite>Class
|
||||||
|
|
||||||
|
// FILE: A.java
|
||||||
|
class JavaClass {
|
||||||
|
<TYPE> TYPE ma<caret>terialize() {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
+2
@@ -0,0 +1,2 @@
|
|||||||
|
PsiType: PsiType:TYPE
|
||||||
|
KtType: TYPE
|
||||||
+9
@@ -0,0 +1,9 @@
|
|||||||
|
// FILE: KotlinClass.kt
|
||||||
|
class KotlinClass
|
||||||
|
|
||||||
|
// FILE: A.java
|
||||||
|
class JavaClass {
|
||||||
|
<TYPE> TYPE ma<caret>teria<caret_useSite>lize() {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
+2
@@ -0,0 +1,2 @@
|
|||||||
|
PsiType: PsiType:TYPE
|
||||||
|
KtType: TYPE?
|
||||||
+9
@@ -0,0 +1,9 @@
|
|||||||
|
// FILE: KotlinClass.kt
|
||||||
|
class KotlinClass
|
||||||
|
|
||||||
|
// FILE: A.java
|
||||||
|
class JavaClass {
|
||||||
|
<TY<caret_useSite>PE> TYPE ma<caret>terialize() {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
+2
@@ -0,0 +1,2 @@
|
|||||||
|
PsiType: PsiType:TYPE
|
||||||
|
KtType: TYPE
|
||||||
+7
@@ -0,0 +1,7 @@
|
|||||||
|
// FILE: KotlinClass.kt
|
||||||
|
class Kotlin<caret_useSite>Class
|
||||||
|
|
||||||
|
// FILE: A.java
|
||||||
|
public interface A<T> {
|
||||||
|
T f<caret>oo();
|
||||||
|
}
|
||||||
+2
@@ -0,0 +1,2 @@
|
|||||||
|
PsiType: PsiType:T
|
||||||
|
KtType: T
|
||||||
+7
@@ -0,0 +1,7 @@
|
|||||||
|
// FILE: KotlinClass.kt
|
||||||
|
class KotlinClass
|
||||||
|
|
||||||
|
// FILE: A.java
|
||||||
|
public interface A<T> {
|
||||||
|
T f<caret>o<caret_useSite>o();
|
||||||
|
}
|
||||||
+2
@@ -0,0 +1,2 @@
|
|||||||
|
PsiType: PsiType:T
|
||||||
|
KtType: T?
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2010-2021 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
* Copyright 2010-2024 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -10,6 +10,7 @@ import org.jetbrains.kotlin.fir.FirSession
|
|||||||
import org.jetbrains.kotlin.fir.diagnostics.ConeSimpleDiagnostic
|
import org.jetbrains.kotlin.fir.diagnostics.ConeSimpleDiagnostic
|
||||||
import org.jetbrains.kotlin.fir.diagnostics.DiagnosticKind
|
import org.jetbrains.kotlin.fir.diagnostics.DiagnosticKind
|
||||||
import org.jetbrains.kotlin.fir.java.enhancement.readOnlyToMutable
|
import org.jetbrains.kotlin.fir.java.enhancement.readOnlyToMutable
|
||||||
|
import org.jetbrains.kotlin.fir.resolve.diagnostics.ConeUnresolvedNameError
|
||||||
import org.jetbrains.kotlin.fir.resolve.toFirRegularClassSymbol
|
import org.jetbrains.kotlin.fir.resolve.toFirRegularClassSymbol
|
||||||
import org.jetbrains.kotlin.fir.types.*
|
import org.jetbrains.kotlin.fir.types.*
|
||||||
import org.jetbrains.kotlin.fir.types.builder.buildResolvedTypeRef
|
import org.jetbrains.kotlin.fir.types.builder.buildResolvedTypeRef
|
||||||
@@ -214,7 +215,11 @@ private fun JavaClassifierType.toConeKotlinTypeForFlexibleBound(
|
|||||||
|
|
||||||
is JavaTypeParameter -> {
|
is JavaTypeParameter -> {
|
||||||
val symbol = javaTypeParameterStack[classifier]
|
val symbol = javaTypeParameterStack[classifier]
|
||||||
ConeTypeParameterTypeImpl(symbol.toLookupTag(), isNullable = lowerBound != null, attributes)
|
if (symbol != null) {
|
||||||
|
ConeTypeParameterTypeImpl(symbol.toLookupTag(), isNullable = lowerBound != null, attributes)
|
||||||
|
} else {
|
||||||
|
ConeErrorType(ConeUnresolvedNameError(classifier.name))
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
null -> {
|
null -> {
|
||||||
|
|||||||
+4
-5
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2010-2023 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
* Copyright 2010-2024 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -19,9 +19,8 @@ class MutableJavaTypeParameterStack : JavaTypeParameterStack() {
|
|||||||
typeParameterMap += javaTypeParameterStack.typeParameterMap
|
typeParameterMap += javaTypeParameterStack.typeParameterMap
|
||||||
}
|
}
|
||||||
|
|
||||||
override operator fun get(javaTypeParameter: JavaTypeParameter): FirTypeParameterSymbol {
|
override operator fun get(javaTypeParameter: JavaTypeParameter): FirTypeParameterSymbol? {
|
||||||
return typeParameterMap[javaTypeParameter]
|
return typeParameterMap[javaTypeParameter]
|
||||||
?: throw IllegalArgumentException("Cannot find Java type parameter $javaTypeParameter in stack")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override operator fun iterator(): Iterator<Map.Entry<JavaTypeParameter, FirTypeParameterSymbol>> {
|
override operator fun iterator(): Iterator<Map.Entry<JavaTypeParameter, FirTypeParameterSymbol>> {
|
||||||
@@ -31,14 +30,14 @@ class MutableJavaTypeParameterStack : JavaTypeParameterStack() {
|
|||||||
fun snapshot(): JavaTypeParameterStack {
|
fun snapshot(): JavaTypeParameterStack {
|
||||||
val snapshot = typeParameterMap.toMap()
|
val snapshot = typeParameterMap.toMap()
|
||||||
return object : JavaTypeParameterStack() {
|
return object : JavaTypeParameterStack() {
|
||||||
override fun get(javaTypeParameter: JavaTypeParameter): FirTypeParameterSymbol = snapshot.getValue(javaTypeParameter)
|
override fun get(javaTypeParameter: JavaTypeParameter): FirTypeParameterSymbol? = snapshot[javaTypeParameter]
|
||||||
override fun iterator(): Iterator<Map.Entry<JavaTypeParameter, FirTypeParameterSymbol>> = snapshot.iterator()
|
override fun iterator(): Iterator<Map.Entry<JavaTypeParameter, FirTypeParameterSymbol>> = snapshot.iterator()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
abstract class JavaTypeParameterStack : Iterable<Map.Entry<JavaTypeParameter, FirTypeParameterSymbol>> {
|
abstract class JavaTypeParameterStack : Iterable<Map.Entry<JavaTypeParameter, FirTypeParameterSymbol>> {
|
||||||
abstract operator fun get(javaTypeParameter: JavaTypeParameter): FirTypeParameterSymbol
|
abstract operator fun get(javaTypeParameter: JavaTypeParameter): FirTypeParameterSymbol?
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
val EMPTY: JavaTypeParameterStack = MutableJavaTypeParameterStack()
|
val EMPTY: JavaTypeParameterStack = MutableJavaTypeParameterStack()
|
||||||
|
|||||||
Reference in New Issue
Block a user