Files
kotlin-fork/js/js.translator/testData/callableReference/property/cases/simpleMember.kt
T
2014-07-30 17:50:16 +04:00

13 lines
315 B
Kotlin

// This test was adapted from compiler/testData/codegen/boxWithStdlib/callableReference/property/.
package foo
class A(val x: Int)
fun box(): String {
val p = A::x
if (p.get(A(42)) != 42) return "Fail 1"
if (p.get(A(-1)) != -1) return "Fail 2"
if (p.name != "x") return "Fail 3"
return "OK"
}