[TEST] Add test checking cast to DNN type
muted temporary due to required support in backends
This commit is contained in:
committed by
TeamCityServer
parent
5b19c41373
commit
23ad0e7c63
@@ -0,0 +1,17 @@
|
||||
// !LANGUAGE: +DefinitelyNonNullableTypes
|
||||
// IGNORE_BACKEND: JVM
|
||||
// IGNORE_BACKEND: JVM_IR
|
||||
// IGNORE_BACKEND: JS
|
||||
// IGNORE_BACKEND: JS_IR
|
||||
// IGNORE_BACKEND_FIR: JVM_IR
|
||||
|
||||
fun <T> test(t: T) = t as (T & Any)
|
||||
|
||||
fun box(): String {
|
||||
try {
|
||||
test<Any?>(null)
|
||||
} catch (ex: NullPointerException) {
|
||||
return "FAIL: expected NPE"
|
||||
}
|
||||
return test("OK")
|
||||
}
|
||||
Reference in New Issue
Block a user