[IR] MFVC lateinit variables and properties test
Signed-off-by: Evgeniy.Zhelenskiy <Evgeniy.Zhelenskiy@jetbrains.com> #KT-1179
This commit is contained in:
committed by
Space Team
parent
b7f249cdb6
commit
50310d42e3
@@ -133,6 +133,7 @@ public final class C {
|
||||
@kotlin.Metadata
|
||||
public final class ComplexKt {
|
||||
// source: 'complex.kt'
|
||||
public static field late1: E
|
||||
private final static @org.jetbrains.annotations.NotNull field lines: java.util.List
|
||||
static method <clinit>(): void
|
||||
public final static @org.jetbrains.annotations.NotNull method box(): java.lang.String
|
||||
@@ -140,12 +141,14 @@ public final class ComplexKt {
|
||||
public final static method equalsChecks1-iUtXLc0(@org.jetbrains.annotations.NotNull p0: java.util.List): void
|
||||
public final static method f-sUp7gFk(p0: int, p1: int, p2: int, p3: int, @org.jetbrains.annotations.NotNull p4: java.lang.String, @org.jetbrains.annotations.NotNull p5: java.util.List): void
|
||||
public final static method g-sUp7gFk(p0: int, p1: int, @org.jetbrains.annotations.NotNull p2: java.lang.String): void
|
||||
public final static @org.jetbrains.annotations.NotNull method getLate1(): E
|
||||
public final static @org.jetbrains.annotations.NotNull method getLines(): java.util.List
|
||||
public final static method h-sUp7gFk(p0: int, p1: int, p2: int, p3: int, @org.jetbrains.annotations.NotNull p4: java.lang.String, @org.jetbrains.annotations.NotNull p5: java.util.List): void
|
||||
public final static method h1(): void
|
||||
public final static @org.jetbrains.annotations.NotNull method inlined-OsBMiQA(p0: int, p1: int, p2: int): D
|
||||
public final static @org.jetbrains.annotations.NotNull method notInlined-OsBMiQA(p0: int, p1: int, p2: int): D
|
||||
public final static method reuseBoxed(@org.jetbrains.annotations.NotNull p0: java.util.List): void
|
||||
public final static method setLate1-sUp7gFk(p0: int, p1: int, @org.jetbrains.annotations.NotNull p2: java.lang.String): void
|
||||
public final static method supply(@org.jetbrains.annotations.NotNull p0: java.lang.Object): void
|
||||
public final static method testVars(@org.jetbrains.annotations.NotNull p0: NotInlined): void
|
||||
}
|
||||
|
||||
+12
-1
@@ -183,7 +183,7 @@ fun equalsChecks(left: R<List<Int>>, right: R<List<Int>>) {
|
||||
supply(left == right as R<List<Int>>?)
|
||||
}
|
||||
|
||||
// todo add default parameters
|
||||
lateinit var late1: E
|
||||
|
||||
fun box(): String {
|
||||
supply("#1")
|
||||
@@ -219,6 +219,13 @@ fun box(): String {
|
||||
supply("#16")
|
||||
equalsChecks1(A(listOf(listOf())))
|
||||
supply("#17")
|
||||
late1 = e
|
||||
lateinit var late2: E
|
||||
late2 = e
|
||||
supply(e)
|
||||
supply(late1)
|
||||
supply(late2)
|
||||
supply("#18")
|
||||
|
||||
val log = lines.joinToString("\n")
|
||||
val expectedLog =
|
||||
@@ -305,6 +312,10 @@ fun box(): String {
|
||||
true
|
||||
#16
|
||||
#17
|
||||
E(x=D(x=C(x=3, y=B(x=4), z=5)))
|
||||
E(x=D(x=C(x=3, y=B(x=4), z=5)))
|
||||
E(x=D(x=C(x=3, y=B(x=4), z=5)))
|
||||
#18
|
||||
""".trimIndent()
|
||||
require(log == expectedLog) { log }
|
||||
|
||||
|
||||
@@ -133,6 +133,7 @@ public final class C {
|
||||
@kotlin.Metadata
|
||||
public final class ComplexKt {
|
||||
// source: 'complex.kt'
|
||||
public static field late1: E
|
||||
private final static @org.jetbrains.annotations.NotNull field lines: java.util.List
|
||||
static method <clinit>(): void
|
||||
public final static @org.jetbrains.annotations.NotNull method box(): java.lang.String
|
||||
@@ -140,12 +141,14 @@ public final class ComplexKt {
|
||||
public final static method equalsChecks1-iUtXLc0(@org.jetbrains.annotations.NotNull p0: java.util.List): void
|
||||
public final static method f-sUp7gFk(p0: int, p1: int, p2: int, p3: int, @org.jetbrains.annotations.NotNull p4: java.lang.String, @org.jetbrains.annotations.NotNull p5: java.util.List): void
|
||||
public final static method g-sUp7gFk(p0: int, p1: int, @org.jetbrains.annotations.NotNull p2: java.lang.String): void
|
||||
public final static @org.jetbrains.annotations.NotNull method getLate1(): E
|
||||
public final static @org.jetbrains.annotations.NotNull method getLines(): java.util.List
|
||||
public final static method h-sUp7gFk(p0: int, p1: int, p2: int, p3: int, @org.jetbrains.annotations.NotNull p4: java.lang.String, @org.jetbrains.annotations.NotNull p5: java.util.List): void
|
||||
public final static method h1(): void
|
||||
public final static @org.jetbrains.annotations.NotNull method inlined-OsBMiQA(p0: int, p1: int, p2: int): D
|
||||
public final static @org.jetbrains.annotations.NotNull method notInlined-OsBMiQA(p0: int, p1: int, p2: int): D
|
||||
public final static method reuseBoxed(@org.jetbrains.annotations.NotNull p0: java.util.List): void
|
||||
public final static method setLate1-sUp7gFk(p0: int, p1: int, @org.jetbrains.annotations.NotNull p2: java.lang.String): void
|
||||
public final static method supply(@org.jetbrains.annotations.NotNull p0: java.lang.Object): void
|
||||
public final static method testVars(@org.jetbrains.annotations.NotNull p0: NotInlined): void
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@
|
||||
// TARGET_BACKEND: JVM_IR
|
||||
// WORKS_WHEN_VALUE_CLASS
|
||||
// LANGUAGE: +ValueClasses
|
||||
// LAMBDAS: INDY
|
||||
// ^ to ensure that LAMBDAS are actually CLASSes
|
||||
|
||||
// FILE: caller.kt
|
||||
import kotlin.coroutines.*
|
||||
|
||||
Reference in New Issue
Block a user