Improve API of annotation arguments in kotlinx-metadata
See changes in ChangeLog.md for more information
This commit is contained in:
+2
-2
@@ -118,7 +118,7 @@ internal class KlibPropertyExtension : KlibPropertyExtensionVisitor(), KmPropert
|
||||
val setterAnnotations: MutableList<KmAnnotation> = mutableListOf()
|
||||
var uniqId: UniqId? = null
|
||||
var file: Int? = null
|
||||
var compileTimeValue: KmAnnotationArgument<*>? = null
|
||||
var compileTimeValue: KmAnnotationArgument? = null
|
||||
|
||||
override fun visitAnnotation(annotation: KmAnnotation) {
|
||||
annotations += annotation
|
||||
@@ -140,7 +140,7 @@ internal class KlibPropertyExtension : KlibPropertyExtensionVisitor(), KmPropert
|
||||
this.uniqId = uniqId
|
||||
}
|
||||
|
||||
override fun visitCompileTimeValue(value: KmAnnotationArgument<*>) {
|
||||
override fun visitCompileTimeValue(value: KmAnnotationArgument) {
|
||||
this.compileTimeValue = value
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -299,7 +299,7 @@ internal class KlibMetadataExtensions : MetadataExtensions {
|
||||
)
|
||||
}
|
||||
|
||||
override fun visitCompileTimeValue(value: KmAnnotationArgument<*>) {
|
||||
override fun visitCompileTimeValue(value: KmAnnotationArgument) {
|
||||
proto.setExtension(
|
||||
KlibMetadataProtoBuf.compileTimeValue,
|
||||
value.writeAnnotationArgument(c.strings).build()
|
||||
|
||||
@@ -62,7 +62,7 @@ var KmProperty.file: Int?
|
||||
klibExtensions.file = value
|
||||
}
|
||||
|
||||
var KmProperty.compileTimeValue: KmAnnotationArgument<*>?
|
||||
var KmProperty.compileTimeValue: KmAnnotationArgument?
|
||||
get() = klibExtensions.compileTimeValue
|
||||
set(value) {
|
||||
klibExtensions.compileTimeValue = value
|
||||
|
||||
+1
-1
@@ -65,7 +65,7 @@ abstract class KlibPropertyExtensionVisitor : KmPropertyExtensionVisitor {
|
||||
|
||||
abstract fun visitUniqId(uniqId: UniqId)
|
||||
|
||||
abstract fun visitCompileTimeValue(value: KmAnnotationArgument<*>)
|
||||
abstract fun visitCompileTimeValue(value: KmAnnotationArgument)
|
||||
|
||||
override val type: KmExtensionType
|
||||
get() = TYPE
|
||||
|
||||
Reference in New Issue
Block a user