Add inspection to move the variable declaration into when
#KT-29001 Fixed
This commit is contained in:
+8
@@ -0,0 +1,8 @@
|
||||
fun test() = 42
|
||||
|
||||
fun foo() {
|
||||
when (val a = test()) {
|
||||
1 -> a
|
||||
else -> 24
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user