Migrate testdata to new lambda syntax
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
// IS_APPLICABLE: false
|
||||
|
||||
val foo = {(<caret>s: String, n: Int) -> s.length() - n/2 > 1 }
|
||||
val foo = { <caret>s: String, n: Int -> s.length() - n/2 > 1 }
|
||||
|
||||
fun test() {
|
||||
foo("1", 2)
|
||||
|
||||
+1
-1
@@ -4,5 +4,5 @@ class Mocha() {
|
||||
}
|
||||
fun main() {
|
||||
val mocha = Mocha()
|
||||
val testing = mocha<caret>(1, "fire"){ (x: Int) -> "hello world" }
|
||||
val testing = mocha<caret>(1, "fire"){ x: Int -> "hello world" }
|
||||
}
|
||||
+1
-1
@@ -4,5 +4,5 @@ class Mocha() {
|
||||
}
|
||||
fun main() {
|
||||
val mocha = Mocha()
|
||||
val testing = mocha.invoke(1, "fire"){ (x: Int) -> "hello world" }
|
||||
val testing = mocha.invoke(1, "fire"){ x: Int -> "hello world" }
|
||||
}
|
||||
@@ -3,5 +3,5 @@ class Mocha() {
|
||||
}
|
||||
fun main() {
|
||||
val mocha = Mocha()
|
||||
val testing = mocha<caret>{ (x: Int) -> "hello world" }
|
||||
val testing = mocha<caret>{ x: Int -> "hello world" }
|
||||
}
|
||||
@@ -3,5 +3,5 @@ class Mocha() {
|
||||
}
|
||||
fun main() {
|
||||
val mocha = Mocha()
|
||||
val testing = mocha.invoke{ (x: Int) -> "hello world" }
|
||||
val testing = mocha.invoke{ x: Int -> "hello world" }
|
||||
}
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
// WITH_RUNTIME
|
||||
// IS_APPLICABLE: false
|
||||
fun foo() {
|
||||
val bar = { (x: Int) -> x + 1 }
|
||||
val bar = { x: Int -> x + 1 }
|
||||
val incremented = listOf(1, 2, 3).<caret>map(bar)
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
// IS_APPLICABLE: true
|
||||
fun foo() {
|
||||
bar<caret><(Int) -> Int> { (it: Int) -> it }
|
||||
bar<caret><(Int) -> Int> { it: Int -> it }
|
||||
}
|
||||
|
||||
fun bar<T>(t: T): Int = 1
|
||||
@@ -1,6 +1,6 @@
|
||||
// IS_APPLICABLE: true
|
||||
fun foo() {
|
||||
bar { (it: Int) -> it }
|
||||
bar { it: Int -> it }
|
||||
}
|
||||
|
||||
fun bar<T>(t: T): Int = 1
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
// IS_APPLICABLE: false
|
||||
|
||||
val foo = { (x: Int) ->
|
||||
val foo = { x: Int ->
|
||||
class Inner() {
|
||||
fun temp(<caret>y: Int) : Int { return x + y }
|
||||
}
|
||||
|
||||
+1
-1
@@ -1,2 +1,2 @@
|
||||
// IS_APPLICABLE: false
|
||||
val incr = { (<caret>x: Int) -> x + 1}
|
||||
val incr = { <caret>x: Int -> x + 1}
|
||||
|
||||
@@ -1 +1 @@
|
||||
val x<caret> = { (a: Int) -> ""}
|
||||
val x<caret> = { a: Int -> ""}
|
||||
@@ -1 +1 @@
|
||||
val x: (Int) -> String = { (a: Int) -> ""}
|
||||
val x: (Int) -> String = { a: Int -> ""}
|
||||
Reference in New Issue
Block a user