NI: approximate not top-level captured types during code generation

^KT-40693 Fixed
This commit is contained in:
Victor Petukhov
2020-08-04 16:03:59 +03:00
parent f6d7e7c52a
commit f45de9d8fb
9 changed files with 64 additions and 1 deletions
@@ -0,0 +1,13 @@
interface BasePublisher<U>
interface Flow<out P>
fun <R> asFlow(x: BasePublisher<R>): Flow<R> = null as Flow<R>
class Document<S>
interface DerivedPublisher<K>: BasePublisher<Document<K>> {}
class Foo<T>(val x: DerivedPublisher<out T>) : Flow<Document<out T>> by asFlow(x)
fun box() = "OK"