mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-10 00:21:35 +00:00
13 lines
341 B
Kotlin
Vendored
13 lines
341 B
Kotlin
Vendored
// !DIAGNOSTICS: -UNUSED_PARAMETER
|
|
|
|
fun testArgumentInCall() {
|
|
fun bar(i: Int, s: String, x: Any) {}
|
|
|
|
<!UNREACHABLE_CODE!>bar(<!>1, todo(), <!UNREACHABLE_CODE!>"")<!>
|
|
}
|
|
|
|
fun testArgumentInVariableAsFunctionCall(f: (Any) -> Unit) {
|
|
f<!UNREACHABLE_CODE!>(<!>todo()<!UNREACHABLE_CODE!>)<!>
|
|
}
|
|
|
|
fun todo(): Nothing = throw Exception() |