[FIR] Consider variance of type parameters during java type enhancement
#KT-41940 Fixed
This commit is contained in:
@@ -0,0 +1,23 @@
|
|||||||
|
// ISSUE: KT-41940
|
||||||
|
|
||||||
|
// FILE: Matcher.java
|
||||||
|
|
||||||
|
public interface Matcher<T> {}
|
||||||
|
|
||||||
|
// FILE: Matchers.java
|
||||||
|
|
||||||
|
public class Matchers {
|
||||||
|
public static <T> Matcher<java.lang.Iterable<? super T>> hasItem(T item) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static <T> void assertThat(T actual, Matcher<? super T> matcher) {}
|
||||||
|
}
|
||||||
|
|
||||||
|
// FILE: main.kt
|
||||||
|
|
||||||
|
import Matchers.*
|
||||||
|
|
||||||
|
fun test(list: List<String>, string: String) {
|
||||||
|
assertThat(list, <!DEBUG_INFO_EXPRESSION_TYPE("Matcher<kotlin.collections.MutableIterable<*>..kotlin.collections.Iterable<*>?!>..Matcher<kotlin.collections.MutableIterable<*>..kotlin.collections.Iterable<*>?!>?!")!>hasItem(string)<!>)
|
||||||
|
}
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
FILE: main.kt
|
||||||
|
public final fun test(list: R|kotlin/collections/List<kotlin/String>|, string: R|kotlin/String|): R|kotlin/Unit| {
|
||||||
|
R|/Matchers.assertThat|<R|ft<kotlin/collections/List<kotlin/String>, kotlin/collections/List<kotlin/String>?>!|>(R|<local>/list|, R|/Matchers.hasItem|<R|ft<kotlin/String, kotlin/String?>!|>(R|<local>/string|))
|
||||||
|
}
|
||||||
Generated
+5
@@ -520,6 +520,11 @@ public class FirDiagnosticsTestGenerated extends AbstractFirDiagnosticsTest {
|
|||||||
runTest("compiler/fir/analysis-tests/testData/resolve/arguments/javaArrayVariance.kt");
|
runTest("compiler/fir/analysis-tests/testData/resolve/arguments/javaArrayVariance.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("kt41940.kt")
|
||||||
|
public void testKt41940() throws Exception {
|
||||||
|
runTest("compiler/fir/analysis-tests/testData/resolve/arguments/kt41940.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("lambda.kt")
|
@TestMetadata("lambda.kt")
|
||||||
public void testLambda() throws Exception {
|
public void testLambda() throws Exception {
|
||||||
runTest("compiler/fir/analysis-tests/testData/resolve/arguments/lambda.kt");
|
runTest("compiler/fir/analysis-tests/testData/resolve/arguments/lambda.kt");
|
||||||
|
|||||||
+5
@@ -520,6 +520,11 @@ public class FirDiagnosticsWithLightTreeTestGenerated extends AbstractFirDiagnos
|
|||||||
runTest("compiler/fir/analysis-tests/testData/resolve/arguments/javaArrayVariance.kt");
|
runTest("compiler/fir/analysis-tests/testData/resolve/arguments/javaArrayVariance.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("kt41940.kt")
|
||||||
|
public void testKt41940() throws Exception {
|
||||||
|
runTest("compiler/fir/analysis-tests/testData/resolve/arguments/kt41940.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("lambda.kt")
|
@TestMetadata("lambda.kt")
|
||||||
public void testLambda() throws Exception {
|
public void testLambda() throws Exception {
|
||||||
runTest("compiler/fir/analysis-tests/testData/resolve/arguments/lambda.kt");
|
runTest("compiler/fir/analysis-tests/testData/resolve/arguments/lambda.kt");
|
||||||
|
|||||||
@@ -196,7 +196,6 @@ class JavaSymbolProvider(
|
|||||||
isInline = false
|
isInline = false
|
||||||
isFun = classKind == ClassKind.INTERFACE
|
isFun = classKind == ClassKind.INTERFACE
|
||||||
}
|
}
|
||||||
addAnnotationsFrom(this@JavaSymbolProvider.session, javaClass, javaTypeParameterStack)
|
|
||||||
// TODO: may be we can process fields & methods later.
|
// TODO: may be we can process fields & methods later.
|
||||||
// However, they should be built up to override resolve stage
|
// However, they should be built up to override resolve stage
|
||||||
for (javaField in javaClass.fields) {
|
for (javaField in javaClass.fields) {
|
||||||
@@ -257,6 +256,7 @@ class JavaSymbolProvider(
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
firJavaClass.addAnnotationsFrom(this@JavaSymbolProvider.session, javaClass, javaTypeParameterStack)
|
||||||
return firJavaClass
|
return firJavaClass
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ import org.jetbrains.kotlin.fir.declarations.*
|
|||||||
import org.jetbrains.kotlin.fir.diagnostics.*
|
import org.jetbrains.kotlin.fir.diagnostics.*
|
||||||
import org.jetbrains.kotlin.fir.expressions.*
|
import org.jetbrains.kotlin.fir.expressions.*
|
||||||
import org.jetbrains.kotlin.fir.expressions.builder.*
|
import org.jetbrains.kotlin.fir.expressions.builder.*
|
||||||
|
import org.jetbrains.kotlin.fir.java.declarations.FirJavaClass
|
||||||
import org.jetbrains.kotlin.fir.java.declarations.buildJavaValueParameter
|
import org.jetbrains.kotlin.fir.java.declarations.buildJavaValueParameter
|
||||||
import org.jetbrains.kotlin.fir.java.enhancement.readOnlyToMutable
|
import org.jetbrains.kotlin.fir.java.enhancement.readOnlyToMutable
|
||||||
import org.jetbrains.kotlin.fir.references.builder.buildErrorNamedReference
|
import org.jetbrains.kotlin.fir.references.builder.buildErrorNamedReference
|
||||||
@@ -40,6 +41,7 @@ import org.jetbrains.kotlin.load.java.typeEnhancement.TypeComponentPosition
|
|||||||
import org.jetbrains.kotlin.name.ClassId
|
import org.jetbrains.kotlin.name.ClassId
|
||||||
import org.jetbrains.kotlin.name.Name
|
import org.jetbrains.kotlin.name.Name
|
||||||
import org.jetbrains.kotlin.types.Variance.*
|
import org.jetbrains.kotlin.types.Variance.*
|
||||||
|
import org.jetbrains.kotlin.utils.addToStdlib.runIf
|
||||||
|
|
||||||
internal val JavaModifierListOwner.modality: Modality
|
internal val JavaModifierListOwner.modality: Modality
|
||||||
get() = when {
|
get() = when {
|
||||||
@@ -70,7 +72,7 @@ internal fun FirTypeRef.toConeKotlinTypeProbablyFlexible(
|
|||||||
when (this) {
|
when (this) {
|
||||||
is FirResolvedTypeRef -> type
|
is FirResolvedTypeRef -> type
|
||||||
is FirJavaTypeRef -> {
|
is FirJavaTypeRef -> {
|
||||||
type.toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack)
|
type.toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack, isForSupertypes = false)
|
||||||
}
|
}
|
||||||
else -> ConeKotlinErrorType(
|
else -> ConeKotlinErrorType(
|
||||||
ConeSimpleDiagnostic("Unexpected type reference in JavaClassUseSiteMemberScope: ${this::class.java}", DiagnosticKind.Java)
|
ConeSimpleDiagnostic("Unexpected type reference in JavaClassUseSiteMemberScope: ${this::class.java}", DiagnosticKind.Java)
|
||||||
@@ -93,9 +95,9 @@ internal fun JavaClassifierType.toFirResolvedTypeRef(
|
|||||||
): FirResolvedTypeRef {
|
): FirResolvedTypeRef {
|
||||||
val coneType =
|
val coneType =
|
||||||
if (isForSupertypes)
|
if (isForSupertypes)
|
||||||
toConeKotlinTypeForFlexibleBound(session, javaTypeParameterStack, isLowerBound = true, forTypeParameterBounds)
|
toConeKotlinTypeForFlexibleBound(session, javaTypeParameterStack, isLowerBound = true, forTypeParameterBounds, isForSupertypes)
|
||||||
else
|
else
|
||||||
toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack, forTypeParameterBounds)
|
toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack, forTypeParameterBounds, isForSupertypes)
|
||||||
|
|
||||||
return buildResolvedTypeRef {
|
return buildResolvedTypeRef {
|
||||||
type = coneType
|
type = coneType
|
||||||
@@ -106,7 +108,8 @@ internal fun JavaClassifierType.toFirResolvedTypeRef(
|
|||||||
internal fun JavaType?.toConeKotlinTypeWithoutEnhancement(
|
internal fun JavaType?.toConeKotlinTypeWithoutEnhancement(
|
||||||
session: FirSession,
|
session: FirSession,
|
||||||
javaTypeParameterStack: JavaTypeParameterStack,
|
javaTypeParameterStack: JavaTypeParameterStack,
|
||||||
forAnnotationValueParameter: Boolean = false
|
forAnnotationValueParameter: Boolean = false,
|
||||||
|
isForSupertypes: Boolean = false
|
||||||
): ConeKotlinType {
|
): ConeKotlinType {
|
||||||
return when (this) {
|
return when (this) {
|
||||||
is JavaClassifierType -> {
|
is JavaClassifierType -> {
|
||||||
@@ -123,9 +126,9 @@ internal fun JavaType?.toConeKotlinTypeWithoutEnhancement(
|
|||||||
classId.toConeKotlinType(emptyArray(), isNullable = false)
|
classId.toConeKotlinType(emptyArray(), isNullable = false)
|
||||||
}
|
}
|
||||||
is JavaArrayType -> {
|
is JavaArrayType -> {
|
||||||
toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack, forAnnotationValueParameter)
|
toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack, forAnnotationValueParameter, isForSupertypes)
|
||||||
}
|
}
|
||||||
is JavaWildcardType -> bound?.toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack) ?: run {
|
is JavaWildcardType -> bound?.toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack, isForSupertypes = isForSupertypes) ?: run {
|
||||||
StandardClassIds.Any.toConeFlexibleType(emptyArray())
|
StandardClassIds.Any.toConeFlexibleType(emptyArray())
|
||||||
}
|
}
|
||||||
null -> {
|
null -> {
|
||||||
@@ -138,12 +141,13 @@ internal fun JavaType?.toConeKotlinTypeWithoutEnhancement(
|
|||||||
private fun JavaArrayType.toConeKotlinTypeWithoutEnhancement(
|
private fun JavaArrayType.toConeKotlinTypeWithoutEnhancement(
|
||||||
session: FirSession,
|
session: FirSession,
|
||||||
javaTypeParameterStack: JavaTypeParameterStack,
|
javaTypeParameterStack: JavaTypeParameterStack,
|
||||||
forAnnotationValueParameter: Boolean = false
|
forAnnotationValueParameter: Boolean = false,
|
||||||
|
isForSupertypes: Boolean
|
||||||
): ConeFlexibleType {
|
): ConeFlexibleType {
|
||||||
val componentType = componentType
|
val componentType = componentType
|
||||||
return if (componentType !is JavaPrimitiveType) {
|
return if (componentType !is JavaPrimitiveType) {
|
||||||
val classId = StandardClassIds.Array
|
val classId = StandardClassIds.Array
|
||||||
val argumentType = componentType.toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack, forAnnotationValueParameter)
|
val argumentType = componentType.toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack, forAnnotationValueParameter, isForSupertypes)
|
||||||
classId.toConeFlexibleType(
|
classId.toConeFlexibleType(
|
||||||
arrayOf(argumentType),
|
arrayOf(argumentType),
|
||||||
typeArgumentsForUpper = arrayOf(ConeKotlinTypeProjectionOut(argumentType))
|
typeArgumentsForUpper = arrayOf(ConeKotlinTypeProjectionOut(argumentType))
|
||||||
@@ -168,6 +172,7 @@ private fun JavaClassifierType.toConeKotlinTypeWithoutEnhancement(
|
|||||||
session: FirSession,
|
session: FirSession,
|
||||||
javaTypeParameterStack: JavaTypeParameterStack,
|
javaTypeParameterStack: JavaTypeParameterStack,
|
||||||
forTypeParameterBounds: Boolean = false,
|
forTypeParameterBounds: Boolean = false,
|
||||||
|
isForSupertypes: Boolean = false,
|
||||||
forAnnotationValueParameter: Boolean = false
|
forAnnotationValueParameter: Boolean = false
|
||||||
): ConeKotlinType {
|
): ConeKotlinType {
|
||||||
val lowerBound = toConeKotlinTypeForFlexibleBound(
|
val lowerBound = toConeKotlinTypeForFlexibleBound(
|
||||||
@@ -175,6 +180,7 @@ private fun JavaClassifierType.toConeKotlinTypeWithoutEnhancement(
|
|||||||
javaTypeParameterStack,
|
javaTypeParameterStack,
|
||||||
isLowerBound = true,
|
isLowerBound = true,
|
||||||
forTypeParameterBounds,
|
forTypeParameterBounds,
|
||||||
|
isForSupertypes,
|
||||||
forAnnotationValueParameter = forAnnotationValueParameter
|
forAnnotationValueParameter = forAnnotationValueParameter
|
||||||
)
|
)
|
||||||
val upperBound =
|
val upperBound =
|
||||||
@@ -183,6 +189,7 @@ private fun JavaClassifierType.toConeKotlinTypeWithoutEnhancement(
|
|||||||
javaTypeParameterStack,
|
javaTypeParameterStack,
|
||||||
isLowerBound = false,
|
isLowerBound = false,
|
||||||
forTypeParameterBounds,
|
forTypeParameterBounds,
|
||||||
|
isForSupertypes,
|
||||||
lowerBound,
|
lowerBound,
|
||||||
forAnnotationValueParameter = forAnnotationValueParameter
|
forAnnotationValueParameter = forAnnotationValueParameter
|
||||||
)
|
)
|
||||||
@@ -285,6 +292,7 @@ private fun JavaClassifierType.toConeKotlinTypeForFlexibleBound(
|
|||||||
javaTypeParameterStack: JavaTypeParameterStack,
|
javaTypeParameterStack: JavaTypeParameterStack,
|
||||||
isLowerBound: Boolean,
|
isLowerBound: Boolean,
|
||||||
forTypeParameterBounds: Boolean,
|
forTypeParameterBounds: Boolean,
|
||||||
|
isForSupertypes: Boolean,
|
||||||
lowerBound: ConeLookupTagBasedType? = null,
|
lowerBound: ConeLookupTagBasedType? = null,
|
||||||
forAnnotationValueParameter: Boolean = false
|
forAnnotationValueParameter: Boolean = false
|
||||||
): ConeLookupTagBasedType {
|
): ConeLookupTagBasedType {
|
||||||
@@ -308,8 +316,9 @@ private fun JavaClassifierType.toConeKotlinTypeForFlexibleBound(
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
val mappedTypeArguments = if (isRaw) {
|
val classSymbol = session.firSymbolProvider.getClassLikeSymbolByFqName(classId) as? FirRegularClassSymbol
|
||||||
|
|
||||||
|
val mappedTypeArguments = if (isRaw) {
|
||||||
val defaultArgs = (1..classifier.typeParameters.size).map { ConeStarProjection }
|
val defaultArgs = (1..classifier.typeParameters.size).map { ConeStarProjection }
|
||||||
|
|
||||||
if (forTypeParameterBounds) {
|
if (forTypeParameterBounds) {
|
||||||
@@ -317,15 +326,18 @@ private fun JavaClassifierType.toConeKotlinTypeForFlexibleBound(
|
|||||||
// to create a proper raw type arguments, we should take class parameters some time
|
// to create a proper raw type arguments, we should take class parameters some time
|
||||||
defaultArgs
|
defaultArgs
|
||||||
} else {
|
} else {
|
||||||
val classSymbol = session.firSymbolProvider.getClassLikeSymbolByFqName(classId) as? FirRegularClassSymbol
|
|
||||||
val position = if (isLowerBound) TypeComponentPosition.FLEXIBLE_LOWER else TypeComponentPosition.FLEXIBLE_UPPER
|
val position = if (isLowerBound) TypeComponentPosition.FLEXIBLE_LOWER else TypeComponentPosition.FLEXIBLE_UPPER
|
||||||
|
|
||||||
classSymbol?.fir?.createRawArguments(defaultArgs, position) ?: defaultArgs
|
classSymbol?.fir?.createRawArguments(defaultArgs, position) ?: defaultArgs
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
typeArguments.map { argument ->
|
val typeParameters = runIf(!forTypeParameterBounds && !isForSupertypes) { classSymbol?.fir?.typeParameters } ?: emptyList()
|
||||||
|
|
||||||
|
typeArguments.indices.map { index ->
|
||||||
|
val argument = typeArguments[index]
|
||||||
|
val parameter = typeParameters.getOrNull(index)?.symbol?.fir
|
||||||
argument.toConeProjectionWithoutEnhancement(
|
argument.toConeProjectionWithoutEnhancement(
|
||||||
session, javaTypeParameterStack, boundTypeParameter = null
|
session, javaTypeParameterStack, boundTypeParameter = parameter, isForSupertypes = isForSupertypes
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -371,9 +383,23 @@ internal fun JavaAnnotation.toFirAnnotationCall(
|
|||||||
@FirBuilderDsl
|
@FirBuilderDsl
|
||||||
internal fun FirAnnotationContainerBuilder.addAnnotationsFrom(
|
internal fun FirAnnotationContainerBuilder.addAnnotationsFrom(
|
||||||
session: FirSession, javaAnnotationOwner: JavaAnnotationOwner, javaTypeParameterStack: JavaTypeParameterStack
|
session: FirSession, javaAnnotationOwner: JavaAnnotationOwner, javaTypeParameterStack: JavaTypeParameterStack
|
||||||
|
) {
|
||||||
|
annotations.addAnnotationsFrom(session, javaAnnotationOwner, javaTypeParameterStack)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal fun FirJavaClass.addAnnotationsFrom(
|
||||||
|
session: FirSession, javaAnnotationOwner: JavaAnnotationOwner, javaTypeParameterStack: JavaTypeParameterStack
|
||||||
|
) {
|
||||||
|
annotations.addAnnotationsFrom(session, javaAnnotationOwner, javaTypeParameterStack)
|
||||||
|
}
|
||||||
|
|
||||||
|
private fun MutableList<FirAnnotationCall>.addAnnotationsFrom(
|
||||||
|
session: FirSession,
|
||||||
|
javaAnnotationOwner: JavaAnnotationOwner,
|
||||||
|
javaTypeParameterStack: JavaTypeParameterStack
|
||||||
) {
|
) {
|
||||||
for (annotation in javaAnnotationOwner.annotations) {
|
for (annotation in javaAnnotationOwner.annotations) {
|
||||||
annotations += annotation.toFirAnnotationCall(session, javaTypeParameterStack)
|
this += annotation.toFirAnnotationCall(session, javaTypeParameterStack)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -393,7 +419,8 @@ internal fun JavaValueParameter.toFirValueParameter(
|
|||||||
private fun JavaType?.toConeProjectionWithoutEnhancement(
|
private fun JavaType?.toConeProjectionWithoutEnhancement(
|
||||||
session: FirSession,
|
session: FirSession,
|
||||||
javaTypeParameterStack: JavaTypeParameterStack,
|
javaTypeParameterStack: JavaTypeParameterStack,
|
||||||
boundTypeParameter: FirTypeParameter?
|
boundTypeParameter: FirTypeParameter?,
|
||||||
|
isForSupertypes: Boolean = false
|
||||||
): ConeTypeProjection {
|
): ConeTypeProjection {
|
||||||
return when (this) {
|
return when (this) {
|
||||||
null -> ConeStarProjection
|
null -> ConeStarProjection
|
||||||
@@ -404,7 +431,7 @@ private fun JavaType?.toConeProjectionWithoutEnhancement(
|
|||||||
if (bound == null || parameterVariance != INVARIANT && parameterVariance != argumentVariance) {
|
if (bound == null || parameterVariance != INVARIANT && parameterVariance != argumentVariance) {
|
||||||
ConeStarProjection
|
ConeStarProjection
|
||||||
} else {
|
} else {
|
||||||
val boundType = bound.toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack)
|
val boundType = bound.toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack, isForSupertypes = isForSupertypes)
|
||||||
if (argumentVariance == OUT_VARIANCE) {
|
if (argumentVariance == OUT_VARIANCE) {
|
||||||
ConeKotlinTypeProjectionOut(boundType)
|
ConeKotlinTypeProjectionOut(boundType)
|
||||||
} else {
|
} else {
|
||||||
@@ -412,8 +439,8 @@ private fun JavaType?.toConeProjectionWithoutEnhancement(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
is JavaClassifierType -> toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack)
|
is JavaClassifierType -> toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack, isForSupertypes)
|
||||||
is JavaArrayType -> toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack)
|
is JavaArrayType -> toConeKotlinTypeWithoutEnhancement(session, javaTypeParameterStack, isForSupertypes = isForSupertypes)
|
||||||
else -> ConeClassErrorType(ConeSimpleDiagnostic("Unexpected type argument: $this", DiagnosticKind.Java))
|
else -> ConeClassErrorType(ConeSimpleDiagnostic("Unexpected type argument: $this", DiagnosticKind.Java))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -19,6 +19,6 @@ class In<in F> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
A.foo().<!UNRESOLVED_REFERENCE!>x<!>() <!INAPPLICABLE_CANDIDATE!>checkType<!> { _<Any?>() }
|
A.foo().x() checkType { _<Any?>() }
|
||||||
A.bar().<!UNRESOLVED_REFERENCE!>y<!>(null)
|
A.bar().<!INAPPLICABLE_CANDIDATE!>y<!>(null)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ FILE fqName:<root> fileName:/v8arrayToList.kt
|
|||||||
CONSTRUCTOR_CALL 'public constructor <init> () [primary] declared in <root>.V8Array' type=<root>.V8Array origin=null
|
CONSTRUCTOR_CALL 'public constructor <init> () [primary] declared in <root>.V8Array' type=<root>.V8Array origin=null
|
||||||
VAR name:list type:kotlin.collections.List<kotlin.String> [val]
|
VAR name:list type:kotlin.collections.List<kotlin.String> [val]
|
||||||
TYPE_OP type=kotlin.collections.List<kotlin.String> origin=CAST typeOperand=kotlin.collections.List<kotlin.String>
|
TYPE_OP type=kotlin.collections.List<kotlin.String> origin=CAST typeOperand=kotlin.collections.List<kotlin.String>
|
||||||
CALL 'public open fun toList (array: <root>.V8Array?): kotlin.collections.List<in kotlin.Any?>? declared in <root>.Utils' type=IrErrorType origin=null
|
CALL 'public open fun toList (array: <root>.V8Array?): kotlin.collections.List<*>? declared in <root>.Utils' type=kotlin.collections.List<*>? origin=null
|
||||||
array: GET_VAR 'val array: <root>.V8Array [val] declared in <root>.box' type=<root>.V8Array origin=null
|
array: GET_VAR 'val array: <root>.V8Array [val] declared in <root>.box' type=<root>.V8Array origin=null
|
||||||
RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'
|
RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'
|
||||||
CALL 'public abstract fun get (index: kotlin.Int): E of kotlin.collections.List [operator] declared in kotlin.collections.List' type=kotlin.String origin=null
|
CALL 'public abstract fun get (index: kotlin.Int): E of kotlin.collections.List [operator] declared in kotlin.collections.List' type=kotlin.String origin=null
|
||||||
|
|||||||
+2
-2
@@ -1,7 +1,7 @@
|
|||||||
public open class MethodWithMappedClasses : R|kotlin/Any| {
|
public open class MethodWithMappedClasses : R|kotlin/Any| {
|
||||||
public open fun <T : R|ft<kotlin/Any, kotlin/Any?>!|> copy(dest: R|ft<kotlin/collections/MutableList<in ft<T, T?>!>, kotlin/collections/List<in ft<T, T?>!>?>!|, src: R|ft<kotlin/collections/MutableList<ft<T, T?>!>, kotlin/collections/List<ft<T, T?>!>?>!|): R|kotlin/Unit|
|
public open fun <T : R|ft<kotlin/Any, kotlin/Any?>!|> copy(dest: R|ft<kotlin/collections/MutableList<in ft<T, T?>!>, kotlin/collections/List<*>?>!|, src: R|ft<kotlin/collections/MutableList<ft<T, T?>!>, kotlin/collections/List<ft<T, T?>!>?>!|): R|kotlin/Unit|
|
||||||
|
|
||||||
public open fun <T : R|ft<kotlin/Any, kotlin/Any?>!|> copyMap(dest: R|ft<kotlin/collections/MutableMap<ft<kotlin/String, kotlin/String?>!, in ft<T, T?>!>, kotlin/collections/Map<ft<kotlin/String, kotlin/String?>!, in ft<T, T?>!>?>!|, src: R|ft<kotlin/collections/MutableMap<ft<kotlin/String, kotlin/String?>!, ft<T, T?>!>, kotlin/collections/Map<ft<kotlin/String, kotlin/String?>!, ft<T, T?>!>?>!|): R|kotlin/Unit|
|
public open fun <T : R|ft<kotlin/Any, kotlin/Any?>!|> copyMap(dest: R|ft<kotlin/collections/MutableMap<ft<kotlin/String, kotlin/String?>!, in ft<T, T?>!>, kotlin/collections/Map<ft<kotlin/String, kotlin/String?>!, *>?>!|, src: R|ft<kotlin/collections/MutableMap<ft<kotlin/String, kotlin/String?>!, ft<T, T?>!>, kotlin/collections/Map<ft<kotlin/String, kotlin/String?>!, ft<T, T?>!>?>!|): R|kotlin/Unit|
|
||||||
|
|
||||||
public constructor(): R|test/MethodWithMappedClasses|
|
public constructor(): R|test/MethodWithMappedClasses|
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -1,5 +1,5 @@
|
|||||||
public open class MethodWithTypeParameters : R|kotlin/Any| {
|
public open class MethodWithTypeParameters : R|kotlin/Any| {
|
||||||
public open fun <A : R|ft<kotlin/Any, kotlin/Any?>!|, B : R|ft<java/lang/Runnable, java/lang/Runnable?>!|, R|ft<kotlin/collections/MutableList<ft<kotlin/Cloneable, kotlin/Cloneable?>!>, kotlin/collections/List<ft<kotlin/Cloneable, kotlin/Cloneable?>!>?>!|> foo(a: R|ft<A, A?>!|, b: R|ft<kotlin/collections/MutableList<out ft<B, B?>!>, kotlin/collections/List<out ft<B, B?>!>?>!|, list: R|ft<kotlin/collections/MutableList<in ft<kotlin/String, kotlin/String?>!>, kotlin/collections/List<in ft<kotlin/String, kotlin/String?>!>?>!|): R|kotlin/Unit|
|
public open fun <A : R|ft<kotlin/Any, kotlin/Any?>!|, B : R|ft<java/lang/Runnable, java/lang/Runnable?>!|, R|ft<kotlin/collections/MutableList<ft<kotlin/Cloneable, kotlin/Cloneable?>!>, kotlin/collections/List<ft<kotlin/Cloneable, kotlin/Cloneable?>!>?>!|> foo(a: R|ft<A, A?>!|, b: R|ft<kotlin/collections/MutableList<out ft<B, B?>!>, kotlin/collections/List<out ft<B, B?>!>?>!|, list: R|ft<kotlin/collections/MutableList<in ft<kotlin/String, kotlin/String?>!>, kotlin/collections/List<*>?>!|): R|kotlin/Unit|
|
||||||
|
|
||||||
public constructor(): R|test/MethodWithTypeParameters|
|
public constructor(): R|test/MethodWithTypeParameters|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user