Look into proper context when generating backing field access
Problem manifests when a class property name matches a companion object property name, and class property is referenced in closure context. #KT-19367 Fixed Target versions 1.1.5
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
// WITH_RUNTIME
|
||||
|
||||
class Host {
|
||||
val ok = "OK"
|
||||
|
||||
fun foo() = run { bar(ok) }
|
||||
|
||||
companion object {
|
||||
val ok = 0
|
||||
|
||||
fun bar(s: String) = s.substring(ok)
|
||||
}
|
||||
}
|
||||
|
||||
fun box() = Host().foo()
|
||||
Reference in New Issue
Block a user