FIR2IR: fix problems with enum entry / anonymous object visibility

This commit is contained in:
Mikhail Glukhikh
2020-02-18 10:48:11 +03:00
parent 9f0ef77531
commit fdf4f477a6
35 changed files with 94 additions and 113 deletions
@@ -34,23 +34,23 @@ FILE fqName:<root> fileName:/enumEntriesWithAnnotations.kt
DELEGATING_CONSTRUCTOR_CALL 'public constructor <init> () [primary] declared in kotlin.Any'
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_CLASS name:TestEnum modality:FINAL visibility:public superTypes:[kotlin.Enum<<root>.TestEnum>]'
ENUM_ENTRY name:ENTRY1
class: CLASS ENUM_ENTRY name:ENTRY1 modality:FINAL visibility:local superTypes:[<root>.TestEnum]
class: CLASS ENUM_ENTRY name:ENTRY1 modality:FINAL visibility:private superTypes:[<root>.TestEnum]
annotations:
TestAnn(x = 'ENTRY1')
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum.ENTRY1
CONSTRUCTOR visibility:private <> () returnType:<uninitialized parent>.<anonymous> [primary]
BLOCK_BODY
DELEGATING_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestEnum'
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_ENTRY name:ENTRY1 modality:FINAL visibility:local superTypes:[<root>.TestEnum]'
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_ENTRY name:ENTRY1 modality:FINAL visibility:private superTypes:[<root>.TestEnum]'
ENUM_ENTRY name:ENTRY2
class: CLASS ENUM_ENTRY name:ENTRY2 modality:FINAL visibility:local superTypes:[<root>.TestEnum]
class: CLASS ENUM_ENTRY name:ENTRY2 modality:FINAL visibility:private superTypes:[<root>.TestEnum]
annotations:
TestAnn(x = 'ENTRY2')
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.TestEnum.ENTRY2
CONSTRUCTOR visibility:private <> () returnType:<uninitialized parent>.<anonymous> [primary]
BLOCK_BODY
DELEGATING_CONSTRUCTOR_CALL 'private constructor <init> () [primary] declared in <root>.TestEnum'
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_ENTRY name:ENTRY2 modality:FINAL visibility:local superTypes:[<root>.TestEnum]'
INSTANCE_INITIALIZER_CALL classDescriptor='CLASS ENUM_ENTRY name:ENTRY2 modality:FINAL visibility:private superTypes:[<root>.TestEnum]'
PROPERTY name:x visibility:public modality:FINAL [val]
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:private [final]
EXPRESSION_BODY