[NI] Improve completing callable references with type variable as expected type
#KT-32462 Fixed
This commit is contained in:
Generated
+5
@@ -9978,6 +9978,11 @@ public class FirOldFrontendDiagnosticsTestGenerated extends AbstractFirOldFronte
|
|||||||
runTest("compiler/testData/diagnostics/tests/inference/kt32434.kt");
|
runTest("compiler/testData/diagnostics/tests/inference/kt32434.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("kt32462.kt")
|
||||||
|
public void testKt32462() throws Exception {
|
||||||
|
runTest("compiler/testData/diagnostics/tests/inference/kt32462.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("kt33263.kt")
|
@TestMetadata("kt33263.kt")
|
||||||
public void testKt33263() throws Exception {
|
public void testKt33263() throws Exception {
|
||||||
runTest("compiler/testData/diagnostics/tests/inference/kt33263.kt");
|
runTest("compiler/testData/diagnostics/tests/inference/kt33263.kt");
|
||||||
|
|||||||
+66
-32
@@ -6,6 +6,7 @@
|
|||||||
package org.jetbrains.kotlin.resolve.calls.inference.components
|
package org.jetbrains.kotlin.resolve.calls.inference.components
|
||||||
|
|
||||||
import org.jetbrains.kotlin.builtins.isBuiltinFunctionalType
|
import org.jetbrains.kotlin.builtins.isBuiltinFunctionalType
|
||||||
|
import org.jetbrains.kotlin.builtins.isBuiltinFunctionalTypeOrSubtype
|
||||||
import org.jetbrains.kotlin.resolve.calls.components.KotlinResolutionStatelessCallbacks
|
import org.jetbrains.kotlin.resolve.calls.components.KotlinResolutionStatelessCallbacks
|
||||||
import org.jetbrains.kotlin.resolve.calls.components.transformToResolvedLambda
|
import org.jetbrains.kotlin.resolve.calls.components.transformToResolvedLambda
|
||||||
import org.jetbrains.kotlin.resolve.calls.inference.ConstraintSystemBuilder
|
import org.jetbrains.kotlin.resolve.calls.inference.ConstraintSystemBuilder
|
||||||
@@ -121,51 +122,83 @@ class KotlinConstraintSystemCompleter(
|
|||||||
): Boolean {
|
): Boolean {
|
||||||
val variable = variableForFixation.variable as TypeConstructor
|
val variable = variableForFixation.variable as TypeConstructor
|
||||||
val postponedArguments = getOrderedNotAnalyzedPostponedArguments(topLevelAtoms)
|
val postponedArguments = getOrderedNotAnalyzedPostponedArguments(topLevelAtoms)
|
||||||
|
val hasProperAtom = postponedArguments.any {
|
||||||
|
when (it) {
|
||||||
|
is LambdaWithTypeVariableAsExpectedTypeAtom,
|
||||||
|
is PostponedCallableReferenceAtom -> it.expectedType?.constructor == variable
|
||||||
|
else -> false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (
|
if (
|
||||||
!postponedArguments.any { (it as? LambdaWithTypeVariableAsExpectedTypeAtom)?.expectedType?.constructor == variable } &&
|
!hasProperAtom &&
|
||||||
variableForFixation.hasProperConstraint &&
|
variableForFixation.hasProperConstraint &&
|
||||||
!variableForFixation.hasOnlyTrivialProperConstraint
|
!variableForFixation.hasOnlyTrivialProperConstraint
|
||||||
) return false
|
) return false
|
||||||
|
|
||||||
val postponedAtom = postponedArguments.firstOrNull() ?: return false
|
val postponedAtom = postponedArguments.firstOrNull() ?: return false
|
||||||
when (postponedAtom) {
|
|
||||||
is PostponedCallableReferenceAtom -> {
|
val builtIns = (variable as TypeVariableTypeConstructor).builtIns
|
||||||
analyze(postponedAtom)
|
val csBuilder = (c as NewConstraintSystemImpl).getBuilder()
|
||||||
}
|
val atomToAnalyze = when (postponedAtom) {
|
||||||
is LambdaWithTypeVariableAsExpectedTypeAtom -> {
|
is PostponedCallableReferenceAtom -> postponedAtom.preparePostponedAtomWithTypeVariableAsExpectedType(
|
||||||
var atomToAnalyze = postponedAtom
|
c, csBuilder, variable,
|
||||||
if (postponedAtom.atom.parametersTypes?.all { it != null } != true) {
|
condition = { true },
|
||||||
val functionalType = resultTypeResolver.findResultType(
|
isSuitable = KotlinType::isBuiltinFunctionalTypeOrSubtype,
|
||||||
c,
|
typeVariableCreator = { TypeVariableForCallableReferenceReturnType(builtIns, "_Q") },
|
||||||
c.notFixedTypeVariables.getValue(variable),
|
newAtomCreator = { returnVariable, expectedType ->
|
||||||
TypeVariableDirectionCalculator.ResolveDirection.TO_SUPERTYPE
|
CallableReferenceWithTypeVariableAsExpectedTypeAtom(postponedAtom.atom, expectedType, returnVariable).also {
|
||||||
) as KotlinType
|
postponedAtom.setAnalyzedResults(null, listOf(it))
|
||||||
if (functionalType.isBuiltinFunctionalType) {
|
|
||||||
val csBuilder = c as ConstraintSystemBuilder
|
|
||||||
val builtIns = (variable as TypeVariableTypeConstructor).builtIns
|
|
||||||
val returnVariable = TypeVariableForLambdaReturnType(postponedAtom.atom, builtIns, "_R")
|
|
||||||
csBuilder.registerVariable(returnVariable)
|
|
||||||
val expectedType = KotlinTypeFactory.simpleType(
|
|
||||||
functionalType.annotations,
|
|
||||||
functionalType.constructor,
|
|
||||||
functionalType.arguments.dropLast(1) + returnVariable.defaultType.asTypeProjection(),
|
|
||||||
functionalType.isMarkedNullable
|
|
||||||
)
|
|
||||||
csBuilder.addSubtypeConstraint(
|
|
||||||
expectedType,
|
|
||||||
variable.typeForTypeVariable(),
|
|
||||||
ArgumentConstraintPosition(postponedAtom.atom)
|
|
||||||
)
|
|
||||||
atomToAnalyze = postponedAtom.transformToResolvedLambda(csBuilder, expectedType, returnVariable)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
analyze(atomToAnalyze)
|
)
|
||||||
}
|
is LambdaWithTypeVariableAsExpectedTypeAtom -> postponedAtom.preparePostponedAtomWithTypeVariableAsExpectedType(
|
||||||
|
c, csBuilder, variable,
|
||||||
|
condition = { it.atom.parametersTypes?.all { type -> type != null } != true },
|
||||||
|
isSuitable = KotlinType::isBuiltinFunctionalType,
|
||||||
|
typeVariableCreator = { TypeVariableForLambdaReturnType(postponedAtom.atom, builtIns, "_R") },
|
||||||
|
newAtomCreator = { returnVariable, expectedType ->
|
||||||
|
postponedAtom.transformToResolvedLambda(csBuilder, expectedType, returnVariable)
|
||||||
|
}
|
||||||
|
)
|
||||||
else -> return false
|
else -> return false
|
||||||
}
|
}
|
||||||
|
analyze(atomToAnalyze)
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private inline fun <T : PostponedResolvedAtom, V : NewTypeVariable> T.preparePostponedAtomWithTypeVariableAsExpectedType(
|
||||||
|
c: Context,
|
||||||
|
csBuilder: ConstraintSystemBuilder,
|
||||||
|
variable: TypeConstructor,
|
||||||
|
condition: (T) -> Boolean,
|
||||||
|
isSuitable: KotlinType.() -> Boolean,
|
||||||
|
typeVariableCreator: () -> V,
|
||||||
|
newAtomCreator: (V, SimpleType) -> PostponedResolvedAtom
|
||||||
|
): PostponedResolvedAtom {
|
||||||
|
if (!condition(this)) return this
|
||||||
|
val functionalType = resultTypeResolver.findResultType(
|
||||||
|
c,
|
||||||
|
c.notFixedTypeVariables.getValue(variable),
|
||||||
|
TypeVariableDirectionCalculator.ResolveDirection.TO_SUPERTYPE
|
||||||
|
) as KotlinType
|
||||||
|
if (!functionalType.isSuitable()) return this
|
||||||
|
val returnVariable = typeVariableCreator()
|
||||||
|
csBuilder.registerVariable(returnVariable)
|
||||||
|
val expectedType = KotlinTypeFactory.simpleType(
|
||||||
|
functionalType.annotations,
|
||||||
|
functionalType.constructor,
|
||||||
|
functionalType.arguments.dropLast(1) + returnVariable.defaultType.asTypeProjection(),
|
||||||
|
functionalType.isMarkedNullable
|
||||||
|
)
|
||||||
|
csBuilder.addSubtypeConstraint(
|
||||||
|
expectedType,
|
||||||
|
variable.typeForTypeVariable(),
|
||||||
|
ArgumentConstraintPosition(atom as KotlinCallArgument)
|
||||||
|
)
|
||||||
|
return newAtomCreator(returnVariable, expectedType)
|
||||||
|
}
|
||||||
|
|
||||||
// true if we do analyze
|
// true if we do analyze
|
||||||
private fun analyzePostponeArgumentIfPossible(
|
private fun analyzePostponeArgumentIfPossible(
|
||||||
c: Context,
|
c: Context,
|
||||||
@@ -208,6 +241,7 @@ class KotlinConstraintSystemCompleter(
|
|||||||
fun ResolvedAtom.process(to: LinkedHashSet<TypeConstructor>) {
|
fun ResolvedAtom.process(to: LinkedHashSet<TypeConstructor>) {
|
||||||
val typeVariables = when (this) {
|
val typeVariables = when (this) {
|
||||||
is ResolvedCallAtom -> freshVariablesSubstitutor.freshVariables
|
is ResolvedCallAtom -> freshVariablesSubstitutor.freshVariables
|
||||||
|
is CallableReferenceWithTypeVariableAsExpectedTypeAtom -> listOfNotNull(typeVariableForReturnType)
|
||||||
is ResolvedCallableReferenceAtom -> candidate?.freshSubstitutor?.freshVariables.orEmpty()
|
is ResolvedCallableReferenceAtom -> candidate?.freshSubstitutor?.freshVariables.orEmpty()
|
||||||
is ResolvedLambdaAtom -> listOfNotNull(typeVariableForLambdaReturnType)
|
is ResolvedLambdaAtom -> listOfNotNull(typeVariableForLambdaReturnType)
|
||||||
else -> emptyList()
|
else -> emptyList()
|
||||||
|
|||||||
+8
@@ -20,6 +20,7 @@ import org.jetbrains.kotlin.builtins.KotlinBuiltIns
|
|||||||
import org.jetbrains.kotlin.descriptors.ClassifierDescriptor
|
import org.jetbrains.kotlin.descriptors.ClassifierDescriptor
|
||||||
import org.jetbrains.kotlin.descriptors.TypeParameterDescriptor
|
import org.jetbrains.kotlin.descriptors.TypeParameterDescriptor
|
||||||
import org.jetbrains.kotlin.descriptors.annotations.Annotations
|
import org.jetbrains.kotlin.descriptors.annotations.Annotations
|
||||||
|
import org.jetbrains.kotlin.resolve.calls.model.CallableReferenceKotlinCallArgument
|
||||||
import org.jetbrains.kotlin.resolve.calls.model.LambdaKotlinCallArgument
|
import org.jetbrains.kotlin.resolve.calls.model.LambdaKotlinCallArgument
|
||||||
import org.jetbrains.kotlin.resolve.descriptorUtil.builtIns
|
import org.jetbrains.kotlin.resolve.descriptorUtil.builtIns
|
||||||
import org.jetbrains.kotlin.resolve.descriptorUtil.hasOnlyInputTypesAnnotation
|
import org.jetbrains.kotlin.resolve.descriptorUtil.hasOnlyInputTypesAnnotation
|
||||||
@@ -82,3 +83,10 @@ class TypeVariableForLambdaReturnType(
|
|||||||
) : NewTypeVariable(builtIns, name) {
|
) : NewTypeVariable(builtIns, name) {
|
||||||
override fun hasOnlyInputTypesAnnotation(): Boolean = false
|
override fun hasOnlyInputTypesAnnotation(): Boolean = false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
class TypeVariableForCallableReferenceReturnType(
|
||||||
|
builtIns: KotlinBuiltIns,
|
||||||
|
name: String
|
||||||
|
) : NewTypeVariable(builtIns, name) {
|
||||||
|
override fun hasOnlyInputTypesAnnotation(): Boolean = false
|
||||||
|
}
|
||||||
|
|||||||
+19
-8
@@ -14,7 +14,7 @@ import org.jetbrains.kotlin.resolve.calls.inference.components.FreshVariableNewT
|
|||||||
import org.jetbrains.kotlin.resolve.calls.inference.components.NewTypeSubstitutor
|
import org.jetbrains.kotlin.resolve.calls.inference.components.NewTypeSubstitutor
|
||||||
import org.jetbrains.kotlin.resolve.calls.inference.model.ConstraintStorage
|
import org.jetbrains.kotlin.resolve.calls.inference.model.ConstraintStorage
|
||||||
import org.jetbrains.kotlin.resolve.calls.inference.model.NewConstraintError
|
import org.jetbrains.kotlin.resolve.calls.inference.model.NewConstraintError
|
||||||
import org.jetbrains.kotlin.resolve.calls.inference.model.NewTypeVariable
|
import org.jetbrains.kotlin.resolve.calls.inference.model.TypeVariableForCallableReferenceReturnType
|
||||||
import org.jetbrains.kotlin.resolve.calls.inference.model.TypeVariableForLambdaReturnType
|
import org.jetbrains.kotlin.resolve.calls.inference.model.TypeVariableForLambdaReturnType
|
||||||
import org.jetbrains.kotlin.resolve.calls.tasks.ExplicitReceiverKind
|
import org.jetbrains.kotlin.resolve.calls.tasks.ExplicitReceiverKind
|
||||||
import org.jetbrains.kotlin.types.KotlinType
|
import org.jetbrains.kotlin.types.KotlinType
|
||||||
@@ -91,11 +91,12 @@ interface PostponedResolvedAtomMarker {
|
|||||||
sealed class PostponedResolvedAtom : ResolvedAtom(), PostponedResolvedAtomMarker {
|
sealed class PostponedResolvedAtom : ResolvedAtom(), PostponedResolvedAtomMarker {
|
||||||
abstract override val inputTypes: Collection<UnwrappedType>
|
abstract override val inputTypes: Collection<UnwrappedType>
|
||||||
abstract override val outputType: UnwrappedType?
|
abstract override val outputType: UnwrappedType?
|
||||||
|
abstract val expectedType: UnwrappedType?
|
||||||
}
|
}
|
||||||
|
|
||||||
class LambdaWithTypeVariableAsExpectedTypeAtom(
|
class LambdaWithTypeVariableAsExpectedTypeAtom(
|
||||||
override val atom: LambdaKotlinCallArgument,
|
override val atom: LambdaKotlinCallArgument,
|
||||||
val expectedType: UnwrappedType
|
override val expectedType: UnwrappedType
|
||||||
) : PostponedResolvedAtom() {
|
) : PostponedResolvedAtom() {
|
||||||
override val inputTypes: Collection<UnwrappedType> get() = listOf(expectedType)
|
override val inputTypes: Collection<UnwrappedType> get() = listOf(expectedType)
|
||||||
override val outputType: UnwrappedType? get() = null
|
override val outputType: UnwrappedType? get() = null
|
||||||
@@ -112,7 +113,7 @@ class ResolvedLambdaAtom(
|
|||||||
val parameters: List<UnwrappedType>,
|
val parameters: List<UnwrappedType>,
|
||||||
val returnType: UnwrappedType,
|
val returnType: UnwrappedType,
|
||||||
val typeVariableForLambdaReturnType: TypeVariableForLambdaReturnType?,
|
val typeVariableForLambdaReturnType: TypeVariableForLambdaReturnType?,
|
||||||
val expectedType: UnwrappedType?
|
override val expectedType: UnwrappedType?
|
||||||
) : PostponedResolvedAtom() {
|
) : PostponedResolvedAtom() {
|
||||||
lateinit var resultArguments: List<KotlinCallArgument>
|
lateinit var resultArguments: List<KotlinCallArgument>
|
||||||
private set
|
private set
|
||||||
@@ -131,7 +132,7 @@ class ResolvedLambdaAtom(
|
|||||||
|
|
||||||
abstract class ResolvedCallableReferenceAtom(
|
abstract class ResolvedCallableReferenceAtom(
|
||||||
override val atom: CallableReferenceKotlinCallArgument,
|
override val atom: CallableReferenceKotlinCallArgument,
|
||||||
val expectedType: UnwrappedType?
|
override val expectedType: UnwrappedType?
|
||||||
) : PostponedResolvedAtom() {
|
) : PostponedResolvedAtom() {
|
||||||
var candidate: CallableReferenceCandidate? = null
|
var candidate: CallableReferenceCandidate? = null
|
||||||
private set
|
private set
|
||||||
@@ -157,10 +158,10 @@ class EagerCallableReferenceAtom(
|
|||||||
fun transformToPostponed(): PostponedCallableReferenceAtom = PostponedCallableReferenceAtom(this)
|
fun transformToPostponed(): PostponedCallableReferenceAtom = PostponedCallableReferenceAtom(this)
|
||||||
}
|
}
|
||||||
|
|
||||||
class PostponedCallableReferenceAtom(
|
sealed class AbstractPostponedCallableReferenceAtom(
|
||||||
eagerCallableReferenceAtom: EagerCallableReferenceAtom
|
atom: CallableReferenceKotlinCallArgument,
|
||||||
) : ResolvedCallableReferenceAtom(eagerCallableReferenceAtom.atom, eagerCallableReferenceAtom.expectedType) {
|
expectedType: UnwrappedType?
|
||||||
|
) : ResolvedCallableReferenceAtom(atom, expectedType) {
|
||||||
override val inputTypes: Collection<UnwrappedType>
|
override val inputTypes: Collection<UnwrappedType>
|
||||||
get() = extractInputOutputTypesFromCallableReferenceExpectedType(expectedType)?.inputTypes ?: listOfNotNull(expectedType)
|
get() = extractInputOutputTypesFromCallableReferenceExpectedType(expectedType)?.inputTypes ?: listOfNotNull(expectedType)
|
||||||
|
|
||||||
@@ -168,6 +169,16 @@ class PostponedCallableReferenceAtom(
|
|||||||
get() = extractInputOutputTypesFromCallableReferenceExpectedType(expectedType)?.outputType
|
get() = extractInputOutputTypesFromCallableReferenceExpectedType(expectedType)?.outputType
|
||||||
}
|
}
|
||||||
|
|
||||||
|
class CallableReferenceWithTypeVariableAsExpectedTypeAtom(
|
||||||
|
atom: CallableReferenceKotlinCallArgument,
|
||||||
|
expectedType: UnwrappedType?,
|
||||||
|
val typeVariableForReturnType: TypeVariableForCallableReferenceReturnType?
|
||||||
|
) : AbstractPostponedCallableReferenceAtom(atom, expectedType)
|
||||||
|
|
||||||
|
class PostponedCallableReferenceAtom(
|
||||||
|
eagerCallableReferenceAtom: EagerCallableReferenceAtom
|
||||||
|
) : AbstractPostponedCallableReferenceAtom(eagerCallableReferenceAtom.atom, eagerCallableReferenceAtom.expectedType)
|
||||||
|
|
||||||
class ResolvedCollectionLiteralAtom(
|
class ResolvedCollectionLiteralAtom(
|
||||||
override val atom: CollectionLiteralKotlinCallArgument,
|
override val atom: CollectionLiteralKotlinCallArgument,
|
||||||
val expectedType: UnwrappedType?
|
val expectedType: UnwrappedType?
|
||||||
|
|||||||
@@ -0,0 +1,15 @@
|
|||||||
|
// !LANGUAGE: +NewInference
|
||||||
|
// IGNORE_BACKEND_FIR: JVM_IR
|
||||||
|
// WITH_RUNTIME
|
||||||
|
// ISSUE: KT-32462
|
||||||
|
|
||||||
|
fun decodeValue(value: String): Any {
|
||||||
|
return when (value[0]) {
|
||||||
|
'F' -> String::toFloat
|
||||||
|
'B' -> String::toBoolean
|
||||||
|
'I' -> String::toInt
|
||||||
|
else -> throw IllegalArgumentException("Unexpected value prefix: ${value[0]}")
|
||||||
|
}(value.substring(2))
|
||||||
|
}
|
||||||
|
|
||||||
|
fun box(): String = "OK"
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
// !LANGUAGE: +NewInference
|
||||||
|
// !DIAGNOSTICS: -UNUSED_PARAMETER
|
||||||
|
// ISSUE: KT-32462
|
||||||
|
|
||||||
|
fun <K> select(x: K, y: K): K = x
|
||||||
|
|
||||||
|
interface A {
|
||||||
|
fun toB(): B
|
||||||
|
fun toC(): C
|
||||||
|
fun toC(x: Int): C
|
||||||
|
}
|
||||||
|
interface B
|
||||||
|
interface C
|
||||||
|
|
||||||
|
fun test_1() {
|
||||||
|
select(
|
||||||
|
{ a: A -> a.toB() },
|
||||||
|
{ a: A -> a.toC() }
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
fun test_2() {
|
||||||
|
select(
|
||||||
|
A::toB,
|
||||||
|
<!UNRESOLVED_REFERENCE!>A::toC<!>
|
||||||
|
)
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
// !LANGUAGE: +NewInference
|
||||||
|
// !DIAGNOSTICS: -UNUSED_PARAMETER
|
||||||
|
// ISSUE: KT-32462
|
||||||
|
|
||||||
|
fun <K> select(x: K, y: K): K = x
|
||||||
|
|
||||||
|
interface A {
|
||||||
|
fun toB(): B
|
||||||
|
fun toC(): C
|
||||||
|
fun toC(x: Int): C
|
||||||
|
}
|
||||||
|
interface B
|
||||||
|
interface C
|
||||||
|
|
||||||
|
fun test_1() {
|
||||||
|
<!DEBUG_INFO_EXPRESSION_TYPE("(A) -> kotlin.Any")!>select(
|
||||||
|
{ a: A -> a.toB() },
|
||||||
|
{ a: A -> a.toC() }
|
||||||
|
)<!>
|
||||||
|
}
|
||||||
|
|
||||||
|
fun test_2() {
|
||||||
|
<!DEBUG_INFO_EXPRESSION_TYPE("kotlin.reflect.KFunction1<A, kotlin.Any>")!>select(
|
||||||
|
A::toB,
|
||||||
|
A::toC
|
||||||
|
)<!>
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package
|
||||||
|
|
||||||
|
public fun </*0*/ K> select(/*0*/ x: K, /*1*/ y: K): K
|
||||||
|
public fun test_1(): kotlin.Unit
|
||||||
|
public fun test_2(): kotlin.Unit
|
||||||
|
|
||||||
|
public interface A {
|
||||||
|
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||||
|
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||||
|
public abstract fun toB(): B
|
||||||
|
public abstract fun toC(): C
|
||||||
|
public abstract fun toC(/*0*/ x: kotlin.Int): C
|
||||||
|
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||||
|
}
|
||||||
|
|
||||||
|
public interface B {
|
||||||
|
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||||
|
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||||
|
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||||
|
}
|
||||||
|
|
||||||
|
public interface C {
|
||||||
|
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||||
|
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||||
|
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||||
|
}
|
||||||
@@ -9985,6 +9985,11 @@ public class DiagnosticsTestGenerated extends AbstractDiagnosticsTest {
|
|||||||
runTest("compiler/testData/diagnostics/tests/inference/kt32434.kt");
|
runTest("compiler/testData/diagnostics/tests/inference/kt32434.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("kt32462.kt")
|
||||||
|
public void testKt32462() throws Exception {
|
||||||
|
runTest("compiler/testData/diagnostics/tests/inference/kt32462.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("kt33263.kt")
|
@TestMetadata("kt33263.kt")
|
||||||
public void testKt33263() throws Exception {
|
public void testKt33263() throws Exception {
|
||||||
runTest("compiler/testData/diagnostics/tests/inference/kt33263.kt");
|
runTest("compiler/testData/diagnostics/tests/inference/kt33263.kt");
|
||||||
|
|||||||
Generated
+5
@@ -9980,6 +9980,11 @@ public class DiagnosticsUsingJavacTestGenerated extends AbstractDiagnosticsUsing
|
|||||||
runTest("compiler/testData/diagnostics/tests/inference/kt32434.kt");
|
runTest("compiler/testData/diagnostics/tests/inference/kt32434.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("kt32462.kt")
|
||||||
|
public void testKt32462() throws Exception {
|
||||||
|
runTest("compiler/testData/diagnostics/tests/inference/kt32462.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("kt33263.kt")
|
@TestMetadata("kt33263.kt")
|
||||||
public void testKt33263() throws Exception {
|
public void testKt33263() throws Exception {
|
||||||
runTest("compiler/testData/diagnostics/tests/inference/kt33263.kt");
|
runTest("compiler/testData/diagnostics/tests/inference/kt33263.kt");
|
||||||
|
|||||||
+5
@@ -2253,6 +2253,11 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest {
|
|||||||
runTest("compiler/testData/codegen/box/callableReference/function/kt21787.kt");
|
runTest("compiler/testData/codegen/box/callableReference/function/kt21787.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("kt32462.kt")
|
||||||
|
public void testKt32462() throws Exception {
|
||||||
|
runTest("compiler/testData/codegen/box/callableReference/function/kt32462.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("nestedConstructorFromClass.kt")
|
@TestMetadata("nestedConstructorFromClass.kt")
|
||||||
public void testNestedConstructorFromClass() throws Exception {
|
public void testNestedConstructorFromClass() throws Exception {
|
||||||
runTest("compiler/testData/codegen/box/callableReference/function/nestedConstructorFromClass.kt");
|
runTest("compiler/testData/codegen/box/callableReference/function/nestedConstructorFromClass.kt");
|
||||||
|
|||||||
+5
@@ -2253,6 +2253,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
|||||||
runTest("compiler/testData/codegen/box/callableReference/function/kt21787.kt");
|
runTest("compiler/testData/codegen/box/callableReference/function/kt21787.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("kt32462.kt")
|
||||||
|
public void testKt32462() throws Exception {
|
||||||
|
runTest("compiler/testData/codegen/box/callableReference/function/kt32462.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("nestedConstructorFromClass.kt")
|
@TestMetadata("nestedConstructorFromClass.kt")
|
||||||
public void testNestedConstructorFromClass() throws Exception {
|
public void testNestedConstructorFromClass() throws Exception {
|
||||||
runTest("compiler/testData/codegen/box/callableReference/function/nestedConstructorFromClass.kt");
|
runTest("compiler/testData/codegen/box/callableReference/function/nestedConstructorFromClass.kt");
|
||||||
|
|||||||
+5
@@ -2233,6 +2233,11 @@ public class FirBlackBoxCodegenTestGenerated extends AbstractFirBlackBoxCodegenT
|
|||||||
runTest("compiler/testData/codegen/box/callableReference/function/kt21787.kt");
|
runTest("compiler/testData/codegen/box/callableReference/function/kt21787.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("kt32462.kt")
|
||||||
|
public void testKt32462() throws Exception {
|
||||||
|
runTest("compiler/testData/codegen/box/callableReference/function/kt32462.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("nestedConstructorFromClass.kt")
|
@TestMetadata("nestedConstructorFromClass.kt")
|
||||||
public void testNestedConstructorFromClass() throws Exception {
|
public void testNestedConstructorFromClass() throws Exception {
|
||||||
runTest("compiler/testData/codegen/box/callableReference/function/nestedConstructorFromClass.kt");
|
runTest("compiler/testData/codegen/box/callableReference/function/nestedConstructorFromClass.kt");
|
||||||
|
|||||||
+5
@@ -2233,6 +2233,11 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes
|
|||||||
runTest("compiler/testData/codegen/box/callableReference/function/kt21787.kt");
|
runTest("compiler/testData/codegen/box/callableReference/function/kt21787.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("kt32462.kt")
|
||||||
|
public void testKt32462() throws Exception {
|
||||||
|
runTest("compiler/testData/codegen/box/callableReference/function/kt32462.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("nestedConstructorFromClass.kt")
|
@TestMetadata("nestedConstructorFromClass.kt")
|
||||||
public void testNestedConstructorFromClass() throws Exception {
|
public void testNestedConstructorFromClass() throws Exception {
|
||||||
runTest("compiler/testData/codegen/box/callableReference/function/nestedConstructorFromClass.kt");
|
runTest("compiler/testData/codegen/box/callableReference/function/nestedConstructorFromClass.kt");
|
||||||
|
|||||||
Generated
+5
@@ -1683,6 +1683,11 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest {
|
|||||||
runTest("compiler/testData/codegen/box/callableReference/function/kt21787.kt");
|
runTest("compiler/testData/codegen/box/callableReference/function/kt21787.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("kt32462.kt")
|
||||||
|
public void testKt32462() throws Exception {
|
||||||
|
runTest("compiler/testData/codegen/box/callableReference/function/kt32462.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("nestedConstructorFromClass.kt")
|
@TestMetadata("nestedConstructorFromClass.kt")
|
||||||
public void testNestedConstructorFromClass() throws Exception {
|
public void testNestedConstructorFromClass() throws Exception {
|
||||||
runTest("compiler/testData/codegen/box/callableReference/function/nestedConstructorFromClass.kt");
|
runTest("compiler/testData/codegen/box/callableReference/function/nestedConstructorFromClass.kt");
|
||||||
|
|||||||
+5
@@ -1683,6 +1683,11 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest {
|
|||||||
runTest("compiler/testData/codegen/box/callableReference/function/kt21787.kt");
|
runTest("compiler/testData/codegen/box/callableReference/function/kt21787.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("kt32462.kt")
|
||||||
|
public void testKt32462() throws Exception {
|
||||||
|
runTest("compiler/testData/codegen/box/callableReference/function/kt32462.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("nestedConstructorFromClass.kt")
|
@TestMetadata("nestedConstructorFromClass.kt")
|
||||||
public void testNestedConstructorFromClass() throws Exception {
|
public void testNestedConstructorFromClass() throws Exception {
|
||||||
runTest("compiler/testData/codegen/box/callableReference/function/nestedConstructorFromClass.kt");
|
runTest("compiler/testData/codegen/box/callableReference/function/nestedConstructorFromClass.kt");
|
||||||
|
|||||||
Reference in New Issue
Block a user