Render 'type' for IrTypeOperatorCall expressions, update testData.

This commit is contained in:
Dmitry Petrov
2017-03-06 16:15:20 +03:00
parent b3aeddac85
commit 8c32719f3d
32 changed files with 93 additions and 93 deletions
@@ -141,7 +141,7 @@ class RenderIrElementVisitor : IrElementVisitor<String, Nothing?> {
"STRING_CONCATENATION type=${expression.type.render()}"
override fun visitTypeOperator(expression: IrTypeOperatorCall, data: Nothing?): String =
"TYPE_OP origin=${expression.operator} typeOperand=${expression.typeOperand.render()}"
"TYPE_OP type=${expression.type.render()} origin=${expression.operator} typeOperand=${expression.typeOperand.render()}"
override fun visitWhen(expression: IrWhen, data: Nothing?): String =
"WHEN type=${expression.type.render()} origin=${expression.origin}"
+1 -1
View File
@@ -29,7 +29,7 @@ CONTENT
2 VAR IR_TEMPORARY_VARIABLE val tmp0: kotlin.Int
3 SET_VAR 'count: Int' type=kotlin.Unit origin=POSTFIX_INCR
4 GET_VAR 'tmp0: Int' type=kotlin.Int origin=null
5 TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
5 TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
OUTGOING -> BB 3
When exit: WHEN type=kotlin.Unit origin=null
BB 3
+2 -2
View File
@@ -116,12 +116,12 @@ FILE /dataClasses.kt
CONST Boolean type=kotlin.Boolean value='true'
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=NOT_INSTANCEOF typeOperand=Test1
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=Test1
GET_VAR 'value-parameter other: Any?' type=kotlin.Any? origin=null
then: RETURN type=kotlin.Nothing from='equals(Any?): Boolean'
CONST Boolean type=kotlin.Boolean value='false'
VAR IR_TEMPORARY_VARIABLE val tmp0_other_with_cast: Test1
TYPE_OP origin=CAST typeOperand=Test1
TYPE_OP type=Test1 origin=CAST typeOperand=Test1
GET_VAR 'value-parameter other: Any?' type=kotlin.Any? origin=null
WHEN type=kotlin.Unit origin=null
BRANCH
@@ -39,26 +39,26 @@ FILE /localDelegatedProperties.kt
FUN DELEGATED_PROPERTY_ACCESSOR local final fun <set-x>(value: kotlin.Int): kotlin.Int
BLOCK_BODY
RETURN type=kotlin.Nothing from='<set-x>(Int): Int'
TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.Int
TYPE_OP type=kotlin.Int origin=IMPLICIT_CAST typeOperand=kotlin.Int
CALL 'setValue(Any?, KProperty<*>, Int) on MutableMap<in String, in Int>: Unit' type=kotlin.Unit origin=null
<V>: Int
$receiver: GET_VAR '`x$delegate`: HashMap<String, Int> /* = HashMap<String, Int> */' type=kotlin.collections.HashMap<kotlin.String, kotlin.Int> /* = java.util.HashMap<kotlin.String, kotlin.Int> */ origin=null
thisRef: CONST Null type=kotlin.Nothing? value='null'
property: CALLABLE_REFERENCE 'x: Int' type=kotlin.reflect.KMutableProperty0<kotlin.Int> origin=PROPERTY_REFERENCE_FOR_DELEGATE
value: GET_VAR 'value-parameter value: Int' type=kotlin.Int origin=null
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CALL '<set-x>(Int): Int' type=kotlin.Int origin=EQ
value: CONST Int type=kotlin.Int value='0'
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp0: kotlin.Int
CALL '<get-x>(): Int' type=kotlin.Int origin=POSTFIX_INCR
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CALL '<set-x>(Int): Int' type=kotlin.Int origin=POSTFIX_INCR
value: CALL 'inc(): Int' type=kotlin.Int origin=POSTFIX_INCR
$this: GET_VAR 'tmp0: Int' type=kotlin.Int origin=null
GET_VAR 'tmp0: Int' type=kotlin.Int origin=null
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CALL '<set-x>(Int): Int' type=kotlin.Int origin=PLUSEQ
value: CALL 'plus(Int): Int' type=kotlin.Int origin=PLUSEQ
$this: CALL '<get-x>(): Int' type=kotlin.Int origin=PLUSEQ
@@ -59,7 +59,7 @@ FILE /arrayAugmentedAssignment1.kt
other: CONST Int type=kotlin.Int value='2'
FUN public fun testMember(c: C): kotlin.Unit
BLOCK_BODY
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp0_array: kotlin.IntArray
CALL '<get-x>(): IntArray' type=kotlin.IntArray origin=GET_PROPERTY
+4 -4
View File
@@ -6,15 +6,15 @@ FILE /classReference.kt
INSTANCE_INITIALIZER_CALL classDescriptor='A'
FUN public fun test(): kotlin.Unit
BLOCK_BODY
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CLASS_REFERENCE 'A' type=kotlin.reflect.KClass<A>
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
GET_CLASS type=kotlin.reflect.KClass<out A>
CALL 'constructor A()' type=A origin=null
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CALL '<get-java>() on KClass<A>: Class<A>' type=java.lang.Class<A> origin=GET_PROPERTY
$receiver: CLASS_REFERENCE 'A' type=kotlin.reflect.KClass<A>
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CALL '<get-java>() on KClass<out A>: Class<out A>' type=java.lang.Class<out A> origin=GET_PROPERTY
$receiver: GET_CLASS type=kotlin.reflect.KClass<out A>
CALL 'constructor A()' type=A origin=null
+6 -6
View File
@@ -6,7 +6,7 @@ FILE /coercionToUnit.kt
FUN LOCAL_FUNCTION_FOR_LAMBDA local final fun <anonymous>(): kotlin.Unit
BLOCK_BODY
RETURN type=kotlin.Nothing from='<anonymous>(): Unit'
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CONST Int type=kotlin.Int value='42'
CALLABLE_REFERENCE '<anonymous>(): Unit' type=() -> kotlin.Unit origin=LAMBDA
FUN DEFAULT_PROPERTY_ACCESSOR public fun <get-test1>(): () -> kotlin.Unit
@@ -15,13 +15,13 @@ FILE /coercionToUnit.kt
GET_FIELD 'test1: () -> Unit' type=() -> kotlin.Unit origin=null
FUN public fun test2(mc: kotlin.collections.MutableCollection<kotlin.String>): kotlin.Unit
BLOCK_BODY
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CALL 'add(String): Boolean' type=kotlin.Boolean origin=null
$this: GET_VAR 'value-parameter mc: MutableCollection<String>' type=kotlin.collections.MutableCollection<kotlin.String> origin=null
element: CONST String type=kotlin.String value=''
FUN public fun test3(): kotlin.Unit
BLOCK_BODY
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Unit? origin=SAFE_CALL
VAR IR_TEMPORARY_VARIABLE val tmp0_safe_receiver: java.io.PrintStream!
GET_FIELD 'out: PrintStream!' type=java.io.PrintStream! origin=GET_PROPERTY
@@ -34,10 +34,10 @@ FILE /coercionToUnit.kt
BRANCH
if: CONST Boolean type=kotlin.Boolean value='true'
then: CALL 'println(String!): Unit' type=kotlin.Unit origin=null
$this: TYPE_OP origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
$this: TYPE_OP type=java.io.PrintStream origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
GET_VAR 'tmp0_safe_receiver: PrintStream!' type=java.io.PrintStream! origin=null
p0: CONST String type=kotlin.String value='Hello,'
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Unit? origin=SAFE_CALL
VAR IR_TEMPORARY_VARIABLE val tmp1_safe_receiver: java.io.PrintStream!
GET_FIELD 'out: PrintStream!' type=java.io.PrintStream! origin=GET_PROPERTY
@@ -50,6 +50,6 @@ FILE /coercionToUnit.kt
BRANCH
if: CONST Boolean type=kotlin.Boolean value='true'
then: CALL 'println(String!): Unit' type=kotlin.Unit origin=null
$this: TYPE_OP origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
$this: TYPE_OP type=java.io.PrintStream origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
GET_VAR 'tmp1_safe_receiver: PrintStream!' type=java.io.PrintStream! origin=null
p0: CONST String type=kotlin.String value='world!'
@@ -60,7 +60,7 @@ FILE /complexAugmentedAssignment.kt
BLOCK_BODY
VAR var i: kotlin.Int
CONST Int type=kotlin.Int value='0'
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp1_array: kotlin.IntArray
GET_VAR 'value-parameter a: IntArray' type=kotlin.IntArray origin=null
@@ -84,7 +84,7 @@ FILE /complexAugmentedAssignment.kt
GET_VAR 'tmp3: Int' type=kotlin.Int origin=null
FUN public fun test2(): kotlin.Unit
BLOCK_BODY
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp0_this: X1
GET_OBJECT 'X1' type=X1
@@ -97,7 +97,7 @@ FILE /complexAugmentedAssignment.kt
<set-?>: CALL 'inc(): Int' type=kotlin.Int origin=POSTFIX_INCR
$this: GET_VAR 'tmp1: Int' type=kotlin.Int origin=null
GET_VAR 'tmp1: Int' type=kotlin.Int origin=null
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp2_this: X1.X2
GET_OBJECT 'X2' type=X1.X2
@@ -110,7 +110,7 @@ FILE /complexAugmentedAssignment.kt
<set-?>: CALL 'inc(): Int' type=kotlin.Int origin=POSTFIX_INCR
$this: GET_VAR 'tmp3: Int' type=kotlin.Int origin=null
GET_VAR 'tmp3: Int' type=kotlin.Int origin=null
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp4_this: X1.X2.X3
GET_OBJECT 'X3' type=X1.X2.X3
+4 -4
View File
@@ -45,13 +45,13 @@ FILE /elvis.kt
BLOCK_BODY
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=NOT_INSTANCEOF typeOperand=kotlin.String
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.String
GET_VAR 'value-parameter b: Any?' type=kotlin.Any? origin=null
then: RETURN type=kotlin.Nothing from='test3(Any?, Any?): String'
CONST String type=kotlin.String value=''
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=NOT_INSTANCEOF typeOperand=kotlin.String?
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.String?
GET_VAR 'value-parameter a: Any?' type=kotlin.Any? origin=null
then: RETURN type=kotlin.Nothing from='test3(Any?, Any?): String'
CONST String type=kotlin.String value=''
@@ -64,11 +64,11 @@ FILE /elvis.kt
if: CALL 'EQEQ(Any?, Any?): Boolean' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'tmp0_elvis_lhs: Any?' type=kotlin.Any? origin=null
arg1: CONST Null type=kotlin.Nothing? value='null'
then: TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.String
then: TYPE_OP type=kotlin.String origin=IMPLICIT_CAST typeOperand=kotlin.String
GET_VAR 'value-parameter b: Any?' type=kotlin.Any? origin=null
BRANCH
if: CONST Boolean type=kotlin.Boolean value='true'
then: TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.String
then: TYPE_OP type=kotlin.String origin=IMPLICIT_CAST typeOperand=kotlin.String
GET_VAR 'tmp0_elvis_lhs: Any?' type=kotlin.Any? origin=null
FUN public fun test4(x: kotlin.Any): kotlin.Any
BLOCK_BODY
@@ -2,6 +2,6 @@ FILE /implicitCastOnPlatformType.kt
FUN public fun test(): kotlin.String
BLOCK_BODY
RETURN type=kotlin.Nothing from='test(): String'
TYPE_OP origin=IMPLICIT_NOTNULL typeOperand=kotlin.String
TYPE_OP type=kotlin.String origin=IMPLICIT_NOTNULL typeOperand=kotlin.String
CALL 'getProperty(String!): String!' type=kotlin.String! origin=null
p0: CONST String type=kotlin.String value='test'
@@ -2,14 +2,14 @@ FILE /jvmStaticFieldReference.kt
FUN public fun testFun(): kotlin.Unit
BLOCK_BODY
CALL 'println(String!): Unit' type=kotlin.Unit origin=null
$this: TYPE_OP origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
$this: TYPE_OP type=java.io.PrintStream origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
GET_FIELD 'out: PrintStream!' type=java.io.PrintStream! origin=GET_PROPERTY
p0: CONST String type=kotlin.String value='testFun'
PROPERTY public var testProp: kotlin.Any
FUN public fun <get-testProp>(): kotlin.Any
BLOCK_BODY
CALL 'println(String!): Unit' type=kotlin.Unit origin=null
$this: TYPE_OP origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
$this: TYPE_OP type=java.io.PrintStream origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
GET_FIELD 'out: PrintStream!' type=java.io.PrintStream! origin=GET_PROPERTY
p0: CONST String type=kotlin.String value='testProp/get'
RETURN type=kotlin.Nothing from='<get-testProp>(): Any'
@@ -17,7 +17,7 @@ FILE /jvmStaticFieldReference.kt
FUN public fun <set-testProp>(value: kotlin.Any): kotlin.Unit
BLOCK_BODY
CALL 'println(String!): Unit' type=kotlin.Unit origin=null
$this: TYPE_OP origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
$this: TYPE_OP type=java.io.PrintStream origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
GET_FIELD 'out: PrintStream!' type=java.io.PrintStream! origin=GET_PROPERTY
p0: CONST String type=kotlin.String value='testProp/set'
CLASS CLASS TestClass
@@ -33,7 +33,7 @@ FILE /jvmStaticFieldReference.kt
if: CONST Boolean type=kotlin.Boolean value='true'
then: BLOCK type=kotlin.Int origin=null
CALL 'println(String!): Unit' type=kotlin.Unit origin=null
$this: TYPE_OP origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
$this: TYPE_OP type=java.io.PrintStream origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
GET_FIELD 'out: PrintStream!' type=java.io.PrintStream! origin=GET_PROPERTY
p0: CONST String type=kotlin.String value='TestClass/test'
CONST Int type=kotlin.Int value='42'
@@ -45,6 +45,6 @@ FILE /jvmStaticFieldReference.kt
ANONYMOUS_INITIALIZER TestClass
BLOCK_BODY
CALL 'println(String!): Unit' type=kotlin.Unit origin=null
$this: TYPE_OP origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
$this: TYPE_OP type=java.io.PrintStream origin=IMPLICIT_NOTNULL typeOperand=java.io.PrintStream
GET_FIELD 'out: PrintStream!' type=java.io.PrintStream! origin=GET_PROPERTY
p0: CONST String type=kotlin.String value='TestClass/init'
@@ -6,8 +6,8 @@ FILE /objectClassReference.kt
INSTANCE_INITIALIZER_CALL classDescriptor='A'
FUN public fun test(): kotlin.Unit
BLOCK_BODY
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CLASS_REFERENCE 'A' type=kotlin.reflect.KClass<A>
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CALL '<get-java>() on KClass<A>: Class<A>' type=java.lang.Class<A> origin=GET_PROPERTY
$receiver: CLASS_REFERENCE 'A' type=kotlin.reflect.KClass<A>
@@ -26,7 +26,7 @@ FILE /primitivesImplicitConversions.kt
PROPERTY public val test4: kotlin.Long = -42.toLong()
FIELD PROPERTY_BACKING_FIELD public val test4: kotlin.Long = -42.toLong()
EXPRESSION_BODY
TYPE_OP origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Long
TYPE_OP type=kotlin.Long origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Long
CALL 'unaryMinus(): Int' type=kotlin.Int origin=null
$this: CONST Int type=kotlin.Int value='42'
FUN DEFAULT_PROPERTY_ACCESSOR public fun <get-test4>(): kotlin.Long
@@ -36,7 +36,7 @@ FILE /primitivesImplicitConversions.kt
PROPERTY public val test5: kotlin.Short = -42.toShort()
FIELD PROPERTY_BACKING_FIELD public val test5: kotlin.Short = -42.toShort()
EXPRESSION_BODY
TYPE_OP origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Short
TYPE_OP type=kotlin.Short origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Short
CALL 'unaryMinus(): Int' type=kotlin.Int origin=null
$this: CONST Int type=kotlin.Int value='42'
FUN DEFAULT_PROPERTY_ACCESSOR public fun <get-test5>(): kotlin.Short
@@ -46,7 +46,7 @@ FILE /primitivesImplicitConversions.kt
PROPERTY public val test6: kotlin.Byte = -42.toByte()
FIELD PROPERTY_BACKING_FIELD public val test6: kotlin.Byte = -42.toByte()
EXPRESSION_BODY
TYPE_OP origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Byte
TYPE_OP type=kotlin.Byte origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Byte
CALL 'unaryMinus(): Int' type=kotlin.Int origin=null
$this: CONST Int type=kotlin.Int value='42'
FUN DEFAULT_PROPERTY_ACCESSOR public fun <get-test6>(): kotlin.Byte
@@ -64,27 +64,27 @@ FILE /primitivesImplicitConversions.kt
VAR val test4: kotlin.Long? = -1.toLong()
CONST Long type=kotlin.Long value='-1'
VAR val test5: kotlin.Long? = -1.toLong()
TYPE_OP origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Long
TYPE_OP type=kotlin.Long? origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Long
CALL 'unaryMinus(): Int' type=kotlin.Int origin=null
$this: CONST Int type=kotlin.Int value='1'
VAR val test6: kotlin.Short? = -1.toShort()
TYPE_OP origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Short
TYPE_OP type=kotlin.Short? origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Short
CALL 'unaryMinus(): Int' type=kotlin.Int origin=null
$this: CONST Int type=kotlin.Int value='1'
VAR val test7: kotlin.Byte? = -1.toByte()
TYPE_OP origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Byte
TYPE_OP type=kotlin.Byte? origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Byte
CALL 'unaryMinus(): Int' type=kotlin.Int origin=null
$this: CONST Int type=kotlin.Int value='1'
FUN public fun testImplicitArguments(x: kotlin.Long = ...): kotlin.Unit
x: EXPRESSION_BODY
TYPE_OP origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Long
TYPE_OP type=kotlin.Long origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Long
CALL 'unaryMinus(): Int' type=kotlin.Int origin=null
$this: CONST Int type=kotlin.Int value='1'
BLOCK_BODY
CLASS CLASS TestImplicitArguments
CONSTRUCTOR public constructor TestImplicitArguments(x: kotlin.Long = ...)
x: EXPRESSION_BODY
TYPE_OP origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Long
TYPE_OP type=kotlin.Long origin=IMPLICIT_INTEGER_COERCION typeOperand=kotlin.Long
CALL 'unaryMinus(): Int' type=kotlin.Int origin=null
$this: CONST Int type=kotlin.Int value='1'
BLOCK_BODY
+1 -1
View File
@@ -28,7 +28,7 @@ FILE /safeAssignment.kt
if: CALL 'EQEQ(Any?, Any?): Boolean' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'tmp0_safe_receiver: C?' type=C? origin=null
arg1: CONST Null type=kotlin.Nothing? value='null'
then: TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
then: TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CONST Null type=kotlin.Nothing? value='null'
BRANCH
if: CONST Boolean type=kotlin.Boolean value='true'
@@ -43,11 +43,11 @@ FILE /safeCallWithIncrementDecrement.kt
if: CALL 'EQEQ(Any?, Any?): Boolean' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'tmp0_safe_receiver: C?' type=test.C? origin=null
arg1: CONST Null type=kotlin.Nothing? value='null'
then: TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
then: TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CONST Null type=kotlin.Nothing? value='null'
BRANCH
if: CONST Boolean type=kotlin.Boolean value='true'
then: TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
then: TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp1_receiver: test.C?
GET_VAR 'tmp0_safe_receiver: C?' type=test.C? origin=null
@@ -62,7 +62,7 @@ FILE /safeCallWithIncrementDecrement.kt
GET_VAR 'tmp2: Int' type=kotlin.Int origin=null
FUN public fun testArrayAccess(nc: test.C?): kotlin.Unit
BLOCK_BODY
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp3_array: kotlin.Int?
BLOCK type=kotlin.Int? origin=SAFE_CALL
+2 -2
View File
@@ -83,7 +83,7 @@ FILE /safeCalls.kt
if: CALL 'EQEQ(Any?, Any?): Boolean' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'tmp0_safe_receiver: Ref?' type=Ref? origin=null
arg1: CONST Null type=kotlin.Nothing? value='null'
then: TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
then: TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CONST Null type=kotlin.Nothing? value='null'
BRANCH
if: CONST Boolean type=kotlin.Boolean value='true'
@@ -113,7 +113,7 @@ FILE /safeCalls.kt
CONST Int type=kotlin.Int value='239'
FUN public fun box(): kotlin.Unit
BLOCK_BODY
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int? origin=SAFE_CALL
VAR IR_TEMPORARY_VARIABLE val tmp0_safe_receiver: kotlin.Int
CONST Int type=kotlin.Int value='42'
@@ -8,10 +8,10 @@ FILE /Derived.kt
BLOCK_BODY
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=INSTANCEOF typeOperand=kotlin.String
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=kotlin.String
GET_VAR 'value-parameter v: Any' type=kotlin.Any origin=null
then: BLOCK type=kotlin.Unit origin=null
SET_FIELD 'value: String!' type=kotlin.Unit origin=EQ
receiver: GET_VAR '<receiver: Derived>' type=Derived origin=null
value: TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.String!
value: TYPE_OP type=kotlin.String! origin=IMPLICIT_CAST typeOperand=kotlin.String!
GET_VAR 'value-parameter v: Any' type=kotlin.Any origin=null
+9 -9
View File
@@ -15,45 +15,45 @@ FILE /smartCasts.kt
BLOCK_BODY
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=NOT_INSTANCEOF typeOperand=kotlin.String
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.String
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
then: RETURN type=kotlin.Nothing from='test1(Any): Unit'
GET_OBJECT 'Unit' type=kotlin.Unit
CALL 'println(Int): Unit' type=kotlin.Unit origin=null
message: CALL '<get-length>(): Int' type=kotlin.Int origin=GET_PROPERTY
$this: TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.String
$this: TYPE_OP type=kotlin.String origin=IMPLICIT_CAST typeOperand=kotlin.String
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
CALL 'expectsString(String): Unit' type=kotlin.Unit origin=null
s: TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.String
s: TYPE_OP type=kotlin.String origin=IMPLICIT_CAST typeOperand=kotlin.String
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
CALL 'expectsInt(Int): Unit' type=kotlin.Unit origin=null
i: CALL '<get-length>(): Int' type=kotlin.Int origin=GET_PROPERTY
$this: TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.String
$this: TYPE_OP type=kotlin.String origin=IMPLICIT_CAST typeOperand=kotlin.String
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
CALL 'expectsString(String): Unit' type=kotlin.Unit origin=null
s: CALL 'overloaded(String): String' type=kotlin.String origin=null
s: TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.String
s: TYPE_OP type=kotlin.String origin=IMPLICIT_CAST typeOperand=kotlin.String
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
FUN public fun test2(x: kotlin.Any): kotlin.String
BLOCK_BODY
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=NOT_INSTANCEOF typeOperand=kotlin.String
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.String
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
then: RETURN type=kotlin.Nothing from='test2(Any): String'
CONST String type=kotlin.String value=''
RETURN type=kotlin.Nothing from='test2(Any): String'
CALL 'overloaded(String): String' type=kotlin.String origin=null
s: TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.String
s: TYPE_OP type=kotlin.String origin=IMPLICIT_CAST typeOperand=kotlin.String
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
FUN public fun test3(x: kotlin.Any): kotlin.String
BLOCK_BODY
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=NOT_INSTANCEOF typeOperand=kotlin.String
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.String
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
then: RETURN type=kotlin.Nothing from='test3(Any): String'
CONST String type=kotlin.String value=''
RETURN type=kotlin.Nothing from='test3(Any): String'
TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.String
TYPE_OP type=kotlin.String origin=IMPLICIT_CAST typeOperand=kotlin.String
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
@@ -13,7 +13,7 @@ FILE /smartCastsWithDestructuring.kt
BLOCK_BODY
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=NOT_INSTANCEOF typeOperand=I2
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=I2
GET_VAR 'value-parameter x: I1' type=I1 origin=null
then: RETURN type=kotlin.Nothing from='test(I1): Unit'
GET_OBJECT 'Unit' type=kotlin.Unit
@@ -25,5 +25,5 @@ FILE /smartCastsWithDestructuring.kt
$receiver: GET_VAR 'tmp0_container: I1' type=I1 origin=null
VAR val c2: kotlin.String
CALL 'component2() on I2: String' type=kotlin.String origin=COMPONENT_N(index=2)
$receiver: TYPE_OP origin=IMPLICIT_CAST typeOperand=I2
$receiver: TYPE_OP type=I2 origin=IMPLICIT_CAST typeOperand=I2
GET_VAR 'tmp0_container: I1' type=I1 origin=null
+2 -2
View File
@@ -7,9 +7,9 @@ FILE /throw.kt
BLOCK_BODY
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=INSTANCEOF typeOperand=kotlin.Throwable
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=kotlin.Throwable
GET_VAR 'value-parameter a: Any' type=kotlin.Any origin=null
then: BLOCK type=kotlin.Nothing origin=null
THROW type=kotlin.Nothing
TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.Throwable
TYPE_OP type=kotlin.Throwable origin=IMPLICIT_CAST typeOperand=kotlin.Throwable
GET_VAR 'value-parameter a: Any' type=kotlin.Any origin=null
+1 -1
View File
@@ -20,7 +20,7 @@ FILE /tryCatch.kt
BLOCK type=kotlin.Int origin=null
CALL 'println(): Unit' type=kotlin.Unit origin=null
CONST Int type=kotlin.Int value='24'
finally: TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
finally: TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=null
CALL 'println(): Unit' type=kotlin.Unit origin=null
CONST Int type=kotlin.Int value='555'
@@ -3,14 +3,14 @@ FILE /tryCatchWithImplicitCast.kt
BLOCK_BODY
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=NOT_INSTANCEOF typeOperand=kotlin.String
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.String
GET_VAR 'value-parameter a: Any' type=kotlin.Any origin=null
then: RETURN type=kotlin.Nothing from='testImplicitCast(Any): Unit'
GET_OBJECT 'Unit' type=kotlin.Unit
VAR val t: kotlin.String
TRY type=kotlin.String
try: BLOCK type=kotlin.String origin=null
TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.String
TYPE_OP type=kotlin.String origin=IMPLICIT_CAST typeOperand=kotlin.String
GET_VAR 'value-parameter a: Any' type=kotlin.Any origin=null
CATCH parameter=e: Throwable
BLOCK type=kotlin.String origin=null
+2 -2
View File
@@ -4,11 +4,11 @@ FILE /typeArguments.kt
RETURN type=kotlin.Nothing from='test1(Any): Boolean'
WHEN type=kotlin.Boolean origin=ANDAND
BRANCH
if: TYPE_OP origin=INSTANCEOF typeOperand=kotlin.Array<*>
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=kotlin.Array<*>
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
then: CALL 'isArrayOf() on Array<*>: Boolean' type=kotlin.Boolean origin=null
<reified T : Any>: String
$receiver: TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.Array<*>
$receiver: TYPE_OP type=kotlin.Array<*> origin=IMPLICIT_CAST typeOperand=kotlin.Array<*>
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
BRANCH
if: CONST Boolean type=kotlin.Boolean value='true'
+4 -4
View File
@@ -3,20 +3,20 @@ FILE /typeOperators.kt
FUN public fun test1(x: kotlin.Any): kotlin.Boolean
BLOCK_BODY
RETURN type=kotlin.Nothing from='test1(Any): Boolean'
TYPE_OP origin=INSTANCEOF typeOperand=IThing
TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=IThing
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
FUN public fun test2(x: kotlin.Any): kotlin.Boolean
BLOCK_BODY
RETURN type=kotlin.Nothing from='test2(Any): Boolean'
TYPE_OP origin=NOT_INSTANCEOF typeOperand=IThing
TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=IThing
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
FUN public fun test3(x: kotlin.Any): IThing
BLOCK_BODY
RETURN type=kotlin.Nothing from='test3(Any): IThing'
TYPE_OP origin=CAST typeOperand=IThing
TYPE_OP type=IThing origin=CAST typeOperand=IThing
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
FUN public fun test4(x: kotlin.Any): IThing?
BLOCK_BODY
RETURN type=kotlin.Nothing from='test4(Any): IThing?'
TYPE_OP origin=SAFE_CAST typeOperand=IThing
TYPE_OP type=IThing? origin=SAFE_CAST typeOperand=IThing
GET_VAR 'value-parameter x: Any' type=kotlin.Any origin=null
@@ -3,20 +3,20 @@ FILE /varargWithImplicitCast.kt
BLOCK_BODY
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=NOT_INSTANCEOF typeOperand=kotlin.Int
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.Int
GET_VAR 'value-parameter a: Any' type=kotlin.Any origin=null
then: RETURN type=kotlin.Nothing from='testScalar(Any): IntArray'
CALL 'intArrayOf(vararg Int): IntArray' type=kotlin.IntArray origin=null
RETURN type=kotlin.Nothing from='testScalar(Any): IntArray'
CALL 'intArrayOf(vararg Int): IntArray' type=kotlin.IntArray origin=null
elements: VARARG type=IntArray varargElementType=Int
TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.Int
TYPE_OP type=kotlin.Int origin=IMPLICIT_CAST typeOperand=kotlin.Int
GET_VAR 'value-parameter a: Any' type=kotlin.Any origin=null
FUN public fun testSpread(a: kotlin.Any): kotlin.IntArray
BLOCK_BODY
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=NOT_INSTANCEOF typeOperand=kotlin.IntArray
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.IntArray
GET_VAR 'value-parameter a: Any' type=kotlin.Any origin=null
then: RETURN type=kotlin.Nothing from='testSpread(Any): IntArray'
CALL 'intArrayOf(vararg Int): IntArray' type=kotlin.IntArray origin=null
@@ -24,5 +24,5 @@ FILE /varargWithImplicitCast.kt
CALL 'intArrayOf(vararg Int): IntArray' type=kotlin.IntArray origin=null
elements: VARARG type=IntArray varargElementType=Int
SPREAD_ELEMENT
TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.IntArray
TYPE_OP type=kotlin.IntArray origin=IMPLICIT_CAST typeOperand=kotlin.IntArray
GET_VAR 'value-parameter a: Any' type=kotlin.Any origin=null
+2 -2
View File
@@ -22,7 +22,7 @@ FILE /when.kt
arg1: GET_OBJECT 'A' type=A
then: CONST String type=kotlin.String value='A'
BRANCH
if: TYPE_OP origin=INSTANCEOF typeOperand=kotlin.String
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=kotlin.String
GET_VAR 'tmp0_subject: Any?' type=kotlin.Any? origin=null
then: CONST String type=kotlin.String value='String'
BRANCH
@@ -50,7 +50,7 @@ FILE /when.kt
arg1: GET_OBJECT 'A' type=A
then: CONST String type=kotlin.String value='A'
BRANCH
if: TYPE_OP origin=INSTANCEOF typeOperand=kotlin.String
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=kotlin.String
GET_VAR 'value-parameter x: Any?' type=kotlin.Any? origin=null
then: CONST String type=kotlin.String value='String'
BRANCH
@@ -9,5 +9,5 @@ FILE /whenCoercedToUnit.kt
if: CALL 'EQEQ(Any?, Any?): Boolean' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'tmp0_subject: Int' type=kotlin.Int origin=null
arg1: CONST Int type=kotlin.Int value='0'
then: TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
then: TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CONST Int type=kotlin.Int value='0'
+7 -7
View File
@@ -13,7 +13,7 @@ FILE /whileDoWhile.kt
arg0: CALL 'compareTo(Int): Int' type=kotlin.Int origin=LT
$this: GET_VAR 'x: Int' type=kotlin.Int origin=null
other: CONST Int type=kotlin.Int value='5'
body: TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
body: TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp0: kotlin.Int
GET_VAR 'x: Int' type=kotlin.Int origin=POSTFIX_INCR
@@ -26,7 +26,7 @@ FILE /whileDoWhile.kt
arg0: CALL 'compareTo(Int): Int' type=kotlin.Int origin=LT
$this: GET_VAR 'x: Int' type=kotlin.Int origin=null
other: CONST Int type=kotlin.Int value='10'
body: TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
body: TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=null
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp1: kotlin.Int
@@ -41,7 +41,7 @@ FILE /whileDoWhile.kt
$this: GET_VAR 'x: Int' type=kotlin.Int origin=null
other: CONST Int type=kotlin.Int value='0'
DO_WHILE label=null origin=DO_WHILE_LOOP
body: TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
body: TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp2: kotlin.Int
GET_VAR 'x: Int' type=kotlin.Int origin=POSTFIX_INCR
@@ -55,7 +55,7 @@ FILE /whileDoWhile.kt
other: CONST Int type=kotlin.Int value='15'
DO_WHILE label=null origin=DO_WHILE_LOOP
body: BLOCK type=kotlin.Unit origin=null
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp3: kotlin.Int
GET_VAR 'x: Int' type=kotlin.Int origin=POSTFIX_INCR
@@ -73,14 +73,14 @@ FILE /whileDoWhile.kt
CONST Null type=kotlin.Nothing? value='null'
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=INSTANCEOF typeOperand=kotlin.Boolean
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=kotlin.Boolean
GET_VAR 'a: Any?' type=kotlin.Any? origin=null
then: BLOCK type=kotlin.Unit origin=null
WHILE label=null origin=WHILE_LOOP
condition: TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.Boolean
condition: TYPE_OP type=kotlin.Boolean origin=IMPLICIT_CAST typeOperand=kotlin.Boolean
GET_VAR 'a: Any?' type=kotlin.Any? origin=null
body: BLOCK type=kotlin.Unit origin=null
DO_WHILE label=null origin=DO_WHILE_LOOP
body: BLOCK type=kotlin.Unit origin=null
condition: TYPE_OP origin=IMPLICIT_CAST typeOperand=kotlin.Boolean
condition: TYPE_OP type=kotlin.Boolean origin=IMPLICIT_CAST typeOperand=kotlin.Boolean
GET_VAR 'a: Any?' type=kotlin.Any? origin=null
@@ -86,12 +86,12 @@ FILE /destructuringInLambda.kt
CONST Boolean type=kotlin.Boolean value='true'
WHEN type=kotlin.Unit origin=null
BRANCH
if: TYPE_OP origin=NOT_INSTANCEOF typeOperand=A
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=A
GET_VAR 'value-parameter other: Any?' type=kotlin.Any? origin=null
then: RETURN type=kotlin.Nothing from='equals(Any?): Boolean'
CONST Boolean type=kotlin.Boolean value='false'
VAR IR_TEMPORARY_VARIABLE val tmp0_other_with_cast: A
TYPE_OP origin=CAST typeOperand=A
TYPE_OP type=A origin=CAST typeOperand=A
GET_VAR 'value-parameter other: Any?' type=kotlin.Any? origin=null
WHEN type=kotlin.Unit origin=null
BRANCH
+1 -1
View File
@@ -5,7 +5,7 @@ FILE /localFunction.kt
CONST Int type=kotlin.Int value='0'
FUN local final fun local(): kotlin.Unit
BLOCK_BODY
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=POSTFIX_INCR
VAR IR_TEMPORARY_VARIABLE val tmp0: kotlin.Int
GET_VAR 'x: Int' type=kotlin.Int origin=POSTFIX_INCR
@@ -22,7 +22,7 @@ FILE /multipleImplicitReceivers.kt
CONST Int type=kotlin.Int value='42'
FUN public fun test(fooImpl: IFoo, invokeImpl: IInvoke): kotlin.Unit
BLOCK_BODY
TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
CALL 'with(A, A.() -> Int): Int' type=kotlin.Int origin=null
<T>: A
<R>: Int
+1 -1
View File
@@ -12,7 +12,7 @@ FILE /coercionInLoop.kt
WHILE label=null origin=WHILE_LOOP
condition: CALL 'hasNext(): Boolean' type=kotlin.Boolean origin=null
$this: GET_VAR 'x: DoubleIterator' type=kotlin.collections.DoubleIterator origin=null
body: TYPE_OP origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
body: TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit
BLOCK type=kotlin.Int origin=null
WHEN type=kotlin.Unit origin=null
BRANCH