Mark expressions for correct recognition by "unreachable code"
This commit is contained in:
@@ -7,5 +7,4 @@ fun main(args: Array<String>) {
|
||||
}
|
||||
}
|
||||
|
||||
// callback is unused due to KT-4233
|
||||
fun test<R>(<!UNUSED_PARAMETER!>callback<!>: (R) -> Unit):Unit = <!UNREACHABLE_CODE!>callback(null!!)<!>
|
||||
fun test<R>(callback: (R) -> Unit):Unit = <!UNREACHABLE_CODE!>callback<!>(null!!)
|
||||
@@ -9,9 +9,9 @@ fun test(a: Int) {
|
||||
bar(a, <!NULL_FOR_NONNULL_TYPE!>null<!>)
|
||||
}
|
||||
fun test1(a: Int) {
|
||||
<!UNREACHABLE_CODE!>foo(a, throw Exception())<!>
|
||||
<!UNREACHABLE_CODE!>foo<!>(a, throw Exception())
|
||||
}
|
||||
|
||||
fun test2(a: Int) {
|
||||
<!UNREACHABLE_CODE!>bar(a, throw Exception())<!>
|
||||
<!UNREACHABLE_CODE!>bar<!>(a, throw Exception())
|
||||
}
|
||||
Reference in New Issue
Block a user