[NI] Turn off KnownTypeParameterSubstitutor for NI
The main consequence of it is that TYPE_MISMATCH range for control structures became wider. Also, for extra safety, don't change behaviour of OI.
This commit is contained in:
+2
-2
@@ -133,8 +133,8 @@ public class ControlStructureTypingUtils {
|
||||
@NotNull KotlinType expectedType,
|
||||
@NotNull LanguageVersionSettings languageVersionSettings
|
||||
) {
|
||||
if (construct == ResolveConstruct.ELVIS
|
||||
|| construct == ResolveConstruct.EXCL_EXCL
|
||||
if (languageVersionSettings.supportsFeature(LanguageFeature.NewInference)
|
||||
|| construct == ResolveConstruct.ELVIS
|
||||
|| TypeUtils.noExpectedType(expectedType)
|
||||
|| TypeUtils.isDontCarePlaceholder(expectedType)
|
||||
|| KotlinBuiltIns.isUnitOrNullableUnit(expectedType)
|
||||
|
||||
Reference in New Issue
Block a user