[NI] Introduce feature for passing function references with defaults
Relates to KT-8834, we continue reducing differences between old and new inference. Note that as for `SamConversionPerArgument`, this feature is enabled in the compiler and not in the IDE to avoid breaking code for those users that already enabled new inference in the compiler
This commit is contained in:
@@ -1714,6 +1714,16 @@ public class DiagnosticsTestGenerated extends AbstractDiagnosticsTest {
|
||||
runTest("compiler/testData/diagnostics/tests/callableReference/expectedTypeAsSubtypeOfFunctionType.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("functionReferenceWithDefaultValueAsOtherFunctionType.kt")
|
||||
public void testFunctionReferenceWithDefaultValueAsOtherFunctionType() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/callableReference/functionReferenceWithDefaultValueAsOtherFunctionType.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("functionReferenceWithDefaultValueAsOtherFunctionType_enabled.kt")
|
||||
public void testFunctionReferenceWithDefaultValueAsOtherFunctionType_enabled() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/callableReference/functionReferenceWithDefaultValueAsOtherFunctionType_enabled.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt15439_completeCall.kt")
|
||||
public void testKt15439_completeCall() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/callableReference/kt15439_completeCall.kt");
|
||||
|
||||
Generated
+10
@@ -1709,6 +1709,16 @@ public class DiagnosticsUsingJavacTestGenerated extends AbstractDiagnosticsUsing
|
||||
runTest("compiler/testData/diagnostics/tests/callableReference/expectedTypeAsSubtypeOfFunctionType.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("functionReferenceWithDefaultValueAsOtherFunctionType.kt")
|
||||
public void testFunctionReferenceWithDefaultValueAsOtherFunctionType() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/callableReference/functionReferenceWithDefaultValueAsOtherFunctionType.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("functionReferenceWithDefaultValueAsOtherFunctionType_enabled.kt")
|
||||
public void testFunctionReferenceWithDefaultValueAsOtherFunctionType_enabled() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/callableReference/functionReferenceWithDefaultValueAsOtherFunctionType_enabled.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt15439_completeCall.kt")
|
||||
public void testKt15439_completeCall() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/callableReference/kt15439_completeCall.kt");
|
||||
|
||||
@@ -266,6 +266,16 @@ public class CliTestGenerated extends AbstractCliTest {
|
||||
runTest("compiler/testData/cli/jvm/flagAllowingResultAsReturnType.args");
|
||||
}
|
||||
|
||||
@TestMetadata("functionReferenceWithDefaultValuesFeatureIsEnabledWithNewInference.args")
|
||||
public void testFunctionReferenceWithDefaultValuesFeatureIsEnabledWithNewInference() throws Exception {
|
||||
runTest("compiler/testData/cli/jvm/functionReferenceWithDefaultValuesFeatureIsEnabledWithNewInference.args");
|
||||
}
|
||||
|
||||
@TestMetadata("functionReferenceWithDefaultValuesFeatureIsEnabledWithXXNewInference.args")
|
||||
public void testFunctionReferenceWithDefaultValuesFeatureIsEnabledWithXXNewInference() throws Exception {
|
||||
runTest("compiler/testData/cli/jvm/functionReferenceWithDefaultValuesFeatureIsEnabledWithXXNewInference.args");
|
||||
}
|
||||
|
||||
@TestMetadata("help.args")
|
||||
public void testHelp() throws Exception {
|
||||
runTest("compiler/testData/cli/jvm/help.args");
|
||||
|
||||
Reference in New Issue
Block a user