Files
kotlin/compiler/testData/codegen/bytecodeListing/annotations/kt27895.kt
Alexander Udalov 17d740a373 Do not try computing return type in OverloadChecker
Return type is not needed for checking overloads, but querying it may
involve resolving function bodies, which usually happens after overload
checking (see LazyTopDownAnalyzer.analyzeDeclarations) and at this point
can lead to incorrect BACKING_FIELD_REQUIRED value being computed for
some properties (see KT-27895)

 #KT-27895 Fixed
2018-11-07 11:00:15 +01:00

11 lines
179 B
Kotlin
Vendored

@Target(AnnotationTarget.FIELD)
annotation class Anno
data class C(val x: Int) {
@Anno
val json: String = ""
get() = field
fun copy() = this.also { json }
}