diff --git a/compiler/ir/backend.jvm/src/org/jetbrains/kotlin/backend/jvm/lower/JvmInlineClassLowering.kt b/compiler/ir/backend.jvm/src/org/jetbrains/kotlin/backend/jvm/lower/JvmInlineClassLowering.kt index 115f5ebb65b..5b1c4b88c35 100644 --- a/compiler/ir/backend.jvm/src/org/jetbrains/kotlin/backend/jvm/lower/JvmInlineClassLowering.kt +++ b/compiler/ir/backend.jvm/src/org/jetbrains/kotlin/backend/jvm/lower/JvmInlineClassLowering.kt @@ -474,6 +474,7 @@ private class JvmInlineClassLowering(private val context: JvmBackendContext) : F // Don't create a default argument stub for the primary constructor irConstructor.valueParameters.forEach { it.defaultValue = null } copyParameterDeclarationsFrom(irConstructor) + annotations += irConstructor.annotations body = context.createIrBuilder(this.symbol).irBlockBody(this) { +irDelegatingConstructorCall(context.irBuiltIns.anyClass.owner.constructors.single()) +irSetField( diff --git a/compiler/testData/codegen/bytecodeListing/inlineClasses/publishedApiAnnotationOnInlineClassConstructor.kt b/compiler/testData/codegen/bytecodeListing/inlineClasses/publishedApiAnnotationOnInlineClassConstructor.kt index c4b954eb558..0f122f258d6 100644 --- a/compiler/testData/codegen/bytecodeListing/inlineClasses/publishedApiAnnotationOnInlineClassConstructor.kt +++ b/compiler/testData/codegen/bytecodeListing/inlineClasses/publishedApiAnnotationOnInlineClassConstructor.kt @@ -1,5 +1,4 @@ // !LANGUAGE: +InlineClasses -// IGNORE_BACKEND: JVM_IR @Suppress("NON_PUBLIC_PRIMARY_CONSTRUCTOR_OF_INLINE_CLASS") inline class Z @PublishedApi internal constructor(val value: Int) \ No newline at end of file