Do not force new line in body for empty functions and function expressions (KT-10828)
#KT-10828 Fixed
This commit is contained in:
committed by
Nikolay Krasko
parent
268d55104c
commit
2841931ffa
+13
-1
@@ -27,4 +27,16 @@ fun test() {
|
||||
(fun(){})
|
||||
|
||||
test( fun test ( ) = 4 )
|
||||
}
|
||||
}
|
||||
|
||||
fun d = fun(a: Int,
|
||||
b: String) {}
|
||||
|
||||
fun e = fun() {
|
||||
val a = 1}
|
||||
|
||||
fun f = fun() {foo()}
|
||||
|
||||
val g: (String) -> Int = fun(p: String): Unit { /* comment */ /* other comment */ }
|
||||
|
||||
fun foo() {}
|
||||
Reference in New Issue
Block a user