[FE1.0, FIR] Support secondary constructors for Value Classes

Signed-off-by: Evgeniy.Zhelenskiy <Evgeniy.Zhelenskiy@jetbrains.com>

#KT-1179
This commit is contained in:
Evgeniy.Zhelenskiy
2022-10-13 19:18:08 +02:00
committed by Space Team
parent 8c3fa6f09f
commit 6107caa8e2
18 changed files with 296 additions and 93 deletions
@@ -1,10 +1,9 @@
// WITH_STDLIB
// WORKS_WHEN_VALUE_CLASS
// LANGUAGE: +ValueClasses
// LANGUAGE: +ValueClasses, +ValueClassesSecondaryConstructorWithBody
OPTIONAL_JVM_INLINE_ANNOTATION
value class IC private constructor(val i: Int) {
@Suppress("SECONDARY_CONSTRUCTOR_WITH_BODY_INSIDE_VALUE_CLASS")
constructor() : this(0) {
counter += 1
}