FIR: support CONDITION_TYPE_MISMATCH diagnostic
We report CONDITION_TYPE_MISMATCH on - loop conditions - when branch conditions - binary logic arguments
This commit is contained in:
@@ -108,7 +108,7 @@ fun case_11(x: Any?) {
|
||||
* ISSUES: KT-30376
|
||||
*/
|
||||
fun case_12(x: Any?) {
|
||||
if (x!! as Boolean?) {
|
||||
if (<!CONDITION_TYPE_MISMATCH!>x!! as Boolean?<!>) {
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("kotlin.Any? & kotlin.Any")!>x<!>.<!UNRESOLVED_REFERENCE!>not<!>()
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("kotlin.Any")!>select(x)<!>.<!UNRESOLVED_REFERENCE!>not<!>()
|
||||
}
|
||||
|
||||
@@ -613,7 +613,7 @@ fun case_30(a: ((Float) -> Int?)?, b: Float?) {
|
||||
|
||||
// TESTCASE NUMBER: 31
|
||||
fun case_31(z1: Boolean?, z: Nothing?) {
|
||||
if (false || EnumClassWithNullableProperty.A.prop_1 != z && z1 !== z && z1) {
|
||||
if (false || EnumClassWithNullableProperty.A.prop_1 != z && z1 !== z && <!CONDITION_TYPE_MISMATCH!>z1<!>) {
|
||||
EnumClassWithNullableProperty.A.prop_1
|
||||
EnumClassWithNullableProperty.A.prop_1<!UNSAFE_CALL!>.<!>equals(null)
|
||||
EnumClassWithNullableProperty.A.prop_1.propT
|
||||
|
||||
Reference in New Issue
Block a user