Current behavior:
fun main() {
{
println("-----------------------------------")
println("-----------------------------------")
}
.invoke()
[
println("-----------------------------------"),
println("-----------------------------------"),
]
.map { it }
val a =
[
println("-----------------------------------"),
println("-----------------------------------"),
]
.map { it }
}
They just feel weird, and this problem would get worse and worse with the stabilization of collection literals because the pattern of constructing a list and do operations on it is so common. The current formatting is too weird to be acceptable.
Why don't we put ] ) } at the same indentation of the line containing [ ( {, and move the dot to align with ] ) } as well, so that everything would look nice?
fun main() {
{
println("-----------------------------------")
println("-----------------------------------")
}
.invoke()
[
println("-----------------------------------"),
println("-----------------------------------"),
]
[
println("-----------------------------------"),
println("-----------------------------------"),
]
.map { it }
val a =
[
println("-----------------------------------"),
println("-----------------------------------"),
]
.map { it }
run(
block = {
println("-----------------------------------")
println("-----------------------------------")
}
)
}
Current behavior:
They just feel weird, and this problem would get worse and worse with the stabilization of collection literals because the pattern of constructing a list and do operations on it is so common. The current formatting is too weird to be acceptable.
Why don't we put ] ) } at the same indentation of the line containing [ ( {, and move the dot to align with ] ) } as well, so that everything would look nice?