[FIR] Approximate exotic return types for public declarations

This commit is contained in:
Mikhail Glukhikh
2020-09-02 10:48:07 +03:00
parent bf918e6184
commit a7da0d5080
11 changed files with 54 additions and 22 deletions
@@ -16,12 +16,12 @@ FILE: intersectionTypes.kt
}
public final fun <K> select(x: R|K|, y: R|K|): R|K|
public final fun test(): R|it(A & B)| {
public final fun test(): R|kotlin/Any| {
^test R|/select|<R|it(A & B)|>(R|/Clazz1.Clazz1|(), R|/Clazz2.Clazz2|())
}
public final fun <T> makeNull(x: R|T|): R|T?| {
^makeNull Null(null)
}
public final fun testNull(): R|it(A? & B?)| {
public final fun testNull(): R|kotlin/Any?| {
^testNull R|/makeNull|<R|it(A & B)|>(R|/select|<R|it(A & B)|>(R|/Clazz1.Clazz1|(), R|/Clazz2.Clazz2|()))
}
+1 -1
View File
@@ -28,7 +28,7 @@ FILE: whenElse.kt
public get(): R|B|
}
public final fun get(f: R|kotlin/Boolean|): R|it(kotlin/Comparable<it(A & kotlin/String)> & java/io/Serializable)| {
public final fun get(f: R|kotlin/Boolean|): R|kotlin/Any| {
^get when () {
R|<local>/f| -> {
Q|A|.R|/A.A1|