4266e50be8
There are cases when members deserialized from JVM classes have no JVM signature in the proto. For example, if a member is inherited from a built-in class (such as Map.getOrDefault in some Map implementations), or if a member is synthesized in the compiler front-end and back-end separately (such as enum values/valueOf). In these cases, we'll use the naive type mapping to try to recover the signature. #KT-16616 Fixed #KT-17542 Fixed
29 lines
603 B
Kotlin
Vendored
29 lines
603 B
Kotlin
Vendored
// IGNORE_BACKEND: JVM_IR, JS_IR, JS, NATIVE
|
|
// WITH_REFLECT
|
|
// FULL_JDK
|
|
|
|
// See KT-11258, KT-16616
|
|
|
|
import java.util.*
|
|
import kotlin.test.assertEquals
|
|
|
|
fun box(): String {
|
|
listOf(
|
|
ArrayList::class,
|
|
LinkedList::class,
|
|
AbstractList::class,
|
|
HashSet::class,
|
|
TreeSet::class,
|
|
HashMap::class,
|
|
TreeMap::class,
|
|
AbstractMap::class,
|
|
AbstractMap.SimpleEntry::class
|
|
).map {
|
|
it.members.map(Any::toString)
|
|
}
|
|
|
|
assertEquals(1, Collection<Any>::size.getter(listOf(1)))
|
|
|
|
return "OK"
|
|
}
|