Support non-reified type parameters in typeOf in JVM and JVM_IR
#KT-30279 Fixed
This commit is contained in:
committed by
Alexander Udalov
parent
6fb40878c4
commit
0ce16b9d8c
@@ -14,15 +14,17 @@ inline fun <reified T> T.causeBug() {
|
||||
x is T
|
||||
x as T
|
||||
T::class
|
||||
typeOf<T>()
|
||||
Array<T>(1) { x }
|
||||
|
||||
// Non-reified type parameters with recursive bounds are not yet supported
|
||||
// typeOf<T>()
|
||||
}
|
||||
|
||||
interface SomeToImplement<SELF_TVAR>
|
||||
|
||||
class Y : SomeToImplement<Y>
|
||||
|
||||
class Something<T> where T: SomeToImplement<T> {
|
||||
class Something<Z> where Z : SomeToImplement<Z> {
|
||||
fun op() = causeBug()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user