[FIR] Update tests for previous commit

This commit is contained in:
Dmitriy Novozhilov
2019-08-02 14:40:25 +03:00
parent e48959350c
commit 57a2665b00
21 changed files with 187 additions and 108 deletions
@@ -27,7 +27,7 @@ FILE: recursiveCallOnWhenWithSealedClass.kt
}
public final fun unwrap(): R|class error: Unresolved name: meat| {
public final fun unwrap(): <ERROR TYPE REF: No type for block> {
^unwrap when (this#) {
($subj$ is R|Maybe.Nope|) -> {
throw R|java/lang/Exception.Exception|(String())
+17
View File
@@ -0,0 +1,17 @@
fun <T> materialize(): T = throw Exception()
interface A
fun takeA(a: A) {}
fun test() {
takeA(
try {
materialize()
} catch (e: Exception) {
materialize()
} finally {
materialize() // Should be an errror
}
)
}
+20
View File
@@ -0,0 +1,20 @@
FILE: tryInference.kt
public final fun <T> materialize(): R|T| {
^materialize throw R|java/lang/Exception.Exception|()
}
public abstract interface A : R|kotlin/Any| {
}
public final fun takeA(a: R|A|): R|kotlin/Unit| {
}
public final fun test(): R|kotlin/Unit| {
R|/takeA|(try {
R|/materialize|<R|A|>()
}
catch (e: R|java/lang/Exception|) {
R|/materialize|<R|A|>()
}
finally {
R|/materialize|<R|kotlin/Nothing|>()
}
)
}
@@ -0,0 +1,9 @@
fun <T> materialize(): T = throw Exception()
interface A
fun takeA(a: A) {}
fun test() {
takeA(if(true) materialize() else materialize())
}
+19
View File
@@ -0,0 +1,19 @@
FILE: whenInference.kt
public final fun <T> materialize(): R|T| {
^materialize throw R|java/lang/Exception.Exception|()
}
public abstract interface A : R|kotlin/Any| {
}
public final fun takeA(a: R|A|): R|kotlin/Unit| {
}
public final fun test(): R|kotlin/Unit| {
R|/takeA|(when () {
Boolean(true) -> {
R|/materialize|<R|A|>()
}
else -> {
R|/materialize|<R|A|>()
}
}
)
}
@@ -139,6 +139,11 @@ public class FirResolveTestCaseGenerated extends AbstractFirResolveTestCase {
runTest("compiler/fir/resolve/testData/resolve/treeSet.kt");
}
@TestMetadata("tryInference.kt")
public void testTryInference() throws Exception {
runTest("compiler/fir/resolve/testData/resolve/tryInference.kt");
}
@TestMetadata("TwoDeclarationsInSameFile.kt")
public void testTwoDeclarationsInSameFile() throws Exception {
runTest("compiler/fir/resolve/testData/resolve/TwoDeclarationsInSameFile.kt");
@@ -169,6 +174,11 @@ public class FirResolveTestCaseGenerated extends AbstractFirResolveTestCase {
runTest("compiler/fir/resolve/testData/resolve/typeParameterVsNested.kt");
}
@TestMetadata("whenInference.kt")
public void testWhenInference() throws Exception {
runTest("compiler/fir/resolve/testData/resolve/whenInference.kt");
}
@TestMetadata("compiler/fir/resolve/testData/resolve/arguments")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
@@ -6,10 +6,10 @@ FILE fqName:<root> fileName:/breakContinueInLoopHeader.kt
condition: CONST Boolean type=kotlin.Boolean value=true
body: BLOCK type=kotlin.Unit origin=null
WHILE label=L2 origin=WHILE_LOOP
condition: BLOCK type=kotlin.Unit origin=ELVIS
condition: BLOCK type=kotlin.Boolean origin=ELVIS
VAR name:<elvis> type:kotlin.Boolean? [val]
GET_VAR 'c: kotlin.Boolean? declared in <root>.test1' type=kotlin.Boolean? origin=null
WHEN type=kotlin.Unit origin=ELVIS
WHEN type=kotlin.Boolean origin=ELVIS
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val <elvis>: kotlin.Boolean? [val] declared in <root>.test1' type=kotlin.Boolean? origin=null
@@ -26,10 +26,10 @@ FILE fqName:<root> fileName:/breakContinueInLoopHeader.kt
condition: CONST Boolean type=kotlin.Boolean value=true
body: BLOCK type=kotlin.Unit origin=null
WHILE label=L2 origin=WHILE_LOOP
condition: BLOCK type=kotlin.Unit origin=ELVIS
condition: BLOCK type=kotlin.Boolean origin=ELVIS
VAR name:<elvis> type:kotlin.Boolean? [val]
GET_VAR 'c: kotlin.Boolean? declared in <root>.test2' type=kotlin.Boolean? origin=null
WHEN type=kotlin.Unit origin=ELVIS
WHEN type=kotlin.Boolean origin=ELVIS
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val <elvis>: kotlin.Boolean? [val] declared in <root>.test2' type=kotlin.Boolean? origin=null
@@ -120,9 +120,11 @@ FILE fqName:<root> fileName:/breakContinueInLoopHeader.kt
CALL 'public final fun inc (): kotlin.Int declared in kotlin.Int' type=kotlin.Int origin=null
$this: GET_VAR 'val <unary>: kotlin.Int [val] declared in <root>.test5' type=kotlin.Int origin=null
GET_VAR 'var j: kotlin.Int [var] declared in <root>.test5' type=kotlin.Int origin=null
condition: WHEN type=kotlin.Unit origin=IF
condition: WHEN type=kotlin.Boolean origin=IF
BRANCH
if: ERROR_CALL 'Comparison of arguments with different types: kotlin/Int, kotlin/Unit' type=kotlin.Boolean
if: CALL 'public final fun greaterOrEqual (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=GTEQ
arg0: GET_VAR 'var j: kotlin.Int [var] declared in <root>.test5' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.Int value=3
then: CONST Boolean type=kotlin.Boolean value=false
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
@@ -131,5 +133,5 @@ FILE fqName:<root> fileName:/breakContinueInLoopHeader.kt
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'var i: kotlin.Int [var] declared in <root>.test5' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.Unit value=3
arg1: CONST Int type=kotlin.Int value=3
then: BREAK label=null loop.label=Outer
+4 -4
View File
@@ -50,23 +50,23 @@ FILE fqName:<root> fileName:/elvis.kt
VALUE_PARAMETER name:a index:0 type:kotlin.Any?
VALUE_PARAMETER name:b index:1 type:kotlin.Any?
BLOCK_BODY
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.String
GET_VAR 'b: kotlin.Any? declared in <root>.test3' type=kotlin.Any? origin=null
then: RETURN type=kotlin.Nothing from='public final fun test3 (a: kotlin.Any?, b: kotlin.Any?): kotlin.String declared in <root>'
CONST String type=kotlin.String value=""
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.String?
GET_VAR 'a: kotlin.Any? declared in <root>.test3' type=kotlin.Any? origin=null
then: RETURN type=kotlin.Nothing from='public final fun test3 (a: kotlin.Any?, b: kotlin.Any?): kotlin.String declared in <root>'
CONST String type=kotlin.String value=""
RETURN type=kotlin.Nothing from='public final fun test3 (a: kotlin.Any?, b: kotlin.Any?): kotlin.String declared in <root>'
BLOCK type=kotlin.String origin=ELVIS
BLOCK type=kotlin.Any? origin=ELVIS
VAR name:<elvis> type:kotlin.Any? [val]
GET_VAR 'a: kotlin.Any? declared in <root>.test3' type=kotlin.Any? origin=null
WHEN type=kotlin.String origin=ELVIS
WHEN type=kotlin.Any? origin=ELVIS
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val <elvis>: kotlin.Any? [val] declared in <root>.test3' type=kotlin.Any? origin=null
@@ -19,7 +19,7 @@ FILE fqName:<root> fileName:/floatingPointCompareTo.kt
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: ERROR_CALL 'Unresolved reference: <Inapplicable(INAPPLICABLE): [kotlin/Double.compareTo, kotlin/Double.compareTo, kotlin/Double.compareTo, kotlin/Double.compareTo, kotlin/Double.compareTo, kotlin/Double.compareTo]>#' type=IrErrorType
GET_VAR 'y: kotlin.Any declared in <root>.test2d' type=kotlin.Any origin=null
arg1: CONST Int type=kotlin.Boolean value=0
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
@@ -42,7 +42,7 @@ FILE fqName:<root> fileName:/floatingPointCompareTo.kt
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: ERROR_CALL 'Unresolved reference: <Unresolved name: compareTo>#' type=IrErrorType
GET_VAR 'y: kotlin.Any declared in <root>.test3d' type=kotlin.Any origin=null
arg1: CONST Int type=kotlin.Boolean value=0
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
@@ -66,7 +66,7 @@ FILE fqName:<root> fileName:/floatingPointCompareTo.kt
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: ERROR_CALL 'Unresolved reference: <Inapplicable(INAPPLICABLE): [kotlin/Float.compareTo, kotlin/Float.compareTo, kotlin/Float.compareTo, kotlin/Float.compareTo, kotlin/Float.compareTo, kotlin/Float.compareTo]>#' type=IrErrorType
GET_VAR 'y: kotlin.Any declared in <root>.test2f' type=kotlin.Any origin=null
arg1: CONST Int type=kotlin.Boolean value=0
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
@@ -89,7 +89,7 @@ FILE fqName:<root> fileName:/floatingPointCompareTo.kt
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: ERROR_CALL 'Unresolved reference: <Unresolved name: compareTo>#' type=IrErrorType
GET_VAR 'y: kotlin.Any declared in <root>.test3f' type=kotlin.Any origin=null
arg1: CONST Int type=kotlin.Boolean value=0
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
@@ -112,7 +112,7 @@ FILE fqName:<root> fileName:/floatingPointCompareTo.kt
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: ERROR_CALL 'Unresolved reference: <Unresolved name: compareTo>#' type=IrErrorType
GET_VAR 'y: kotlin.Any declared in <root>.testFD' type=kotlin.Any origin=null
arg1: CONST Int type=kotlin.Boolean value=0
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
@@ -135,7 +135,7 @@ FILE fqName:<root> fileName:/floatingPointCompareTo.kt
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: ERROR_CALL 'Unresolved reference: <Unresolved name: compareTo>#' type=IrErrorType
GET_VAR 'y: kotlin.Any declared in <root>.testDF' type=kotlin.Any origin=null
arg1: CONST Int type=kotlin.Boolean value=0
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
@@ -158,7 +158,7 @@ FILE fqName:<root> fileName:/floatingPointCompareTo.kt
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: ERROR_CALL 'Unresolved reference: <Inapplicable(INAPPLICABLE): [kotlin/Float.compareTo, kotlin/Float.compareTo, kotlin/Float.compareTo, kotlin/Float.compareTo, kotlin/Float.compareTo, kotlin/Float.compareTo]>#' type=IrErrorType
GET_VAR 'x: kotlin.Any declared in <root>.test2fr' type=kotlin.Any origin=null
arg1: CONST Int type=kotlin.Boolean value=0
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
@@ -174,7 +174,7 @@ FILE fqName:<root> fileName:/floatingPointCompareTo.kt
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: ERROR_CALL 'Unresolved reference: <Inapplicable(INAPPLICABLE): [kotlin/Float.compareTo, kotlin/Float.compareTo, kotlin/Float.compareTo, kotlin/Float.compareTo, kotlin/Float.compareTo, kotlin/Float.compareTo]>#' type=IrErrorType
GET_VAR 'x: kotlin.Any declared in <root>.test3fr' type=kotlin.Any origin=null
arg1: CONST Int type=kotlin.Boolean value=0
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
@@ -9,7 +9,7 @@ FILE fqName:<root> fileName:/whenByFloatingPoint.kt
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp0_subject: kotlin.Double [val] declared in <root>.testSimple' type=kotlin.Double origin=null
arg1: CONST Double type=kotlin.Int value=0.0
arg1: CONST Double type=kotlin.Double value=0.0
then: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
@@ -17,7 +17,7 @@ FILE fqName:<root> fileName:/whenByFloatingPoint.kt
FUN name:testSmartCastInWhenSubject visibility:public modality:FINAL <> (x:kotlin.Any) returnType:kotlin.Int
VALUE_PARAMETER name:x index:0 type:kotlin.Any
BLOCK_BODY
WHEN type=kotlin.Int origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.Double
GET_VAR 'x: kotlin.Any declared in <root>.testSmartCastInWhenSubject' type=kotlin.Any origin=null
@@ -31,7 +31,7 @@ FILE fqName:<root> fileName:/whenByFloatingPoint.kt
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp1_subject: kotlin.Any [val] declared in <root>.testSmartCastInWhenSubject' type=kotlin.Any origin=null
arg1: CONST Double type=kotlin.Int value=0.0
arg1: CONST Double type=kotlin.Double value=0.0
then: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
@@ -40,7 +40,7 @@ FILE fqName:<root> fileName:/whenByFloatingPoint.kt
VALUE_PARAMETER name:x index:0 type:kotlin.Double
VALUE_PARAMETER name:y index:1 type:kotlin.Any
BLOCK_BODY
WHEN type=kotlin.Int origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.Double
GET_VAR 'y: kotlin.Any declared in <root>.testSmartCastInWhenCondition' type=kotlin.Any origin=null
@@ -74,7 +74,7 @@ FILE fqName:<root> fileName:/whenByFloatingPoint.kt
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp3_subject: kotlin.Any [val] declared in <root>.testSmartCastInWhenConditionInBranch' type=kotlin.Any origin=null
arg1: CONST Double type=kotlin.Int value=0.0
arg1: CONST Double type=kotlin.Double value=0.0
then: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
@@ -83,14 +83,14 @@ FILE fqName:<root> fileName:/whenByFloatingPoint.kt
VALUE_PARAMETER name:x index:0 type:kotlin.Any
VALUE_PARAMETER name:y index:1 type:kotlin.Any
BLOCK_BODY
WHEN type=kotlin.Int origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.Double
GET_VAR 'x: kotlin.Any declared in <root>.testSmartCastToDifferentTypes' type=kotlin.Any origin=null
then: RETURN type=kotlin.Nothing from='public final fun testSmartCastToDifferentTypes (x: kotlin.Any, y: kotlin.Any): kotlin.Int declared in <root>'
CALL 'public final fun unaryMinus (): kotlin.Int declared in kotlin.Int' type=kotlin.Int origin=null
$this: CONST Int type=kotlin.Int value=1
WHEN type=kotlin.Int origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.Float
GET_VAR 'y: kotlin.Any declared in <root>.testSmartCastToDifferentTypes' type=kotlin.Any origin=null
@@ -35,7 +35,7 @@ FILE fqName:<root> fileName:/implicitCastToNonNull.kt
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=T of <root>.test3
GET_VAR 'x: kotlin.Any declared in <root>.test3' type=kotlin.Any origin=null
then: CONST Int type=IrErrorType value=0
then: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: ERROR_CALL 'Unresolved reference: <Unresolved name: length>#' type=IrErrorType
@@ -48,7 +48,7 @@ FILE fqName:<root> fileName:/implicitCastToNonNull.kt
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=T of <root>.test4
GET_VAR 'x: kotlin.Any? declared in <root>.test4' type=kotlin.Any? origin=null
then: CONST Int type=IrErrorType value=0
then: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: ERROR_CALL 'Unresolved reference: <Unresolved name: length>#' type=IrErrorType
@@ -4,7 +4,7 @@ FILE fqName:<root> fileName:/implicitCastToTypeParameter.kt
$receiver: VALUE_PARAMETER name:<this> type:kotlin.Any
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun test1 <T> (): T of <root>.test1? [inline] declared in <root>'
WHEN type=T of <root>.test1? origin=IF
WHEN type=kotlin.Any? origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=T of <root>.test1
ERROR_CALL 'Unresolved reference: this#' type=kotlin.Any
@@ -33,7 +33,7 @@ FILE fqName:<root> fileName:/implicitCastToTypeParameter.kt
correspondingProperty: PROPERTY name:asT visibility:public modality:FINAL [val]
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun <get-asT> (): T of <uninitialized parent>? declared in <root>'
WHEN type=T of <uninitialized parent>? origin=IF
WHEN type=IrErrorType origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=T of <uninitialized parent>
ERROR_CALL 'Unresolved reference: this#' type=IrErrorType
+7 -5
View File
@@ -10,19 +10,21 @@ FILE fqName:<root> fileName:/kt24804.kt
VAR name:z type:kotlin.Int [var]
CONST Int type=kotlin.Int value=10
DO_WHILE label=l2 origin=DO_WHILE_LOOP
body: BLOCK type=kotlin.String origin=null
body: BLOCK type=kotlin.Unit origin=null
SET_VAR 'var z: kotlin.Int [var] declared in <root>.run' type=kotlin.Int origin=null
CONST Int type=kotlin.Int value=1
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: ERROR_CALL 'Comparison of arguments with different types: kotlin/Int, kotlin/String' type=kotlin.Boolean
if: CALL 'public final fun greater (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=GT
arg0: GET_VAR 'var z: kotlin.Int [var] declared in <root>.run' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.Int value=100
then: RETURN type=kotlin.Nothing from='public final fun run (x: kotlin.Boolean, y: kotlin.Boolean): kotlin.String declared in <root>'
CONST String type=kotlin.String value="NOT_OK"
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: GET_VAR 'x: kotlin.Boolean declared in <root>.run' type=kotlin.Boolean origin=null
then: ERROR_EXPR 'Unbound loop: continue@@@[ERROR_EXPR(Cannot bind label l1 to a loop)] ' type=kotlin.Nothing
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: GET_VAR 'y: kotlin.Boolean declared in <root>.run' type=kotlin.Boolean origin=null
then: CONTINUE label=l2 loop.label=l2
+24 -24
View File
@@ -11,36 +11,36 @@ FILE fqName:<root> fileName:/kt30796.kt
VALUE_PARAMETER name:value2 index:1 type:T of <root>.test
BLOCK_BODY
VAR name:x1 type:kotlin.Any [val]
BLOCK type=kotlin.Any origin=ELVIS
BLOCK type=kotlin.Any? origin=ELVIS
VAR name:<elvis> type:T of <root>.test [val]
GET_VAR 'value: T of <root>.test declared in <root>.test' type=T of <root>.test origin=null
WHEN type=kotlin.Any origin=ELVIS
WHEN type=kotlin.Any? origin=ELVIS
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
arg1: CONST Null type=kotlin.Nothing? value=null
then: CONST Int type=kotlin.Any value=42
then: CONST Int type=kotlin.Int value=42
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
VAR name:x2 type:kotlin.Any [val]
BLOCK type=kotlin.Any origin=ELVIS
BLOCK type=kotlin.Any? origin=ELVIS
VAR name:<elvis> type:T of <root>.test [val]
GET_VAR 'value: T of <root>.test declared in <root>.test' type=T of <root>.test origin=null
WHEN type=kotlin.Any origin=ELVIS
WHEN type=kotlin.Any? origin=ELVIS
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
arg1: CONST Null type=kotlin.Nothing? value=null
then: BLOCK type=kotlin.Any origin=ELVIS
then: BLOCK type=kotlin.Any? origin=ELVIS
VAR name:<elvis> type:T of <root>.test [val]
GET_VAR 'value2: T of <root>.test declared in <root>.test' type=T of <root>.test origin=null
WHEN type=kotlin.Any origin=ELVIS
WHEN type=kotlin.Any? origin=ELVIS
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
arg1: CONST Null type=kotlin.Nothing? value=null
then: CONST Int type=kotlin.Any value=42
then: CONST Int type=kotlin.Int value=42
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
@@ -48,7 +48,7 @@ FILE fqName:<root> fileName:/kt30796.kt
if: CONST Boolean type=kotlin.Boolean value=true
then: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
VAR name:x3 type:kotlin.Any [val]
BLOCK type=kotlin.Any origin=ELVIS
BLOCK type=kotlin.Any? origin=ELVIS
VAR name:<elvis> type:T of <root>.test [val]
BLOCK type=T of <root>.test origin=ELVIS
VAR name:<elvis> type:T of <root>.test [val]
@@ -62,17 +62,17 @@ FILE fqName:<root> fileName:/kt30796.kt
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
WHEN type=kotlin.Any origin=ELVIS
WHEN type=kotlin.Any? origin=ELVIS
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
arg1: CONST Null type=kotlin.Nothing? value=null
then: CONST Int type=kotlin.Any value=42
then: CONST Int type=kotlin.Int value=42
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
VAR name:x4 type:kotlin.Any [val]
BLOCK type=kotlin.Any origin=ELVIS
BLOCK type=kotlin.Any? origin=ELVIS
VAR name:<elvis> type:T of <root>.test [val]
BLOCK type=T of <root>.test origin=ELVIS
VAR name:<elvis> type:T of <root>.test [val]
@@ -86,31 +86,31 @@ FILE fqName:<root> fileName:/kt30796.kt
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
WHEN type=kotlin.Any origin=ELVIS
WHEN type=kotlin.Any? origin=ELVIS
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
arg1: CONST Null type=kotlin.Nothing? value=null
then: CONST Int type=kotlin.Any value=42
then: CONST Int type=kotlin.Int value=42
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
VAR name:x5 type:kotlin.Any [val]
BLOCK type=kotlin.Any origin=ELVIS
BLOCK type=kotlin.Int origin=ELVIS
VAR name:<elvis> type:kotlin.Nothing [val]
CALL 'public final fun magic <T> (): T of <root>.magic declared in <root>' type=kotlin.Nothing origin=null
<T>: <none>
WHEN type=kotlin.Any origin=ELVIS
WHEN type=kotlin.Int origin=ELVIS
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val <elvis>: kotlin.Nothing [val] declared in <root>.test' type=kotlin.Nothing origin=null
arg1: CONST Null type=kotlin.Nothing? value=null
then: CONST Int type=kotlin.Any value=42
then: CONST Int type=kotlin.Int value=42
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: GET_VAR 'val <elvis>: kotlin.Nothing [val] declared in <root>.test' type=kotlin.Nothing origin=null
VAR name:x6 type:kotlin.Any [val]
BLOCK type=kotlin.Any origin=ELVIS
BLOCK type=kotlin.Any? origin=ELVIS
VAR name:<elvis> type:T of <root>.test [val]
BLOCK type=T of <root>.test origin=ELVIS
VAR name:<elvis> type:T of <root>.test [val]
@@ -120,22 +120,22 @@ FILE fqName:<root> fileName:/kt30796.kt
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
arg1: CONST Null type=kotlin.Nothing? value=null
then: CALL 'public final fun magic <T> (): T of <root>.magic declared in <root>' type=kotlin.Nothing origin=null
then: CALL 'public final fun magic <T> (): T of <root>.magic declared in <root>' type=T of <root>.test origin=null
<T>: <none>
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
WHEN type=kotlin.Any origin=ELVIS
WHEN type=kotlin.Any? origin=ELVIS
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
arg1: CONST Null type=kotlin.Nothing? value=null
then: CONST Int type=kotlin.Any value=42
then: CONST Int type=kotlin.Int value=42
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
VAR name:x7 type:kotlin.Any [val]
BLOCK type=kotlin.Any origin=ELVIS
BLOCK type=kotlin.Any? origin=ELVIS
VAR name:<elvis> type:T of <root>.test [val]
BLOCK type=T of <root>.test origin=ELVIS
VAR name:<elvis> type:kotlin.Nothing [val]
@@ -150,12 +150,12 @@ FILE fqName:<root> fileName:/kt30796.kt
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: GET_VAR 'val <elvis>: kotlin.Nothing [val] declared in <root>.test' type=kotlin.Nothing origin=null
WHEN type=kotlin.Any origin=ELVIS
WHEN type=kotlin.Any? origin=ELVIS
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
arg1: CONST Null type=kotlin.Nothing? value=null
then: CONST Int type=kotlin.Any value=42
then: CONST Int type=kotlin.Int value=42
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: GET_VAR 'val <elvis>: T of <root>.test [val] declared in <root>.test' type=T of <root>.test origin=null
@@ -2,7 +2,7 @@ FILE fqName:<root> fileName:/samConversionsWithSmartCasts.kt
FUN name:test1 visibility:public modality:FINAL <> (a:kotlin.Function0<kotlin.Unit>) returnType:kotlin.Unit
VALUE_PARAMETER name:a index:0 type:kotlin.Function0<kotlin.Unit>
BLOCK_BODY
WHEN type=kotlin.Unit origin=IF
WHEN type=IrErrorType origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=java.lang.Runnable
GET_VAR 'a: kotlin.Function0<kotlin.Unit> declared in <root>.test1' type=kotlin.Function0<kotlin.Unit> origin=null
@@ -11,7 +11,7 @@ FILE fqName:<root> fileName:/samConversionsWithSmartCasts.kt
FUN name:test2 visibility:public modality:FINAL <> (a:kotlin.Function0<kotlin.Unit>) returnType:kotlin.Unit
VALUE_PARAMETER name:a index:0 type:kotlin.Function0<kotlin.Unit>
BLOCK_BODY
WHEN type=kotlin.Unit origin=IF
WHEN type=IrErrorType origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=java.lang.Runnable
GET_VAR 'a: kotlin.Function0<kotlin.Unit> declared in <root>.test2' type=kotlin.Function0<kotlin.Unit> origin=null
@@ -20,7 +20,7 @@ FILE fqName:<root> fileName:/samConversionsWithSmartCasts.kt
FUN name:test3 visibility:public modality:FINAL <> (a:kotlin.Function0<kotlin.Unit>) returnType:kotlin.Unit
VALUE_PARAMETER name:a index:0 type:kotlin.Function0<kotlin.Unit>
BLOCK_BODY
WHEN type=kotlin.Unit origin=IF
WHEN type=IrErrorType origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=java.lang.Runnable
GET_VAR 'a: kotlin.Function0<kotlin.Unit> declared in <root>.test3' type=kotlin.Function0<kotlin.Unit> origin=null
@@ -31,7 +31,7 @@ FILE fqName:<root> fileName:/samConversionsWithSmartCasts.kt
VALUE_PARAMETER name:a index:0 type:kotlin.Function0<kotlin.Unit>
VALUE_PARAMETER name:b index:1 type:kotlin.Function0<kotlin.Unit>
BLOCK_BODY
WHEN type=kotlin.Unit origin=IF
WHEN type=IrErrorType origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=java.lang.Runnable
GET_VAR 'a: kotlin.Function0<kotlin.Unit> declared in <root>.test4' type=kotlin.Function0<kotlin.Unit> origin=null
@@ -41,7 +41,7 @@ FILE fqName:<root> fileName:/samConversionsWithSmartCasts.kt
FUN name:test5 visibility:public modality:FINAL <> (a:kotlin.Any) returnType:kotlin.Unit
VALUE_PARAMETER name:a index:0 type:kotlin.Any
BLOCK_BODY
WHEN type=kotlin.Unit origin=IF
WHEN type=IrErrorType origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=java.lang.Runnable
GET_VAR 'a: kotlin.Any declared in <root>.test5' type=kotlin.Any origin=null
@@ -50,7 +50,7 @@ FILE fqName:<root> fileName:/samConversionsWithSmartCasts.kt
FUN name:test5x visibility:public modality:FINAL <> (a:kotlin.Any) returnType:kotlin.Unit
VALUE_PARAMETER name:a index:0 type:kotlin.Any
BLOCK_BODY
WHEN type=kotlin.Unit origin=IF
WHEN type=IrErrorType origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=java.lang.Runnable
GET_VAR 'a: kotlin.Any declared in <root>.test5x' type=kotlin.Any origin=null
@@ -143,61 +143,61 @@ FILE fqName:<root> fileName:/useImportedMember.kt
VALUE_PARAMETER name:g index:0 type:kotlin.String
FUN name:box visibility:public modality:FINAL <> () returnType:kotlin.String
BLOCK_BODY
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun not (): kotlin.Boolean declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCLEQ
$this: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EXCLEQ
arg0: CALL 'public final fun f (s: kotlin.Int): kotlin.Int declared in <root>.C' type=kotlin.Int origin=null
s: CONST Int type=kotlin.Int value=1
arg1: CONST Int type=kotlin.String value=1
arg1: CONST Int type=kotlin.Int value=1
then: RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'
CONST String type=kotlin.String value="1"
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun not (): kotlin.Boolean declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCLEQ
$this: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EXCLEQ
arg0: CALL 'public final fun f (s: kotlin.String): kotlin.Int declared in <root>.C' type=kotlin.Int origin=null
s: CONST String type=kotlin.String value="s"
arg1: CONST Int type=kotlin.String value=2
arg1: CONST Int type=kotlin.Int value=2
then: RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'
CONST String type=kotlin.String value="2"
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun not (): kotlin.Boolean declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCLEQ
$this: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EXCLEQ
arg0: CALL 'public final fun f (): kotlin.Int declared in <root>.C' type=kotlin.Int origin=null
$this: CONST Boolean type=kotlin.Boolean value=true
arg1: CONST Int type=kotlin.String value=3
arg1: CONST Int type=kotlin.Int value=3
then: RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'
CONST String type=kotlin.String value="3"
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun not (): kotlin.Boolean declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCLEQ
$this: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EXCLEQ
arg0: CALL 'public final fun <get-p> (): kotlin.Int declared in <root>.C' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.String value=4
arg1: CONST Int type=kotlin.Int value=4
then: RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'
CONST String type=kotlin.String value="4"
SET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:p type:kotlin.Int visibility:public' type=kotlin.Int origin=null
value: CONST Int type=kotlin.Int value=5
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun not (): kotlin.Boolean declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCLEQ
$this: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EXCLEQ
arg0: CALL 'public final fun <get-p> (): kotlin.Int declared in <root>.C' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.String value=5
arg1: CONST Int type=kotlin.Int value=5
then: RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'
CONST String type=kotlin.String value="5"
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun not (): kotlin.Boolean declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCLEQ
$this: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EXCLEQ
arg0: CALL 'public final fun <get-ext> (): kotlin.Int declared in <root>.C' type=kotlin.Int origin=null
$this: CONST Int type=kotlin.Int value=5
arg1: CONST Int type=kotlin.String value=6
arg1: CONST Int type=kotlin.Int value=6
then: RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'
CONST String type=kotlin.String value="6"
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun not (): kotlin.Boolean declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCLEQ
$this: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EXCLEQ
@@ -207,7 +207,7 @@ FILE fqName:<root> fileName:/useImportedMember.kt
arg1: CONST String type=kotlin.String value="7"
then: RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'
CONST String type=kotlin.String value="7"
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun not (): kotlin.Boolean declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCLEQ
$this: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EXCLEQ
@@ -216,15 +216,15 @@ FILE fqName:<root> fileName:/useImportedMember.kt
arg1: CONST String type=kotlin.String value="8"
then: RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'
CONST String type=kotlin.String value="8"
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun not (): kotlin.Boolean declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCLEQ
$this: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EXCLEQ
arg0: ERROR_CALL 'Unresolved reference: <Unresolved name: fromInterface>#' type=IrErrorType
arg1: CONST Int type=kotlin.String value=9
arg1: CONST Int type=kotlin.Int value=9
then: RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'
CONST String type=kotlin.String value="9"
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun not (): kotlin.Boolean declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCLEQ
$this: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EXCLEQ
@@ -233,7 +233,7 @@ FILE fqName:<root> fileName:/useImportedMember.kt
arg1: CONST String type=kotlin.String value="10"
then: RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'
CONST String type=kotlin.String value="10"
WHEN type=kotlin.String origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun not (): kotlin.Boolean declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCLEQ
$this: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EXCLEQ
+9 -9
View File
@@ -98,25 +98,25 @@ FILE fqName:<root> fileName:/when.kt
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp1_subject: kotlin.Int [val] declared in <root>.testComma' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.String value=1
arg1: CONST Int type=kotlin.Int value=1
then: CONST Boolean type=kotlin.Boolean value=true
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp1_subject: kotlin.Int [val] declared in <root>.testComma' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.String value=2
arg1: CONST Int type=kotlin.Int value=2
then: CONST Boolean type=kotlin.Boolean value=true
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp1_subject: kotlin.Int [val] declared in <root>.testComma' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.String value=3
arg1: CONST Int type=kotlin.Int value=3
then: CONST Boolean type=kotlin.Boolean value=true
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp1_subject: kotlin.Int [val] declared in <root>.testComma' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.String value=4
arg1: CONST Int type=kotlin.Int value=4
then: CONST String type=kotlin.String value="1234"
BRANCH
if: WHEN type=kotlin.Boolean origin=null
@@ -125,32 +125,32 @@ FILE fqName:<root> fileName:/when.kt
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp1_subject: kotlin.Int [val] declared in <root>.testComma' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.String value=5
arg1: CONST Int type=kotlin.Int value=5
then: CONST Boolean type=kotlin.Boolean value=true
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp1_subject: kotlin.Int [val] declared in <root>.testComma' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.String value=6
arg1: CONST Int type=kotlin.Int value=6
then: CONST Boolean type=kotlin.Boolean value=true
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp1_subject: kotlin.Int [val] declared in <root>.testComma' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.String value=7
arg1: CONST Int type=kotlin.Int value=7
then: CONST String type=kotlin.String value="567"
BRANCH
if: WHEN type=kotlin.Boolean origin=null
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp1_subject: kotlin.Int [val] declared in <root>.testComma' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.String value=8
arg1: CONST Int type=kotlin.Int value=8
then: CONST Boolean type=kotlin.Boolean value=true
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp1_subject: kotlin.Int [val] declared in <root>.testComma' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.String value=9
arg1: CONST Int type=kotlin.Int value=9
then: CONST String type=kotlin.String value="89"
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
@@ -2,11 +2,11 @@ FILE fqName:<root> fileName:/whenCoercedToUnit.kt
FUN name:foo visibility:public modality:FINAL <> (x:kotlin.Int) returnType:kotlin.Unit
VALUE_PARAMETER name:x index:0 type:kotlin.Int
BLOCK_BODY
BLOCK type=kotlin.Unit origin=WHEN
BLOCK type=kotlin.Int origin=WHEN
VAR IR_TEMPORARY_VARIABLE name:tmp0_subject type:kotlin.Int [val]
WHEN type=kotlin.Unit origin=WHEN
WHEN type=kotlin.Int origin=WHEN
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp0_subject: kotlin.Int [val] declared in <root>.foo' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.Unit value=0
then: CONST Int type=kotlin.Unit value=0
arg1: CONST Int type=kotlin.Int value=0
then: CONST Int type=kotlin.Int value=0
@@ -3,17 +3,17 @@ FILE fqName:<root> fileName:/whenUnusedExpression.kt
VALUE_PARAMETER name:b index:0 type:kotlin.Boolean
VALUE_PARAMETER name:i index:1 type:kotlin.Int
BLOCK_BODY
WHEN type=kotlin.Unit origin=IF
WHEN type=kotlin.Int? origin=IF
BRANCH
if: GET_VAR 'b: kotlin.Boolean declared in <root>.test' type=kotlin.Boolean origin=null
then: BLOCK type=kotlin.Unit origin=WHEN
then: BLOCK type=kotlin.Int? origin=WHEN
VAR IR_TEMPORARY_VARIABLE name:tmp0_subject type:kotlin.Int [val]
WHEN type=kotlin.Unit origin=WHEN
WHEN type=kotlin.Int? origin=WHEN
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp0_subject: kotlin.Int [val] declared in <root>.test' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.Unit value=0
then: CONST Int type=kotlin.Unit value=1
arg1: CONST Int type=kotlin.Int value=0
then: CONST Int type=kotlin.Int value=1
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Null type=kotlin.Nothing? value=null
+2 -2
View File
@@ -48,7 +48,7 @@ FILE fqName:<root> fileName:/nonLocalReturn.kt
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'it: kotlin.Int declared in <root>.testLrmFoo1.<anonymous>' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.Unit value=0
arg1: CONST Int type=kotlin.Int value=0
then: RETURN type=kotlin.Nothing from='local final fun <anonymous> (it: kotlin.Int): kotlin.Unit declared in <root>.testLrmFoo1'
GET_OBJECT 'CLASS IR_EXTERNAL_DECLARATION_STUB OBJECT name:Unit modality:FINAL visibility:public superTypes:[kotlin.Any]' type=kotlin.Unit
CALL 'public final fun print (message: kotlin.Int): kotlin.Unit [inline] declared in kotlin.io' type=kotlin.Unit origin=null
@@ -66,7 +66,7 @@ FILE fqName:<root> fileName:/nonLocalReturn.kt
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'it: kotlin.Int declared in <root>.testLrmFoo2.<anonymous>' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.Unit value=0
arg1: CONST Int type=kotlin.Int value=0
then: RETURN type=kotlin.Nothing from='local final fun <anonymous> (it: kotlin.Int): kotlin.Unit declared in <root>.testLrmFoo2'
GET_OBJECT 'CLASS IR_EXTERNAL_DECLARATION_STUB OBJECT name:Unit modality:FINAL visibility:public superTypes:[kotlin.Any]' type=kotlin.Unit
CALL 'public final fun print (message: kotlin.Int): kotlin.Unit [inline] declared in kotlin.io' type=kotlin.Unit origin=null
+4 -4
View File
@@ -18,9 +18,9 @@ FILE fqName:<root> fileName:/kt24114.kt
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp0_subject: kotlin.Int [val] declared in <root>.test1' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.Int value=1
then: BLOCK type=kotlin.Int origin=WHEN
then: BLOCK type=kotlin.Nothing origin=WHEN
VAR IR_TEMPORARY_VARIABLE name:tmp1_subject type:kotlin.Int [val]
WHEN type=kotlin.Int origin=WHEN
WHEN type=kotlin.Nothing origin=WHEN
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp1_subject: kotlin.Int [val] declared in <root>.test1' type=kotlin.Int origin=null
@@ -42,9 +42,9 @@ FILE fqName:<root> fileName:/kt24114.kt
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp2_subject: kotlin.Int [val] declared in <root>.test2' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.Int value=1
then: BLOCK type=kotlin.Int origin=WHEN
then: BLOCK type=kotlin.Nothing origin=WHEN
VAR IR_TEMPORARY_VARIABLE name:tmp3_subject type:kotlin.Int [val]
WHEN type=kotlin.Int origin=WHEN
WHEN type=kotlin.Nothing origin=WHEN
BRANCH
if: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val tmp3_subject: kotlin.Int [val] declared in <root>.test2' type=kotlin.Int origin=null