kotlinx.serialization: Support InheritableSerialInfo

This commit is contained in:
Leonid Startsev
2021-07-21 10:06:12 +00:00
committed by Space
parent 8eea749231
commit 4bc521249b
12 changed files with 131 additions and 11 deletions
@@ -12,9 +12,11 @@ import org.jetbrains.kotlin.name.FqName
internal fun IrClass.isNonGeneratedAnnotation(): Boolean =
this.kind == ClassKind.ANNOTATION_CLASS &&
!this.annotations.hasAnnotation(serialInfoAnnotationFqName)
!this.annotations.hasAnnotation(serialInfoAnnotationFqName) &&
!this.annotations.hasAnnotation(inheritableSerialInfoFqName)
private val serialInfoAnnotationFqName = FqName("kotlinx.serialization.SerialInfo")
private val inheritableSerialInfoFqName = FqName("kotlinx.serialization.InheritableSerialInfo")
/**
* We don't need to generate RTTI in some cases, e.g. Objective-C external classes.