mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-08 15:53:19 +00:00
A lot of problem arise with current solution (loading them with lowpriority annotation + additional call checkers): - We errorneously treated ArrayList.stream as an existing method, while it's just a fake override from List - The same problem arises when creating a class delegating to List. Also the latter case is failing with codegen internal error (see issue KT-16171) The negative side of this solution is that instead of reporting meaningful diagnostic, there will be UNRESOLVED_REFERENCE. But it seems to be better than having strange problems like ones described above. #KT-16073 Fixed #KT-16171 Fixed
9 lines
155 B
Kotlin
Vendored
9 lines
155 B
Kotlin
Vendored
// LANGUAGE_VERSION: 1.0
|
|
// WITH_RUNTIME
|
|
// FULL_JDK
|
|
class A(val x: List<String>) : List<String> by x
|
|
|
|
fun box(): String {
|
|
return A(listOf("OK"))[0]
|
|
}
|