diff --git a/compiler/frontend/src/org/jetbrains/kotlin/resolve/calls/smartcasts/DataFlowInfoImpl.kt b/compiler/frontend/src/org/jetbrains/kotlin/resolve/calls/smartcasts/DataFlowInfoImpl.kt index fa54e4eba17..23a689cc904 100644 --- a/compiler/frontend/src/org/jetbrains/kotlin/resolve/calls/smartcasts/DataFlowInfoImpl.kt +++ b/compiler/frontend/src/org/jetbrains/kotlin/resolve/calls/smartcasts/DataFlowInfoImpl.kt @@ -64,8 +64,7 @@ internal class DataFlowInfoImpl private constructor( nullability: Nullability, languageVersionSettings: LanguageVersionSettings, newTypeInfoBuilder: SetMultimap? = null, - // TODO: remove me in version 1.3! I'm very dirty hack! - // In normal circumstances this should be always true + // XXX: set to false only as a workaround for OI, see KT-26357 for details (in NI everything works automagically) recordUnstable: Boolean = true ) { if (value.isStable || recordUnstable) { diff --git a/compiler/util/src/org/jetbrains/kotlin/config/LanguageVersionSettings.kt b/compiler/util/src/org/jetbrains/kotlin/config/LanguageVersionSettings.kt index 0c5b0e140ce..5c01c0a6d82 100644 --- a/compiler/util/src/org/jetbrains/kotlin/config/LanguageVersionSettings.kt +++ b/compiler/util/src/org/jetbrains/kotlin/config/LanguageVersionSettings.kt @@ -57,7 +57,6 @@ enum class LanguageFeature( ExpectedTypeFromCast(KOTLIN_1_2), DefaultMethodsCallFromJava6TargetError(KOTLIN_1_2), - BooleanElvisBoundSmartCasts(KOTLIN_1_3), RestrictionOfValReassignmentViaBackingField(KOTLIN_1_3, kind = BUG_FIX), NestedClassesInEnumEntryShouldBeInner(KOTLIN_1_3, kind = BUG_FIX), ProhibitDataClassesOverridingCopy(KOTLIN_1_3, kind = BUG_FIX), @@ -104,6 +103,8 @@ enum class LanguageFeature( MultiPlatformProjects(sinceVersion = null, defaultState = State.DISABLED), NewInference(sinceVersion = KOTLIN_1_3, defaultState = State.DISABLED), + // This feature can be enabled only along with new inference, see KT-26357 for details + BooleanElvisBoundSmartCasts(sinceVersion = KOTLIN_1_3, defaultState = State.DISABLED), SamConversionForKotlinFunctions(sinceVersion = KOTLIN_1_3, defaultState = State.DISABLED),