Files
kotlin-fork/idea/testData/quickfix/renameToUnderscore/lambdaParameterNoRemoveParameter.kt
T
Dmitry Gridin 6c439ae85a Create TrailingCommaIntention
#KT-34744
2020-02-04 21:34:53 +07:00

18 lines
458 B
Kotlin
Vendored

// "Remove parameter 'x'" "false"
// ACTION: Enable a trailing comma by default in the formatter
// ACTION: Move lambda argument into parentheses
// ACTION: Remove explicit lambda parameter types (may break code)
// ACTION: Rename to _
// ACTION: Convert to anonymous function
// ACTION: Convert to single-line lambda
fun foo(block: (String, Int) -> Unit) {
block("", 1)
}
fun bar() {
foo { x<caret>: String, y: Int ->
y.hashCode()
}
}