[FIR] Render original type before smartcasted type in DEBUG_INFO_EXPRESSION_TYPE
This is made for keep consistency with same renderer in FE 1.0
This commit is contained in:
@@ -5,31 +5,31 @@
|
||||
// TESTCASE NUMBER: 1
|
||||
fun test1(x: ClassLevel1?) {
|
||||
if (x!! is ClassLevel2) {
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("ClassLevel1 & ClassLevel1?")!>x<!>
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("ClassLevel1 & ClassLevel1?")!>x<!>.<!UNRESOLVED_REFERENCE!>test2<!>()
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("ClassLevel1? & ClassLevel1")!>x<!>
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("ClassLevel1? & ClassLevel1")!>x<!>.<!UNRESOLVED_REFERENCE!>test2<!>()
|
||||
}
|
||||
}
|
||||
|
||||
// TESTCASE NUMBER: 2
|
||||
fun case_2(x: Any?) {
|
||||
(x as ClassLevel1?)!!
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("ClassLevel1? & kotlin.Any?")!>x<!>
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("ClassLevel1? & kotlin.Any?")!>x<!><!UNSAFE_CALL!>.<!>test1()
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("kotlin.Any? & ClassLevel1?")!>x<!>
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("kotlin.Any? & ClassLevel1?")!>x<!><!UNSAFE_CALL!>.<!>test1()
|
||||
}
|
||||
|
||||
// TESTCASE NUMBER: 3
|
||||
fun case_3(x: Any?) {
|
||||
if (x as ClassLevel1? is ClassLevel1) {
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("ClassLevel1? & kotlin.Any?")!>x<!>
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("ClassLevel1? & kotlin.Any?")!>x<!><!UNSAFE_CALL!>.<!>test1()
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("kotlin.Any? & ClassLevel1?")!>x<!>
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("kotlin.Any? & ClassLevel1?")!>x<!><!UNSAFE_CALL!>.<!>test1()
|
||||
}
|
||||
}
|
||||
|
||||
// TESTCASE NUMBER: 4
|
||||
fun case_4(x: Any?) {
|
||||
if ((x as Class).prop_8 != null) {
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("Class & kotlin.Any?")!>x<!>
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("Class & kotlin.Any?")!>x<!>.prop_8<!UNSAFE_CALL!>.<!>prop_8
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("kotlin.Any? & Class")!>x<!>
|
||||
<!DEBUG_INFO_EXPRESSION_TYPE("kotlin.Any? & Class")!>x<!>.prop_8<!UNSAFE_CALL!>.<!>prop_8
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user