Add tests for obsolete issues

#KT-38804 Obsolete
 #KT-38801 Obsolete
 #KT-38835 Obsolete
 #KT-38737 Obsolete
 #KT-38664 Obsolete
 #KT-38549 Obsolete
 #KT-38766 Obsolete
 #KT-38714 Obsolete
This commit is contained in:
Mikhail Zarechenskiy
2020-08-11 10:11:47 +03:00
parent 7f4df19dd1
commit 2e131b870a
30 changed files with 503 additions and 0 deletions
@@ -0,0 +1,22 @@
// FIR_IDENTICAL
// !USE_EXPERIMENTAL: kotlin.RequiresOptIn
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.experimental.ExperimentalTypeInference
inline fun <reified T, R> emptyFlow(crossinline transform: suspend (Array<T>) -> R): Flow1<R> =
flow1 { emit(transform(emptyArray())) }
inline fun <reified T, R> emptyFlow(crossinline transform: (Array<T>) -> R): Flow1<R> =
flowOf1(transform(emptyArray()))
fun <T> flowOf1(value: T): Flow1<T> = TODO()
@OptIn(ExperimentalTypeInference::class)
fun <T> flow1(@BuilderInference block: suspend FlowCollector1<T>.() -> Unit): Flow1<T> = TODO()
interface FlowCollector1<in T> {
suspend fun emit(value: T)
}
interface Flow1<out T>
@@ -0,0 +1,19 @@
package
public inline fun </*0*/ reified T, /*1*/ R> emptyFlow(/*0*/ crossinline transform: (kotlin.Array<T>) -> R): Flow1<R>
public inline fun </*0*/ reified T, /*1*/ R> emptyFlow(/*0*/ crossinline transform: suspend (kotlin.Array<T>) -> R): Flow1<R>
@kotlin.OptIn(markerClass = {kotlin.experimental.ExperimentalTypeInference::class}) public fun </*0*/ T> flow1(/*0*/ @kotlin.BuilderInference block: suspend FlowCollector1<T>.() -> kotlin.Unit): Flow1<T>
public fun </*0*/ T> flowOf1(/*0*/ value: T): Flow1<T>
public interface Flow1</*0*/ out T> {
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
public interface FlowCollector1</*0*/ in T> {
public abstract suspend fun emit(/*0*/ value: T): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}