Move statement out of top-level lambda in scripts (KT-19322)

#KT-19322 Fixed
This commit is contained in:
Nikolay Krasko
2017-08-03 14:51:46 +03:00
parent 656f8bb5cf
commit 6194bc10f8
9 changed files with 68 additions and 8 deletions
@@ -0,0 +1,7 @@
// MOVE: down
fun takeLamb(f: () -> Unit) {}
fun foo() {}
takeLamb {
<caret>foo()
}
@@ -0,0 +1,7 @@
// MOVE: down
fun takeLamb(f: () -> Unit) {}
fun foo() {}
takeLamb {
}
<caret>foo()
@@ -0,0 +1,7 @@
// MOVE: up
fun takeLamb(f: () -> Unit) {}
takeLamb {
<caret>foo()
}
fun foo() {}
@@ -0,0 +1,7 @@
// MOVE: up
fun takeLamb(f: () -> Unit) {}
<caret>foo()
takeLamb {
}
fun foo() {}