[FIR] Set correct constraint position for callable reference

This fixes a false positive resolution error for callable references
to functions with a type parameter that's annotated with
@OnlyInputTypes.

#KT-57994 Fixed
This commit is contained in:
Kirill Rakhman
2023-04-24 13:35:18 +02:00
committed by Space Team
parent 89acaae819
commit 7f46225bed
7 changed files with 50 additions and 2 deletions
@@ -4223,6 +4223,12 @@ public class DiagnosticCompilerTestFE10TestdataTestGenerated extends AbstractDia
runTest("compiler/testData/diagnostics/tests/callableReference/resolve/noFakeDescriptorForObject.kt");
}
@Test
@TestMetadata("onlyInputTypesOnCallableReference.kt")
public void testOnlyInputTypesOnCallableReference() throws Exception {
runTest("compiler/testData/diagnostics/tests/callableReference/resolve/onlyInputTypesOnCallableReference.kt");
}
@Test
@TestMetadata("overloadAmbiguityForSimpleLastExpressionOfBlock.kt")
public void testOverloadAmbiguityForSimpleLastExpressionOfBlock() throws Exception {
@@ -4223,6 +4223,12 @@ public class LLFirPreresolvedReversedDiagnosticCompilerFE10TestDataTestGenerated
runTest("compiler/testData/diagnostics/tests/callableReference/resolve/noFakeDescriptorForObject.kt");
}
@Test
@TestMetadata("onlyInputTypesOnCallableReference.kt")
public void testOnlyInputTypesOnCallableReference() throws Exception {
runTest("compiler/testData/diagnostics/tests/callableReference/resolve/onlyInputTypesOnCallableReference.kt");
}
@Test
@TestMetadata("overloadAmbiguityForSimpleLastExpressionOfBlock.kt")
public void testOverloadAmbiguityForSimpleLastExpressionOfBlock() throws Exception {