Files
kotlin-fork/compiler/testData/diagnostics/tests/resolve/priority/syntheticPropertiesVsExtensions.kt
T
Stanislav Erokhin 298a075381 Minor. removed functions which declared in Standard.kt from diagnostic testdata.
Removed declaration for functions: TODO, run, with, apply, let.
2016-01-25 19:13:31 +03:00

30 lines
492 B
Kotlin
Vendored

// !CHECK_TYPE
// !DIAGNOSTICS: -UNUSED_EXPRESSION -UNUSED_PARAMETER -UNUSED_VARIABLE
// FILE: A.java
public class A {
public A getFoo() { return 3; }
}
// FILE: 1.kt
private val A.foo: Int get() = 4
fun test(a: A) {
a.foo checkType { _<A>() }
with(a) {
foo checkType { _<A>() }
}
}
class B {
private val A.foo: B get() = this@B
fun test(a: A) {
a.foo checkType { _<A>() }
with(a) {
foo checkType { _<A>() }
}
}
}