Fix tests after disabling trailing comma
#KT-34744
This commit is contained in:
+2
-4
@@ -115,10 +115,8 @@ class SmartEnterCompletionTest : KotlinLightCodeInsightFixtureTestCase() {
|
|||||||
fun foo(p:Int) {}
|
fun foo(p:Int) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(1 +
|
||||||
1 +
|
2)<caret>
|
||||||
2
|
|
||||||
)<caret>
|
|
||||||
}
|
}
|
||||||
"""
|
"""
|
||||||
)
|
)
|
||||||
|
|||||||
+5
-7
@@ -1,11 +1,9 @@
|
|||||||
import javax.swing.SwingUtilities
|
import javax.swing.SwingUtilities
|
||||||
|
|
||||||
fun main(args : Array<String>) {
|
fun main(args : Array<String>) {
|
||||||
SwingUtilities.invokeLater(
|
SwingUtilities.invokeLater(object : Runnable {
|
||||||
object : Runnable {
|
override fun run() {
|
||||||
override fun run() {
|
TODO("Not yet implemented")
|
||||||
TODO("Not yet implemented")
|
}
|
||||||
}
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-4
@@ -1,9 +1,7 @@
|
|||||||
import javax.swing.SwingUtilities
|
import javax.swing.SwingUtilities
|
||||||
|
|
||||||
fun main(args : Array<String>) {
|
fun main(args : Array<String>) {
|
||||||
SwingUtilities.invokeLater(
|
SwingUtilities.invokeLater(object : Thread(<caret>) {
|
||||||
object : Thread(<caret>) {
|
|
||||||
|
|
||||||
}
|
})
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
+3
-3
@@ -5,19 +5,19 @@ fun test() {
|
|||||||
a[1, 2]
|
a[1, 2]
|
||||||
|
|
||||||
a[
|
a[
|
||||||
1, 2,
|
1, 2
|
||||||
]
|
]
|
||||||
|
|
||||||
a[
|
a[
|
||||||
|
|
||||||
1, 2,
|
1, 2
|
||||||
|
|
||||||
]
|
]
|
||||||
|
|
||||||
a[
|
a[
|
||||||
|
|
||||||
|
|
||||||
1, 2,
|
1, 2
|
||||||
|
|
||||||
|
|
||||||
]
|
]
|
||||||
|
|||||||
+2
-2
@@ -2,6 +2,6 @@
|
|||||||
modules = [
|
modules = [
|
||||||
AppModule::class,
|
AppModule::class,
|
||||||
DataModule::class,
|
DataModule::class,
|
||||||
DomainModule::class,
|
DomainModule::class
|
||||||
],
|
]
|
||||||
)
|
)
|
||||||
@@ -19,7 +19,7 @@ class FooM
|
|||||||
}
|
}
|
||||||
|
|
||||||
class FooC(
|
class FooC(
|
||||||
val x: String,
|
val x: String
|
||||||
) {
|
) {
|
||||||
|
|
||||||
fun bar()
|
fun bar()
|
||||||
|
|||||||
+14
-22
@@ -37,17 +37,13 @@ val s2 = Shadow { // wdwd
|
|||||||
val a = 42
|
val a = 42
|
||||||
}
|
}
|
||||||
|
|
||||||
val s3 = Shadow(
|
val s3 = Shadow(fun() { // wdwd
|
||||||
fun() { // wdwd
|
val a = 42
|
||||||
val a = 42
|
})
|
||||||
},
|
|
||||||
)
|
|
||||||
|
|
||||||
val s4 = Shadow(
|
val s4 = Shadow(fun() { /* s */
|
||||||
fun() { /* s */
|
val a = 42
|
||||||
val a = 42
|
})
|
||||||
},
|
|
||||||
)
|
|
||||||
|
|
||||||
val s5 = Shadow { ->
|
val s5 = Shadow { ->
|
||||||
// wdwd
|
// wdwd
|
||||||
@@ -59,19 +55,15 @@ val s6 = Shadow {
|
|||||||
val a = 42
|
val a = 42
|
||||||
}
|
}
|
||||||
|
|
||||||
val s7 = Shadow(
|
val s7 = Shadow(fun() {
|
||||||
fun() {
|
// wdwd
|
||||||
// wdwd
|
val a = 42
|
||||||
val a = 42
|
})
|
||||||
},
|
|
||||||
)
|
|
||||||
|
|
||||||
val s8 = Shadow(
|
val s8 = Shadow(fun() {
|
||||||
fun() {
|
// wdwd
|
||||||
// wdwd
|
val a = 42
|
||||||
val a = 42
|
})
|
||||||
},
|
|
||||||
)
|
|
||||||
|
|
||||||
val s9 = Shadow { -> /* s */
|
val s9 = Shadow { -> /* s */
|
||||||
val a = 42
|
val a = 42
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
fun foo(
|
fun foo(
|
||||||
x: Int,
|
x: Int
|
||||||
) {
|
) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -4,7 +4,7 @@ fun foo() {
|
|||||||
?: DescriptorUtils.getParentOfType(
|
?: DescriptorUtils.getParentOfType(
|
||||||
referencedDescriptor,
|
referencedDescriptor,
|
||||||
TypeAliasConstructorDescriptor::class.java,
|
TypeAliasConstructorDescriptor::class.java,
|
||||||
false,
|
false
|
||||||
)?.typeAliasDescriptor
|
)?.typeAliasDescriptor
|
||||||
?: DescriptorUtils.getParentOfType(referencedDescriptor, FunctionDescriptor::class.java, false)
|
?: DescriptorUtils.getParentOfType(referencedDescriptor, FunctionDescriptor::class.java, false)
|
||||||
?: return emptyList()
|
?: return emptyList()
|
||||||
|
|||||||
+1
-1
@@ -4,7 +4,7 @@ fun foo() {
|
|||||||
?: DescriptorUtils.getParentOfType(
|
?: DescriptorUtils.getParentOfType(
|
||||||
referencedDescriptor,
|
referencedDescriptor,
|
||||||
TypeAliasConstructorDescriptor::class.java,
|
TypeAliasConstructorDescriptor::class.java,
|
||||||
false,
|
false
|
||||||
)?.typeAliasDescriptor
|
)?.typeAliasDescriptor
|
||||||
?: DescriptorUtils.getParentOfType(referencedDescriptor, FunctionDescriptor::class.java, false)
|
?: DescriptorUtils.getParentOfType(referencedDescriptor, FunctionDescriptor::class.java, false)
|
||||||
?: return emptyList()
|
?: return emptyList()
|
||||||
|
|||||||
+1
-1
@@ -3,6 +3,6 @@ package test
|
|||||||
enum class EnumTest(val value: Int) {
|
enum class EnumTest(val value: Int) {
|
||||||
VALUE_1
|
VALUE_1
|
||||||
(
|
(
|
||||||
value = 0,
|
value = 0
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
enum class EnumTest(val value: Int) {
|
enum class EnumTest(val value: Int) {
|
||||||
VALUE_1(
|
VALUE_1(
|
||||||
value = 0,
|
value = 0
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
enum class EnumTest(val value: Int) {
|
enum class EnumTest(val value: Int) {
|
||||||
VALUE_1(
|
VALUE_1(
|
||||||
value = 0,
|
value = 0
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,6 @@
|
|||||||
fun test() {
|
fun test() {
|
||||||
someTestLong(
|
someTestLong(12,
|
||||||
12,
|
13)
|
||||||
13,
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// SET_TRUE: ALIGN_MULTILINE_PARAMETERS_IN_CALLS
|
// SET_TRUE: ALIGN_MULTILINE_PARAMETERS_IN_CALLS
|
||||||
+4
-8
@@ -13,10 +13,8 @@ val c = fun() = 4
|
|||||||
fun test() = fun test() = 4
|
fun test() = fun test() = 4
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
test(
|
test(fun() {
|
||||||
fun() {
|
})
|
||||||
},
|
|
||||||
)
|
|
||||||
test(fun test() {})
|
test(fun test() {})
|
||||||
test(fun test() = 5)
|
test(fun test() = 5)
|
||||||
|
|
||||||
@@ -30,10 +28,8 @@ fun test() {
|
|||||||
test(fun test() = 4)
|
test(fun test() = 4)
|
||||||
}
|
}
|
||||||
|
|
||||||
fun d = fun(
|
fun d = fun(a: Int,
|
||||||
a: Int,
|
b: String) {
|
||||||
b: String,
|
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun e = fun() {
|
fun e = fun() {
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
open class GFMOutputBuilder(
|
open class GFMOutputBuilder(
|
||||||
to: StringBuilder,
|
to: StringBuilder
|
||||||
) : MarkdownOutputBuilder(to) {
|
) : MarkdownOutputBuilder(to) {
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
open class GFMOutputBuilder(
|
open class GFMOutputBuilder(
|
||||||
to: StringBuilder,
|
to: StringBuilder
|
||||||
) : MarkdownOutputBuilder(to) {
|
) : MarkdownOutputBuilder(to) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -10,6 +10,6 @@ fun test() {
|
|||||||
items,
|
items,
|
||||||
shippingMethods,
|
shippingMethods,
|
||||||
addresses,
|
addresses,
|
||||||
preferredAddressId,
|
preferredAddressId
|
||||||
) = argument
|
) = argument
|
||||||
}
|
}
|
||||||
@@ -1,9 +1,7 @@
|
|||||||
fun foo(
|
fun foo(@Deprecated("x")
|
||||||
@Deprecated("x")
|
|
||||||
x: Int,
|
x: Int,
|
||||||
@Deprecated("y")
|
@Deprecated("y")
|
||||||
@Deprecated("z")
|
@Deprecated("z")
|
||||||
y: Int,
|
y: Int)
|
||||||
)
|
|
||||||
|
|
||||||
// SET_INT: PARAMETER_ANNOTATION_WRAP = 2
|
// SET_INT: PARAMETER_ANNOTATION_WRAP = 2
|
||||||
|
|||||||
+2
-3
@@ -8,8 +8,7 @@ class A(
|
|||||||
/**
|
/**
|
||||||
* Doc
|
* Doc
|
||||||
*/
|
*/
|
||||||
val p2: String,
|
val p2: String)
|
||||||
)
|
|
||||||
|
|
||||||
class B(
|
class B(
|
||||||
/** Doc1 */
|
/** Doc1 */
|
||||||
@@ -18,5 +17,5 @@ class B(
|
|||||||
/**
|
/**
|
||||||
* Doc2
|
* Doc2
|
||||||
*/
|
*/
|
||||||
val v2: Int,
|
val v2: Int
|
||||||
)
|
)
|
||||||
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
fun some(
|
fun some(
|
||||||
a :Int,
|
a :Int,
|
||||||
b :String, c :Int,
|
b :String, c :Int,
|
||||||
d :String, e :Int,
|
d :String, e :Int
|
||||||
) {
|
) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
fun some(
|
fun some(
|
||||||
a: Int,
|
a: Int,
|
||||||
b: String, c: Int,
|
b: String, c: Int,
|
||||||
d: String, e: Int,
|
d: String, e: Int
|
||||||
) {
|
) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -58,3 +58,4 @@ fun some(x: Any) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// SET_TRUE: ALLOW_TRAILING_COMMA
|
||||||
+1
@@ -66,3 +66,4 @@ else
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// SET_TRUE: ALLOW_TRAILING_COMMA
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
abstract class RustNavigationContributorBase<T> protected constructor(
|
abstract class RustNavigationContributorBase<T> protected constructor(
|
||||||
private val indexKey: StubIndexKey<String, T>,
|
private val indexKey: StubIndexKey<String, T>,
|
||||||
private val clazz: Class<T>,
|
private val clazz: Class<T>
|
||||||
) : ChooseByNameContributor, GotoClassContributor
|
) : ChooseByNameContributor, GotoClassContributor
|
||||||
where T : NavigationItem,
|
where T : NavigationItem,
|
||||||
T : RustNamedElement {
|
T : RustNamedElement {
|
||||||
|
|||||||
@@ -41,12 +41,10 @@ val x8 = foo!!!!!!!!
|
|||||||
val x9 = ((b!!)!!!!)!!
|
val x9 = ((b!!)!!!!)!!
|
||||||
.f
|
.f
|
||||||
|
|
||||||
val y = xyzzy(
|
val y = xyzzy(foo
|
||||||
foo
|
.bar()
|
||||||
.bar()
|
.baz()
|
||||||
.baz()
|
.quux())
|
||||||
.quux(),
|
|
||||||
)
|
|
||||||
|
|
||||||
fun foo() {
|
fun foo() {
|
||||||
foo
|
foo
|
||||||
@@ -91,4 +89,5 @@ fun foo() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// SET_INT: METHOD_CALL_CHAIN_WRAP = 2
|
// SET_INT: METHOD_CALL_CHAIN_WRAP = 2
|
||||||
// SET_FALSE: WRAP_FIRST_METHOD_IN_CALL_CHAIN
|
// SET_FALSE: WRAP_FIRST_METHOD_IN_CALL_CHAIN
|
||||||
|
// SET_TRUE: ALLOW_TRAILING_COMMA
|
||||||
@@ -71,4 +71,5 @@ fun foo() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// SET_INT: METHOD_CALL_CHAIN_WRAP = 2
|
// SET_INT: METHOD_CALL_CHAIN_WRAP = 2
|
||||||
// SET_FALSE: WRAP_FIRST_METHOD_IN_CALL_CHAIN
|
// SET_FALSE: WRAP_FIRST_METHOD_IN_CALL_CHAIN
|
||||||
|
// SET_TRUE: ALLOW_TRAILING_COMMA
|
||||||
|
|||||||
+2
-1
@@ -38,4 +38,5 @@ fun foo() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// SET_INT: METHOD_CALL_CHAIN_WRAP = 2
|
// SET_INT: METHOD_CALL_CHAIN_WRAP = 2
|
||||||
// SET_FALSE: WRAP_FIRST_METHOD_IN_CALL_CHAIN
|
// SET_FALSE: WRAP_FIRST_METHOD_IN_CALL_CHAIN
|
||||||
|
// SET_TRUE: ALLOW_TRAILING_COMMA
|
||||||
|
|||||||
+8
-11
@@ -12,16 +12,12 @@ fun test() {
|
|||||||
|
|
||||||
fun test1() {
|
fun test1() {
|
||||||
val abc = ArrayList<Int>()
|
val abc = ArrayList<Int>()
|
||||||
.map(
|
.map({
|
||||||
{
|
it * 2
|
||||||
it * 2
|
})
|
||||||
},
|
.filter({
|
||||||
)
|
it > 4
|
||||||
.filter(
|
})
|
||||||
{
|
|
||||||
it > 4
|
|
||||||
},
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun test2() {
|
fun test2() {
|
||||||
@@ -39,7 +35,7 @@ fun test3() {
|
|||||||
|
|
||||||
fun test4() {
|
fun test4() {
|
||||||
val abc = ArrayList<Int>().mapTo(
|
val abc = ArrayList<Int>().mapTo(
|
||||||
LinkedHashSet(),
|
LinkedHashSet()
|
||||||
) {
|
) {
|
||||||
it * 2
|
it * 2
|
||||||
}
|
}
|
||||||
@@ -56,3 +52,4 @@ fun testWithComments() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// SET_TRUE: CONTINUATION_INDENT_FOR_CHAINED_CALLS
|
// SET_TRUE: CONTINUATION_INDENT_FOR_CHAINED_CALLS
|
||||||
|
// SET_TRUE: ALLOW_TRAILING_COMMA
|
||||||
@@ -56,3 +56,4 @@ fun testWithComments() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// SET_TRUE: CONTINUATION_INDENT_FOR_CHAINED_CALLS
|
// SET_TRUE: CONTINUATION_INDENT_FOR_CHAINED_CALLS
|
||||||
|
// SET_TRUE: ALLOW_TRAILING_COMMA
|
||||||
@@ -52,3 +52,4 @@ fun testWithComments() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// SET_TRUE: CONTINUATION_INDENT_FOR_CHAINED_CALLS
|
// SET_TRUE: CONTINUATION_INDENT_FOR_CHAINED_CALLS
|
||||||
|
// SET_TRUE: ALLOW_TRAILING_COMMA
|
||||||
+5
-7
@@ -6,11 +6,9 @@ fun foo() {
|
|||||||
finish()
|
finish()
|
||||||
}
|
}
|
||||||
|
|
||||||
FirebaseAuth.getInstance().addAuthStateListener(
|
FirebaseAuth.getInstance().addAuthStateListener(object : FirebaseAuth.AuthStateListener {
|
||||||
object : FirebaseAuth.AuthStateListener {
|
override fun onAuthStateChanged(auth: FirebaseAuth) {
|
||||||
override fun onAuthStateChanged(auth: FirebaseAuth) {
|
// ...
|
||||||
// ...
|
}
|
||||||
}
|
})
|
||||||
},
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -10,15 +10,12 @@ fun foo() {
|
|||||||
testtest(foofoo)
|
testtest(foofoo)
|
||||||
|
|
||||||
testtesttesttest(
|
testtesttesttest(
|
||||||
foofoofoofoofoofoofoofoofoofoofoofoo,
|
foofoofoofoofoofoofoofoofoofoofoofoo)
|
||||||
)
|
|
||||||
|
|
||||||
testtest(foobar, barfoo)
|
testtest(foobar, barfoo)
|
||||||
|
|
||||||
testtesttesttest(
|
testtesttesttest(foofoo,
|
||||||
foofoo,
|
barbar,
|
||||||
barbar,
|
foobar,
|
||||||
foobar,
|
barfoo)
|
||||||
barfoo,
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -11,15 +11,11 @@ fun foo() {
|
|||||||
|
|
||||||
testtesttesttest(foofoofoofoofoofoofoofoofoofoofoofoo)
|
testtesttesttest(foofoofoofoofoofoofoofoofoofoofoofoo)
|
||||||
|
|
||||||
testtest(
|
testtest(foobar,
|
||||||
foobar,
|
barfoo)
|
||||||
barfoo,
|
|
||||||
)
|
|
||||||
|
|
||||||
testtesttesttest(
|
testtesttesttest(foofoo,
|
||||||
foofoo,
|
barbar,
|
||||||
barbar,
|
foobar,
|
||||||
foobar,
|
barfoo)
|
||||||
barfoo,
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -10,15 +10,12 @@ fun foo() {
|
|||||||
testtest(foofoo)
|
testtest(foofoo)
|
||||||
|
|
||||||
testtesttesttest(
|
testtesttesttest(
|
||||||
foofoofoofoofoofoofoofoofoofoofoofoo,
|
foofoofoofoofoofoofoofoofoofoofoofoo)
|
||||||
)
|
|
||||||
|
|
||||||
testtest(foobar, barfoo)
|
testtest(foobar, barfoo)
|
||||||
|
|
||||||
testtesttesttest(
|
testtesttesttest(foofoo,
|
||||||
foofoo,
|
barbar,
|
||||||
barbar,
|
foobar,
|
||||||
foobar,
|
barfoo)
|
||||||
barfoo,
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -4,10 +4,8 @@
|
|||||||
fun foo() {
|
fun foo() {
|
||||||
foo(bar, baz)
|
foo(bar, baz)
|
||||||
|
|
||||||
foo(
|
foo(object : Quux {
|
||||||
object : Quux {
|
override fun foo() {
|
||||||
override fun foo() {
|
}
|
||||||
}
|
})
|
||||||
},
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
fun foo(
|
fun foo(
|
||||||
x: Int =
|
x: Int =
|
||||||
42,
|
42
|
||||||
) {
|
) {
|
||||||
}
|
}
|
||||||
|
|
||||||
class C(
|
class C(
|
||||||
val x: Int =
|
val x: Int =
|
||||||
42,
|
42
|
||||||
)
|
)
|
||||||
|
|
||||||
// SET_TRUE: CONTINUATION_INDENT_FOR_EXPRESSION_BODIES
|
// SET_TRUE: CONTINUATION_INDENT_FOR_EXPRESSION_BODIES
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
fun foo(
|
fun foo(
|
||||||
x: Int =
|
x: Int =
|
||||||
42,
|
42
|
||||||
) {
|
) {
|
||||||
}
|
}
|
||||||
|
|
||||||
class C(
|
class C(
|
||||||
val x: Int =
|
val x: Int =
|
||||||
42,
|
42
|
||||||
)
|
)
|
||||||
|
|
||||||
// SET_TRUE: CONTINUATION_INDENT_FOR_EXPRESSION_BODIES
|
// SET_TRUE: CONTINUATION_INDENT_FOR_EXPRESSION_BODIES
|
||||||
|
|||||||
+11
-20
@@ -5,28 +5,19 @@ fun useCallable(tag: String, callable: Callable<*>) {
|
|||||||
fun main(args: Array<String>) {
|
fun main(args: Array<String>) {
|
||||||
useCallable("A", Callable { println("Hello world") })
|
useCallable("A", Callable { println("Hello world") })
|
||||||
|
|
||||||
useCallable(
|
useCallable("B", Callable {
|
||||||
"B",
|
println("Hello world")
|
||||||
Callable {
|
})
|
||||||
println("Hello world")
|
|
||||||
},
|
|
||||||
)
|
|
||||||
|
|
||||||
useCallable(
|
useCallable("C", object : Callable<Unit> {
|
||||||
"C",
|
override fun call() {
|
||||||
object : Callable<Unit> {
|
println("Hello world")
|
||||||
override fun call() {
|
}
|
||||||
println("Hello world")
|
})
|
||||||
}
|
|
||||||
},
|
|
||||||
)
|
|
||||||
|
|
||||||
useCallable(
|
useCallable("B", fun() {
|
||||||
"B",
|
println("Hello world")
|
||||||
fun() {
|
})
|
||||||
println("Hello world")
|
|
||||||
},
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// SET_TRUE: CALL_PARAMETERS_LPAREN_ON_NEXT_LINE
|
// SET_TRUE: CALL_PARAMETERS_LPAREN_ON_NEXT_LINE
|
||||||
|
|||||||
@@ -12,12 +12,10 @@ fun testtesttesttest(foofoo: Int)
|
|||||||
|
|
||||||
fun test(foo: Int, bar: Int)
|
fun test(foo: Int, bar: Int)
|
||||||
|
|
||||||
fun testtesttesttest(
|
fun testtesttesttest(foofoo: Int,
|
||||||
foofoo: Int,
|
barbar: Int,
|
||||||
barbar: Int,
|
foobar: Int,
|
||||||
foobar: Int,
|
barfoo: Int)
|
||||||
barfoo: Int,
|
|
||||||
)
|
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
for (foo: Int in bar) {
|
for (foo: Int in bar) {
|
||||||
@@ -41,34 +39,26 @@ class LongLongLongLongNameCLass
|
|||||||
class ShorName
|
class ShorName
|
||||||
class SN
|
class SN
|
||||||
|
|
||||||
class A(
|
class A(longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
||||||
longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
|
||||||
longLongLongLongNameCLass2: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass2: LongLongLongLongNameCLass,
|
||||||
longLongLongLongNameCLass3: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass3: LongLongLongLongNameCLass) {
|
||||||
) {
|
|
||||||
constructor(
|
constructor(
|
||||||
longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
||||||
longLongLongLongNameCLass2: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass2: LongLongLongLongNameCLass,
|
||||||
longLongLongLongNameCLass3: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass3: LongLongLongLongNameCLass) {
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class B(
|
class B(a: LongLongLongLongNameCLass,
|
||||||
a: LongLongLongLongNameCLass,
|
|
||||||
b: LongLongLongLongNameCLass,
|
b: LongLongLongLongNameCLass,
|
||||||
c: LongLongLongLongNameCLass,
|
c: LongLongLongLongNameCLass) {
|
||||||
) {
|
constructor(a: LongLongLongLongNameCLass,
|
||||||
constructor(
|
b: LongLongLongLongNameCLass,
|
||||||
a: LongLongLongLongNameCLass,
|
c: LongLongLongLongNameCLass) {
|
||||||
b: LongLongLongLongNameCLass,
|
|
||||||
c: LongLongLongLongNameCLass,
|
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class C(
|
class C(sn1: ShorName,
|
||||||
sn1: ShorName,
|
|
||||||
sn2: ShorName,
|
sn2: ShorName,
|
||||||
sn3: ShorName,
|
sn3: ShorName,
|
||||||
sn4: ShorName,
|
sn4: ShorName,
|
||||||
@@ -76,24 +66,20 @@ class C(
|
|||||||
sn6: ShorName,
|
sn6: ShorName,
|
||||||
sn6: ShorName,
|
sn6: ShorName,
|
||||||
sn8: ShorName,
|
sn8: ShorName,
|
||||||
sn9: ShorName,
|
sn9: ShorName) {
|
||||||
) {
|
constructor(sn1: ShorName,
|
||||||
constructor(
|
sn2: ShorName,
|
||||||
sn1: ShorName,
|
sn3: ShorName,
|
||||||
sn2: ShorName,
|
sn4: ShorName,
|
||||||
sn3: ShorName,
|
sn5: ShorName,
|
||||||
sn4: ShorName,
|
sn6: ShorName,
|
||||||
sn5: ShorName,
|
sn6: ShorName,
|
||||||
sn6: ShorName,
|
sn8: ShorName,
|
||||||
sn6: ShorName,
|
sn9: ShorName) {
|
||||||
sn8: ShorName,
|
|
||||||
sn9: ShorName,
|
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class D(
|
class D(sn1: SN,
|
||||||
sn1: SN,
|
|
||||||
sn2: SN,
|
sn2: SN,
|
||||||
sn3: SN,
|
sn3: SN,
|
||||||
sn4: SN,
|
sn4: SN,
|
||||||
@@ -106,31 +92,27 @@ class D(
|
|||||||
sn11: SN,
|
sn11: SN,
|
||||||
sn12: SN,
|
sn12: SN,
|
||||||
sn13: SN,
|
sn13: SN,
|
||||||
sn14: SN,
|
sn14: SN) {
|
||||||
) {
|
constructor(sn1: SN,
|
||||||
constructor(
|
sn2: SN,
|
||||||
sn1: SN,
|
sn3: SN,
|
||||||
sn2: SN,
|
sn4: SN,
|
||||||
sn3: SN,
|
sn5: SN,
|
||||||
sn4: SN,
|
sn6: SN,
|
||||||
sn5: SN,
|
sn6: SN,
|
||||||
sn6: SN,
|
sn8: SN,
|
||||||
sn6: SN,
|
sn9: SN,
|
||||||
sn8: SN,
|
sn10: SN,
|
||||||
sn9: SN,
|
sn11: SN,
|
||||||
sn10: SN,
|
sn12: SN,
|
||||||
sn11: SN,
|
sn13: SN,
|
||||||
sn12: SN,
|
sn14: SN) {
|
||||||
sn13: SN,
|
|
||||||
sn14: SN,
|
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class E(longLongLongLongNameCLass1: LongLongLongLongNameCLass) {
|
class E(longLongLongLongNameCLass1: LongLongLongLongNameCLass) {
|
||||||
constructor(
|
constructor(
|
||||||
longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass1: LongLongLongLongNameCLass) {
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -10,31 +10,23 @@ fun testtest(foofoo: Int)
|
|||||||
|
|
||||||
fun testtesttesttest(foofoo: Int)
|
fun testtesttesttest(foofoo: Int)
|
||||||
|
|
||||||
fun test(
|
fun test(foo: Int,
|
||||||
foo: Int,
|
bar: Int)
|
||||||
bar: Int,
|
|
||||||
)
|
|
||||||
|
|
||||||
fun testtesttesttest(
|
fun testtesttesttest(foofoo: Int,
|
||||||
foofoo: Int,
|
barbar: Int,
|
||||||
barbar: Int,
|
foobar: Int,
|
||||||
foobar: Int,
|
barfoo: Int)
|
||||||
barfoo: Int,
|
|
||||||
)
|
|
||||||
|
|
||||||
fun testtesttesttest(
|
fun testtesttesttest(foofoo: Int,
|
||||||
foofoo: Int,
|
@Some barbar: Int,
|
||||||
@Some barbar: Int,
|
foobar: Int,
|
||||||
foobar: Int,
|
barfoo: Int)
|
||||||
barfoo: Int,
|
|
||||||
)
|
|
||||||
|
|
||||||
fun testtesttesttest(
|
fun testtesttesttest(@Some foofoo: Int,
|
||||||
@Some foofoo: Int,
|
@Some barbar: Int,
|
||||||
@Some barbar: Int,
|
@Some foobar: Int,
|
||||||
@Some foobar: Int,
|
barfoo: Int)
|
||||||
barfoo: Int,
|
|
||||||
)
|
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
for (foo: Int in bar) {
|
for (foo: Int in bar) {
|
||||||
@@ -58,34 +50,25 @@ class LongLongLongLongNameCLass
|
|||||||
class ShorName
|
class ShorName
|
||||||
class SN
|
class SN
|
||||||
|
|
||||||
class A(
|
class A(longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
||||||
longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
|
||||||
longLongLongLongNameCLass2: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass2: LongLongLongLongNameCLass,
|
||||||
longLongLongLongNameCLass3: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass3: LongLongLongLongNameCLass) {
|
||||||
) {
|
constructor(longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
||||||
constructor(
|
longLongLongLongNameCLass2: LongLongLongLongNameCLass,
|
||||||
longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass3: LongLongLongLongNameCLass) {
|
||||||
longLongLongLongNameCLass2: LongLongLongLongNameCLass,
|
|
||||||
longLongLongLongNameCLass3: LongLongLongLongNameCLass,
|
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class B(
|
class B(a: LongLongLongLongNameCLass,
|
||||||
a: LongLongLongLongNameCLass,
|
|
||||||
b: LongLongLongLongNameCLass,
|
b: LongLongLongLongNameCLass,
|
||||||
c: LongLongLongLongNameCLass,
|
c: LongLongLongLongNameCLass) {
|
||||||
) {
|
constructor(a: LongLongLongLongNameCLass,
|
||||||
constructor(
|
b: LongLongLongLongNameCLass,
|
||||||
a: LongLongLongLongNameCLass,
|
c: LongLongLongLongNameCLass) {
|
||||||
b: LongLongLongLongNameCLass,
|
|
||||||
c: LongLongLongLongNameCLass,
|
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class C(
|
class C(sn1: ShorName,
|
||||||
sn1: ShorName,
|
|
||||||
sn2: ShorName,
|
sn2: ShorName,
|
||||||
sn3: ShorName,
|
sn3: ShorName,
|
||||||
sn4: ShorName,
|
sn4: ShorName,
|
||||||
@@ -93,24 +76,20 @@ class C(
|
|||||||
sn6: ShorName,
|
sn6: ShorName,
|
||||||
sn6: ShorName,
|
sn6: ShorName,
|
||||||
sn8: ShorName,
|
sn8: ShorName,
|
||||||
sn9: ShorName,
|
sn9: ShorName) {
|
||||||
) {
|
constructor(sn1: ShorName,
|
||||||
constructor(
|
sn2: ShorName,
|
||||||
sn1: ShorName,
|
sn3: ShorName,
|
||||||
sn2: ShorName,
|
sn4: ShorName,
|
||||||
sn3: ShorName,
|
sn5: ShorName,
|
||||||
sn4: ShorName,
|
sn6: ShorName,
|
||||||
sn5: ShorName,
|
sn6: ShorName,
|
||||||
sn6: ShorName,
|
sn8: ShorName,
|
||||||
sn6: ShorName,
|
sn9: ShorName) {
|
||||||
sn8: ShorName,
|
|
||||||
sn9: ShorName,
|
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class D(
|
class D(sn1: SN,
|
||||||
sn1: SN,
|
|
||||||
sn2: SN,
|
sn2: SN,
|
||||||
sn3: SN,
|
sn3: SN,
|
||||||
sn4: SN,
|
sn4: SN,
|
||||||
@@ -123,24 +102,21 @@ class D(
|
|||||||
sn11: SN,
|
sn11: SN,
|
||||||
sn12: SN,
|
sn12: SN,
|
||||||
sn13: SN,
|
sn13: SN,
|
||||||
sn14: SN,
|
sn14: SN) {
|
||||||
) {
|
constructor(sn1: SN,
|
||||||
constructor(
|
sn2: SN,
|
||||||
sn1: SN,
|
sn3: SN,
|
||||||
sn2: SN,
|
sn4: SN,
|
||||||
sn3: SN,
|
sn5: SN,
|
||||||
sn4: SN,
|
sn6: SN,
|
||||||
sn5: SN,
|
sn6: SN,
|
||||||
sn6: SN,
|
sn8: SN,
|
||||||
sn6: SN,
|
sn9: SN,
|
||||||
sn8: SN,
|
sn10: SN,
|
||||||
sn9: SN,
|
sn11: SN,
|
||||||
sn10: SN,
|
sn12: SN,
|
||||||
sn11: SN,
|
sn13: SN,
|
||||||
sn12: SN,
|
sn14: SN) {
|
||||||
sn13: SN,
|
|
||||||
sn14: SN,
|
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -159,16 +135,13 @@ class G(sn1: ShorName) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class H(
|
class H(sn1: SN,
|
||||||
sn1: SN,
|
sn2: SN) {
|
||||||
sn2: SN,
|
|
||||||
) {
|
|
||||||
constructor(sn1: SN) {
|
constructor(sn1: SN) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class I(
|
class I(sn1: SN,
|
||||||
sn1: SN,
|
|
||||||
@field:Some val sn2: SN,
|
@field:Some val sn2: SN,
|
||||||
sn3: SN,
|
sn3: SN,
|
||||||
sn4: SN,
|
sn4: SN,
|
||||||
@@ -181,23 +154,20 @@ class I(
|
|||||||
sn11: SN,
|
sn11: SN,
|
||||||
sn12: SN,
|
sn12: SN,
|
||||||
sn13: SN,
|
sn13: SN,
|
||||||
sn14: SN,
|
sn14: SN) {
|
||||||
) {
|
constructor(sn1: SN,
|
||||||
constructor(
|
sn2: SN,
|
||||||
sn1: SN,
|
sn3: SN,
|
||||||
sn2: SN,
|
@Some sn4: SN,
|
||||||
sn3: SN,
|
sn5: SN,
|
||||||
@Some sn4: SN,
|
sn6: SN,
|
||||||
sn5: SN,
|
sn6: SN,
|
||||||
sn6: SN,
|
sn8: SN,
|
||||||
sn6: SN,
|
sn9: SN,
|
||||||
sn8: SN,
|
sn10: SN,
|
||||||
sn9: SN,
|
sn11: SN,
|
||||||
sn10: SN,
|
sn12: SN,
|
||||||
sn11: SN,
|
sn13: SN,
|
||||||
sn12: SN,
|
sn14: SN) {
|
||||||
sn13: SN,
|
|
||||||
sn14: SN,
|
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,8 +9,7 @@ fun testtesttesttesttesttesttesttesttest()
|
|||||||
fun testtest(foofoo: Int)
|
fun testtest(foofoo: Int)
|
||||||
|
|
||||||
fun testtesttesttest(
|
fun testtesttesttest(
|
||||||
foofoo: Int,
|
foofoo: Int)
|
||||||
)
|
|
||||||
|
|
||||||
fun test(foo: Int, bar: Int)
|
fun test(foo: Int, bar: Int)
|
||||||
|
|
||||||
@@ -18,8 +17,7 @@ fun testtesttesttest(
|
|||||||
foofoo: Int,
|
foofoo: Int,
|
||||||
barbar: Int,
|
barbar: Int,
|
||||||
foobar: Int,
|
foobar: Int,
|
||||||
barfoo: Int,
|
barfoo: Int)
|
||||||
)
|
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
for (foo: Int in bar) {
|
for (foo: Int in bar) {
|
||||||
@@ -43,34 +41,27 @@ class LongLongLongLongNameCLass
|
|||||||
class ShorName
|
class ShorName
|
||||||
class SN
|
class SN
|
||||||
|
|
||||||
class A(
|
class A(longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
||||||
longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
|
||||||
longLongLongLongNameCLass2: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass2: LongLongLongLongNameCLass,
|
||||||
longLongLongLongNameCLass3: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass3: LongLongLongLongNameCLass) {
|
||||||
) {
|
|
||||||
constructor(
|
constructor(
|
||||||
longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
||||||
longLongLongLongNameCLass2: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass2: LongLongLongLongNameCLass,
|
||||||
longLongLongLongNameCLass3: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass3: LongLongLongLongNameCLass) {
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class B(
|
class B(a: LongLongLongLongNameCLass,
|
||||||
a: LongLongLongLongNameCLass,
|
|
||||||
b: LongLongLongLongNameCLass,
|
b: LongLongLongLongNameCLass,
|
||||||
c: LongLongLongLongNameCLass,
|
c: LongLongLongLongNameCLass) {
|
||||||
) {
|
|
||||||
constructor(
|
constructor(
|
||||||
a: LongLongLongLongNameCLass,
|
a: LongLongLongLongNameCLass,
|
||||||
b: LongLongLongLongNameCLass,
|
b: LongLongLongLongNameCLass,
|
||||||
c: LongLongLongLongNameCLass,
|
c: LongLongLongLongNameCLass) {
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class C(
|
class C(sn1: ShorName,
|
||||||
sn1: ShorName,
|
|
||||||
sn2: ShorName,
|
sn2: ShorName,
|
||||||
sn3: ShorName,
|
sn3: ShorName,
|
||||||
sn4: ShorName,
|
sn4: ShorName,
|
||||||
@@ -78,68 +69,58 @@ class C(
|
|||||||
sn6: ShorName,
|
sn6: ShorName,
|
||||||
sn6: ShorName,
|
sn6: ShorName,
|
||||||
sn8: ShorName,
|
sn8: ShorName,
|
||||||
sn9: ShorName,
|
sn9: ShorName) {
|
||||||
) {
|
constructor(sn1: ShorName,
|
||||||
constructor(
|
sn2: ShorName,
|
||||||
sn1: ShorName,
|
sn3: ShorName,
|
||||||
sn2: ShorName,
|
sn4: ShorName,
|
||||||
sn3: ShorName,
|
sn5: ShorName,
|
||||||
sn4: ShorName,
|
sn6: ShorName,
|
||||||
sn5: ShorName,
|
sn6: ShorName,
|
||||||
sn6: ShorName,
|
sn8: ShorName,
|
||||||
sn6: ShorName,
|
sn9: ShorName) {
|
||||||
sn8: ShorName,
|
|
||||||
sn9: ShorName,
|
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class D(
|
class D(sn1: SN, sn2: SN,
|
||||||
sn1: SN, sn2: SN,
|
|
||||||
sn3: SN, sn4: SN,
|
sn3: SN, sn4: SN,
|
||||||
sn5: SN, sn6: SN,
|
sn5: SN, sn6: SN,
|
||||||
sn6: SN, sn8: SN,
|
sn6: SN, sn8: SN,
|
||||||
sn9: SN, sn10: SN,
|
sn9: SN, sn10: SN,
|
||||||
sn11: SN, sn12: SN,
|
sn11: SN, sn12: SN,
|
||||||
sn13: SN, sn14: SN,
|
sn13: SN, sn14: SN) {
|
||||||
) {
|
constructor(sn1: SN,
|
||||||
constructor(
|
sn2: SN,
|
||||||
sn1: SN,
|
sn3: SN,
|
||||||
sn2: SN,
|
sn4: SN,
|
||||||
sn3: SN,
|
sn5: SN,
|
||||||
sn4: SN,
|
sn6: SN,
|
||||||
sn5: SN,
|
sn6: SN,
|
||||||
sn6: SN,
|
sn8: SN,
|
||||||
sn6: SN,
|
sn9: SN,
|
||||||
sn8: SN,
|
sn10: SN,
|
||||||
sn9: SN,
|
sn11: SN,
|
||||||
sn10: SN,
|
sn12: SN,
|
||||||
sn11: SN,
|
sn13: SN,
|
||||||
sn12: SN,
|
sn14: SN) {
|
||||||
sn13: SN,
|
|
||||||
sn14: SN,
|
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class E(longLongLongLongNameCLass1: LongLongLongLongNameCLass) {
|
class E(longLongLongLongNameCLass1: LongLongLongLongNameCLass) {
|
||||||
constructor(
|
constructor(
|
||||||
longLongLongLongNameCLass1: LongLongLongLongNameCLass,
|
longLongLongLongNameCLass1: LongLongLongLongNameCLass) {
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class F(a: LongLongLongLongNameCLass) {
|
class F(a: LongLongLongLongNameCLass) {
|
||||||
constructor(
|
constructor(
|
||||||
a: LongLongLongLongNameCLass,
|
a: LongLongLongLongNameCLass) {
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class G(sn1: ShorName) {
|
class G(sn1: ShorName) {
|
||||||
constructor(
|
constructor(
|
||||||
sn1: ShorName,
|
sn1: ShorName) {
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -4,8 +4,9 @@ val x = listOf(1, 2, 3).joinToString(
|
|||||||
// comment2
|
// comment2
|
||||||
prefix = "= ",
|
prefix = "= ",
|
||||||
// comment3
|
// comment3
|
||||||
separator = " + ",
|
separator = " + "
|
||||||
// comment4
|
// comment4
|
||||||
|
,
|
||||||
// comment1
|
// comment1
|
||||||
transform = Int::toString
|
transform = Int::toString
|
||||||
)
|
)
|
||||||
+2
-4
@@ -2,8 +2,6 @@
|
|||||||
// HIGHLIGHT: INFORMATION
|
// HIGHLIGHT: INFORMATION
|
||||||
|
|
||||||
fun test(list: List<Int>) {
|
fun test(list: List<Int>) {
|
||||||
println(
|
println(list.filter { it > 1 }
|
||||||
list.filter { it > 1 }
|
.filter { it > 2 })
|
||||||
.filter { it > 2 }
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -2,9 +2,7 @@
|
|||||||
// HIGHLIGHT: INFORMATION
|
// HIGHLIGHT: INFORMATION
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
println(
|
println(runCatching {
|
||||||
runCatching {
|
|
||||||
/* lots of code*/
|
/* lots of code*/
|
||||||
}
|
})
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -3,11 +3,9 @@
|
|||||||
fun foo(x: Int) {}
|
fun foo(x: Int) {}
|
||||||
|
|
||||||
fun bar() {
|
fun bar() {
|
||||||
foo(
|
foo(run {
|
||||||
run {
|
foo(1)
|
||||||
foo(1)
|
foo(2)
|
||||||
foo(2)
|
1
|
||||||
1
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
Vendored
+3
-6
@@ -3,12 +3,9 @@ fun test() {
|
|||||||
operator fun get(a: Int, b: Int, fn: (i: Int) -> Int) : Int = 0
|
operator fun get(a: Int, b: Int, fn: (i: Int) -> Int) : Int = 0
|
||||||
}
|
}
|
||||||
val test = Test()
|
val test = Test()
|
||||||
test<caret>[
|
test<caret>[1, 2, { i ->
|
||||||
1, 2,
|
i
|
||||||
{ i ->
|
}]
|
||||||
i
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun withSuppression() {
|
fun withSuppression() {
|
||||||
|
|||||||
Vendored
+3
-5
@@ -3,9 +3,7 @@ fun test() {
|
|||||||
operator fun get(fn: (i: Int) -> Int) : Int = 0
|
operator fun get(fn: (i: Int) -> Int) : Int = 0
|
||||||
}
|
}
|
||||||
val test = Test()
|
val test = Test()
|
||||||
test<caret>[
|
test<caret>[{ i ->
|
||||||
{ i ->
|
i
|
||||||
i
|
}]
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,5 @@
|
|||||||
fun test() {
|
fun test() {
|
||||||
Foo.Bar().bar(
|
Foo.Bar().bar({
|
||||||
{
|
true
|
||||||
true
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
Vendored
+2
-4
@@ -1,10 +1,8 @@
|
|||||||
// WITH_RUNTIME
|
// WITH_RUNTIME
|
||||||
fun main(args: Array<String>) {
|
fun main(args: Array<String>) {
|
||||||
val doSomething = doSomething(
|
val doSomething = doSomething("one" + 1,
|
||||||
"one" + 1,
|
|
||||||
"two",
|
"two",
|
||||||
3 * 4
|
3 * 4)
|
||||||
)
|
|
||||||
val t = if (doSomething != null) doSomething else throw NullPointerException("Expression 'doSomething(\"one\" + 1, ...' must not be null")
|
val t = if (doSomething != null) doSomething else throw NullPointerException("Expression 'doSomething(\"one\" + 1, ...' must not be null")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+1
-2
@@ -5,7 +5,6 @@ class WithComments/* Some parameter */
|
|||||||
/**
|
/**
|
||||||
* A very important property
|
* A very important property
|
||||||
*/
|
*/
|
||||||
val veryImportant: Any
|
val veryImportant: Any) {
|
||||||
) {
|
|
||||||
|
|
||||||
}
|
}
|
||||||
Vendored
+2
-4
@@ -2,9 +2,7 @@ annotation class AnnParam
|
|||||||
|
|
||||||
annotation class AnnProperty
|
annotation class AnnProperty
|
||||||
|
|
||||||
abstract class WithComposedModifiers(
|
abstract class WithComposedModifiers(@AnnParam vararg @AnnProperty
|
||||||
@AnnParam vararg @AnnProperty
|
open val x: String) {
|
||||||
open val x: String
|
|
||||||
) {
|
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -1,9 +1,7 @@
|
|||||||
fun foo(f: (Int) -> String) {}
|
fun foo(f: (Int) -> String) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(fun(it: Int): String {
|
||||||
fun(it: Int): String {
|
return ""
|
||||||
return ""
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
+3
-5
@@ -1,9 +1,7 @@
|
|||||||
fun bar(f: (Int, Int) -> String) {}
|
fun bar(f: (Int, Int) -> String) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
bar(
|
bar(fun(i: Int, j: Int): String {
|
||||||
fun(i: Int, j: Int): String {
|
return "$i$j"
|
||||||
return "$i$j"
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -2,9 +2,7 @@ class Foo
|
|||||||
fun bar(f: Foo.() -> Unit) {}
|
fun bar(f: Foo.() -> Unit) {}
|
||||||
|
|
||||||
fun main(args: Array<String>) {
|
fun main(args: Array<String>) {
|
||||||
bar(
|
bar(fun Foo.() {
|
||||||
fun Foo.() {
|
|
||||||
|
|
||||||
}
|
})
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -2,9 +2,7 @@ class Foo
|
|||||||
fun baz(f: Foo.(i: Int, j: Int) -> Int) {}
|
fun baz(f: Foo.(i: Int, j: Int) -> Int) {}
|
||||||
|
|
||||||
fun main(args: Array<String>) {
|
fun main(args: Array<String>) {
|
||||||
baz(
|
baz(fun Foo.(i: Int, j: Int): Int {
|
||||||
fun Foo.(i: Int, j: Int): Int {
|
return i + j
|
||||||
return i + j
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -6,9 +6,7 @@ import java.util.*
|
|||||||
fun foo(f: () -> ArrayDeque<*>) {}
|
fun foo(f: () -> ArrayDeque<*>) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(fun(): ArrayDeque<Int> {
|
||||||
fun(): ArrayDeque<Int> {
|
return ArrayDeque<Int>()
|
||||||
return ArrayDeque<Int>()
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
+3
-5
@@ -6,9 +6,7 @@ import java.util.*
|
|||||||
fun foo(f: () -> ArrayDeque<*>) {}
|
fun foo(f: () -> ArrayDeque<*>) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(fun(): ArrayDeque<*> {
|
||||||
fun(): ArrayDeque<*> {
|
return ArrayDeque<Int>()
|
||||||
return ArrayDeque<Int>()
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,11 +1,9 @@
|
|||||||
fun foo(f: (Int) -> String) {}
|
fun foo(f: (Int) -> String) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(fun(it: Int): String {
|
||||||
fun(it: Int): String {
|
// comment1
|
||||||
// comment1
|
return ""
|
||||||
return ""
|
// comment2
|
||||||
// comment2
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -1,9 +1,7 @@
|
|||||||
fun foo(f: (Int) -> String) {}
|
fun foo(f: (Int) -> String) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(fun(it: Int): String {
|
||||||
fun(it: Int): String {
|
return "$it"
|
||||||
return "$it"
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -1,12 +1,10 @@
|
|||||||
fun foo(f: (Int) -> String) {}
|
fun foo(f: (Int) -> String) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(fun(it: Int): String {
|
||||||
fun(it: Int): String {
|
if (it == 1) {
|
||||||
if (it == 1) {
|
return "1"
|
||||||
return "1"
|
}
|
||||||
}
|
return "$it"
|
||||||
return "$it"
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -1,15 +1,13 @@
|
|||||||
fun foo(f: (Int) -> String) {}
|
fun foo(f: (Int) -> String) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(fun(it: Int): String {
|
||||||
fun(it: Int): String {
|
if (it == 1) {
|
||||||
if (it == 1) {
|
return "1"
|
||||||
return "1"
|
} else if (it == 2) {
|
||||||
} else if (it == 2) {
|
return "2"
|
||||||
return "2"
|
} else {
|
||||||
} else {
|
return "$it"
|
||||||
return "$it"
|
}
|
||||||
}
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -2,12 +2,10 @@
|
|||||||
fun foo(f: (Int) -> String) {}
|
fun foo(f: (Int) -> String) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(fun(it: Int): String {
|
||||||
fun(it: Int): String {
|
listOf(1).map {
|
||||||
listOf(1).map {
|
return@map 2
|
||||||
return@map 2
|
}
|
||||||
}
|
return "$it"
|
||||||
return "$it"
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
+4
-6
@@ -1,10 +1,8 @@
|
|||||||
fun foo(f: (Int) -> String) {}
|
fun foo(f: (Int) -> String) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(fun(it: Int): String {
|
||||||
fun(it: Int): String {
|
val b = it == 1
|
||||||
val b = it == 1
|
return if (b) "1" else "2"
|
||||||
return if (b) "1" else "2"
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
+3
-5
@@ -1,9 +1,7 @@
|
|||||||
fun foo(f: (Int) -> String) {}
|
fun foo(f: (Int) -> String) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(fun(it: Int): String {
|
||||||
fun(it: Int): String {
|
return "$it"
|
||||||
return "$it"
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -1,7 +1,5 @@
|
|||||||
fun main() {
|
fun main() {
|
||||||
Test().foo(
|
Test().foo(fun(it: Int) {
|
||||||
fun(it: Int) {
|
|
||||||
|
|
||||||
}
|
})
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -3,6 +3,5 @@ fun baz(name: String, f: (Int) -> String) {}
|
|||||||
fun test() {
|
fun test() {
|
||||||
baz(name = "", f = fun(it: Int): String {
|
baz(name = "", f = fun(it: Int): String {
|
||||||
return "$it"
|
return "$it"
|
||||||
}
|
})
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -1,9 +1,7 @@
|
|||||||
fun foo(f: () -> String) {}
|
fun foo(f: () -> String) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(fun(): String {
|
||||||
fun(): String {
|
return ""
|
||||||
return ""
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -3,10 +3,8 @@ fun unit(f: (Int) -> Unit) {}
|
|||||||
fun foo(i: Int) {}
|
fun foo(i: Int) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
unit(
|
unit(fun(it: Int) {
|
||||||
fun(it: Int) {
|
foo(it)
|
||||||
foo(it)
|
foo(it)
|
||||||
foo(it)
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -7,9 +7,7 @@ data class My(val x: Int)
|
|||||||
fun foo(f: () -> My) {}
|
fun foo(f: () -> My) {}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(fun(): My {
|
||||||
fun(): My {
|
return My(42)
|
||||||
return My(42)
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
// IS_APPLICABLE: true
|
// IS_APPLICABLE: true
|
||||||
fun foo() {
|
fun foo() {
|
||||||
bar(2,
|
bar(2, {
|
||||||
{
|
it * 3
|
||||||
it * 3
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun bar(a: Int, b: (Int) -> Int) {
|
fun bar(a: Int, b: (Int) -> Int) {
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
// IS_APPLICABLE: true
|
// IS_APPLICABLE: true
|
||||||
fun foo() {
|
fun foo() {
|
||||||
bar(
|
bar(b = {
|
||||||
b = {
|
it * 3
|
||||||
it * 3
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun bar(a : Int = 2, b: (Int) -> Int) {
|
fun bar(a : Int = 2, b: (Int) -> Int) {
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
// IS_APPLICABLE: true
|
// IS_APPLICABLE: true
|
||||||
fun foo() {
|
fun foo() {
|
||||||
bar(1,
|
bar(1, b = {
|
||||||
b = {
|
it * 3
|
||||||
it * 3
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun bar(c: Int, a: Int = 2, b: (Int) -> Int) {
|
fun bar(c: Int, a: Int = 2, b: (Int) -> Int) {
|
||||||
|
|||||||
@@ -1,11 +1,9 @@
|
|||||||
// IS_APPLICABLE: true
|
// IS_APPLICABLE: true
|
||||||
fun foo() {
|
fun foo() {
|
||||||
bar(2,
|
bar(2, {
|
||||||
{
|
val x = 3
|
||||||
val x = 3
|
it * x
|
||||||
it * x
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun bar(a: Int, b: (Int) -> Int) {
|
fun bar(a: Int, b: (Int) -> Int) {
|
||||||
|
|||||||
@@ -1,11 +1,9 @@
|
|||||||
// IS_APPLICABLE: true
|
// IS_APPLICABLE: true
|
||||||
fun foo() {
|
fun foo() {
|
||||||
bar(a = 2,
|
bar(a = 2, b = {
|
||||||
b = {
|
val x = 3
|
||||||
val x = 3
|
it * x
|
||||||
it * x
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun bar(a: Int, b: (Int) -> Int) {
|
fun bar(a: Int, b: (Int) -> Int) {
|
||||||
|
|||||||
@@ -3,13 +3,11 @@
|
|||||||
fun foo(runnable: Runnable) {}
|
fun foo(runnable: Runnable) {}
|
||||||
|
|
||||||
fun bar(list: List<String>) {
|
fun bar(list: List<String>) {
|
||||||
foo(
|
foo(Runnable {
|
||||||
Runnable {
|
list.filter(fun (element: String): Boolean {
|
||||||
list.filter(fun (element: String): Boolean {
|
if (element == "a") return false
|
||||||
if (element == "a") return false
|
if (element == "b") return@Runnable
|
||||||
if (element == "b") return@Runnable
|
return true
|
||||||
return true
|
})
|
||||||
})
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,11 +3,9 @@
|
|||||||
fun foo(runnable: Runnable) {}
|
fun foo(runnable: Runnable) {}
|
||||||
|
|
||||||
fun bar(p: Int) {
|
fun bar(p: Int) {
|
||||||
foo(
|
foo(Runnable {
|
||||||
Runnable {
|
if (p < 0) return@Runnable
|
||||||
if (p < 0) return@Runnable
|
println("a")
|
||||||
println("a")
|
println("b")
|
||||||
println("b")
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -5,10 +5,8 @@ import java.io.FilenameFilter
|
|||||||
fun foo(filter: FilenameFilter) {}
|
fun foo(filter: FilenameFilter) {}
|
||||||
|
|
||||||
fun bar() {
|
fun bar() {
|
||||||
foo(
|
foo(FilenameFilter { file, name ->
|
||||||
FilenameFilter { file, name ->
|
if (file.isDirectory) return@FilenameFilter true
|
||||||
if (file.isDirectory) return@FilenameFilter true
|
name == "x"
|
||||||
name == "x"
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,20 +5,18 @@ import java.io.FileFilter
|
|||||||
fun foo(filter: FileFilter) {}
|
fun foo(filter: FileFilter) {}
|
||||||
|
|
||||||
fun bar() {
|
fun bar() {
|
||||||
foo(
|
foo(FileFilter { file ->
|
||||||
FileFilter { file ->
|
val name = file.name
|
||||||
val name = file.name
|
if (name.startsWith("a")) {
|
||||||
if (name.startsWith("a")) {
|
false
|
||||||
false
|
}
|
||||||
}
|
else {
|
||||||
else {
|
if (name.endsWith("b"))
|
||||||
if (name.endsWith("b"))
|
true
|
||||||
true
|
else {
|
||||||
else {
|
val l = name.length
|
||||||
val l = name.length
|
l > 10
|
||||||
l > 10
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
)
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,19 +5,17 @@ import java.io.FileFilter
|
|||||||
fun foo(filter: FileFilter) {}
|
fun foo(filter: FileFilter) {}
|
||||||
|
|
||||||
fun bar() {
|
fun bar() {
|
||||||
foo(
|
foo(FileFilter { file ->
|
||||||
FileFilter { file ->
|
val name = file.name
|
||||||
val name = file.name
|
when (name) {
|
||||||
when (name) {
|
"foo" -> true
|
||||||
"foo" -> true
|
|
||||||
|
|
||||||
"bar" -> false
|
"bar" -> false
|
||||||
|
|
||||||
else -> {
|
else -> {
|
||||||
if (name.startsWith("a")) return@FileFilter true
|
if (name.startsWith("a")) return@FileFilter true
|
||||||
false
|
false
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
)
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
Vendored
+4
-6
@@ -3,10 +3,8 @@
|
|||||||
import javax.swing.SwingUtilities
|
import javax.swing.SwingUtilities
|
||||||
|
|
||||||
fun bar(p: Int) {
|
fun bar(p: Int) {
|
||||||
SwingUtilities.invokeLater(
|
SwingUtilities.invokeLater(Runnable {
|
||||||
Runnable {
|
if (p < 0) return@Runnable
|
||||||
if (p < 0) return@Runnable
|
throw UnsupportedOperationException()
|
||||||
throw UnsupportedOperationException()
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -5,10 +5,8 @@ import java.io.FileFilter
|
|||||||
fun foo(filter: FileFilter) {}
|
fun foo(filter: FileFilter) {}
|
||||||
|
|
||||||
fun bar() {
|
fun bar() {
|
||||||
foo(
|
foo(FileFilter { file ->
|
||||||
FileFilter { file ->
|
val name = file.name
|
||||||
val name = file.name
|
name.startsWith("a")
|
||||||
name.startsWith("a")
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,9 +4,7 @@ interface C {
|
|||||||
|
|
||||||
class D(val c: C) {
|
class D(val c: C) {
|
||||||
fun foo() {
|
fun foo() {
|
||||||
this.c/* and this is c */.set(
|
this.c/* and this is c */.set("a", // it's "a"
|
||||||
"a", // it's "a"
|
"b" /* and this is "b" */, /* we use 10 */10)
|
||||||
"b" /* and this is "b" */, /* we use 10 */10
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+4
-6
@@ -1,9 +1,7 @@
|
|||||||
fun main() {
|
fun main() {
|
||||||
J().foo(
|
J().foo(object : J.Sam {
|
||||||
object : J.Sam {
|
override fun bar() {
|
||||||
override fun bar() {
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-4
@@ -7,9 +7,7 @@ fun newFun(p1: Int, a: Int, p2: Int, p3: Int, b: Int){}
|
|||||||
|
|
||||||
|
|
||||||
fun foo() {
|
fun foo() {
|
||||||
newFun(
|
newFun(0, // 0
|
||||||
0, // 0
|
|
||||||
-1, 1, // 1
|
-1, 1, // 1
|
||||||
2, // 2
|
2, // 2
|
||||||
-2
|
-2)
|
||||||
)
|
|
||||||
|
|||||||
+3
-8
@@ -7,12 +7,7 @@ fun newFun(p4: Int, p3: Int, p2: Int, p1: Int, p0: Int){}
|
|||||||
|
|
||||||
|
|
||||||
fun foo() {
|
fun foo() {
|
||||||
newFun(
|
newFun(/* 4 */ 4, 3, 2, // 2
|
||||||
/* 4 */
|
/* 1 */ 1,
|
||||||
4, 3, 2, // 2
|
/* 0 */ 0)
|
||||||
/* 1 */
|
|
||||||
1,
|
|
||||||
/* 0 */
|
|
||||||
0
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-2
@@ -8,8 +8,7 @@ interface X {
|
|||||||
fun newFun(x: X, a: Int, b: Int){}
|
fun newFun(x: X, a: Int, b: Int){}
|
||||||
|
|
||||||
fun foo(x: X) {
|
fun foo(x: X) {
|
||||||
newFun(
|
newFun(x/*receiver*/, 1, // pass 1
|
||||||
x/*receiver*/, 1, // pass 1
|
|
||||||
2 // pass 2
|
2 // pass 2
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-2
@@ -11,6 +11,5 @@ fun foo(x: X) {
|
|||||||
x.newFun(
|
x.newFun(
|
||||||
1,
|
1,
|
||||||
2,
|
2,
|
||||||
0
|
0)
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-4
@@ -8,9 +8,7 @@ interface X {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun foo(x: X) {
|
fun foo(x: X) {
|
||||||
x.<caret>newFun(
|
x.<caret>newFun(1,
|
||||||
1,
|
|
||||||
2,
|
2,
|
||||||
3
|
3)
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
Vendored
+3
-5
@@ -18,9 +18,7 @@ fun useSimple(s: Int): Int {
|
|||||||
fun println(s: String) {}
|
fun println(s: String) {}
|
||||||
|
|
||||||
fun useIt() {
|
fun useIt() {
|
||||||
val t = useSimple(
|
val t = useSimple(simple {
|
||||||
simple {
|
println("abc")
|
||||||
println("abc")
|
})
|
||||||
}
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
+1
-2
@@ -36,6 +36,5 @@ fun createHi(any: Any) = "Hi $any"
|
|||||||
val unDeprecateMe = mutableListOf("Hello").apply {
|
val unDeprecateMe = mutableListOf("Hello").apply {
|
||||||
addA(d(::createHi, 1 ) { // Run the quick fix from the IDE and watch it produce broken code.
|
addA(d(::createHi, 1 ) { // Run the quick fix from the IDE and watch it produce broken code.
|
||||||
println("Yo")
|
println("Yo")
|
||||||
}, Unit
|
}, Unit)
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -3,19 +3,15 @@ fun <caret>foo(a: Int, b: Int, d: Int, c: Int, e: Int) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(1,
|
||||||
1,
|
|
||||||
2,
|
2,
|
||||||
4,
|
4,
|
||||||
3,
|
3,
|
||||||
5
|
5)
|
||||||
)
|
foo(1, 2,
|
||||||
foo(
|
|
||||||
1, 2,
|
|
||||||
4,
|
4,
|
||||||
3,
|
3,
|
||||||
5
|
5)
|
||||||
)
|
|
||||||
foo(
|
foo(
|
||||||
1,
|
1,
|
||||||
2,
|
2,
|
||||||
|
|||||||
@@ -3,11 +3,7 @@ fun foo(x: Int, cl: () -> Int, y: Int): Int {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun bar() {
|
fun bar() {
|
||||||
foo(
|
foo(1, {
|
||||||
1,
|
3
|
||||||
{
|
}, 2)
|
||||||
3
|
|
||||||
},
|
|
||||||
2
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
+6
-12
@@ -1,24 +1,18 @@
|
|||||||
interface T {
|
interface T {
|
||||||
fun foo(
|
fun foo(a: Int = 1,
|
||||||
a: Int = 1,
|
b: String = "2")
|
||||||
b: String = "2"
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
open class A: T {
|
open class A: T {
|
||||||
override fun foo(
|
override fun foo(a: Int,
|
||||||
a: Int,
|
b: String) {
|
||||||
b: String
|
|
||||||
) {
|
|
||||||
throw UnsupportedOperationException()
|
throw UnsupportedOperationException()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class B: A() {
|
class B: A() {
|
||||||
override fun foo(
|
override fun foo(a: Int,
|
||||||
a: Int,
|
b: String) {
|
||||||
b: String
|
|
||||||
) {
|
|
||||||
throw UnsupportedOperationException()
|
throw UnsupportedOperationException()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
+2
-4
@@ -3,10 +3,8 @@ fun <caret>foo(b: Int, c: Int) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(2,
|
||||||
2,
|
3)
|
||||||
3
|
|
||||||
)
|
|
||||||
foo(2, 3)
|
foo(2, 3)
|
||||||
foo(
|
foo(
|
||||||
2,
|
2,
|
||||||
|
|||||||
+2
-4
@@ -3,10 +3,8 @@ fun <caret>foo(a: Int, c: Int) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(1,
|
||||||
1,
|
3)
|
||||||
3
|
|
||||||
)
|
|
||||||
foo(1, 3)
|
foo(1, 3)
|
||||||
foo(
|
foo(
|
||||||
1,
|
1,
|
||||||
|
|||||||
+2
-4
@@ -3,10 +3,8 @@ fun <caret>foo(a: Int, b: Int) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(1,
|
||||||
1,
|
2)
|
||||||
2
|
|
||||||
)
|
|
||||||
foo(1, 2)
|
foo(1, 2)
|
||||||
foo(
|
foo(
|
||||||
1,
|
1,
|
||||||
|
|||||||
@@ -3,15 +3,11 @@ fun <caret>foo(c: Int, b: Int, a: Int) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun test() {
|
fun test() {
|
||||||
foo(
|
foo(3,
|
||||||
3,
|
|
||||||
2,
|
2,
|
||||||
1
|
1)
|
||||||
)
|
foo(3, 2,
|
||||||
foo(
|
1)
|
||||||
3, 2,
|
|
||||||
1
|
|
||||||
)
|
|
||||||
foo(
|
foo(
|
||||||
3,
|
3,
|
||||||
2,
|
2,
|
||||||
|
|||||||
+1
-2
@@ -3,6 +3,5 @@ fun callInDefault(simple: List<String> = provideSimple(), complex: List<String>
|
|||||||
val result = mutableListOf("statement 1")
|
val result = mutableListOf("statement 1")
|
||||||
result.add("statement 2")
|
result.add("statement 2")
|
||||||
result
|
result
|
||||||
}
|
}) {
|
||||||
) {
|
|
||||||
}
|
}
|
||||||
+5
-7
@@ -1,8 +1,6 @@
|
|||||||
fun g() {
|
fun g() {
|
||||||
println(
|
println(listOf("a", "b").any {
|
||||||
listOf("a", "b").any {
|
if (it.isEmpty()) return@any false
|
||||||
if (it.isEmpty()) return@any false
|
it.length < 10
|
||||||
it.length < 10
|
})
|
||||||
}
|
}
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user