More annotation generation for declarations with test cases
This commit is contained in:
@@ -22,10 +22,14 @@ import org.jetbrains.kotlin.ir.declarations.impl.IrFileImpl
|
||||
import org.jetbrains.kotlin.ir.declarations.impl.IrModuleFragmentImpl
|
||||
import org.jetbrains.kotlin.ir.util.ExternalDependenciesGenerator
|
||||
import org.jetbrains.kotlin.psi.KtFile
|
||||
import org.jetbrains.kotlin.psi2ir.transformations.AnnotationGenerator
|
||||
import org.jetbrains.kotlin.resolve.BindingContext
|
||||
import org.jetbrains.kotlin.resolve.lazy.descriptors.findPackageFragmentForFile
|
||||
|
||||
class ModuleGenerator(override val context: GeneratorContext) : Generator {
|
||||
|
||||
private val annotationGenerator = AnnotationGenerator(context)
|
||||
|
||||
fun generateModuleFragment(ktFiles: Collection<KtFile>): IrModuleFragment =
|
||||
generateModuleFragmentWithoutDependencies(ktFiles).also { irModule ->
|
||||
generateUnboundSymbolsAsDependencies(irModule)
|
||||
@@ -52,7 +56,9 @@ class ModuleGenerator(override val context: GeneratorContext) : Generator {
|
||||
val irFile = createEmptyIrFile(ktFile)
|
||||
|
||||
for (ktAnnotationEntry in ktFile.annotationEntries) {
|
||||
irFile.fileAnnotations.add(getOrFail(BindingContext.ANNOTATION, ktAnnotationEntry))
|
||||
val annotationDescriptor = getOrFail(BindingContext.ANNOTATION, ktAnnotationEntry)
|
||||
irFile.fileAnnotations.add(annotationDescriptor)
|
||||
irFile.annotations.add(annotationGenerator.generateAnnotationConstructorCall(annotationDescriptor))
|
||||
}
|
||||
|
||||
for (ktDeclaration in ktFile.declarations) {
|
||||
|
||||
+35
-21
@@ -6,16 +6,13 @@
|
||||
package org.jetbrains.kotlin.psi2ir.transformations
|
||||
|
||||
import org.jetbrains.kotlin.descriptors.ClassDescriptor
|
||||
import org.jetbrains.kotlin.descriptors.PropertyGetterDescriptor
|
||||
import org.jetbrains.kotlin.descriptors.PropertySetterDescriptor
|
||||
import org.jetbrains.kotlin.descriptors.annotations.AnnotationDescriptor
|
||||
import org.jetbrains.kotlin.descriptors.annotations.AnnotationUseSiteTarget
|
||||
import org.jetbrains.kotlin.descriptors.annotations.AnnotationWithTarget
|
||||
import org.jetbrains.kotlin.ir.IrElement
|
||||
import org.jetbrains.kotlin.ir.UNDEFINED_OFFSET
|
||||
import org.jetbrains.kotlin.ir.declarations.IrDeclaration
|
||||
import org.jetbrains.kotlin.ir.declarations.IrField
|
||||
import org.jetbrains.kotlin.ir.declarations.IrProperty
|
||||
import org.jetbrains.kotlin.ir.declarations.IrSimpleFunction
|
||||
import org.jetbrains.kotlin.ir.declarations.*
|
||||
import org.jetbrains.kotlin.ir.expressions.IrCall
|
||||
import org.jetbrains.kotlin.ir.expressions.impl.IrCallImpl
|
||||
import org.jetbrains.kotlin.ir.visitors.IrElementVisitorVoid
|
||||
@@ -45,12 +42,31 @@ class AnnotationGenerator(private val context: GeneratorContext) : IrElementVisi
|
||||
generateAnnotationsForDeclaration(declaration)
|
||||
}
|
||||
|
||||
private fun generateAnnotationsForDeclaration(declaration: IrDeclaration) {
|
||||
val allAnnotations = declaration.descriptor.annotations.getAllAnnotations()
|
||||
val matchingAnnotations = allAnnotations.filter {
|
||||
isAnnotationTargetMatchingDeclaration(it.target, declaration)
|
||||
override fun visitValueParameter(declaration: IrValueParameter) {
|
||||
super.visitValueParameter(declaration)
|
||||
|
||||
val descriptor = declaration.descriptor
|
||||
val containingDeclaration = descriptor.containingDeclaration
|
||||
|
||||
if (containingDeclaration is PropertySetterDescriptor) {
|
||||
containingDeclaration.correspondingProperty.annotations.getUseSiteTargetedAnnotations()
|
||||
.filter { it.target == AnnotationUseSiteTarget.SETTER_PARAMETER }
|
||||
.generateAnnotationConstructorCalls(declaration)
|
||||
}
|
||||
matchingAnnotations.mapTo(declaration.annotations) {
|
||||
|
||||
descriptor.type.annotations.getAllAnnotations()
|
||||
.filter { it.target == AnnotationUseSiteTarget.RECEIVER }
|
||||
.generateAnnotationConstructorCalls(declaration)
|
||||
}
|
||||
|
||||
private fun generateAnnotationsForDeclaration(declaration: IrDeclaration) {
|
||||
declaration.descriptor.annotations.getAllAnnotations()
|
||||
.filter { isAnnotationTargetMatchingDeclaration(it.target, declaration) }
|
||||
.generateAnnotationConstructorCalls(declaration)
|
||||
}
|
||||
|
||||
private fun List<AnnotationWithTarget>.generateAnnotationConstructorCalls(declaration: IrDeclaration) {
|
||||
mapTo(declaration.annotations) {
|
||||
generateAnnotationConstructorCall(it.annotation)
|
||||
}
|
||||
}
|
||||
@@ -80,8 +96,7 @@ class AnnotationGenerator(private val context: GeneratorContext) : IrElementVisi
|
||||
|
||||
for (valueParameter in primaryConstructorDescriptor.valueParameters) {
|
||||
val argumentIndex = valueParameter.index
|
||||
val argumentValue = annotationDescriptor.allValueArguments[valueParameter.name]
|
||||
?: throw AssertionError("Annotation $annotationDescriptor missing value argument for $valueParameter")
|
||||
val argumentValue = annotationDescriptor.allValueArguments[valueParameter.name] ?: continue
|
||||
val irArgument =
|
||||
constantValueGenerator.generateConstantValueAsExpression(
|
||||
UNDEFINED_OFFSET,
|
||||
@@ -97,18 +112,17 @@ class AnnotationGenerator(private val context: GeneratorContext) : IrElementVisi
|
||||
|
||||
private fun isAnnotationTargetMatchingDeclaration(target: AnnotationUseSiteTarget?, element: IrElement): Boolean =
|
||||
when (element) {
|
||||
is IrProperty -> target == null || target == AnnotationUseSiteTarget.PROPERTY
|
||||
is IrProperty ->
|
||||
target == null || target == AnnotationUseSiteTarget.PROPERTY
|
||||
|
||||
is IrField -> target == AnnotationUseSiteTarget.FIELD
|
||||
is IrField ->
|
||||
target == AnnotationUseSiteTarget.FIELD || target == AnnotationUseSiteTarget.PROPERTY_DELEGATE_FIELD
|
||||
|
||||
is IrSimpleFunction ->
|
||||
target == null || element.descriptor.let {
|
||||
when (it) {
|
||||
is PropertyGetterDescriptor -> target == AnnotationUseSiteTarget.PROPERTY_GETTER
|
||||
is PropertySetterDescriptor -> target == AnnotationUseSiteTarget.PROPERTY_SETTER
|
||||
else -> false
|
||||
}
|
||||
}
|
||||
target == null || target == AnnotationUseSiteTarget.PROPERTY_GETTER || target == AnnotationUseSiteTarget.PROPERTY_SETTER
|
||||
|
||||
is IrValueParameter ->
|
||||
target == null || target == AnnotationUseSiteTarget.CONSTRUCTOR_PARAMETER
|
||||
|
||||
else -> target == null
|
||||
}
|
||||
|
||||
+36
-29
@@ -47,24 +47,26 @@ interface IrImplementingDelegateDescriptor : IrDelegateDescriptor {
|
||||
abstract class IrDelegateDescriptorBase(
|
||||
containingDeclaration: DeclarationDescriptor,
|
||||
name: Name,
|
||||
delegateType: KotlinType
|
||||
) : PropertyDescriptorImpl(
|
||||
containingDeclaration,
|
||||
/* original = */ null,
|
||||
Annotations.EMPTY,
|
||||
Modality.FINAL,
|
||||
Visibilities.PRIVATE,
|
||||
/* isVar = */ false,
|
||||
name,
|
||||
CallableMemberDescriptor.Kind.SYNTHESIZED,
|
||||
SourceElement.NO_SOURCE,
|
||||
/* lateInit = */ false,
|
||||
/* isConst = */ false,
|
||||
/* isExpect = */ false,
|
||||
/* isActual = */ false,
|
||||
/* isExternal = */ false,
|
||||
/* isDelegated = */ true
|
||||
) {
|
||||
delegateType: KotlinType,
|
||||
annotations: Annotations = Annotations.EMPTY
|
||||
) :
|
||||
PropertyDescriptorImpl(
|
||||
containingDeclaration,
|
||||
/* original = */ null,
|
||||
annotations,
|
||||
Modality.FINAL,
|
||||
Visibilities.PRIVATE,
|
||||
/* isVar = */ false,
|
||||
name,
|
||||
CallableMemberDescriptor.Kind.SYNTHESIZED,
|
||||
SourceElement.NO_SOURCE,
|
||||
/* lateInit = */ false,
|
||||
/* isConst = */ false,
|
||||
/* isExpect = */ false,
|
||||
/* isActual = */ false,
|
||||
/* isExternal = */ false,
|
||||
/* isDelegated = */ true
|
||||
) {
|
||||
init {
|
||||
val typeParameters: List<TypeParameterDescriptor> = emptyList()
|
||||
val extensionReceiverParameter: ReceiverParameterDescriptor? = null
|
||||
@@ -75,7 +77,7 @@ abstract class IrDelegateDescriptorBase(
|
||||
setType(delegateType, typeParameters, dispatchReceiverParameter, extensionReceiverParameter)
|
||||
}
|
||||
|
||||
override final fun setOutType(outType: KotlinType?) {
|
||||
final override fun setOutType(outType: KotlinType?) {
|
||||
super.setOutType(outType)
|
||||
}
|
||||
|
||||
@@ -97,21 +99,26 @@ class IrPropertyDelegateDescriptorImpl(
|
||||
override val correspondingProperty: PropertyDescriptor,
|
||||
delegateType: KotlinType,
|
||||
override val kPropertyType: KotlinType
|
||||
) : IrDelegateDescriptorBase(
|
||||
correspondingProperty.containingDeclaration,
|
||||
getDelegateName(correspondingProperty.name),
|
||||
delegateType
|
||||
), IrPropertyDelegateDescriptor
|
||||
) :
|
||||
IrDelegateDescriptorBase(
|
||||
correspondingProperty.containingDeclaration,
|
||||
getDelegateName(correspondingProperty.name),
|
||||
delegateType,
|
||||
correspondingProperty.annotations
|
||||
),
|
||||
IrPropertyDelegateDescriptor
|
||||
|
||||
class IrImplementingDelegateDescriptorImpl(
|
||||
containingDeclaration: ClassDescriptor,
|
||||
delegateType: KotlinType,
|
||||
override val correspondingSuperType: KotlinType
|
||||
) : IrDelegateDescriptorBase(
|
||||
containingDeclaration,
|
||||
getDelegateName(containingDeclaration, correspondingSuperType),
|
||||
delegateType
|
||||
), IrImplementingDelegateDescriptor
|
||||
) :
|
||||
IrDelegateDescriptorBase(
|
||||
containingDeclaration,
|
||||
getDelegateName(containingDeclaration, correspondingSuperType),
|
||||
delegateType
|
||||
),
|
||||
IrImplementingDelegateDescriptor
|
||||
|
||||
internal fun getDelegateName(name: Name): Name =
|
||||
Name.identifier(name.asString() + "\$delegate")
|
||||
|
||||
@@ -80,7 +80,9 @@ open class DeepCopyIrTree : IrElementTransformerVoid() {
|
||||
mapPackageFragmentDescriptor(declaration.packageFragmentDescriptor),
|
||||
declaration.fileAnnotations.toMutableList(),
|
||||
declaration.declarations.map { it.transform() }
|
||||
)
|
||||
).apply {
|
||||
transformAnnotations(declaration)
|
||||
}
|
||||
|
||||
override fun visitDeclaration(declaration: IrDeclaration): IrStatement =
|
||||
throw IllegalArgumentException("Unsupported declaration type: $declaration")
|
||||
@@ -202,6 +204,7 @@ open class DeepCopyIrTree : IrElementTransformerVoid() {
|
||||
mapDeclarationOrigin(originalTypeParameter.origin),
|
||||
newTypeParameterDescriptor
|
||||
).apply {
|
||||
transformAnnotations(originalTypeParameter)
|
||||
for (i in upperBounds.indices) {
|
||||
val upperBoundClassifier = upperBounds[i].constructor.declarationDescriptor ?: continue
|
||||
val oldSuperClassifierSymbol = originalTypeParameter.superClassifiers[i]
|
||||
@@ -268,7 +271,9 @@ open class DeepCopyIrTree : IrElementTransformerVoid() {
|
||||
declaration.delegate.transform(),
|
||||
declaration.getter.transform(),
|
||||
declaration.setter?.transform()
|
||||
)
|
||||
).apply {
|
||||
transformAnnotations(declaration)
|
||||
}
|
||||
|
||||
override fun visitEnumEntry(declaration: IrEnumEntry): IrEnumEntry =
|
||||
IrEnumEntryImpl(
|
||||
@@ -277,7 +282,9 @@ open class DeepCopyIrTree : IrElementTransformerVoid() {
|
||||
mapEnumEntryDeclaration(declaration.descriptor),
|
||||
declaration.correspondingClass?.transform(),
|
||||
declaration.initializerExpression?.transform()
|
||||
)
|
||||
).apply {
|
||||
transformAnnotations(declaration)
|
||||
}
|
||||
|
||||
override fun visitAnonymousInitializer(declaration: IrAnonymousInitializer): IrAnonymousInitializer =
|
||||
IrAnonymousInitializerImpl(
|
||||
|
||||
@@ -73,6 +73,7 @@ open class DeepCopyIrTreeWithSymbols(private val symbolRemapper: SymbolRemapper)
|
||||
declaration.fileEntry,
|
||||
symbolRemapper.getDeclaredFile(declaration.symbol)
|
||||
).apply {
|
||||
transformAnnotations(declaration)
|
||||
fileAnnotations.addAll(declaration.fileAnnotations)
|
||||
declaration.transformDeclarationsTo(this)
|
||||
}
|
||||
@@ -135,7 +136,7 @@ open class DeepCopyIrTreeWithSymbols(private val symbolRemapper: SymbolRemapper)
|
||||
body = declaration.body?.transform()
|
||||
}
|
||||
|
||||
private fun IrDeclaration.transformAnnotations(declaration: IrDeclaration) {
|
||||
private fun IrAnnotationContainer.transformAnnotations(declaration: IrAnnotationContainer) {
|
||||
declaration.annotations.transformTo(annotations)
|
||||
}
|
||||
|
||||
@@ -170,7 +171,9 @@ open class DeepCopyIrTreeWithSymbols(private val symbolRemapper: SymbolRemapper)
|
||||
declaration.delegate.transform(),
|
||||
declaration.getter.transform(),
|
||||
declaration.setter?.transform()
|
||||
)
|
||||
).apply {
|
||||
transformAnnotations(declaration)
|
||||
}
|
||||
|
||||
override fun visitEnumEntry(declaration: IrEnumEntry): IrEnumEntry =
|
||||
IrEnumEntryImpl(
|
||||
@@ -178,6 +181,7 @@ open class DeepCopyIrTreeWithSymbols(private val symbolRemapper: SymbolRemapper)
|
||||
mapDeclarationOrigin(declaration.origin),
|
||||
symbolRemapper.getDeclaredEnumEntry(declaration.symbol)
|
||||
).apply {
|
||||
transformAnnotations(declaration)
|
||||
correspondingClass = declaration.correspondingClass?.transform()
|
||||
initializerExpression = declaration.initializerExpression?.transform()
|
||||
}
|
||||
@@ -207,6 +211,7 @@ open class DeepCopyIrTreeWithSymbols(private val symbolRemapper: SymbolRemapper)
|
||||
mapDeclarationOrigin(declaration.origin),
|
||||
symbolRemapper.getDeclaredTypeParameter(declaration.symbol)
|
||||
).apply {
|
||||
transformAnnotations(declaration)
|
||||
declaration.superClassifiers.mapTo(superClassifiers) {
|
||||
symbolRemapper.getReferencedClassifier(it)
|
||||
}
|
||||
|
||||
@@ -78,6 +78,7 @@ class DumpIrTreeVisitor(out: Appendable) : IrElementVisitor<Unit, String> {
|
||||
}
|
||||
}
|
||||
}
|
||||
dumpAnnotations(declaration)
|
||||
declaration.declarations.dumpElements()
|
||||
}
|
||||
}
|
||||
|
||||
Vendored
+7
@@ -0,0 +1,7 @@
|
||||
annotation class A(val x: String = "", val y: Int = 42)
|
||||
|
||||
@A("abc", 123) fun test1() {}
|
||||
@A("def") fun test2() {}
|
||||
@A(x = "ghi") fun test3() {}
|
||||
@A(y = 456) fun test4() {}
|
||||
@A fun test5() {}
|
||||
Vendored
+70
@@ -0,0 +1,70 @@
|
||||
FILE fqName:<root> fileName:/annotationsWithDefaultParameterValues.kt
|
||||
CLASS ANNOTATION_CLASS name:A modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:A flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (x:kotlin.String, y:kotlin.Int) returnType:A flags:
|
||||
VALUE_PARAMETER name:x index:0 type:kotlin.String flags:
|
||||
EXPRESSION_BODY
|
||||
CONST String type=kotlin.String value=
|
||||
VALUE_PARAMETER name:y index:1 type:kotlin.Int flags:
|
||||
EXPRESSION_BODY
|
||||
CONST Int type=kotlin.Int value=42
|
||||
PROPERTY name:x type:kotlin.String visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.String visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter x: String = ...' type=kotlin.String origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-x> visibility:public modality:FINAL <> ($this:A) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:A flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-x>(): String'
|
||||
GET_FIELD 'x: String' type=kotlin.String origin=null
|
||||
receiver: GET_VAR 'this@A: A' type=A origin=null
|
||||
PROPERTY name:y type:kotlin.Int visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:y type:kotlin.Int visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter y: Int = ...' type=kotlin.Int origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-y> visibility:public modality:FINAL <> ($this:A) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:A flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-y>(): Int'
|
||||
GET_FIELD 'y: Int' type=kotlin.Int origin=null
|
||||
receiver: GET_VAR 'this@A: A' type=A origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN name:test1 visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(String = ..., Int = ...)' type=A origin=null
|
||||
x: CONST String type=kotlin.String value=abc
|
||||
y: CONST Int type=kotlin.Int value=123
|
||||
BLOCK_BODY
|
||||
FUN name:test2 visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(String = ..., Int = ...)' type=A origin=null
|
||||
x: CONST String type=kotlin.String value=def
|
||||
BLOCK_BODY
|
||||
FUN name:test3 visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(String = ..., Int = ...)' type=A origin=null
|
||||
x: CONST String type=kotlin.String value=ghi
|
||||
BLOCK_BODY
|
||||
FUN name:test4 visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(String = ..., Int = ...)' type=A origin=null
|
||||
y: CONST Int type=kotlin.Int value=456
|
||||
BLOCK_BODY
|
||||
FUN name:test5 visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(String = ..., Int = ...)' type=A origin=null
|
||||
BLOCK_BODY
|
||||
+5
@@ -0,0 +1,5 @@
|
||||
annotation class A(vararg val xs: String)
|
||||
|
||||
@A("abc", "def") fun test1() {}
|
||||
@A("abc") fun test2() {}
|
||||
@A fun test3() {}
|
||||
+48
@@ -0,0 +1,48 @@
|
||||
FILE fqName:<root> fileName:/annotationsWithVarargParameters.kt
|
||||
CLASS ANNOTATION_CLASS name:A modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:A flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (xs:kotlin.Array<out kotlin.String>) returnType:A flags:
|
||||
VALUE_PARAMETER name:xs index:0 type:kotlin.Array<out kotlin.String> varargElementType:kotlin.String flags:vararg
|
||||
PROPERTY name:xs type:kotlin.Array<out kotlin.String> visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:xs type:kotlin.Array<out kotlin.String> visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter vararg xs: String' type=kotlin.Array<out kotlin.String> origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-xs> visibility:public modality:FINAL <> ($this:A) returnType:Array<out String> flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:A flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-xs>(): Array<out String>'
|
||||
GET_FIELD 'xs: Array<out String>' type=kotlin.Array<out kotlin.String> origin=null
|
||||
receiver: GET_VAR 'this@A: A' type=A origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN name:test1 visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(vararg String)' type=A origin=null
|
||||
xs: VARARG type=Array<out String> varargElementType=String
|
||||
CONST String type=kotlin.String value=abc
|
||||
CONST String type=kotlin.String value=def
|
||||
BLOCK_BODY
|
||||
FUN name:test2 visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(vararg String)' type=A origin=null
|
||||
xs: VARARG type=Array<out String> varargElementType=String
|
||||
CONST String type=kotlin.String value=abc
|
||||
BLOCK_BODY
|
||||
FUN name:test3 visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(vararg String)' type=A origin=null
|
||||
xs: VARARG type=Array<out String> varargElementType=String
|
||||
BLOCK_BODY
|
||||
Vendored
+6
@@ -0,0 +1,6 @@
|
||||
const val ONE = 1
|
||||
|
||||
annotation class A(val x: Int)
|
||||
|
||||
@A(ONE) fun test1() {}
|
||||
@A(1+1) fun test2() {}
|
||||
Vendored
+48
@@ -0,0 +1,48 @@
|
||||
FILE fqName:<root> fileName:/constExpressionsInAnnotationArguments.kt
|
||||
PROPERTY name:ONE type:kotlin.Int visibility:public modality:FINAL flags:constmval
|
||||
FIELD PROPERTY_BACKING_FIELD name:ONE type:kotlin.Int visibility:public
|
||||
EXPRESSION_BODY
|
||||
CONST Int type=kotlin.Int value=1
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-ONE> visibility:public modality:FINAL <> () returnType:Int flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-ONE>(): Int'
|
||||
GET_FIELD 'ONE: Int' type=kotlin.Int origin=null
|
||||
CLASS ANNOTATION_CLASS name:A modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:A flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (x:kotlin.Int) returnType:A flags:
|
||||
VALUE_PARAMETER name:x index:0 type:kotlin.Int flags:
|
||||
PROPERTY name:x type:kotlin.Int visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter x: Int' type=kotlin.Int origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-x> visibility:public modality:FINAL <> ($this:A) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:A flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-x>(): Int'
|
||||
GET_FIELD 'x: Int' type=kotlin.Int origin=null
|
||||
receiver: GET_VAR 'this@A: A' type=A origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN name:test1 visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(Int)' type=A origin=null
|
||||
x: CONST Int type=kotlin.Int value=1
|
||||
BLOCK_BODY
|
||||
FUN name:test2 visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(Int)' type=A origin=null
|
||||
x: CONST Int type=kotlin.Int value=2
|
||||
BLOCK_BODY
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
// WITH_RUNTIME
|
||||
|
||||
annotation class Ann
|
||||
|
||||
@delegate:Ann
|
||||
val test1 by lazy { 42 }
|
||||
+40
@@ -0,0 +1,40 @@
|
||||
FILE fqName:<root> fileName:/delegateFieldWithAnnotations.kt
|
||||
CLASS ANNOTATION_CLASS name:Ann modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:Ann flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> () returnType:Ann flags:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
PROPERTY name:test1 type:kotlin.Int visibility:public modality:FINAL flags:delegatedmval
|
||||
FIELD DELEGATE name:test1$delegate type:kotlin.Lazy<kotlin.Int> visibility:private
|
||||
annotations:
|
||||
CALL 'constructor Ann()' type=Ann origin=null
|
||||
EXPRESSION_BODY
|
||||
CALL 'lazy(() -> Int): Lazy<Int>' type=kotlin.Lazy<kotlin.Int> origin=null
|
||||
<T>: Int
|
||||
initializer: BLOCK type=() -> kotlin.Int origin=LAMBDA
|
||||
FUN LOCAL_FUNCTION_FOR_LAMBDA name:<anonymous> visibility:local modality:FINAL <> () returnType:Int flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<anonymous>(): Int'
|
||||
CONST Int type=kotlin.Int value=42
|
||||
FUNCTION_REFERENCE '<anonymous>(): Int' type=() -> kotlin.Int origin=LAMBDA
|
||||
FUN DELEGATED_PROPERTY_ACCESSOR name:<get-test1> visibility:public modality:FINAL <> () returnType:Int flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-test1>(): Int'
|
||||
CALL 'getValue(Any?, KProperty<*>) on Lazy<Int>: Int' type=kotlin.Int origin=null
|
||||
<T>: Int
|
||||
$receiver: GET_FIELD '`test1$delegate`: Lazy<Int>' type=kotlin.Lazy<kotlin.Int> origin=null
|
||||
thisRef: CONST Null type=kotlin.Nothing? value=null
|
||||
property: PROPERTY_REFERENCE 'test1: Int' field=null getter='<get-test1>(): Int' setter=null type=kotlin.reflect.KProperty0<kotlin.Int> origin=PROPERTY_REFERENCE_FOR_DELEGATE
|
||||
Vendored
+17
@@ -0,0 +1,17 @@
|
||||
annotation class A(val x: String)
|
||||
|
||||
class Cell(var value: Int) {
|
||||
operator fun getValue(thisRef: Any?, kProp: Any?) = value
|
||||
|
||||
operator fun setValue(thisRef: Any?, kProp: Any?, newValue: Int) {
|
||||
value = newValue
|
||||
}
|
||||
}
|
||||
|
||||
@get:A("test1.get")
|
||||
val test1 by Cell(1)
|
||||
|
||||
@get:A("test2.get")
|
||||
@set:A("test2.set")
|
||||
@setparam:A("test2.set.param")
|
||||
var test2 by Cell(2)
|
||||
Vendored
+131
@@ -0,0 +1,131 @@
|
||||
FILE fqName:<root> fileName:/delegatedPropertyAccessorsWithAnnotations.kt
|
||||
CLASS ANNOTATION_CLASS name:A modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:A flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (x:kotlin.String) returnType:A flags:
|
||||
VALUE_PARAMETER name:x index:0 type:kotlin.String flags:
|
||||
PROPERTY name:x type:kotlin.String visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.String visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter x: String' type=kotlin.String origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-x> visibility:public modality:FINAL <> ($this:A) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:A flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-x>(): String'
|
||||
GET_FIELD 'x: String' type=kotlin.String origin=null
|
||||
receiver: GET_VAR 'this@A: A' type=A origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
CLASS CLASS name:Cell modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:Cell flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB CLASS name:Any modality:OPEN visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (value:kotlin.Int) returnType:Cell flags:
|
||||
VALUE_PARAMETER name:value index:0 type:kotlin.Int flags:
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL 'constructor Any()'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor='Cell'
|
||||
PROPERTY name:value type:kotlin.Int visibility:public modality:FINAL flags:var
|
||||
FIELD PROPERTY_BACKING_FIELD name:value type:kotlin.Int visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter value: Int' type=kotlin.Int origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-value> visibility:public modality:FINAL <> ($this:Cell) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:Cell flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-value>(): Int'
|
||||
GET_FIELD 'value: Int' type=kotlin.Int origin=null
|
||||
receiver: GET_VAR 'this@Cell: Cell' type=Cell origin=null
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<set-value> visibility:public modality:FINAL <> ($this:Cell, <set-?>:kotlin.Int) returnType:Unit flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:Cell flags:
|
||||
VALUE_PARAMETER name:<set-?> index:0 type:kotlin.Int flags:
|
||||
BLOCK_BODY
|
||||
SET_FIELD 'value: Int' type=kotlin.Unit origin=null
|
||||
receiver: GET_VAR 'this@Cell: Cell' type=Cell origin=null
|
||||
value: GET_VAR 'value-parameter <set-?>: Int' type=kotlin.Int origin=null
|
||||
FUN name:getValue visibility:public modality:FINAL <> ($this:Cell, thisRef:kotlin.Any?, kProp:kotlin.Any?) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:Cell flags:
|
||||
VALUE_PARAMETER name:thisRef index:0 type:kotlin.Any? flags:
|
||||
VALUE_PARAMETER name:kProp index:1 type:kotlin.Any? flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='getValue(Any?, Any?): Int'
|
||||
CALL '<get-value>(): Int' type=kotlin.Int origin=GET_PROPERTY
|
||||
$this: GET_VAR 'this@Cell: Cell' type=Cell origin=null
|
||||
FUN name:setValue visibility:public modality:FINAL <> ($this:Cell, thisRef:kotlin.Any?, kProp:kotlin.Any?, newValue:kotlin.Int) returnType:Unit flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:Cell flags:
|
||||
VALUE_PARAMETER name:thisRef index:0 type:kotlin.Any? flags:
|
||||
VALUE_PARAMETER name:kProp index:1 type:kotlin.Any? flags:
|
||||
VALUE_PARAMETER name:newValue index:2 type:kotlin.Int flags:
|
||||
BLOCK_BODY
|
||||
CALL '<set-value>(Int): Unit' type=kotlin.Unit origin=EQ
|
||||
$this: GET_VAR 'this@Cell: Cell' type=Cell origin=null
|
||||
<set-?>: GET_VAR 'value-parameter newValue: Int' type=kotlin.Int origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
PROPERTY name:test1 type:kotlin.Int visibility:public modality:FINAL flags:delegatedmval
|
||||
FIELD DELEGATE name:test1$delegate type:Cell visibility:private
|
||||
EXPRESSION_BODY
|
||||
CALL 'constructor Cell(Int)' type=Cell origin=null
|
||||
value: CONST Int type=kotlin.Int value=1
|
||||
FUN DELEGATED_PROPERTY_ACCESSOR name:<get-test1> visibility:public modality:FINAL <> () returnType:Int flags:
|
||||
annotations:
|
||||
CALL 'constructor A(String)' type=A origin=null
|
||||
x: CONST String type=kotlin.String value=test1.get
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-test1>(): Int'
|
||||
CALL 'getValue(Any?, Any?): Int' type=kotlin.Int origin=null
|
||||
$this: GET_FIELD '`test1$delegate`: Cell' type=Cell origin=null
|
||||
thisRef: CONST Null type=kotlin.Nothing? value=null
|
||||
kProp: PROPERTY_REFERENCE 'test1: Int' field=null getter='<get-test1>(): Int' setter=null type=kotlin.reflect.KProperty0<kotlin.Int> origin=PROPERTY_REFERENCE_FOR_DELEGATE
|
||||
PROPERTY name:test2 type:kotlin.Int visibility:public modality:FINAL flags:delegatedmvar
|
||||
FIELD DELEGATE name:test2$delegate type:Cell visibility:private
|
||||
EXPRESSION_BODY
|
||||
CALL 'constructor Cell(Int)' type=Cell origin=null
|
||||
value: CONST Int type=kotlin.Int value=2
|
||||
FUN DELEGATED_PROPERTY_ACCESSOR name:<get-test2> visibility:public modality:FINAL <> () returnType:Int flags:
|
||||
annotations:
|
||||
CALL 'constructor A(String)' type=A origin=null
|
||||
x: CONST String type=kotlin.String value=test2.get
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-test2>(): Int'
|
||||
CALL 'getValue(Any?, Any?): Int' type=kotlin.Int origin=null
|
||||
$this: GET_FIELD '`test2$delegate`: Cell' type=Cell origin=null
|
||||
thisRef: CONST Null type=kotlin.Nothing? value=null
|
||||
kProp: PROPERTY_REFERENCE 'test2: Int' field=null getter='<get-test2>(): Int' setter='<set-test2>(Int): Unit' type=kotlin.reflect.KMutableProperty0<kotlin.Int> origin=PROPERTY_REFERENCE_FOR_DELEGATE
|
||||
FUN DELEGATED_PROPERTY_ACCESSOR name:<set-test2> visibility:public modality:FINAL <> (<set-?>:kotlin.Int) returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(String)' type=A origin=null
|
||||
x: CONST String type=kotlin.String value=test2.set
|
||||
VALUE_PARAMETER name:<set-?> index:0 type:kotlin.Int flags:
|
||||
annotations:
|
||||
CALL 'constructor A(String)' type=A origin=null
|
||||
x: CONST String type=kotlin.String value=test2.set.param
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<set-test2>(Int): Unit'
|
||||
CALL 'setValue(Any?, Any?, Int): Unit' type=kotlin.Unit origin=null
|
||||
$this: GET_FIELD '`test2$delegate`: Cell' type=Cell origin=null
|
||||
thisRef: CONST Null type=kotlin.Nothing? value=null
|
||||
kProp: PROPERTY_REFERENCE 'test2: Int' field=null getter='<get-test2>(): Int' setter='<set-test2>(Int): Unit' type=kotlin.reflect.KMutableProperty0<kotlin.Int> origin=PROPERTY_REFERENCE_FOR_DELEGATE
|
||||
newValue: GET_VAR 'value-parameter <set-?>: Int' type=kotlin.Int origin=null
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
annotation class TestAnn(val x: String)
|
||||
|
||||
enum class TestEnum {
|
||||
@TestAnn("ENTRY1") ENTRY1,
|
||||
@TestAnn("ENTRY2") ENTRY2 {
|
||||
val x = 42
|
||||
}
|
||||
}
|
||||
+155
@@ -0,0 +1,155 @@
|
||||
FILE fqName:<root> fileName:/enumEntriesWithAnnotations.kt
|
||||
CLASS ANNOTATION_CLASS name:TestAnn modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:TestAnn flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (x:kotlin.String) returnType:TestAnn flags:
|
||||
VALUE_PARAMETER name:x index:0 type:kotlin.String flags:
|
||||
PROPERTY name:x type:kotlin.String visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.String visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter x: String' type=kotlin.String origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-x> visibility:public modality:FINAL <> ($this:TestAnn) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:TestAnn flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-x>(): String'
|
||||
GET_FIELD 'x: String' type=kotlin.String origin=null
|
||||
receiver: GET_VAR 'this@TestAnn: TestAnn' type=TestAnn origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
CLASS ENUM_CLASS name:TestEnum modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:TestEnum flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB CLASS name:Enum modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:private <> () returnType:TestEnum flags:
|
||||
BLOCK_BODY
|
||||
ENUM_CONSTRUCTOR_CALL 'constructor Enum(String, Int)'
|
||||
<E : Enum<E>>: TestEnum
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor='TestEnum'
|
||||
ENUM_ENTRY name:ENTRY1
|
||||
annotations:
|
||||
CALL 'constructor TestAnn(String)' type=TestAnn origin=null
|
||||
x: CONST String type=kotlin.String value=ENTRY1
|
||||
init: ENUM_CONSTRUCTOR_CALL 'constructor TestEnum()'
|
||||
ENUM_ENTRY name:ENTRY2
|
||||
annotations:
|
||||
CALL 'constructor TestAnn(String)' type=TestAnn origin=null
|
||||
x: CONST String type=kotlin.String value=ENTRY2
|
||||
init: ENUM_CONSTRUCTOR_CALL 'constructor ENTRY2()'
|
||||
class: CLASS ENUM_ENTRY name:ENTRY2 modality:FINAL visibility:public flags:
|
||||
annotations:
|
||||
CALL 'constructor TestAnn(String)' type=TestAnn origin=null
|
||||
x: CONST String type=kotlin.String value=ENTRY2
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:TestEnum.ENTRY2 flags:
|
||||
superClasses:
|
||||
CLASS ENUM_CLASS name:TestEnum modality:FINAL visibility:public flags:
|
||||
CONSTRUCTOR visibility:private <> () returnType:TestEnum.ENTRY2 flags:
|
||||
BLOCK_BODY
|
||||
ENUM_CONSTRUCTOR_CALL 'constructor TestEnum()'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor='ENTRY2'
|
||||
PROPERTY name:x type:kotlin.Int visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:public
|
||||
EXPRESSION_BODY
|
||||
CONST Int type=kotlin.Int value=42
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-x> visibility:public modality:FINAL <> ($this:TestEnum.ENTRY2) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:TestEnum.ENTRY2 flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-x>(): Int'
|
||||
GET_FIELD 'x: Int' type=kotlin.Int origin=null
|
||||
receiver: GET_VAR 'this@ENTRY2: ENTRY2' type=TestEnum.ENTRY2 origin=null
|
||||
FUN FAKE_OVERRIDE name:clone visibility:protected modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:Any flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:clone visibility:protected modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:Any flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
FUN FAKE_OVERRIDE name:finalize visibility:protected/*protected and package*/ modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:Unit flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:finalize visibility:protected/*protected and package*/ modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:Unit flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
FUN FAKE_OVERRIDE name:getDeclaringClass visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:(java.lang.Class<(TestEnum..TestEnum?)>..java.lang.Class<(TestEnum..TestEnum?)>?) flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:getDeclaringClass visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:(java.lang.Class<(TestEnum..TestEnum?)>..java.lang.Class<(TestEnum..TestEnum?)>?) flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
FUN FAKE_OVERRIDE name:compareTo visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>, other:TestEnum) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:compareTo visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>, other:TestEnum) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
VALUE_PARAMETER name:other index:0 type:TestEnum flags:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
PROPERTY FAKE_OVERRIDE name:name type:kotlin.String visibility:public modality:FINAL flags:val
|
||||
FUN FAKE_OVERRIDE name:<get-name> visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:<get-name> visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
PROPERTY FAKE_OVERRIDE name:ordinal type:kotlin.Int visibility:public modality:FINAL flags:val
|
||||
FUN FAKE_OVERRIDE name:<get-ordinal> visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:<get-ordinal> visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Enum<TestEnum>) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Enum<TestEnum>) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
FUN FAKE_OVERRIDE name:clone visibility:protected modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:Any flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:clone visibility:protected modality:FINAL <> ($this:kotlin.Enum<E>) returnType:Any flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
FUN FAKE_OVERRIDE name:finalize visibility:protected/*protected and package*/ modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:Unit flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:finalize visibility:protected/*protected and package*/ modality:FINAL <> ($this:kotlin.Enum<E>) returnType:Unit flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
FUN FAKE_OVERRIDE name:getDeclaringClass visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:(java.lang.Class<(TestEnum..TestEnum?)>..java.lang.Class<(TestEnum..TestEnum?)>?) flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:getDeclaringClass visibility:public modality:FINAL <> ($this:kotlin.Enum<E>) returnType:(java.lang.Class<(E..E?)>..java.lang.Class<(E..E?)>?) flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
FUN FAKE_OVERRIDE name:compareTo visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>, other:TestEnum) returnType:Int flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:compareTo visibility:public modality:FINAL <> ($this:kotlin.Enum<E>, other:E) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
VALUE_PARAMETER name:other index:0 type:TestEnum flags:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:equals visibility:public modality:FINAL <> ($this:kotlin.Enum<E>, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:Int flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:hashCode visibility:public modality:FINAL <> ($this:kotlin.Enum<E>) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
PROPERTY FAKE_OVERRIDE name:name type:kotlin.String visibility:public modality:FINAL flags:val
|
||||
FUN FAKE_OVERRIDE name:<get-name> visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:String flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:<get-name> visibility:public modality:FINAL <> ($this:kotlin.Enum<E>) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
PROPERTY FAKE_OVERRIDE name:ordinal type:kotlin.Int visibility:public modality:FINAL flags:val
|
||||
FUN FAKE_OVERRIDE name:<get-ordinal> visibility:public modality:FINAL <> ($this:kotlin.Enum<TestEnum>) returnType:Int flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:<get-ordinal> visibility:public modality:FINAL <> ($this:kotlin.Enum<E>) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Enum<TestEnum>) returnType:String flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:toString visibility:public modality:OPEN <> ($this:kotlin.Enum<E>) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Enum<TestEnum> flags:
|
||||
FUN ENUM_CLASS_SPECIAL_MEMBER name:values visibility:public modality:FINAL <> () returnType:Array<TestEnum> flags:
|
||||
SYNTHETIC_BODY kind=ENUM_VALUES
|
||||
FUN ENUM_CLASS_SPECIAL_MEMBER name:valueOf visibility:public modality:FINAL <> (value:kotlin.String) returnType:TestEnum flags:
|
||||
VALUE_PARAMETER name:value index:0 type:kotlin.String flags:
|
||||
SYNTHETIC_BODY kind=ENUM_VALUEOF
|
||||
@@ -0,0 +1,5 @@
|
||||
@file:A("File annotation")
|
||||
package test
|
||||
|
||||
@Target(AnnotationTarget.FILE)
|
||||
annotation class A(val x: String)
|
||||
@@ -0,0 +1,39 @@
|
||||
FILE fqName:test fileName:/fileAnnotations.kt
|
||||
fileAnnotations:
|
||||
@test.A(x = "File annotation")
|
||||
annotations:
|
||||
CALL 'constructor A(String)' type=test.A origin=null
|
||||
x: CONST String type=kotlin.String value=File annotation
|
||||
CLASS ANNOTATION_CLASS name:A modality:FINAL visibility:public flags:
|
||||
annotations:
|
||||
CALL 'constructor Target(vararg AnnotationTarget)' type=kotlin.annotation.Target origin=null
|
||||
allowedTargets: VARARG type=Array<out AnnotationTarget> varargElementType=AnnotationTarget
|
||||
GET_ENUM 'FILE' type=kotlin.annotation.AnnotationTarget
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:test.A flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (x:kotlin.String) returnType:test.A flags:
|
||||
VALUE_PARAMETER name:x index:0 type:kotlin.String flags:
|
||||
PROPERTY name:x type:kotlin.String visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.String visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter x: String' type=kotlin.String origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-x> visibility:public modality:FINAL <> ($this:test.A) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:test.A flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-x>(): String'
|
||||
GET_FIELD 'x: String' type=kotlin.String origin=null
|
||||
receiver: GET_VAR 'this@A: A' type=test.A origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
// WITH_RUNTIME
|
||||
|
||||
annotation class A(val x: String)
|
||||
|
||||
fun foo(m: Map<String, Int>) {
|
||||
@A("foo/test")
|
||||
val test by lazy { 42 }
|
||||
}
|
||||
Vendored
+54
@@ -0,0 +1,54 @@
|
||||
FILE fqName:<root> fileName:/localDelegatedPropertiesWithAnnotations.kt
|
||||
CLASS ANNOTATION_CLASS name:A modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:A flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (x:kotlin.String) returnType:A flags:
|
||||
VALUE_PARAMETER name:x index:0 type:kotlin.String flags:
|
||||
PROPERTY name:x type:kotlin.String visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.String visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter x: String' type=kotlin.String origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-x> visibility:public modality:FINAL <> ($this:A) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:A flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-x>(): String'
|
||||
GET_FIELD 'x: String' type=kotlin.String origin=null
|
||||
receiver: GET_VAR 'this@A: A' type=A origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN name:foo visibility:public modality:FINAL <> (m:kotlin.collections.Map<kotlin.String, kotlin.Int>) returnType:Unit flags:
|
||||
VALUE_PARAMETER name:m index:0 type:kotlin.collections.Map<kotlin.String, kotlin.Int> flags:
|
||||
BLOCK_BODY
|
||||
LOCAL_DELEGATED_PROPERTY name:test type:kotlin.Int flags:val
|
||||
annotations:
|
||||
CALL 'constructor A(String)' type=A origin=null
|
||||
x: CONST String type=kotlin.String value=foo/test
|
||||
VAR DELEGATE name:test$delegate type:kotlin.Lazy<kotlin.Int> flags:val
|
||||
CALL 'lazy(() -> Int): Lazy<Int>' type=kotlin.Lazy<kotlin.Int> origin=null
|
||||
<T>: Int
|
||||
initializer: BLOCK type=() -> kotlin.Int origin=LAMBDA
|
||||
FUN LOCAL_FUNCTION_FOR_LAMBDA name:<anonymous> visibility:local modality:FINAL <> () returnType:Int flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<anonymous>(): Int'
|
||||
CONST Int type=kotlin.Int value=42
|
||||
FUNCTION_REFERENCE '<anonymous>(): Int' type=() -> kotlin.Int origin=LAMBDA
|
||||
FUN DELEGATED_PROPERTY_ACCESSOR name:<get-test> visibility:local modality:FINAL <> () returnType:Int flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-test>(): Int'
|
||||
CALL 'getValue(Any?, KProperty<*>) on Lazy<Int>: Int' type=kotlin.Int origin=null
|
||||
<T>: Int
|
||||
$receiver: GET_VAR '`test$delegate`: Lazy<Int>' type=kotlin.Lazy<kotlin.Int> origin=null
|
||||
thisRef: CONST Null type=kotlin.Nothing? value=null
|
||||
property: LOCAL_DELEGATED_PROPERTY_REFERENCE 'test: Int' delegate='`test$delegate`: Lazy<Int>' getter='<get-test>(): Int' setter=null type=kotlin.reflect.KProperty0<kotlin.Int> origin=PROPERTY_REFERENCE_FOR_DELEGATE
|
||||
Vendored
+5
@@ -0,0 +1,5 @@
|
||||
annotation class A1
|
||||
annotation class A2
|
||||
annotation class A3
|
||||
|
||||
@[A1, A2, A3] fun test() {}
|
||||
Vendored
+61
@@ -0,0 +1,61 @@
|
||||
FILE fqName:<root> fileName:/multipleAnnotationsInSquareBrackets.kt
|
||||
CLASS ANNOTATION_CLASS name:A1 modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:A1 flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> () returnType:A1 flags:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
CLASS ANNOTATION_CLASS name:A2 modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:A2 flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> () returnType:A2 flags:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
CLASS ANNOTATION_CLASS name:A3 modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:A3 flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> () returnType:A3 flags:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN name:test visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A1()' type=A1 origin=null
|
||||
CALL 'constructor A2()' type=A2 origin=null
|
||||
CALL 'constructor A3()' type=A3 origin=null
|
||||
BLOCK_BODY
|
||||
Vendored
+3
@@ -0,0 +1,3 @@
|
||||
annotation class Ann
|
||||
|
||||
class Test(@param:Ann val x: Int)
|
||||
Vendored
+53
@@ -0,0 +1,53 @@
|
||||
FILE fqName:<root> fileName:/primaryConstructorParameterWithAnnotations.kt
|
||||
CLASS ANNOTATION_CLASS name:Ann modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:Ann flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> () returnType:Ann flags:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
CLASS CLASS name:Test modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:Test flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB CLASS name:Any modality:OPEN visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (x:kotlin.Int) returnType:Test flags:
|
||||
VALUE_PARAMETER name:x index:0 type:kotlin.Int flags:
|
||||
annotations:
|
||||
CALL 'constructor Ann()' type=Ann origin=null
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL 'constructor Any()'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor='Test'
|
||||
PROPERTY name:x type:kotlin.Int visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter x: Int' type=kotlin.Int origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-x> visibility:public modality:FINAL <> ($this:Test) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:Test flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-x>(): Int'
|
||||
GET_FIELD 'x: Int' type=kotlin.Int origin=null
|
||||
receiver: GET_VAR 'this@Test: Test' type=Test origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
annotation class A(val x: String)
|
||||
|
||||
class C(
|
||||
@get:A("C.x.get") val x: Int,
|
||||
@get:A("C.y.get") @set:A("C.y.set") var y: Int
|
||||
)
|
||||
+89
@@ -0,0 +1,89 @@
|
||||
FILE fqName:<root> fileName:/propertyAccessorsFromClassHeaderWithAnnotations.kt
|
||||
CLASS ANNOTATION_CLASS name:A modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:A flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (x:kotlin.String) returnType:A flags:
|
||||
VALUE_PARAMETER name:x index:0 type:kotlin.String flags:
|
||||
PROPERTY name:x type:kotlin.String visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.String visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter x: String' type=kotlin.String origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-x> visibility:public modality:FINAL <> ($this:A) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:A flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-x>(): String'
|
||||
GET_FIELD 'x: String' type=kotlin.String origin=null
|
||||
receiver: GET_VAR 'this@A: A' type=A origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
CLASS CLASS name:C modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:C flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB CLASS name:Any modality:OPEN visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (x:kotlin.Int, y:kotlin.Int) returnType:C flags:
|
||||
VALUE_PARAMETER name:x index:0 type:kotlin.Int flags:
|
||||
VALUE_PARAMETER name:y index:1 type:kotlin.Int flags:
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL 'constructor Any()'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor='C'
|
||||
PROPERTY name:x type:kotlin.Int visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.Int visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter x: Int' type=kotlin.Int origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-x> visibility:public modality:FINAL <> ($this:C) returnType:Int flags:
|
||||
annotations:
|
||||
CALL 'constructor A(String)' type=A origin=null
|
||||
x: CONST String type=kotlin.String value=C.x.get
|
||||
$this: VALUE_PARAMETER name:<this> type:C flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-x>(): Int'
|
||||
GET_FIELD 'x: Int' type=kotlin.Int origin=null
|
||||
receiver: GET_VAR 'this@C: C' type=C origin=null
|
||||
PROPERTY name:y type:kotlin.Int visibility:public modality:FINAL flags:var
|
||||
FIELD PROPERTY_BACKING_FIELD name:y type:kotlin.Int visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter y: Int' type=kotlin.Int origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-y> visibility:public modality:FINAL <> ($this:C) returnType:Int flags:
|
||||
annotations:
|
||||
CALL 'constructor A(String)' type=A origin=null
|
||||
x: CONST String type=kotlin.String value=C.y.get
|
||||
$this: VALUE_PARAMETER name:<this> type:C flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-y>(): Int'
|
||||
GET_FIELD 'y: Int' type=kotlin.Int origin=null
|
||||
receiver: GET_VAR 'this@C: C' type=C origin=null
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<set-y> visibility:public modality:FINAL <> ($this:C, <set-?>:kotlin.Int) returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(String)' type=A origin=null
|
||||
x: CONST String type=kotlin.String value=C.y.set
|
||||
$this: VALUE_PARAMETER name:<this> type:C flags:
|
||||
VALUE_PARAMETER name:<set-?> index:0 type:kotlin.Int flags:
|
||||
BLOCK_BODY
|
||||
SET_FIELD 'y: Int' type=kotlin.Unit origin=null
|
||||
receiver: GET_VAR 'this@C: C' type=C origin=null
|
||||
value: GET_VAR 'value-parameter <set-?>: Int' type=kotlin.Int origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
Vendored
+6
@@ -0,0 +1,6 @@
|
||||
annotation class AnnParam
|
||||
|
||||
@setparam:AnnParam
|
||||
var p: Int = 0
|
||||
|
||||
class C(@setparam:AnnParam var p: Int)
|
||||
Vendored
+75
@@ -0,0 +1,75 @@
|
||||
FILE fqName:<root> fileName:/propertySetterParameterWithAnnotations.kt
|
||||
CLASS ANNOTATION_CLASS name:AnnParam modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:AnnParam flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> () returnType:AnnParam flags:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
PROPERTY name:p type:kotlin.Int visibility:public modality:FINAL flags:var
|
||||
FIELD PROPERTY_BACKING_FIELD name:p type:kotlin.Int visibility:public
|
||||
EXPRESSION_BODY
|
||||
CONST Int type=kotlin.Int value=0
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-p> visibility:public modality:FINAL <> () returnType:Int flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-p>(): Int'
|
||||
GET_FIELD 'p: Int' type=kotlin.Int origin=null
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<set-p> visibility:public modality:FINAL <> (<set-?>:kotlin.Int) returnType:Unit flags:
|
||||
VALUE_PARAMETER name:<set-?> index:0 type:kotlin.Int flags:
|
||||
annotations:
|
||||
CALL 'constructor AnnParam()' type=AnnParam origin=null
|
||||
BLOCK_BODY
|
||||
SET_FIELD 'p: Int' type=kotlin.Unit origin=null
|
||||
value: GET_VAR 'value-parameter <set-?>: Int' type=kotlin.Int origin=null
|
||||
CLASS CLASS name:C modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:C flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB CLASS name:Any modality:OPEN visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (p:kotlin.Int) returnType:C flags:
|
||||
VALUE_PARAMETER name:p index:0 type:kotlin.Int flags:
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL 'constructor Any()'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor='C'
|
||||
PROPERTY name:p type:kotlin.Int visibility:public modality:FINAL flags:var
|
||||
FIELD PROPERTY_BACKING_FIELD name:p type:kotlin.Int visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter p: Int' type=kotlin.Int origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-p> visibility:public modality:FINAL <> ($this:C) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:C flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-p>(): Int'
|
||||
GET_FIELD 'p: Int' type=kotlin.Int origin=null
|
||||
receiver: GET_VAR 'this@C: C' type=C origin=null
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<set-p> visibility:public modality:FINAL <> ($this:C, <set-?>:kotlin.Int) returnType:Unit flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:C flags:
|
||||
VALUE_PARAMETER name:<set-?> index:0 type:kotlin.Int flags:
|
||||
annotations:
|
||||
CALL 'constructor AnnParam()' type=AnnParam origin=null
|
||||
BLOCK_BODY
|
||||
SET_FIELD 'p: Int' type=kotlin.Unit origin=null
|
||||
receiver: GET_VAR 'this@C: C' type=C origin=null
|
||||
value: GET_VAR 'value-parameter <set-?>: Int' type=kotlin.Int origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
annotation class Ann
|
||||
|
||||
class A {
|
||||
fun @receiver:Ann String.f(): String = ""
|
||||
|
||||
val @receiver:Ann String?.p: String
|
||||
get() = ""
|
||||
|
||||
}
|
||||
|
||||
fun @receiver:Ann String?.topLevelF(): String = ""
|
||||
|
||||
val @receiver:Ann String.topLevelP: String
|
||||
get() = ""
|
||||
+72
@@ -0,0 +1,72 @@
|
||||
FILE fqName:<root> fileName:/receiverParameterWithAnnotations.kt
|
||||
CLASS ANNOTATION_CLASS name:Ann modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:Ann flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> () returnType:Ann flags:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
CLASS CLASS name:A modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:A flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB CLASS name:Any modality:OPEN visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> () returnType:A flags:
|
||||
BLOCK_BODY
|
||||
DELEGATING_CONSTRUCTOR_CALL 'constructor Any()'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor='A'
|
||||
FUN name:f visibility:public modality:FINAL <> ($this:A, $receiver:@receiver:Ann kotlin.String) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:A flags:
|
||||
$receiver: VALUE_PARAMETER name:<this> type:@receiver:Ann kotlin.String flags:
|
||||
annotations:
|
||||
CALL 'constructor Ann()' type=Ann origin=null
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='f() on String: String'
|
||||
CONST String type=kotlin.String value=
|
||||
PROPERTY name:p type:kotlin.String visibility:public modality:FINAL flags:val
|
||||
FUN name:<get-p> visibility:public modality:FINAL <> ($this:A, $receiver:@receiver:Ann kotlin.String?) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:A flags:
|
||||
$receiver: VALUE_PARAMETER name:<this> type:@receiver:Ann kotlin.String? flags:
|
||||
annotations:
|
||||
CALL 'constructor Ann()' type=Ann origin=null
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-p>() on String?: String'
|
||||
CONST String type=kotlin.String value=
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN name:topLevelF visibility:public modality:FINAL <> ($receiver:@receiver:Ann kotlin.String?) returnType:String flags:
|
||||
$receiver: VALUE_PARAMETER name:<this> type:@receiver:Ann kotlin.String? flags:
|
||||
annotations:
|
||||
CALL 'constructor Ann()' type=Ann origin=null
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='topLevelF() on String?: String'
|
||||
CONST String type=kotlin.String value=
|
||||
PROPERTY name:topLevelP type:kotlin.String visibility:public modality:FINAL flags:val
|
||||
FUN name:<get-topLevelP> visibility:public modality:FINAL <> ($receiver:@receiver:Ann kotlin.String) returnType:String flags:
|
||||
$receiver: VALUE_PARAMETER name:<this> type:@receiver:Ann kotlin.String flags:
|
||||
annotations:
|
||||
CALL 'constructor Ann()' type=Ann origin=null
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-topLevelP>() on String: String'
|
||||
CONST String type=kotlin.String value=
|
||||
Vendored
+5
@@ -0,0 +1,5 @@
|
||||
annotation class A(vararg val xs: String)
|
||||
|
||||
|
||||
@A(*arrayOf("a"), *arrayOf("b"))
|
||||
fun test() {}
|
||||
Vendored
+39
@@ -0,0 +1,39 @@
|
||||
FILE fqName:<root> fileName:/spreadOperatorInAnnotationArguments.kt
|
||||
CLASS ANNOTATION_CLASS name:A modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:A flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> (xs:kotlin.Array<out kotlin.String>) returnType:A flags:
|
||||
VALUE_PARAMETER name:xs index:0 type:kotlin.Array<out kotlin.String> varargElementType:kotlin.String flags:vararg
|
||||
PROPERTY name:xs type:kotlin.Array<out kotlin.String> visibility:public modality:FINAL flags:val
|
||||
FIELD PROPERTY_BACKING_FIELD name:xs type:kotlin.Array<out kotlin.String> visibility:public
|
||||
EXPRESSION_BODY
|
||||
GET_VAR 'value-parameter vararg xs: String' type=kotlin.Array<out kotlin.String> origin=INITIALIZE_PROPERTY_FROM_PARAMETER
|
||||
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-xs> visibility:public modality:FINAL <> ($this:A) returnType:Array<out String> flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:A flags:
|
||||
BLOCK_BODY
|
||||
RETURN type=kotlin.Nothing from='<get-xs>(): Array<out String>'
|
||||
GET_FIELD 'xs: Array<out String>' type=kotlin.Array<out kotlin.String> origin=null
|
||||
receiver: GET_VAR 'this@A: A' type=A origin=null
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN name:test visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
annotations:
|
||||
CALL 'constructor A(vararg String)' type=A origin=null
|
||||
xs: VARARG type=Array<out String> varargElementType=String
|
||||
VARARG type=Array<String> varargElementType=String
|
||||
CONST String type=kotlin.String value=a
|
||||
VARARG type=Array<String> varargElementType=String
|
||||
CONST String type=kotlin.String value=b
|
||||
BLOCK_BODY
|
||||
+4
@@ -0,0 +1,4 @@
|
||||
@Target(AnnotationTarget.TYPE_PARAMETER)
|
||||
annotation class Anno
|
||||
|
||||
fun <@Anno T> foo() {}
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
FILE fqName:<root> fileName:/typeParametersWithAnnotations.kt
|
||||
CLASS ANNOTATION_CLASS name:Anno modality:FINAL visibility:public flags:
|
||||
annotations:
|
||||
CALL 'constructor Target(vararg AnnotationTarget)' type=kotlin.annotation.Target origin=null
|
||||
allowedTargets: VARARG type=Array<out AnnotationTarget> varargElementType=AnnotationTarget
|
||||
GET_ENUM 'TYPE_PARAMETER' type=kotlin.annotation.AnnotationTarget
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:Anno flags:
|
||||
superClasses:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB INTERFACE name:Annotation modality:ABSTRACT visibility:public flags:
|
||||
CONSTRUCTOR visibility:public <> () returnType:Anno flags:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
VALUE_PARAMETER name:other index:0 type:kotlin.Any? flags:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:Int flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
overridden:
|
||||
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:String flags:
|
||||
$this: VALUE_PARAMETER name:<this> type:kotlin.Any flags:
|
||||
FUN name:foo visibility:public modality:FINAL <T> () returnType:Unit flags:
|
||||
TYPE_PARAMETER name:T index:0 variance: upperBounds:[kotlin.Any?]
|
||||
annotations:
|
||||
CALL 'constructor Anno()' type=Anno origin=null
|
||||
superClassifiers:
|
||||
CLASS IR_EXTERNAL_DECLARATION_STUB CLASS name:Any modality:OPEN visibility:public flags:
|
||||
BLOCK_BODY
|
||||
@@ -1,6 +1,9 @@
|
||||
FILE fqName:<root> fileName:/fileWithAnnotations.kt
|
||||
fileAnnotations:
|
||||
@kotlin.jvm.JvmName(name = "FileWithAnnotations")
|
||||
annotations:
|
||||
CALL 'constructor JvmName(String)' type=kotlin.jvm.JvmName origin=null
|
||||
name: CONST String type=kotlin.String value=FileWithAnnotations
|
||||
FUN name:foo visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
BLOCK_BODY
|
||||
PROPERTY name:bar type:kotlin.Int visibility:public modality:FINAL flags:val
|
||||
|
||||
@@ -3,6 +3,10 @@ FILE fqName:<root> fileName:/typeAlias.kt
|
||||
FUN name:foo visibility:public modality:FINAL <> () returnType:Unit flags:
|
||||
BLOCK_BODY
|
||||
TYPEALIAS typealias TestLocal = String type=kotlin.String
|
||||
annotations:
|
||||
CALL 'constructor Suppress(vararg String)' type=kotlin.Suppress origin=null
|
||||
names: VARARG type=Array<out String> varargElementType=String
|
||||
CONST String type=kotlin.String value=TOPLEVEL_TYPEALIASES_ONLY
|
||||
CLASS CLASS name:C modality:FINAL visibility:public flags:
|
||||
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:C flags:
|
||||
superClasses:
|
||||
@@ -12,6 +16,10 @@ FILE fqName:<root> fileName:/typeAlias.kt
|
||||
DELEGATING_CONSTRUCTOR_CALL 'constructor Any()'
|
||||
INSTANCE_INITIALIZER_CALL classDescriptor='C'
|
||||
TYPEALIAS typealias TestNested = String type=kotlin.String
|
||||
annotations:
|
||||
CALL 'constructor Suppress(vararg String)' type=kotlin.Suppress origin=null
|
||||
names: VARARG type=Array<out String> varargElementType=String
|
||||
CONST String type=kotlin.String value=TOPLEVEL_TYPEALIASES_ONLY
|
||||
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
overridden:
|
||||
FUN IR_EXTERNAL_DECLARATION_STUB name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:Boolean flags:
|
||||
|
||||
@@ -344,6 +344,18 @@ public class IrTextTestCaseGenerated extends AbstractIrTextTestCase {
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("annotationsWithDefaultParameterValues.kt")
|
||||
public void testAnnotationsWithDefaultParameterValues() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/annotationsWithDefaultParameterValues.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("annotationsWithVarargParameters.kt")
|
||||
public void testAnnotationsWithVarargParameters() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/annotationsWithVarargParameters.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("arrayInAnnotationArguments.kt")
|
||||
public void testArrayInAnnotationArguments() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/arrayInAnnotationArguments.kt");
|
||||
@@ -356,12 +368,36 @@ public class IrTextTestCaseGenerated extends AbstractIrTextTestCase {
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("constExpressionsInAnnotationArguments.kt")
|
||||
public void testConstExpressionsInAnnotationArguments() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/constExpressionsInAnnotationArguments.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("constructorsWithAnnotations.kt")
|
||||
public void testConstructorsWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/constructorsWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("delegateFieldWithAnnotations.kt")
|
||||
public void testDelegateFieldWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/delegateFieldWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("delegatedPropertyAccessorsWithAnnotations.kt")
|
||||
public void testDelegatedPropertyAccessorsWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/delegatedPropertyAccessorsWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("enumEntriesWithAnnotations.kt")
|
||||
public void testEnumEntriesWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/enumEntriesWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("enumsInAnnotationArguments.kt")
|
||||
public void testEnumsInAnnotationArguments() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/enumsInAnnotationArguments.kt");
|
||||
@@ -374,30 +410,84 @@ public class IrTextTestCaseGenerated extends AbstractIrTextTestCase {
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("fileAnnotations.kt")
|
||||
public void testFileAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/fileAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("functionsWithAnnotations.kt")
|
||||
public void testFunctionsWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/functionsWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("localDelegatedPropertiesWithAnnotations.kt")
|
||||
public void testLocalDelegatedPropertiesWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/localDelegatedPropertiesWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("multipleAnnotationsInSquareBrackets.kt")
|
||||
public void testMultipleAnnotationsInSquareBrackets() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/multipleAnnotationsInSquareBrackets.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("primaryConstructorParameterWithAnnotations.kt")
|
||||
public void testPrimaryConstructorParameterWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/primaryConstructorParameterWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("propertiesWithAnnotations.kt")
|
||||
public void testPropertiesWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/propertiesWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("propertyAccessorsFromClassHeaderWithAnnotations.kt")
|
||||
public void testPropertyAccessorsFromClassHeaderWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/propertyAccessorsFromClassHeaderWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("propertyAccessorsWithAnnotations.kt")
|
||||
public void testPropertyAccessorsWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/propertyAccessorsWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("propertySetterParameterWithAnnotations.kt")
|
||||
public void testPropertySetterParameterWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/propertySetterParameterWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("receiverParameterWithAnnotations.kt")
|
||||
public void testReceiverParameterWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/receiverParameterWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("spreadOperatorInAnnotationArguments.kt")
|
||||
public void testSpreadOperatorInAnnotationArguments() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/spreadOperatorInAnnotationArguments.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("typeAliasesWithAnnotations.kt")
|
||||
public void testTypeAliasesWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/typeAliasesWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("typeParametersWithAnnotations.kt")
|
||||
public void testTypeParametersWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/typeParametersWithAnnotations.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("valueParametersWithAnnotations.kt")
|
||||
public void testValueParametersWithAnnotations() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/ir/irText/declarations/annotations/valueParametersWithAnnotations.kt");
|
||||
|
||||
Reference in New Issue
Block a user