mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-12 00:21:32 +00:00
15 lines
251 B
Plaintext
Vendored
15 lines
251 B
Plaintext
Vendored
// "Lift assignment out of 'try' expression" "true"
|
|
// WITH_RUNTIME
|
|
|
|
fun foo() {
|
|
val x: Int
|
|
x = try {
|
|
1
|
|
} catch (e: RuntimeException) {
|
|
2
|
|
} catch (e: Exception) {
|
|
3
|
|
} catch (e: Throwable) {
|
|
4
|
|
}
|
|
} |