FIR2IR: set enum class modality properly for complex entries case

This commit is contained in:
Mikhail Glukhikh
2020-03-03 18:45:45 +03:00
parent 3ffe1a1876
commit 940567b8bd
35 changed files with 56 additions and 70 deletions
@@ -5,10 +5,7 @@
package org.jetbrains.kotlin.fir.backend package org.jetbrains.kotlin.fir.backend
import org.jetbrains.kotlin.descriptors.DeclarationDescriptor import org.jetbrains.kotlin.descriptors.*
import org.jetbrains.kotlin.descriptors.Modality
import org.jetbrains.kotlin.descriptors.Visibilities
import org.jetbrains.kotlin.descriptors.Visibility
import org.jetbrains.kotlin.fir.FirSession import org.jetbrains.kotlin.fir.FirSession
import org.jetbrains.kotlin.fir.declarations.* import org.jetbrains.kotlin.fir.declarations.*
import org.jetbrains.kotlin.fir.declarations.impl.FirDefaultPropertyGetter import org.jetbrains.kotlin.fir.declarations.impl.FirDefaultPropertyGetter
@@ -248,8 +245,22 @@ class Fir2IrDeclarationStorage(
val descriptor = WrappedClassDescriptor() val descriptor = WrappedClassDescriptor()
val origin = IrDeclarationOrigin.DEFINED val origin = IrDeclarationOrigin.DEFINED
val modality = regularClass.modality ?: Modality.FINAL
val visibility = regularClass.visibility val visibility = regularClass.visibility
val modality = if (regularClass.classKind == ClassKind.ENUM_CLASS) {
when {
regularClass.declarations.any { it is FirCallableMemberDeclaration<*> && it.modality == Modality.ABSTRACT } -> {
Modality.ABSTRACT
}
regularClass.declarations.any { it is FirEnumEntry && it.initializer != null } -> {
Modality.OPEN
}
else -> {
Modality.FINAL
}
}
} else {
regularClass.modality ?: Modality.FINAL
}
val irClass = klass.convertWithOffsets { startOffset, endOffset -> val irClass = klass.convertWithOffsets { startOffset, endOffset ->
irSymbolTable.declareClass(startOffset, endOffset, origin, descriptor, modality, visibility) { symbol -> irSymbolTable.declareClass(startOffset, endOffset, origin, descriptor, modality, visibility) { symbol ->
IrClassImpl( IrClassImpl(
@@ -259,7 +270,7 @@ class Fir2IrDeclarationStorage(
symbol, symbol,
regularClass.name, regularClass.name,
klass.classKind, klass.classKind,
regularClass.visibility, visibility,
modality, modality,
isCompanion = regularClass.isCompanion, isCompanion = regularClass.isCompanion,
isInner = regularClass.isInner, isInner = regularClass.isInner,
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
interface A<T> { interface A<T> {
open fun foo(t: T) = "A" open fun foo(t: T) = "A"
} }
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
import kotlin.reflect.KProperty1 import kotlin.reflect.KProperty1
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class A(val a: Int = 1) { enum class A(val a: Int = 1) {
FIRST(), FIRST(),
SECOND(2) SECOND(2)
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class A() { enum class A() {
ENTRY(){ override fun t() = "OK"}; ENTRY(){ override fun t() = "OK"};
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
// TARGET_BACKEND: JVM // TARGET_BACKEND: JVM
// FILE: Foo.java // FILE: Foo.java
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
// TARGET_BACKEND: JVM // TARGET_BACKEND: JVM
// FILE: Foo.java // FILE: Foo.java
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class Test(val str: String = "OK") { enum class Test(val str: String = "OK") {
OK OK
} }
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class Test(vararg xs: Int) { enum class Test(vararg xs: Int) {
OK; OK;
val values = xs val values = xs
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class Test(val str: String = "OK") { enum class Test(val str: String = "OK") {
OK { OK {
fun foo() {} fun foo() {}
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
// IGNORE_BACKEND: JS // IGNORE_BACKEND: JS
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class Test(val x: Int, val str: String) { enum class Test(val x: Int, val str: String) {
OK; OK;
constructor(x: Int = 0) : this(x, "OK") constructor(x: Int = 0) : this(x, "OK")
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class Test(val x: Int, val str: String) { enum class Test(val x: Int, val str: String) {
OK; OK;
constructor(vararg xs: Int) : this(xs.size + 42, "OK") constructor(vararg xs: Int) : this(xs.size + 42, "OK")
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
package test package test
enum class My(val s: String) { enum class My(val s: String) {
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class Color(val rgb: Int) { enum class Color(val rgb: Int) {
RED(0xff0000), RED(0xff0000),
GREEN(0x00ff00), GREEN(0x00ff00),
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class Test(val x: String, val closure1: () -> String) { enum class Test(val x: String, val closure1: () -> String) {
FOO("O", { FOO.x }) { FOO("O", { FOO.x }) {
override val y: String = "K" override val y: String = "K"
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class Foo( enum class Foo(
val x: String, val x: String,
val callback: () -> String val callback: () -> String
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class X { enum class X {
B { B {
val value2 = "K" val value2 = "K"
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class X { enum class X {
B { B {
override val value2 = "K" override val value2 = "K"
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class X { enum class X {
B { B {
override val value2 = "K" override val value2 = "K"
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
fun <T, R> T.letNoInline(fn: (T) -> R) = fun <T, R> T.letNoInline(fn: (T) -> R) =
fn(this) fn(this)
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class X { enum class X {
B { B {
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class ClassTemplate( enum class ClassTemplate(
// var bug: Int = 1, // var bug: Int = 1,
var code: Int, var code: Int,
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
enum class Enum { enum class Enum {
ENUM_VALUE { ENUM_VALUE {
override fun test() = ENUM_VALUE override fun test() = ENUM_VALUE
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
//WITH_RUNTIME //WITH_RUNTIME
import kotlin.test.assertEquals import kotlin.test.assertEquals
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
//WITH_RUNTIME //WITH_RUNTIME
import kotlin.test.assertEquals import kotlin.test.assertEquals
+10 -10
View File
@@ -53,14 +53,14 @@ FILE fqName:<root> fileName:/enum.kt
overridden: overridden:
public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum
$this: VALUE_PARAMETER name:<this> type:<root>.TestEnum1 $this: VALUE_PARAMETER name:<this> type:<root>.TestEnum1
CLASS ENUM_CLASS name:TestEnum2 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum2>] CLASS ENUM_CLASS name:TestEnum2 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestEnum2>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum2 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum2
CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.TestEnum2 [primary] CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.TestEnum2 [primary]
VALUE_PARAMETER name:x index:0 type:kotlin.Int VALUE_PARAMETER name:x index:0 type:kotlin.Int
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.TestEnum2 <E>: <root>.TestEnum2
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum2 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum2>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum2 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestEnum2>]'
PROPERTY name:x visibility:public modality:FINAL [val] PROPERTY name:x visibility:public modality:FINAL [val]
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final] FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final]
EXPRESSION_BODY EXPRESSION_BODY
@@ -143,13 +143,13 @@ FILE fqName:<root> fileName:/enum.kt
overridden: overridden:
public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum
$this: VALUE_PARAMETER name:<this> type:<root>.TestEnum2 $this: VALUE_PARAMETER name:<this> type:<root>.TestEnum2
CLASS ENUM_CLASS name:TestEnum3 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum3>] CLASS ENUM_CLASS name:TestEnum3 modality:ABSTRACT visibility:public superTypes:[kotlin.Enum<<root>.TestEnum3>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum3 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum3
CONSTRUCTOR visibility:private <> () returnType:<root>.TestEnum3 [primary] CONSTRUCTOR visibility:private <> () returnType:<root>.TestEnum3 [primary]
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.TestEnum3 <E>: <root>.TestEnum3
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum3 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum3>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum3 modality:ABSTRACT visibility:public superTypes:[kotlin.Enum<<root>.TestEnum3>]'
ENUM_ENTRY name:TEST ENUM_ENTRY name:TEST
init: EXPRESSION_BODY init: EXPRESSION_BODY
ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestEnum3.TEST' ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestEnum3.TEST'
@@ -207,14 +207,14 @@ FILE fqName:<root> fileName:/enum.kt
overridden: overridden:
public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum
$this: VALUE_PARAMETER name:<this> type:<root>.TestEnum3 $this: VALUE_PARAMETER name:<this> type:<root>.TestEnum3
CLASS ENUM_CLASS name:TestEnum4 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum4>] CLASS ENUM_CLASS name:TestEnum4 modality:ABSTRACT visibility:public superTypes:[kotlin.Enum<<root>.TestEnum4>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum4 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum4
CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.TestEnum4 [primary] CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.TestEnum4 [primary]
VALUE_PARAMETER name:x index:0 type:kotlin.Int VALUE_PARAMETER name:x index:0 type:kotlin.Int
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.TestEnum4 <E>: <root>.TestEnum4
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum4 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum4>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum4 modality:ABSTRACT visibility:public superTypes:[kotlin.Enum<<root>.TestEnum4>]'
PROPERTY name:x visibility:public modality:FINAL [val] PROPERTY name:x visibility:public modality:FINAL [val]
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final] FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final]
EXPRESSION_BODY EXPRESSION_BODY
@@ -313,7 +313,7 @@ FILE fqName:<root> fileName:/enum.kt
overridden: overridden:
public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum
$this: VALUE_PARAMETER name:<this> type:<root>.TestEnum4 $this: VALUE_PARAMETER name:<this> type:<root>.TestEnum4
CLASS ENUM_CLASS name:TestEnum5 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum5>] CLASS ENUM_CLASS name:TestEnum5 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestEnum5>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum5 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum5
CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.TestEnum5 [primary] CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.TestEnum5 [primary]
VALUE_PARAMETER name:x index:0 type:kotlin.Int VALUE_PARAMETER name:x index:0 type:kotlin.Int
@@ -322,7 +322,7 @@ FILE fqName:<root> fileName:/enum.kt
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.TestEnum5 <E>: <root>.TestEnum5
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum5 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum5>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum5 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestEnum5>]'
PROPERTY name:x visibility:public modality:FINAL [val] PROPERTY name:x visibility:public modality:FINAL [val]
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final] FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final]
EXPRESSION_BODY EXPRESSION_BODY
@@ -407,7 +407,7 @@ FILE fqName:<root> fileName:/enum.kt
BLOCK_BODY BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun f (): kotlin.Int declared in <root>' RETURN type=kotlin.Nothing from='public final fun f (): kotlin.Int declared in <root>'
CONST Int type=kotlin.Int value=1 CONST Int type=kotlin.Int value=1
CLASS ENUM_CLASS name:TestEnum6 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum6>] CLASS ENUM_CLASS name:TestEnum6 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestEnum6>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum6 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum6
CONSTRUCTOR visibility:private <> (x:kotlin.Int, y:kotlin.Int) returnType:<root>.TestEnum6 [primary] CONSTRUCTOR visibility:private <> (x:kotlin.Int, y:kotlin.Int) returnType:<root>.TestEnum6 [primary]
VALUE_PARAMETER name:x index:0 type:kotlin.Int VALUE_PARAMETER name:x index:0 type:kotlin.Int
@@ -415,7 +415,7 @@ FILE fqName:<root> fileName:/enum.kt
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.TestEnum6 <E>: <root>.TestEnum6
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum6 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum6>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum6 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestEnum6>]'
PROPERTY name:x visibility:public modality:FINAL [val] PROPERTY name:x visibility:public modality:FINAL [val]
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final] FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final]
EXPRESSION_BODY EXPRESSION_BODY
+10 -10
View File
@@ -50,14 +50,14 @@ FILE fqName:<root> fileName:/enumClassModality.kt
overridden: overridden:
public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum
$this: VALUE_PARAMETER name:<this> type:<root>.TestFinalEnum1 $this: VALUE_PARAMETER name:<this> type:<root>.TestFinalEnum1
CLASS ENUM_CLASS name:TestFinalEnum2 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestFinalEnum2>] CLASS ENUM_CLASS name:TestFinalEnum2 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestFinalEnum2>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestFinalEnum2 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestFinalEnum2
CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.TestFinalEnum2 [primary] CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.TestFinalEnum2 [primary]
VALUE_PARAMETER name:x index:0 type:kotlin.Int VALUE_PARAMETER name:x index:0 type:kotlin.Int
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.TestFinalEnum2 <E>: <root>.TestFinalEnum2
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestFinalEnum2 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestFinalEnum2>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestFinalEnum2 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestFinalEnum2>]'
PROPERTY name:x visibility:public modality:FINAL [val] PROPERTY name:x visibility:public modality:FINAL [val]
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final] FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final]
EXPRESSION_BODY EXPRESSION_BODY
@@ -174,13 +174,13 @@ FILE fqName:<root> fileName:/enumClassModality.kt
overridden: overridden:
public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum
$this: VALUE_PARAMETER name:<this> type:<root>.TestFinalEnum3 $this: VALUE_PARAMETER name:<this> type:<root>.TestFinalEnum3
CLASS ENUM_CLASS name:TestOpenEnum1 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestOpenEnum1>] CLASS ENUM_CLASS name:TestOpenEnum1 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestOpenEnum1>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestOpenEnum1 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestOpenEnum1
CONSTRUCTOR visibility:private <> () returnType:<root>.TestOpenEnum1 [primary] CONSTRUCTOR visibility:private <> () returnType:<root>.TestOpenEnum1 [primary]
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.TestOpenEnum1 <E>: <root>.TestOpenEnum1
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestOpenEnum1 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestOpenEnum1>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestOpenEnum1 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestOpenEnum1>]'
ENUM_ENTRY name:X1 ENUM_ENTRY name:X1
init: EXPRESSION_BODY init: EXPRESSION_BODY
ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestOpenEnum1.X1' ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestOpenEnum1.X1'
@@ -236,13 +236,13 @@ FILE fqName:<root> fileName:/enumClassModality.kt
overridden: overridden:
public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum
$this: VALUE_PARAMETER name:<this> type:<root>.TestOpenEnum1 $this: VALUE_PARAMETER name:<this> type:<root>.TestOpenEnum1
CLASS ENUM_CLASS name:TestOpenEnum2 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestOpenEnum2>] CLASS ENUM_CLASS name:TestOpenEnum2 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestOpenEnum2>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestOpenEnum2 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestOpenEnum2
CONSTRUCTOR visibility:private <> () returnType:<root>.TestOpenEnum2 [primary] CONSTRUCTOR visibility:private <> () returnType:<root>.TestOpenEnum2 [primary]
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.TestOpenEnum2 <E>: <root>.TestOpenEnum2
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestOpenEnum2 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestOpenEnum2>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestOpenEnum2 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestOpenEnum2>]'
ENUM_ENTRY name:X1 ENUM_ENTRY name:X1
init: EXPRESSION_BODY init: EXPRESSION_BODY
ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestOpenEnum2.X1' ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestOpenEnum2.X1'
@@ -299,13 +299,13 @@ FILE fqName:<root> fileName:/enumClassModality.kt
overridden: overridden:
public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum
$this: VALUE_PARAMETER name:<this> type:<root>.TestOpenEnum2 $this: VALUE_PARAMETER name:<this> type:<root>.TestOpenEnum2
CLASS ENUM_CLASS name:TestAbstractEnum1 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestAbstractEnum1>] CLASS ENUM_CLASS name:TestAbstractEnum1 modality:ABSTRACT visibility:public superTypes:[kotlin.Enum<<root>.TestAbstractEnum1>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestAbstractEnum1 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestAbstractEnum1
CONSTRUCTOR visibility:private <> () returnType:<root>.TestAbstractEnum1 [primary] CONSTRUCTOR visibility:private <> () returnType:<root>.TestAbstractEnum1 [primary]
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.TestAbstractEnum1 <E>: <root>.TestAbstractEnum1
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestAbstractEnum1 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestAbstractEnum1>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestAbstractEnum1 modality:ABSTRACT visibility:public superTypes:[kotlin.Enum<<root>.TestAbstractEnum1>]'
ENUM_ENTRY name:X1 ENUM_ENTRY name:X1
init: EXPRESSION_BODY init: EXPRESSION_BODY
ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestAbstractEnum1.X1' ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestAbstractEnum1.X1'
@@ -378,13 +378,13 @@ FILE fqName:<root> fileName:/enumClassModality.kt
overridden: overridden:
public open fun toString (): kotlin.String declared in kotlin.Any public open fun toString (): kotlin.String declared in kotlin.Any
$this: VALUE_PARAMETER name:<this> type:kotlin.Any $this: VALUE_PARAMETER name:<this> type:kotlin.Any
CLASS ENUM_CLASS name:TestAbstractEnum2 modality:FINAL visibility:public superTypes:[<root>.IFoo; kotlin.Enum<<root>.TestAbstractEnum2>] CLASS ENUM_CLASS name:TestAbstractEnum2 modality:OPEN visibility:public superTypes:[<root>.IFoo; kotlin.Enum<<root>.TestAbstractEnum2>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestAbstractEnum2 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestAbstractEnum2
CONSTRUCTOR visibility:private <> () returnType:<root>.TestAbstractEnum2 [primary] CONSTRUCTOR visibility:private <> () returnType:<root>.TestAbstractEnum2 [primary]
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.TestAbstractEnum2 <E>: <root>.TestAbstractEnum2
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestAbstractEnum2 modality:FINAL visibility:public superTypes:[<root>.IFoo; kotlin.Enum<<root>.TestAbstractEnum2>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestAbstractEnum2 modality:OPEN visibility:public superTypes:[<root>.IFoo; kotlin.Enum<<root>.TestAbstractEnum2>]'
ENUM_ENTRY name:X1 ENUM_ENTRY name:X1
init: EXPRESSION_BODY init: EXPRESSION_BODY
ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestAbstractEnum2.X1' ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestAbstractEnum2.X1'
@@ -1,5 +1,5 @@
FILE fqName:<root> fileName:/enumWithMultipleCtors.kt FILE fqName:<root> fileName:/enumWithMultipleCtors.kt
CLASS ENUM_CLASS name:A modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.A>] CLASS ENUM_CLASS name:A modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.A>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.A $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.A
ENUM_ENTRY name:X ENUM_ENTRY name:X
init: EXPRESSION_BODY init: EXPRESSION_BODY
@@ -85,7 +85,7 @@ FILE fqName:<root> fileName:/enumWithMultipleCtors.kt
value: GET_VAR 'arg: kotlin.String declared in <root>.A.<init>' type=kotlin.String origin=null value: GET_VAR 'arg: kotlin.String declared in <root>.A.<init>' type=kotlin.String origin=null
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.A <E>: <root>.A
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:A modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.A>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:A modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.A>]'
CONSTRUCTOR visibility:private <> () returnType:<root>.A CONSTRUCTOR visibility:private <> () returnType:<root>.A
BLOCK_BODY BLOCK_BODY
SET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:prop1 type:kotlin.String visibility:private [final]' type=kotlin.Unit origin=null SET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:prop1 type:kotlin.String visibility:private [final]' type=kotlin.Unit origin=null
@@ -96,7 +96,7 @@ FILE fqName:<root> fileName:/enumWithMultipleCtors.kt
value: CONST String type=kotlin.String value="empty" value: CONST String type=kotlin.String value="empty"
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.A <E>: <root>.A
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:A modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.A>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:A modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.A>]'
CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.A CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.A
VALUE_PARAMETER name:x index:0 type:kotlin.Int VALUE_PARAMETER name:x index:0 type:kotlin.Int
BLOCK_BODY BLOCK_BODY
@@ -1,12 +1,12 @@
FILE fqName:<root> fileName:/enumWithSecondaryCtor.kt FILE fqName:<root> fileName:/enumWithSecondaryCtor.kt
CLASS ENUM_CLASS name:Test0 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.Test0>] CLASS ENUM_CLASS name:Test0 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.Test0>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.Test0 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.Test0
CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.Test0 [primary] CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.Test0 [primary]
VALUE_PARAMETER name:x index:0 type:kotlin.Int VALUE_PARAMETER name:x index:0 type:kotlin.Int
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.Test0 <E>: <root>.Test0
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:Test0 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.Test0>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:Test0 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.Test0>]'
PROPERTY name:x visibility:public modality:FINAL [val] PROPERTY name:x visibility:public modality:FINAL [val]
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final] FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final]
EXPRESSION_BODY EXPRESSION_BODY
@@ -72,14 +72,14 @@ FILE fqName:<root> fileName:/enumWithSecondaryCtor.kt
overridden: overridden:
public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum
$this: VALUE_PARAMETER name:<this> type:<root>.Test0 $this: VALUE_PARAMETER name:<this> type:<root>.Test0
CLASS ENUM_CLASS name:Test1 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.Test1>] CLASS ENUM_CLASS name:Test1 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.Test1>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.Test1 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.Test1
CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.Test1 [primary] CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.Test1 [primary]
VALUE_PARAMETER name:x index:0 type:kotlin.Int VALUE_PARAMETER name:x index:0 type:kotlin.Int
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.Test1 <E>: <root>.Test1
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:Test1 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.Test1>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:Test1 modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.Test1>]'
PROPERTY name:x visibility:public modality:FINAL [val] PROPERTY name:x visibility:public modality:FINAL [val]
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final] FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final]
EXPRESSION_BODY EXPRESSION_BODY
@@ -155,14 +155,14 @@ FILE fqName:<root> fileName:/enumWithSecondaryCtor.kt
overridden: overridden:
public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum public final fun <get-ordinal> (): kotlin.Int declared in kotlin.Enum
$this: VALUE_PARAMETER name:<this> type:<root>.Test1 $this: VALUE_PARAMETER name:<this> type:<root>.Test1
CLASS ENUM_CLASS name:Test2 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.Test2>] CLASS ENUM_CLASS name:Test2 modality:ABSTRACT visibility:public superTypes:[kotlin.Enum<<root>.Test2>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.Test2 $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.Test2
CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.Test2 [primary] CONSTRUCTOR visibility:private <> (x:kotlin.Int) returnType:<root>.Test2 [primary]
VALUE_PARAMETER name:x index:0 type:kotlin.Int VALUE_PARAMETER name:x index:0 type:kotlin.Int
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.Test2 <E>: <root>.Test2
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:Test2 modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.Test2>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:Test2 modality:ABSTRACT visibility:public superTypes:[kotlin.Enum<<root>.Test2>]'
PROPERTY name:x visibility:public modality:FINAL [val] PROPERTY name:x visibility:public modality:FINAL [val]
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final] FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final]
EXPRESSION_BODY EXPRESSION_BODY
@@ -27,13 +27,13 @@ FILE fqName:<root> fileName:/enumEntriesWithAnnotations.kt
overridden: overridden:
public open fun toString (): kotlin.String declared in kotlin.Any public open fun toString (): kotlin.String declared in kotlin.Any
$this: VALUE_PARAMETER name:<this> type:kotlin.Any $this: VALUE_PARAMETER name:<this> type:kotlin.Any
CLASS ENUM_CLASS name:TestEnum modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum>] CLASS ENUM_CLASS name:TestEnum modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestEnum>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum
CONSTRUCTOR visibility:private <> () returnType:<root>.TestEnum [primary] CONSTRUCTOR visibility:private <> () returnType:<root>.TestEnum [primary]
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.TestEnum <E>: <root>.TestEnum
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.TestEnum>]'
ENUM_ENTRY name:ENTRY1 ENUM_ENTRY name:ENTRY1
init: EXPRESSION_BODY init: EXPRESSION_BODY
ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestEnum.ENTRY1' ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestEnum.ENTRY1'
@@ -1,11 +1,11 @@
FILE fqName:<root> fileName:/enumEntryAsReceiver.kt FILE fqName:<root> fileName:/enumEntryAsReceiver.kt
CLASS ENUM_CLASS name:X modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.X>] CLASS ENUM_CLASS name:X modality:ABSTRACT visibility:public superTypes:[kotlin.Enum<<root>.X>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.X $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.X
CONSTRUCTOR visibility:private <> () returnType:<root>.X [primary] CONSTRUCTOR visibility:private <> () returnType:<root>.X [primary]
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.X <E>: <root>.X
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:X modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.X>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:X modality:ABSTRACT visibility:public superTypes:[kotlin.Enum<<root>.X>]'
ENUM_ENTRY name:B ENUM_ENTRY name:B
init: EXPRESSION_BODY init: EXPRESSION_BODY
ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.X.B' ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.X.B'
@@ -1,11 +1,11 @@
FILE fqName:<root> fileName:/enumEntryReferenceFromEnumEntryClass.kt FILE fqName:<root> fileName:/enumEntryReferenceFromEnumEntryClass.kt
CLASS ENUM_CLASS name:MyEnum modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.MyEnum>] CLASS ENUM_CLASS name:MyEnum modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.MyEnum>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.MyEnum $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.MyEnum
CONSTRUCTOR visibility:private <> () returnType:<root>.MyEnum [primary] CONSTRUCTOR visibility:private <> () returnType:<root>.MyEnum [primary]
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.MyEnum <E>: <root>.MyEnum
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:MyEnum modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.MyEnum>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:MyEnum modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.MyEnum>]'
ENUM_ENTRY name:Z ENUM_ENTRY name:Z
init: EXPRESSION_BODY init: EXPRESSION_BODY
ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.MyEnum.Z' ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.MyEnum.Z'
@@ -8,14 +8,14 @@ FILE fqName:<root> fileName:/temporaryInEnumEntryInitializer.kt
BLOCK_BODY BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun <get-n> (): kotlin.Any? declared in <root>' RETURN type=kotlin.Nothing from='public final fun <get-n> (): kotlin.Any? declared in <root>'
GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:n type:kotlin.Any? visibility:private [final,static]' type=kotlin.Any? origin=null GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:n type:kotlin.Any? visibility:private [final,static]' type=kotlin.Any? origin=null
CLASS ENUM_CLASS name:En modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.En>] CLASS ENUM_CLASS name:En modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.En>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.En $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.En
CONSTRUCTOR visibility:private <> (x:kotlin.String?) returnType:<root>.En [primary] CONSTRUCTOR visibility:private <> (x:kotlin.String?) returnType:<root>.En [primary]
VALUE_PARAMETER name:x index:0 type:kotlin.String? VALUE_PARAMETER name:x index:0 type:kotlin.String?
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.En <E>: <root>.En
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:En modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.En>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:En modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.En>]'
PROPERTY name:x visibility:public modality:FINAL [val] PROPERTY name:x visibility:public modality:FINAL [val]
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.String? visibility:private [final] FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.String? visibility:private [final]
EXPRESSION_BODY EXPRESSION_BODY
+2 -2
View File
@@ -1,11 +1,11 @@
FILE fqName:<root> fileName:/enumEntry.kt FILE fqName:<root> fileName:/enumEntry.kt
CLASS ENUM_CLASS name:Z modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.Z>] CLASS ENUM_CLASS name:Z modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.Z>]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.Z $this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.Z
CONSTRUCTOR visibility:private <> () returnType:<root>.Z [primary] CONSTRUCTOR visibility:private <> () returnType:<root>.Z [primary]
BLOCK_BODY BLOCK_BODY
ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum' ENUM_CONSTRUCTOR_CALL 'public constructor <init> (name: kotlin.String, ordinal: kotlin.Int) [primary] declared in kotlin.Enum'
<E>: <root>.Z <E>: <root>.Z
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:Z modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.Z>]' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:Z modality:OPEN visibility:public superTypes:[kotlin.Enum<<root>.Z>]'
ENUM_ENTRY name:ENTRY ENUM_ENTRY name:ENTRY
init: EXPRESSION_BODY init: EXPRESSION_BODY
ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.Z.ENTRY' ENUM_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.Z.ENTRY'