Files
kotlin-fork/compiler/testData/ir/irText/expressions/assignments.txt
T

36 lines
1.6 KiB
Plaintext
Vendored

FILE /assignments.kt
CLASS CLASS Ref
CONSTRUCTOR public constructor Ref(x: kotlin.Int)
BLOCK_BODY
DELEGATING_CONSTRUCTOR_CALL 'constructor Any()'
INSTANCE_INITIALIZER_CALL classDescriptor='Ref'
PROPERTY public final var x: kotlin.Int
FIELD public final var x: kotlin.Int
EXPRESSION_BODY
GET_VAR 'value-parameter x: Int' type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
FUN public final fun <get-x>(): kotlin.Int
BLOCK_BODY
RETURN type=kotlin.Nothing from='<get-x>(): Int'
GET_BACKING_FIELD 'x: Int' type=kotlin.Int operator=null
receiver: THIS of 'Ref' type=Ref
FUN public final fun <set-x>(<set-?>: kotlin.Int): kotlin.Unit
BLOCK_BODY
SET_BACKING_FIELD 'x: Int' type=kotlin.Unit operator=null
receiver: THIS of 'Ref' type=Ref
value: GET_VAR 'value-parameter <set-?>: Int' type=kotlin.Int operator=null
FUN public fun test1(): kotlin.Unit
BLOCK_BODY
VAR var x: kotlin.Int
CONST Int type=kotlin.Int value='0'
SET_VAR 'x: Int' type=kotlin.Unit operator=EQ
CONST Int type=kotlin.Int value='1'
SET_VAR 'x: Int' type=kotlin.Unit operator=EQ
CALL 'plus(Int): Int' type=kotlin.Int operator=PLUS
$this: GET_VAR 'x: Int' type=kotlin.Int operator=null
other: CONST Int type=kotlin.Int value='1'
FUN public fun test2(r: Ref): kotlin.Unit
BLOCK_BODY
CALL '<set-x>(Int): Unit' type=kotlin.Unit operator=EQ
$this: GET_VAR 'value-parameter r: Ref' type=Ref operator=null
<set-?>: CONST Int type=kotlin.Int value='0'