Files
kotlin-fork/compiler/testData/codegen/boxError/syntax/arrowReference.kt
T
Ivan Kylchik 982d10d127 [TESTS] Add IGNORE_ERROR directive to boxError tests
This is needed because now these tests use new test infrastructure
and here, after frontend facade, there is error check. We need to
disable such check in these tests.
2021-11-08 23:50:34 +03:00

19 lines
265 B
Kotlin
Vendored

// IGNORE_ERRORS
// ERROR_POLICY: SYNTAX
// MODULE: lib
// FILE: t.kt
fun foo() { this->bar() }
// MODULE: main(lib)
// FILE: b.kt
fun box(): String {
try {
foo()
} catch (e: IllegalStateException) {
return "OK"
}
return "FAIL"
}