Introduce compiler key to disable compatibility resolution mechanism

Enable it if one was using new inferene before 1.4

 #KT-40128 Fixed
 #KT-40112 Fixed
 #KT-40113 Fixed
This commit is contained in:
Mikhail Zarechenskiy
2020-07-09 00:26:10 +03:00
parent c1fd891916
commit 0c8b847ae6
17 changed files with 106 additions and 9 deletions
@@ -388,6 +388,7 @@ abstract class CommonCompilerArguments : CommonToolArguments() {
put(LanguageFeature.NewInference, LanguageFeature.State.ENABLED)
put(LanguageFeature.SamConversionPerArgument, LanguageFeature.State.ENABLED)
put(LanguageFeature.FunctionReferenceWithDefaultValueAsOtherType, LanguageFeature.State.ENABLED)
put(LanguageFeature.DisableCompatibilityModeForNewInference, LanguageFeature.State.ENABLED)
}
if (inlineClasses) {
@@ -467,6 +468,8 @@ abstract class CommonCompilerArguments : CommonToolArguments() {
if (!functionReferenceWithDefaultValueFeaturePassedExplicitly)
put(LanguageFeature.FunctionReferenceWithDefaultValueAsOtherType, LanguageFeature.State.ENABLED)
put(LanguageFeature.DisableCompatibilityModeForNewInference, LanguageFeature.State.ENABLED)
}
if (featuresThatForcePreReleaseBinaries.isNotEmpty()) {