Implement "Surround with try/catch(/finally)" and "Surround with if/else" for expressions
Fixes #KT-14175 Fixes #KT-19782
This commit is contained in:
committed by
Nikolay Krasko
parent
e16d16fdb7
commit
08103d1cb4
@@ -0,0 +1,7 @@
|
||||
// IS_APPLICABLE: false
|
||||
|
||||
fun foo() {
|
||||
fun call() {}
|
||||
|
||||
<selection>call()</selection>
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
fun foo() {
|
||||
<selection>"aaa"</selection> + 1
|
||||
}
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
fun foo() {
|
||||
(if (<selection></selection>) "aaa" else) + 1
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
fun foo() {
|
||||
val a = <selection>"aaa"</selection>
|
||||
}
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
fun foo() {
|
||||
val a = if (<selection></selection>) "aaa" else
|
||||
}
|
||||
Reference in New Issue
Block a user