Files
kotlin-fork/compiler/testData/codegen/box/nullabilityAssertions/nullabilityAssertionOnExtensionReceiver_lv11.kt
T
2017-10-24 11:44:02 +03:00

17 lines
347 B
Kotlin
Vendored

// !LANGUAGE: -NullabilityAssertionOnExtensionReceiver
// TARGET_BACKEND: JVM
// WITH_RUNTIME
// FILE: test.kt
import kotlin.test.*
fun String.extension() {}
fun box(): String {
assertFailsWith<IllegalArgumentException> { J.s().extension() }
return "OK"
}
// FILE: J.java
public class J {
public static String s() { return null; }
}