Files
kotlin-fork/compiler/testData/codegen/notNullAssertions/doNotGenerateAssertions.kt
T
Alexander Udalov 95ec2448eb Generate not-null assertions after method calls
If a method comes from Java and is annotated as returning NotNull, after
calling it we should check if it actually returned something other than null.
Introduce checkReturnedValueIsNotNull() in jet/runtime/Intrinsics which does
exactly that.

CallableMethod's invoke() and invokeDefault() are now private, use asserted
versions instead
2012-10-08 14:11:56 +04:00

5 lines
65 B
Kotlin

fun box(): String {
checkAssertions(false)
return "OK"
}