[NI] Fix isSuccessful property for member with LowPriority resolution
The problem was introduced in e40ba73950
This commit is contained in:
+5
@@ -1908,6 +1908,11 @@ public class FirOldFrontendDiagnosticsTestWithStdlibGenerated extends AbstractFi
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/testsWithStdLib/inference/annotationsForResolve"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.fir\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@TestMetadata("checkLowPriorityIsResolvedSuccessfully.kt")
|
||||
public void testCheckLowPriorityIsResolvedSuccessfully() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/annotationsForResolve/checkLowPriorityIsResolvedSuccessfully.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("exactAnnotation.kt")
|
||||
public void testExactAnnotation() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/annotationsForResolve/exactAnnotation.kt");
|
||||
|
||||
@@ -27,7 +27,7 @@ private val INAPPLICABLE_STATUSES = setOf(
|
||||
)
|
||||
|
||||
val ResolutionCandidateApplicability.isSuccess: Boolean
|
||||
get() = this <= ResolutionCandidateApplicability.RESOLVED_WITH_ERROR
|
||||
get() = this <= ResolutionCandidateApplicability.RESOLVED_LOW_PRIORITY
|
||||
|
||||
val CallableDescriptor.isSynthesized: Boolean
|
||||
get() = (this is CallableMemberDescriptor && kind == CallableMemberDescriptor.Kind.SYNTHESIZED)
|
||||
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
class Foo {
|
||||
@Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE")
|
||||
@kotlin.internal.LowPriorityInOverloadResolution
|
||||
val test: Bar = Bar()
|
||||
}
|
||||
|
||||
fun Foo.test() {}
|
||||
class Bar
|
||||
class Scope {
|
||||
operator fun Bar.invoke(f: () -> Unit) {}
|
||||
}
|
||||
|
||||
fun Scope.bar(e: Foo) {
|
||||
e.test {}
|
||||
}
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
class Foo {
|
||||
@Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE")
|
||||
@kotlin.internal.LowPriorityInOverloadResolution
|
||||
val test: Bar = Bar()
|
||||
}
|
||||
|
||||
fun Foo.test() {}
|
||||
class Bar
|
||||
class Scope {
|
||||
operator fun Bar.invoke(<!UNUSED_PARAMETER!>f<!>: () -> Unit) {}
|
||||
}
|
||||
|
||||
fun Scope.bar(e: Foo) {
|
||||
e.test {}
|
||||
}
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
package
|
||||
|
||||
public fun Scope.bar(/*0*/ e: Foo): kotlin.Unit
|
||||
public fun Foo.test(): kotlin.Unit
|
||||
|
||||
public final class Bar {
|
||||
public constructor Bar()
|
||||
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 final class Foo {
|
||||
public constructor Foo()
|
||||
@kotlin.Suppress(names = {"INVISIBLE_MEMBER", "INVISIBLE_REFERENCE"}) @kotlin.internal.LowPriorityInOverloadResolution public final val test: Bar
|
||||
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 final class Scope {
|
||||
public constructor Scope()
|
||||
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 final operator fun Bar.invoke(/*0*/ f: () -> kotlin.Unit): kotlin.Unit
|
||||
}
|
||||
+5
@@ -2858,6 +2858,11 @@ public class DiagnosticsTestWithStdLibGenerated extends AbstractDiagnosticsTestW
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/testsWithStdLib/inference/annotationsForResolve"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.fir\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@TestMetadata("checkLowPriorityIsResolvedSuccessfully.kt")
|
||||
public void testCheckLowPriorityIsResolvedSuccessfully() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/annotationsForResolve/checkLowPriorityIsResolvedSuccessfully.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("exactAnnotation.kt")
|
||||
public void testExactAnnotation() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/annotationsForResolve/exactAnnotation.kt");
|
||||
|
||||
compiler/tests/org/jetbrains/kotlin/checkers/javac/DiagnosticsTestWithStdLibUsingJavacGenerated.java
Generated
+5
@@ -2858,6 +2858,11 @@ public class DiagnosticsTestWithStdLibUsingJavacGenerated extends AbstractDiagno
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/testsWithStdLib/inference/annotationsForResolve"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.fir\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@TestMetadata("checkLowPriorityIsResolvedSuccessfully.kt")
|
||||
public void testCheckLowPriorityIsResolvedSuccessfully() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/annotationsForResolve/checkLowPriorityIsResolvedSuccessfully.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("exactAnnotation.kt")
|
||||
public void testExactAnnotation() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/annotationsForResolve/exactAnnotation.kt");
|
||||
|
||||
Reference in New Issue
Block a user