Represent class instance initialization "as from resolve".
This commit is contained in:
committed by
Dmitry Petrov
parent
c3c758c7cc
commit
1b5dd50359
+3
-2
@@ -6,6 +6,7 @@ FILE /argumentReorderingInDelegatingConstructorCall.kt
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
SET_BACKING_FIELD y type=kotlin.Unit operator=null
|
||||
GET_VAR y type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Base
|
||||
PROPERTY public final val x: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
@@ -23,8 +24,8 @@ FILE /argumentReorderingInDelegatingConstructorCall.kt
|
||||
CALL .<init> type=Base operator=SUPER_CONSTRUCTOR_CALL
|
||||
x: GET_VAR tmp1_x type=kotlin.Int operator=null
|
||||
y: GET_VAR tmp0_y type=kotlin.Int operator=null
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test1
|
||||
CLASS CLASS Test2
|
||||
nestedInitializers: BLOCK_BODY
|
||||
CONSTRUCTOR public constructor Test2(/*0*/ xx: kotlin.Int, /*1*/ yy: kotlin.Int)
|
||||
BLOCK_BODY
|
||||
BLOCK type=Base operator=ARGUMENTS_REORDERING_FOR_CALL
|
||||
@@ -36,7 +37,7 @@ FILE /argumentReorderingInDelegatingConstructorCall.kt
|
||||
DELEGATING_CONSTRUCTOR_CALL Base
|
||||
x: GET_VAR tmp1_x type=kotlin.Int operator=null
|
||||
y: GET_VAR tmp0_y type=kotlin.Int operator=null
|
||||
NESTED_INITIALIZERS_CALL classDescriptor=Test2
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test2
|
||||
CONSTRUCTOR public constructor Test2(/*0*/ xxx: kotlin.Int, /*1*/ yyy: kotlin.Int, /*2*/ a: kotlin.Any)
|
||||
BLOCK_BODY
|
||||
BLOCK type=Test2 operator=ARGUMENTS_REORDERING_FOR_CALL
|
||||
|
||||
+3
-2
@@ -8,8 +8,7 @@ FILE /classMembers.kt
|
||||
GET_VAR y type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
SET_BACKING_FIELD z type=kotlin.Unit operator=null
|
||||
GET_VAR z type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
SET_BACKING_FIELD property type=kotlin.Unit operator=null
|
||||
CONST Int type=kotlin.Int value='0'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=C
|
||||
PROPERTY public final val y: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
GET_VAR y type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
@@ -52,6 +51,7 @@ FILE /classMembers.kt
|
||||
CLASS CLASS NestedClass
|
||||
CONSTRUCTOR public constructor NestedClass()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=NestedClass
|
||||
FUN public final fun function(): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
CALL .println type=kotlin.Unit operator=null
|
||||
@@ -70,3 +70,4 @@ FILE /classMembers.kt
|
||||
CLASS OBJECT Companion
|
||||
CONSTRUCTOR private constructor Companion()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Companion
|
||||
|
||||
@@ -2,17 +2,21 @@ FILE /classes.kt
|
||||
CLASS CLASS TestClass
|
||||
CONSTRUCTOR public constructor TestClass()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestClass
|
||||
CLASS INTERFACE TestInterface
|
||||
CLASS OBJECT TestObject
|
||||
CONSTRUCTOR private constructor TestObject()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestObject
|
||||
CLASS ANNOTATION_CLASS TestAnnotationClass
|
||||
CONSTRUCTOR public constructor TestAnnotationClass()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestAnnotationClass
|
||||
CLASS ENUM_CLASS TestEnumClass
|
||||
CONSTRUCTOR private constructor TestEnumClass()
|
||||
BLOCK_BODY
|
||||
ENUM_CONSTRUCTOR_CALL Enum super
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestEnumClass
|
||||
FUN public final /*synthesized*/ fun values(): kotlin.Array<TestEnumClass>
|
||||
SYNTHETIC_BODY kind=ENUM_VALUES
|
||||
FUN public final /*synthesized*/ fun valueOf(/*0*/ value: kotlin.String): TestEnumClass
|
||||
|
||||
@@ -2,12 +2,16 @@ FILE /companionObject.kt
|
||||
CLASS CLASS Test1
|
||||
CONSTRUCTOR public constructor Test1()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test1
|
||||
CLASS OBJECT Companion
|
||||
CONSTRUCTOR private constructor Companion()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Companion
|
||||
CLASS CLASS Test2
|
||||
CONSTRUCTOR public constructor Test2()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test2
|
||||
CLASS OBJECT Named
|
||||
CONSTRUCTOR private constructor Named()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Named
|
||||
|
||||
@@ -8,6 +8,7 @@ FILE /dataClasses.kt
|
||||
GET_VAR y type=kotlin.String operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
SET_BACKING_FIELD z type=kotlin.Unit operator=null
|
||||
GET_VAR z type=kotlin.Any operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test1
|
||||
PROPERTY public final val x: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
|
||||
+3
-3
@@ -2,16 +2,16 @@ FILE /delegatingConstructorCallsInSecondaryConstructors.kt
|
||||
CLASS CLASS Base
|
||||
CONSTRUCTOR public constructor Base()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Base
|
||||
CLASS CLASS Test
|
||||
nestedInitializers: BLOCK_BODY
|
||||
CONSTRUCTOR public constructor Test()
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL Base
|
||||
NESTED_INITIALIZERS_CALL classDescriptor=Test
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test
|
||||
CONSTRUCTOR public constructor Test(/*0*/ xx: kotlin.Int)
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL Base
|
||||
NESTED_INITIALIZERS_CALL classDescriptor=Test
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test
|
||||
CONSTRUCTOR public constructor Test(/*0*/ xx: kotlin.Short)
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL Test
|
||||
|
||||
+12
-4
@@ -3,6 +3,7 @@ FILE /enum.kt
|
||||
CONSTRUCTOR private constructor TestEnum1()
|
||||
BLOCK_BODY
|
||||
ENUM_CONSTRUCTOR_CALL Enum super
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestEnum1
|
||||
ENUM_ENTRY enum entry TEST1
|
||||
init: ENUM_CONSTRUCTOR_CALL TestEnum1 TEST1
|
||||
ENUM_ENTRY enum entry TEST2
|
||||
@@ -17,6 +18,7 @@ FILE /enum.kt
|
||||
ENUM_CONSTRUCTOR_CALL Enum super
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestEnum2
|
||||
PROPERTY public final val x: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
@@ -37,12 +39,14 @@ FILE /enum.kt
|
||||
CONSTRUCTOR private constructor TestEnum3()
|
||||
BLOCK_BODY
|
||||
ENUM_CONSTRUCTOR_CALL Enum super
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestEnum3
|
||||
ENUM_ENTRY enum entry TEST
|
||||
init: ENUM_CONSTRUCTOR_CALL TEST TEST
|
||||
class: CLASS ENUM_ENTRY TEST
|
||||
CONSTRUCTOR private constructor TEST()
|
||||
BLOCK_BODY
|
||||
ENUM_CONSTRUCTOR_CALL TestEnum3 super
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TEST
|
||||
FUN public open override /*1*/ fun foo(): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
CALL .println type=kotlin.Unit operator=null
|
||||
@@ -58,6 +62,7 @@ FILE /enum.kt
|
||||
ENUM_CONSTRUCTOR_CALL Enum super
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestEnum4
|
||||
PROPERTY public final val x: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
@@ -68,6 +73,7 @@ FILE /enum.kt
|
||||
BLOCK_BODY
|
||||
ENUM_CONSTRUCTOR_CALL TestEnum4 super
|
||||
x: CONST Int type=kotlin.Int value='1'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TEST1
|
||||
FUN public open override /*1*/ fun foo(): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
CALL .println type=kotlin.Unit operator=null
|
||||
@@ -79,11 +85,13 @@ FILE /enum.kt
|
||||
BLOCK_BODY
|
||||
ENUM_CONSTRUCTOR_CALL TestEnum4 super
|
||||
x: CONST Int type=kotlin.Int value='2'
|
||||
BLOCK type=kotlin.Unit operator=null
|
||||
SET_BACKING_FIELD z type=kotlin.Unit operator=null
|
||||
CALL .<get-x> type=kotlin.Int operator=GET_PROPERTY
|
||||
$this: THIS enum entry TEST2 type=TestEnum4.TEST2
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TEST2
|
||||
PROPERTY public final val z: kotlin.Int
|
||||
ANONYMOUS_INITIALIZER TEST2
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD z type=kotlin.Unit operator=null
|
||||
CALL .<get-x> type=kotlin.Int operator=GET_PROPERTY
|
||||
$this: THIS enum entry TEST2 type=TestEnum4.TEST2
|
||||
FUN public open override /*1*/ fun foo(): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
CALL .println type=kotlin.Unit operator=null
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
class Test1 {
|
||||
init {
|
||||
println()
|
||||
}
|
||||
}
|
||||
|
||||
class Test2(val x: Int) {
|
||||
init {
|
||||
println()
|
||||
}
|
||||
}
|
||||
|
||||
class Test3 {
|
||||
init {
|
||||
println()
|
||||
}
|
||||
|
||||
constructor()
|
||||
}
|
||||
|
||||
class Test4 {
|
||||
init {
|
||||
println("1")
|
||||
}
|
||||
|
||||
constructor()
|
||||
|
||||
init {
|
||||
println("2")
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
FILE /initBlock.kt
|
||||
CLASS CLASS Test1
|
||||
CONSTRUCTOR public constructor Test1()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test1
|
||||
ANONYMOUS_INITIALIZER Test1
|
||||
BLOCK_BODY
|
||||
CALL .println type=kotlin.Unit operator=null
|
||||
CLASS CLASS Test2
|
||||
CONSTRUCTOR public constructor Test2(/*0*/ x: kotlin.Int)
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test2
|
||||
PROPERTY public final val x: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
ANONYMOUS_INITIALIZER Test2
|
||||
BLOCK_BODY
|
||||
CALL .println type=kotlin.Unit operator=null
|
||||
CLASS CLASS Test3
|
||||
ANONYMOUS_INITIALIZER Test3
|
||||
BLOCK_BODY
|
||||
CALL .println type=kotlin.Unit operator=null
|
||||
CONSTRUCTOR public constructor Test3()
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL Any
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test3
|
||||
CLASS CLASS Test4
|
||||
ANONYMOUS_INITIALIZER Test4
|
||||
BLOCK_BODY
|
||||
CALL .println type=kotlin.Unit operator=null
|
||||
message: CONST String type=kotlin.String value='1'
|
||||
CONSTRUCTOR public constructor Test4()
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL Any
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test4
|
||||
ANONYMOUS_INITIALIZER Test4
|
||||
BLOCK_BODY
|
||||
CALL .println type=kotlin.Unit operator=null
|
||||
message: CONST String type=kotlin.String value='2'
|
||||
+7
-5
@@ -4,21 +4,23 @@ FILE /initVal.kt
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestInitValFromParameter
|
||||
PROPERTY public final val x: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
CLASS CLASS TestInitValInClass
|
||||
CONSTRUCTOR public constructor TestInitValInClass()
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
CONST Int type=kotlin.Int value='0'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestInitValInClass
|
||||
PROPERTY public final val x: kotlin.Int = 0
|
||||
EXPRESSION_BODY
|
||||
CONST Int type=kotlin.Int value='0'
|
||||
CLASS CLASS TestInitValInInitBlock
|
||||
CONSTRUCTOR public constructor TestInitValInInitBlock()
|
||||
BLOCK_BODY
|
||||
BLOCK type=kotlin.Unit operator=null
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
CONST Int type=kotlin.Int value='0'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestInitValInInitBlock
|
||||
PROPERTY public final val x: kotlin.Int
|
||||
ANONYMOUS_INITIALIZER TestInitValInInitBlock
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
CONST Int type=kotlin.Int value='0'
|
||||
|
||||
+16
-16
@@ -4,30 +4,31 @@ FILE /initVar.kt
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestInitVarFromParameter
|
||||
PROPERTY public final var x: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
CLASS CLASS TestInitVarInClass
|
||||
CONSTRUCTOR public constructor TestInitVarInClass()
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
CONST Int type=kotlin.Int value='0'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestInitVarInClass
|
||||
PROPERTY public final var x: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
CONST Int type=kotlin.Int value='0'
|
||||
CLASS CLASS TestInitVarInInitBlock
|
||||
CONSTRUCTOR public constructor TestInitVarInInitBlock()
|
||||
BLOCK_BODY
|
||||
BLOCK type=kotlin.Unit operator=null
|
||||
CALL .<set-x> type=kotlin.Unit operator=EQ
|
||||
$this: THIS public final class TestInitVarInInitBlock type=TestInitVarInInitBlock
|
||||
<set-?>: CONST Int type=kotlin.Int value='0'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestInitVarInInitBlock
|
||||
PROPERTY public final var x: kotlin.Int
|
||||
ANONYMOUS_INITIALIZER TestInitVarInInitBlock
|
||||
BLOCK_BODY
|
||||
CALL .<set-x> type=kotlin.Unit operator=EQ
|
||||
$this: THIS public final class TestInitVarInInitBlock type=TestInitVarInInitBlock
|
||||
<set-?>: CONST Int type=kotlin.Int value='0'
|
||||
CLASS CLASS TestInitVarWithCustomSetter
|
||||
CONSTRUCTOR public constructor TestInitVarWithCustomSetter()
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
CONST Int type=kotlin.Int value='0'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestInitVarWithCustomSetter
|
||||
PROPERTY public final var x: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
CONST Int type=kotlin.Int value='0'
|
||||
@@ -36,22 +37,21 @@ FILE /initVar.kt
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=EQ
|
||||
GET_VAR value type=kotlin.Int operator=null
|
||||
CLASS CLASS TestInitVarWithCustomSetterWithExplicitCtor
|
||||
nestedInitializers: BLOCK_BODY
|
||||
BLOCK type=kotlin.Unit operator=null
|
||||
CALL .<set-x> type=kotlin.Unit operator=EQ
|
||||
$this: THIS public final class TestInitVarWithCustomSetterWithExplicitCtor type=TestInitVarWithCustomSetterWithExplicitCtor
|
||||
value: CONST Int type=kotlin.Int value='0'
|
||||
PROPERTY public final var x: kotlin.Int
|
||||
PROPERTY_SETTER public final fun <set-x>(/*0*/ value: kotlin.Int): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=EQ
|
||||
GET_VAR value type=kotlin.Int operator=null
|
||||
ANONYMOUS_INITIALIZER TestInitVarWithCustomSetterWithExplicitCtor
|
||||
BLOCK_BODY
|
||||
CALL .<set-x> type=kotlin.Unit operator=EQ
|
||||
$this: THIS public final class TestInitVarWithCustomSetterWithExplicitCtor type=TestInitVarWithCustomSetterWithExplicitCtor
|
||||
value: CONST Int type=kotlin.Int value='0'
|
||||
CONSTRUCTOR public constructor TestInitVarWithCustomSetterWithExplicitCtor()
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL Any
|
||||
NESTED_INITIALIZERS_CALL classDescriptor=TestInitVarWithCustomSetterWithExplicitCtor
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestInitVarWithCustomSetterWithExplicitCtor
|
||||
CLASS CLASS TestInitVarWithCustomSetterInCtor
|
||||
nestedInitializers: BLOCK_BODY
|
||||
PROPERTY public final var x: kotlin.Int
|
||||
PROPERTY_SETTER public final fun <set-x>(/*0*/ value: kotlin.Int): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
@@ -60,7 +60,7 @@ FILE /initVar.kt
|
||||
CONSTRUCTOR public constructor TestInitVarWithCustomSetterInCtor()
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL Any
|
||||
NESTED_INITIALIZERS_CALL classDescriptor=TestInitVarWithCustomSetterInCtor
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestInitVarWithCustomSetterInCtor
|
||||
CALL .<set-x> type=kotlin.Unit operator=EQ
|
||||
$this: THIS public final class TestInitVarWithCustomSetterInCtor type=TestInitVarWithCustomSetterInCtor
|
||||
value: CONST Int type=kotlin.Int value='42'
|
||||
|
||||
@@ -4,6 +4,7 @@ FILE /localClasses.kt
|
||||
CLASS CLASS LocalClass
|
||||
CONSTRUCTOR public constructor LocalClass()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=LocalClass
|
||||
FUN public final fun foo(): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
CALL .foo type=kotlin.Unit operator=null
|
||||
|
||||
@@ -7,6 +7,7 @@ FILE /objectLiteralExpressions.kt
|
||||
CLASS CLASS <no name provided>
|
||||
CONSTRUCTOR public constructor <no name provided>()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=<no name provided>
|
||||
CALL .<init> type=test1.<no name provided> operator=OBJECT_LITERAL
|
||||
PROPERTY public val test2: IFoo
|
||||
EXPRESSION_BODY
|
||||
@@ -14,6 +15,7 @@ FILE /objectLiteralExpressions.kt
|
||||
CLASS CLASS <no name provided>
|
||||
CONSTRUCTOR public constructor <no name provided>()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=<no name provided>
|
||||
FUN public open override /*1*/ fun foo(): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
CALL .println type=kotlin.Unit operator=null
|
||||
@@ -22,9 +24,11 @@ FILE /objectLiteralExpressions.kt
|
||||
CLASS CLASS Outer
|
||||
CONSTRUCTOR public constructor Outer()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Outer
|
||||
CLASS CLASS Inner
|
||||
CONSTRUCTOR public constructor Inner()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Inner
|
||||
FUN public final fun test3(): Outer.Inner
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from=test3
|
||||
@@ -34,6 +38,7 @@ FILE /objectLiteralExpressions.kt
|
||||
BLOCK_BODY
|
||||
CALL .<init> type=Outer.Inner operator=SUPER_CONSTRUCTOR_CALL
|
||||
$this: THIS public final class Outer type=Outer
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=<no name provided>
|
||||
FUN public open override /*1*/ fun foo(): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
CALL .println type=kotlin.Unit operator=null
|
||||
@@ -48,6 +53,7 @@ FILE /objectLiteralExpressions.kt
|
||||
BLOCK_BODY
|
||||
CALL .<init> type=Outer.Inner operator=SUPER_CONSTRUCTOR_CALL
|
||||
$this: $RECEIVER of: test4 type=Outer
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=<no name provided>
|
||||
FUN public open override /*1*/ fun foo(): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
CALL .println type=kotlin.Unit operator=null
|
||||
|
||||
@@ -6,6 +6,7 @@ FILE /primaryConstructor.kt
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
SET_BACKING_FIELD y type=kotlin.Unit operator=null
|
||||
GET_VAR y type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test1
|
||||
PROPERTY public final val x: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
@@ -17,8 +18,7 @@ FILE /primaryConstructor.kt
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD y type=kotlin.Unit operator=null
|
||||
GET_VAR y type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
GET_VAR x type=kotlin.Int operator=null
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test2
|
||||
PROPERTY public final val y: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
GET_VAR y type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
@@ -30,10 +30,12 @@ FILE /primaryConstructor.kt
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD y type=kotlin.Unit operator=null
|
||||
GET_VAR y type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
BLOCK type=kotlin.Unit operator=null
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
GET_VAR x type=kotlin.Int operator=null
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Test3
|
||||
PROPERTY public final val y: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
GET_VAR y type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
PROPERTY public final val x: kotlin.Int
|
||||
ANONYMOUS_INITIALIZER Test3
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
GET_VAR x type=kotlin.Int operator=null
|
||||
|
||||
+4
@@ -2,14 +2,17 @@ FILE /primaryConstructorWithSuperConstructorCall.kt
|
||||
CLASS CLASS Base
|
||||
CONSTRUCTOR public constructor Base()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Base
|
||||
CLASS CLASS TestImplicitPrimaryConstructor
|
||||
CONSTRUCTOR public constructor TestImplicitPrimaryConstructor()
|
||||
BLOCK_BODY
|
||||
CALL .<init> type=Base operator=SUPER_CONSTRUCTOR_CALL
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestImplicitPrimaryConstructor
|
||||
CLASS CLASS TestExplicitPrimaryConstructor
|
||||
CONSTRUCTOR public constructor TestExplicitPrimaryConstructor()
|
||||
BLOCK_BODY
|
||||
CALL .<init> type=Base operator=SUPER_CONSTRUCTOR_CALL
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestExplicitPrimaryConstructor
|
||||
CLASS CLASS TestWithDelegatingConstructor
|
||||
CONSTRUCTOR public constructor TestWithDelegatingConstructor(/*0*/ x: kotlin.Int, /*1*/ y: kotlin.Int)
|
||||
BLOCK_BODY
|
||||
@@ -18,6 +21,7 @@ FILE /primaryConstructorWithSuperConstructorCall.kt
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
SET_BACKING_FIELD y type=kotlin.Unit operator=null
|
||||
GET_VAR y type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestWithDelegatingConstructor
|
||||
PROPERTY public final val x: kotlin.Int
|
||||
EXPRESSION_BODY
|
||||
GET_VAR x type=kotlin.Int operator=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
|
||||
@@ -18,6 +18,7 @@ FILE /qualifiedSuperCalls.kt
|
||||
CLASS CLASS CBoth
|
||||
CONSTRUCTOR public constructor CBoth()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=CBoth
|
||||
FUN public open override /*2*/ fun foo(): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
CALL .foo superQualifier=ILeft type=kotlin.Unit operator=null
|
||||
|
||||
+6
-8
@@ -2,24 +2,22 @@ FILE /secondaryConstructorWithInitializersFromClassBody.kt
|
||||
CLASS CLASS Base
|
||||
CONSTRUCTOR public constructor Base()
|
||||
BLOCK_BODY
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Base
|
||||
CLASS CLASS TestProperty
|
||||
nestedInitializers: BLOCK_BODY
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
CONST Int type=kotlin.Int value='0'
|
||||
PROPERTY public final val x: kotlin.Int = 0
|
||||
EXPRESSION_BODY
|
||||
CONST Int type=kotlin.Int value='0'
|
||||
CONSTRUCTOR public constructor TestProperty()
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL Base
|
||||
NESTED_INITIALIZERS_CALL classDescriptor=TestProperty
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestProperty
|
||||
CLASS CLASS TestInitBlock
|
||||
nestedInitializers: BLOCK_BODY
|
||||
BLOCK type=kotlin.Unit operator=null
|
||||
PROPERTY public final val x: kotlin.Int
|
||||
ANONYMOUS_INITIALIZER TestInitBlock
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD x type=kotlin.Unit operator=null
|
||||
CONST Int type=kotlin.Int value='0'
|
||||
PROPERTY public final val x: kotlin.Int
|
||||
CONSTRUCTOR public constructor TestInitBlock()
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL Base
|
||||
NESTED_INITIALIZERS_CALL classDescriptor=TestInitBlock
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=TestInitBlock
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
FILE /secondaryConstructors.kt
|
||||
CLASS CLASS C
|
||||
nestedInitializers: BLOCK_BODY
|
||||
CONSTRUCTOR public constructor C()
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL C
|
||||
@@ -8,4 +7,4 @@ FILE /secondaryConstructors.kt
|
||||
CONSTRUCTOR public constructor C(/*0*/ x: kotlin.Int)
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL Any
|
||||
NESTED_INITIALIZERS_CALL classDescriptor=C
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=C
|
||||
|
||||
+2
-2
@@ -2,8 +2,7 @@ FILE /superCalls.kt
|
||||
CLASS CLASS Base
|
||||
CONSTRUCTOR public constructor Base()
|
||||
BLOCK_BODY
|
||||
SET_BACKING_FIELD bar type=kotlin.Unit operator=null
|
||||
CONST String type=kotlin.String value=''
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Base
|
||||
FUN public open fun foo(): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
PROPERTY public open val bar: kotlin.String = ""
|
||||
@@ -13,6 +12,7 @@ FILE /superCalls.kt
|
||||
CONSTRUCTOR public constructor Derived()
|
||||
BLOCK_BODY
|
||||
CALL .<init> type=Base operator=SUPER_CONSTRUCTOR_CALL
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor=Derived
|
||||
FUN public open override /*1*/ fun foo(): kotlin.Unit
|
||||
BLOCK_BODY
|
||||
CALL .foo superQualifier=Base type=kotlin.Unit operator=null
|
||||
|
||||
Reference in New Issue
Block a user