Files
kotlin-fork/compiler/testData/diagnostics/tests/classLiteral/nonClassesOnLHS.fir.kt
T
Mikhail Glukhikh 684bdc44bb FIR: add implementation of reified type parameter references
This adds support of T::class.java for reified type parameters
2019-12-17 17:28:01 +03:00

21 lines
333 B
Kotlin
Vendored

// !DIAGNOSTICS: -UNUSED_VARIABLE
class A
val a1 = A?::class
val a2 = A??::class
val l1 = List<String>?::class
val l2 = List?::class
fun <T : Any> foo() {
val t1 = <!OTHER_ERROR!>T<!>::class
val t2 = <!OTHER_ERROR!>T<!>?::class
}
inline fun <reified T : Any> bar() {
val t3 = T?::class
}
val m = Map<String>::class