mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-09 08:31:29 +00:00
16 lines
243 B
Kotlin
Vendored
16 lines
243 B
Kotlin
Vendored
// FILE: Test.java
|
|
|
|
public abstract class Test<F> {
|
|
protected final F value = null;
|
|
}
|
|
|
|
// FILE: test.kt
|
|
|
|
class A : Test<String>() {
|
|
fun foo(): String? = value
|
|
}
|
|
|
|
fun box(): String {
|
|
return if (A().foo() == null) "OK" else "Fail"
|
|
}
|