mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-10 08:31:29 +00:00
Migrate boxWithJava tests to multi-file framework
This commit is contained in:
15
compiler/testData/codegen/boxWithJava/properties/substituteJavaSuperField.kt
vendored
Normal file
15
compiler/testData/codegen/boxWithJava/properties/substituteJavaSuperField.kt
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
// 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"
|
||||
}
|
||||
Reference in New Issue
Block a user