Formatter: support trailing comma in value arguments

#KT-34744
This commit is contained in:
Dmitry Gridin
2019-12-25 18:31:30 +07:00
parent 13ae4a28a8
commit c195cd46f2
70 changed files with 9829 additions and 1575 deletions
@@ -8,6 +8,7 @@ package org.jetbrains.kotlin.idea.formatter
import com.intellij.formatting.* import com.intellij.formatting.*
import com.intellij.lang.ASTNode import com.intellij.lang.ASTNode
import com.intellij.openapi.util.TextRange import com.intellij.openapi.util.TextRange
import com.intellij.openapi.util.text.StringUtil
import com.intellij.psi.PsiComment import com.intellij.psi.PsiComment
import com.intellij.psi.PsiElement import com.intellij.psi.PsiElement
import com.intellij.psi.TokenType import com.intellij.psi.TokenType
@@ -19,7 +20,7 @@ import com.intellij.psi.tree.TokenSet
import org.jetbrains.kotlin.KtNodeTypes.* import org.jetbrains.kotlin.KtNodeTypes.*
import org.jetbrains.kotlin.idea.core.formatter.KotlinCodeStyleSettings import org.jetbrains.kotlin.idea.core.formatter.KotlinCodeStyleSettings
import org.jetbrains.kotlin.idea.formatter.NodeIndentStrategy.Companion.strategy import org.jetbrains.kotlin.idea.formatter.NodeIndentStrategy.Companion.strategy
import org.jetbrains.kotlin.idea.util.getLineCount import org.jetbrains.kotlin.idea.util.isMultiline
import org.jetbrains.kotlin.idea.util.requireNode import org.jetbrains.kotlin.idea.util.requireNode
import org.jetbrains.kotlin.kdoc.lexer.KDocTokens import org.jetbrains.kotlin.kdoc.lexer.KDocTokens
import org.jetbrains.kotlin.kdoc.parser.KDocElementTypes import org.jetbrains.kotlin.kdoc.parser.KDocElementTypes
@@ -585,29 +586,37 @@ abstract class KotlinCommonBlock(
when { when {
elementType === VALUE_ARGUMENT_LIST -> { elementType === VALUE_ARGUMENT_LIST -> {
val wrapSetting = commonSettings.CALL_PARAMETERS_WRAP val wrapSetting = commonSettings.CALL_PARAMETERS_WRAP
if ((wrapSetting == CommonCodeStyleSettings.WRAP_AS_NEEDED || wrapSetting == CommonCodeStyleSettings.WRAP_ON_EVERY_ITEM) && if (!node.withTrailingComma && (wrapSetting == CommonCodeStyleSettings.WRAP_AS_NEEDED || wrapSetting == CommonCodeStyleSettings.WRAP_ON_EVERY_ITEM) &&
!needWrapArgumentList(nodePsi) !needWrapArgumentList(nodePsi)
) { ) {
return ::noWrapping return ::noWrapping
} }
return getWrappingStrategyForItemList(wrapSetting, VALUE_ARGUMENT) return getWrappingStrategyForItemList(
wrapSetting,
VALUE_ARGUMENT,
node.withTrailingComma,
additionalWrap = trailingCommaWrappingStrategy(
LPAR,
RPAR,
thisOrPrevIsMultiLineElement(VALUE_ARGUMENT, COMMA, LPAR, RPAR)
)
)
} }
elementType === VALUE_PARAMETER_LIST -> { elementType === VALUE_PARAMETER_LIST -> {
if (parentElementType === FUN || if (parentElementType === FUN ||
parentElementType === PRIMARY_CONSTRUCTOR || parentElementType === PRIMARY_CONSTRUCTOR ||
parentElementType === SECONDARY_CONSTRUCTOR parentElementType === SECONDARY_CONSTRUCTOR
) { ) return getWrappingStrategyForItemList(
val wrap = Wrap.createWrap(commonSettings.METHOD_PARAMETERS_WRAP, false) commonSettings.METHOD_PARAMETERS_WRAP,
val withTrailingComma = node.withTrailingComma VALUE_PARAMETER,
return { childElement -> node.withTrailingComma,
val childElementType = childElement.elementType additionalWrap = trailingCommaWrappingStrategy(
if (withTrailingComma && (childElementType === RPAR || getPrevWithoutWhitespaceAndComments(childElement)?.elementType === LPAR)) LPAR,
Wrap.createWrap(WrapType.ALWAYS, true) RPAR,
else thisOrPrevIsMultiLineElement(VALUE_PARAMETER, COMMA, LPAR, RPAR)
wrap.takeIf { childElementType === VALUE_PARAMETER } )
} )
}
} }
elementType === SUPER_TYPE_LIST -> { elementType === SUPER_TYPE_LIST -> {
@@ -710,9 +719,74 @@ abstract class KotlinCommonBlock(
private val ASTNode.withTrailingComma: Boolean private val ASTNode.withTrailingComma: Boolean
get() = when { get() = when {
lastChildNode?.let { getPrevWithoutWhitespaceAndComments(it) }?.elementType === COMMA -> true lastChildNode?.let { getPrevWithoutWhitespaceAndComments(it) }?.elementType === COMMA -> true
settings.kotlinCustomSettings.ALLOW_TRAILING_COMMA -> psi?.getLineCount()?.let { it > 1 } == true settings.kotlinCustomSettings.ALLOW_TRAILING_COMMA -> psi?.let(PsiElement::isMultiline) == true
else -> false else -> false
} }
private fun ASTNode.getSiblingNodeInSequence(
forward: Boolean,
withBreakElement: Boolean,
breakType: IElementType,
barrier: IElementType
): ASTNode? {
var sibling: ASTNode? = null
for (element in siblings(forward).filter { it.elementType != WHITE_SPACE }.takeWhile { it.elementType != barrier }) {
if (withBreakElement) {
sibling = element
if (element.elementType == breakType) break
} else {
if (element.elementType == breakType) break
sibling = element
}
}
return sibling
}
private fun thisOrPrevIsMultiLineElement(
type: IElementType,
delimiterType: IElementType,
leftBarrier: IElementType,
rightBarrier: IElementType
) = fun(childElement: ASTNode): Boolean {
if (childElement.elementType != type) return false
val psi = childElement.psi ?: return false
if (psi.isMultiline()) return true
val startOffset = childElement.getSiblingNodeInSequence(
forward = false,
withBreakElement = true,
breakType = type,
barrier = leftBarrier
)?.startOffset ?: psi.startOffset
val endOffset = childElement.getSiblingNodeInSequence(
forward = true,
withBreakElement = false,
breakType = delimiterType,
barrier = rightBarrier
)?.psi?.endOffset ?: psi.endOffset
val treeParent = childElement.treeParent
val textRange = TextRange.create(startOffset, endOffset).shiftLeft(treeParent.startOffset)
return StringUtil.containsLineBreak(textRange.subSequence(treeParent.text))
}
private fun trailingCommaWrappingStrategy(
leftAnchor: IElementType,
rightAnchor: IElementType,
additionalCheck: (ASTNode) -> Boolean
): WrappingStrategy = { childElement ->
val childElementType = childElement.elementType
if (childElement.treeParent.withTrailingComma && (childElementType === rightAnchor ||
getPrevWithoutWhitespaceAndComments(childElement)?.elementType === leftAnchor ||
additionalCheck(childElement)
)
)
Wrap.createWrap(WrapType.ALWAYS, true)
else
null
}
} }
private fun ASTNode.isFirstParameter(): Boolean = treePrev?.elementType == LPAR private fun ASTNode.isFirstParameter(): Boolean = treePrev?.elementType == LPAR
@@ -1028,9 +1102,16 @@ private fun getPrevWithoutWhitespaceAndComments(pNode: ASTNode): ASTNode? {
} }
} }
private fun getWrappingStrategyForItemList(wrapType: Int, itemType: IElementType, wrapFirstElement: Boolean = false): WrappingStrategy { private fun getWrappingStrategyForItemList(
wrapType: Int,
itemType: IElementType,
wrapFirstElement: Boolean = false,
additionalWrap: WrappingStrategy? = null
): WrappingStrategy {
val itemWrap = Wrap.createWrap(wrapType, wrapFirstElement) val itemWrap = Wrap.createWrap(wrapType, wrapFirstElement)
return { childElement -> if (childElement.elementType === itemType) itemWrap else null } return { childElement ->
additionalWrap?.invoke(childElement) ?: if (childElement.elementType === itemType) itemWrap else null
}
} }
private fun getWrappingStrategyForItemList(wrapType: Int, itemTypes: TokenSet, wrapFirstElement: Boolean = false): WrappingStrategy { private fun getWrappingStrategyForItemList(wrapType: Int, itemTypes: TokenSet, wrapFirstElement: Boolean = false): WrappingStrategy {
@@ -190,32 +190,34 @@ fun createSpacingBuilder(settings: CodeStyleSettings, builderUtil: KotlinSpacing
) )
} }
inPosition(parent = VALUE_ARGUMENT_LIST, left = LPAR).customRule { parent, _, _ -> if (!kotlinCustomSettings.ALLOW_TRAILING_COMMA) {
if (kotlinCommonSettings.CALL_PARAMETERS_LPAREN_ON_NEXT_LINE && needWrapArgumentList(parent.requireNode().psi)) { inPosition(parent = VALUE_ARGUMENT_LIST, left = LPAR).customRule { parent, _, _ ->
Spacing.createDependentLFSpacing( if (kotlinCommonSettings.CALL_PARAMETERS_LPAREN_ON_NEXT_LINE && needWrapArgumentList(parent.requireNode().psi)) {
0, 0,
excludeLambdasAndObjects(parent),
commonCodeStyleSettings.KEEP_LINE_BREAKS,
commonCodeStyleSettings.KEEP_BLANK_LINES_IN_CODE
)
} else {
createSpacing(0)
}
}
inPosition(parent = VALUE_ARGUMENT_LIST, right = RPAR).customRule { parent, left, _ ->
when {
kotlinCommonSettings.CALL_PARAMETERS_RPAREN_ON_NEXT_LINE ->
Spacing.createDependentLFSpacing( Spacing.createDependentLFSpacing(
0, 0, 0, 0,
excludeLambdasAndObjects(parent), excludeLambdasAndObjects(parent),
commonCodeStyleSettings.KEEP_LINE_BREAKS, commonCodeStyleSettings.KEEP_LINE_BREAKS,
commonCodeStyleSettings.KEEP_BLANK_LINES_IN_CODE commonCodeStyleSettings.KEEP_BLANK_LINES_IN_CODE
) )
left.requireNode().elementType == COMMA -> // incomplete call being edited } else {
createSpacing(1)
else ->
createSpacing(0) createSpacing(0)
}
}
inPosition(parent = VALUE_ARGUMENT_LIST, right = RPAR).customRule { parent, left, _ ->
when {
kotlinCommonSettings.CALL_PARAMETERS_RPAREN_ON_NEXT_LINE ->
Spacing.createDependentLFSpacing(
0, 0,
excludeLambdasAndObjects(parent),
commonCodeStyleSettings.KEEP_LINE_BREAKS,
commonCodeStyleSettings.KEEP_BLANK_LINES_IN_CODE
)
left.requireNode().elementType == COMMA -> // incomplete call being edited
createSpacing(1)
else ->
createSpacing(0)
}
} }
} }
@@ -37,3 +37,5 @@ fun PsiElement.getLineCount(): Int {
return StringUtil.getLineBreakCount(text ?: "") + 1 return StringUtil.getLineBreakCount(text ?: "") + 1
} }
fun PsiElement.isMultiline() = getLineCount() > 1
@@ -10,16 +10,17 @@ import com.intellij.openapi.diagnostic.Logger
import com.intellij.openapi.util.TextRange import com.intellij.openapi.util.TextRange
import com.intellij.psi.PsiElement import com.intellij.psi.PsiElement
import com.intellij.psi.PsiFile import com.intellij.psi.PsiFile
import com.intellij.psi.codeStyle.CodeStyleManager
import com.intellij.psi.codeStyle.CodeStyleSettings import com.intellij.psi.codeStyle.CodeStyleSettings
import com.intellij.psi.impl.source.codeStyle.PostFormatProcessor import com.intellij.psi.impl.source.codeStyle.PostFormatProcessor
import com.intellij.psi.impl.source.codeStyle.PostFormatProcessorHelper import com.intellij.psi.impl.source.codeStyle.PostFormatProcessorHelper
import org.jetbrains.kotlin.idea.util.getLineCount import org.jetbrains.kotlin.idea.util.isMultiline
import org.jetbrains.kotlin.lexer.KtTokens import org.jetbrains.kotlin.lexer.KtTokens
import org.jetbrains.kotlin.psi.KtElement import org.jetbrains.kotlin.psi.*
import org.jetbrains.kotlin.psi.KtParameterList import org.jetbrains.kotlin.psi.psiUtil.createSmartPointer
import org.jetbrains.kotlin.psi.KtPsiFactory import org.jetbrains.kotlin.psi.psiUtil.getPrevSiblingIgnoringWhitespace
import org.jetbrains.kotlin.psi.KtTreeVisitorVoid
import org.jetbrains.kotlin.psi.psiUtil.getPrevSiblingIgnoringWhitespaceAndComments import org.jetbrains.kotlin.psi.psiUtil.getPrevSiblingIgnoringWhitespaceAndComments
import org.jetbrains.kotlin.psi.psiUtil.siblings
import org.jetbrains.kotlin.utils.addToStdlib.safeAs import org.jetbrains.kotlin.utils.addToStdlib.safeAs
class TrailingCommaPostFormatProcessor : PostFormatProcessor { class TrailingCommaPostFormatProcessor : PostFormatProcessor {
@@ -37,6 +38,10 @@ private class TrailingCommaVisitor(val settings: CodeStyleSettings) : KtTreeVisi
super.visitParameterList(list) super.visitParameterList(list)
} }
override fun visitValueArgumentList(list: KtValueArgumentList) = processCommaOwnerIfInRange(list) {
super.visitValueArgumentList(list)
}
private fun processCommaOwnerIfInRange(element: KtElement, preHook: () -> Unit = {}) { private fun processCommaOwnerIfInRange(element: KtElement, preHook: () -> Unit = {}) {
if (myPostProcessor.isElementPartlyInRange(element)) { if (myPostProcessor.isElementPartlyInRange(element)) {
preHook() preHook()
@@ -46,13 +51,47 @@ private class TrailingCommaVisitor(val settings: CodeStyleSettings) : KtTreeVisi
private fun processCommaOwner(parent: KtElement) { private fun processCommaOwner(parent: KtElement) {
val previous = parent.lastChild?.getPrevSiblingIgnoringWhitespaceAndComments() ?: return val previous = parent.lastChild?.getPrevSiblingIgnoringWhitespaceAndComments() ?: return
if (previous.safeAs<ASTNode>()?.elementType !== KtTokens.COMMA && val elementType = previous.safeAs<ASTNode>()?.elementType
settings.kotlinCustomSettings.ALLOW_TRAILING_COMMA && if (elementType === KtTokens.COMMA || settings.kotlinCustomSettings.ALLOW_TRAILING_COMMA && parent.isMultiline()) {
parent.getLineCount() > 1 // add a missing comma
) { if (elementType !== KtTokens.COMMA) {
val oldLength = parent.textLength changePsi(parent) { element, factory ->
parent.addAfter(KtPsiFactory(parent).createComma(), previous) element.addAfter(factory.createComma(), previous)
myPostProcessor.updateResultRange(oldLength, parent.textLength) }
}
correctCommaPosition(parent)
}
}
private fun changePsi(element: KtElement, update: (KtElement, KtPsiFactory) -> Unit) {
val oldLength = element.textLength
update(element, KtPsiFactory(element))
val result = CodeStyleManager.getInstance(element.project).reformat(element)
myPostProcessor.updateResultRange(oldLength, result.textLength)
}
private fun correctCommaPosition(parent: KtElement) {
val lPar = parent.children.firstOrNull() ?: return
val rPar = parent.children.lastOrNull() ?: return
val invalidElements = lPar.siblings(withItself = false).takeWhile { it != rPar }.mapNotNull {
if (it !is ASTNode || it.elementType != KtTokens.COMMA) return@mapNotNull null
val prevWithComment = it.getPrevSiblingIgnoringWhitespace(false)
val prevWithoutComment = it.getPrevSiblingIgnoringWhitespaceAndComments(false)
if (prevWithoutComment?.equals(prevWithComment) == false) {
it.createSmartPointer() to prevWithoutComment.createSmartPointer()
} else
null
}.toList()
if (invalidElements.isNotEmpty()) {
changePsi(parent) { element, factory ->
for ((pointToComma, pointToElement) in invalidElements) {
element.addAfter(factory.createComma(), pointToElement.element)
pointToComma.element?.delete()
}
}
} }
} }
+1 -1
View File
@@ -3,5 +3,5 @@
AppModule::class, AppModule::class,
DataModule::class, DataModule::class,
DomainModule::class DomainModule::class
] ],
) )
@@ -2,3 +2,4 @@ val x = foo("a",
"b") "b")
// SET_TRUE: CALL_PARAMETERS_LPAREN_ON_NEXT_LINE // SET_TRUE: CALL_PARAMETERS_LPAREN_ON_NEXT_LINE
// TRAILING_COMMA: false
@@ -3,3 +3,4 @@ val x = foo(
"b") "b")
// SET_TRUE: CALL_PARAMETERS_LPAREN_ON_NEXT_LINE // SET_TRUE: CALL_PARAMETERS_LPAREN_ON_NEXT_LINE
// TRAILING_COMMA: false
+1
View File
@@ -2,3 +2,4 @@ val x = foo("a",
"b") "b")
// SET_TRUE: CALL_PARAMETERS_LPAREN_ON_NEXT_LINE // SET_TRUE: CALL_PARAMETERS_LPAREN_ON_NEXT_LINE
// TRAILING_COMMA: false
@@ -2,3 +2,4 @@ val x = foo("a",
"b") "b")
// SET_TRUE: CALL_PARAMETERS_RPAREN_ON_NEXT_LINE // SET_TRUE: CALL_PARAMETERS_RPAREN_ON_NEXT_LINE
// TRAILING_COMMA: false
@@ -3,3 +3,4 @@ val x = foo("a",
) )
// SET_TRUE: CALL_PARAMETERS_RPAREN_ON_NEXT_LINE // SET_TRUE: CALL_PARAMETERS_RPAREN_ON_NEXT_LINE
// TRAILING_COMMA: false
+1
View File
@@ -2,3 +2,4 @@ val x = foo("a",
"b") "b")
// SET_TRUE: CALL_PARAMETERS_RPAREN_ON_NEXT_LINE // SET_TRUE: CALL_PARAMETERS_RPAREN_ON_NEXT_LINE
// TRAILING_COMMA: false
+22 -14
View File
@@ -37,13 +37,17 @@ val s2 = Shadow { // wdwd
val a = 42 val a = 42
} }
val s3 = Shadow(fun() { // wdwd val s3 = Shadow(
val a = 42 fun() { // wdwd
}) val a = 42
},
)
val s4 = Shadow(fun() { /* s */ val s4 = Shadow(
val a = 42 fun() { /* s */
}) val a = 42
},
)
val s5 = Shadow { -> val s5 = Shadow { ->
// wdwd // wdwd
@@ -55,15 +59,19 @@ val s6 = Shadow {
val a = 42 val a = 42
} }
val s7 = Shadow(fun() { val s7 = Shadow(
// wdwd fun() {
val a = 42 // wdwd
}) val a = 42
},
)
val s8 = Shadow(fun() { val s8 = Shadow(
// wdwd fun() {
val a = 42 // wdwd
}) val a = 42
},
)
val s9 = Shadow { -> /* s */ val s9 = Shadow { -> /* s */
val a = 42 val a = 42
+1 -1
View File
@@ -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
View File
@@ -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
View File
@@ -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,
) )
} }
+1 -1
View File
@@ -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
View File
@@ -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,6 +1,8 @@
fun test() { fun test() {
someTestLong(12, someTestLong(
13) 12,
13,
)
} }
// SET_TRUE: ALIGN_MULTILINE_PARAMETERS_IN_CALLS // SET_TRUE: ALIGN_MULTILINE_PARAMETERS_IN_CALLS
+4 -2
View File
@@ -13,8 +13,10 @@ val c = fun() = 4
fun test() = fun test() = 4 fun test() = fun test() = 4
fun test() { fun test() {
test(fun() { test(
}) fun() {
},
)
test(fun test() {}) test(fun test() {})
test(fun test() = 5) test(fun test() = 5)
+2 -1
View File
@@ -1,4 +1,5 @@
fun foo(@Deprecated("x") fun foo(
@Deprecated("x")
x: Int, x: Int,
@Deprecated("y") @Deprecated("y")
@Deprecated("z") @Deprecated("z")
@@ -41,10 +41,12 @@ val x8 = foo!!!!!!!!
val x9 = ((b!!)!!!!)!! val x9 = ((b!!)!!!!)!!
.f .f
val y = xyzzy(foo val y = xyzzy(
.bar() foo
.baz() .bar()
.quux()) .baz()
.quux(),
)
fun foo() { fun foo() {
foo foo
@@ -30,9 +30,11 @@ val x8 = foo!!!!!!!!.bar()
val x9 = ((b!!)!!!!)!!.f val x9 = ((b!!)!!!!)!!.f
val y = xyzzy(foo.bar() val y = xyzzy(
.baz() foo.bar()
.quux()) .baz()
.quux(),
)
fun foo() { fun foo() {
foo.bar() foo.bar()
@@ -12,12 +12,16 @@ 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() {
@@ -35,7 +39,7 @@ fun test3() {
fun test4() { fun test4() {
val abc = ArrayList<Int>().mapTo( val abc = ArrayList<Int>().mapTo(
LinkedHashSet() LinkedHashSet(),
) { ) {
it * 2 it * 2
} }
@@ -12,12 +12,16 @@ 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() {
@@ -35,7 +39,7 @@ fun test3() {
fun test4() { fun test4() {
val abc = ArrayList<Int>().mapTo( val abc = ArrayList<Int>().mapTo(
LinkedHashSet() LinkedHashSet(),
) { ) {
it * 2 it * 2
} }
+7 -5
View File
@@ -6,9 +6,11 @@ fun foo() {
finish() finish()
} }
FirebaseAuth.getInstance().addAuthStateListener(object : FirebaseAuth.AuthStateListener { FirebaseAuth.getInstance().addAuthStateListener(
override fun onAuthStateChanged(auth: FirebaseAuth) { object : FirebaseAuth.AuthStateListener {
// ... override fun onAuthStateChanged(auth: FirebaseAuth) {
} // ...
}) }
},
)
} }
@@ -10,12 +10,15 @@ fun foo() {
testtest(foofoo) testtest(foofoo)
testtesttesttest( testtesttesttest(
foofoofoofoofoofoofoofoofoofoofoofoo) foofoofoofoofoofoofoofoofoofoofoofoo,
)
testtest(foobar, barfoo) testtest(foobar, barfoo)
testtesttesttest(foofoo, testtesttesttest(
barbar, foofoo,
foobar, barbar,
barfoo) foobar,
barfoo,
)
} }
@@ -11,11 +11,15 @@ fun foo() {
testtesttesttest(foofoofoofoofoofoofoofoofoofoofoofoo) testtesttesttest(foofoofoofoofoofoofoofoofoofoofoofoo)
testtest(foobar, testtest(
barfoo) foobar,
barfoo,
)
testtesttesttest(foofoo, testtesttesttest(
barbar, foofoo,
foobar, barbar,
barfoo) foobar,
barfoo,
)
} }
@@ -10,12 +10,15 @@ fun foo() {
testtest(foofoo) testtest(foofoo)
testtesttesttest( testtesttesttest(
foofoofoofoofoofoofoofoofoofoofoofoo) foofoofoofoofoofoofoofoofoofoofoofoo,
)
testtest(foobar, barfoo) testtest(foobar, barfoo)
testtesttesttest(foofoo, testtesttesttest(
barbar, foofoo,
foobar, barbar,
barfoo) foobar,
barfoo,
)
} }
@@ -4,8 +4,10 @@
fun foo() { fun foo() {
foo(bar, baz) foo(bar, baz)
foo(object : Quux { foo(
override fun foo() { object : Quux {
} override fun foo() {
}) }
},
)
} }
+20 -11
View File
@@ -5,19 +5,28 @@ 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("B", Callable { useCallable(
println("Hello world") "B",
}) Callable {
println("Hello world")
},
)
useCallable("C", object : Callable<Unit> { useCallable(
override fun call() { "C",
println("Hello world") object : Callable<Unit> {
} override fun call() {
}) println("Hello world")
}
},
)
useCallable("B", fun() { useCallable(
println("Hello world") "B",
}) fun() {
println("Hello world")
},
)
} }
// SET_TRUE: CALL_PARAMETERS_LPAREN_ON_NEXT_LINE // SET_TRUE: CALL_PARAMETERS_LPAREN_ON_NEXT_LINE
@@ -12,10 +12,11 @@ fun testtesttesttest(foofoo: Int)
fun test(foo: Int, bar: Int) fun test(foo: Int, bar: Int)
fun testtesttesttest(foofoo: Int, fun testtesttesttest(
barbar: Int, foofoo: Int,
foobar: Int, barbar: Int,
barfoo: Int, foobar: Int,
barfoo: Int,
) )
fun test() { fun test() {
@@ -40,7 +41,8 @@ class LongLongLongLongNameCLass
class ShorName class ShorName
class SN class SN
class A(longLongLongLongNameCLass1: LongLongLongLongNameCLass, class A(
longLongLongLongNameCLass1: LongLongLongLongNameCLass,
longLongLongLongNameCLass2: LongLongLongLongNameCLass, longLongLongLongNameCLass2: LongLongLongLongNameCLass,
longLongLongLongNameCLass3: LongLongLongLongNameCLass, longLongLongLongNameCLass3: LongLongLongLongNameCLass,
) { ) {
@@ -52,18 +54,21 @@ class A(longLongLongLongNameCLass1: LongLongLongLongNameCLass,
} }
} }
class B(a: LongLongLongLongNameCLass, class B(
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(sn1: ShorName, class C(
sn1: ShorName,
sn2: ShorName, sn2: ShorName,
sn3: ShorName, sn3: ShorName,
sn4: ShorName, sn4: ShorName,
@@ -73,20 +78,22 @@ class C(sn1: 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(sn1: SN, class D(
sn1: SN,
sn2: SN, sn2: SN,
sn3: SN, sn3: SN,
sn4: SN, sn4: SN,
@@ -101,20 +108,21 @@ class D(sn1: 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,
) { ) {
} }
} }
@@ -10,26 +10,30 @@ fun testtest(foofoo: Int)
fun testtesttesttest(foofoo: Int) fun testtesttesttest(foofoo: Int)
fun test(foo: Int, fun test(
bar: Int, foo: Int,
bar: Int,
) )
fun testtesttesttest(foofoo: Int, fun testtesttesttest(
barbar: Int, foofoo: Int,
foobar: Int, barbar: Int,
barfoo: Int, foobar: Int,
barfoo: Int,
) )
fun testtesttesttest(foofoo: Int, fun testtesttesttest(
@Some barbar: Int, foofoo: Int,
foobar: Int, @Some barbar: Int,
barfoo: Int, foobar: Int,
barfoo: Int,
) )
fun testtesttesttest(@Some foofoo: Int, fun testtesttesttest(
@Some barbar: Int, @Some foofoo: Int,
@Some foobar: Int, @Some barbar: Int,
barfoo: Int, @Some foobar: Int,
barfoo: Int,
) )
fun test() { fun test() {
@@ -54,29 +58,34 @@ class LongLongLongLongNameCLass
class ShorName class ShorName
class SN class SN
class A(longLongLongLongNameCLass1: LongLongLongLongNameCLass, class A(
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(a: LongLongLongLongNameCLass, class B(
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(sn1: ShorName, class C(
sn1: ShorName,
sn2: ShorName, sn2: ShorName,
sn3: ShorName, sn3: ShorName,
sn4: ShorName, sn4: ShorName,
@@ -86,20 +95,22 @@ class C(sn1: 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(sn1: SN, class D(
sn1: SN,
sn2: SN, sn2: SN,
sn3: SN, sn3: SN,
sn4: SN, sn4: SN,
@@ -114,20 +125,21 @@ class D(sn1: 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,
) { ) {
} }
} }
@@ -147,14 +159,16 @@ class G(sn1: ShorName) {
} }
} }
class H(sn1: SN, class H(
sn1: SN,
sn2: SN, sn2: SN,
) { ) {
constructor(sn1: SN) { constructor(sn1: SN) {
} }
} }
class I(sn1: SN, class I(
sn1: SN,
@field:Some val sn2: SN, @field:Some val sn2: SN,
sn3: SN, sn3: SN,
sn4: SN, sn4: SN,
@@ -169,20 +183,21 @@ class I(sn1: 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,
) { ) {
} }
} }
@@ -43,7 +43,8 @@ class LongLongLongLongNameCLass
class ShorName class ShorName
class SN class SN
class A(longLongLongLongNameCLass1: LongLongLongLongNameCLass, class A(
longLongLongLongNameCLass1: LongLongLongLongNameCLass,
longLongLongLongNameCLass2: LongLongLongLongNameCLass, longLongLongLongNameCLass2: LongLongLongLongNameCLass,
longLongLongLongNameCLass3: LongLongLongLongNameCLass, longLongLongLongNameCLass3: LongLongLongLongNameCLass,
) { ) {
@@ -55,7 +56,8 @@ class A(longLongLongLongNameCLass1: LongLongLongLongNameCLass,
} }
} }
class B(a: LongLongLongLongNameCLass, class B(
a: LongLongLongLongNameCLass,
b: LongLongLongLongNameCLass, b: LongLongLongLongNameCLass,
c: LongLongLongLongNameCLass, c: LongLongLongLongNameCLass,
) { ) {
@@ -67,7 +69,8 @@ class B(a: LongLongLongLongNameCLass,
} }
} }
class C(sn1: ShorName, class C(
sn1: ShorName,
sn2: ShorName, sn2: ShorName,
sn3: ShorName, sn3: ShorName,
sn4: ShorName, sn4: ShorName,
@@ -77,20 +80,22 @@ class C(sn1: 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(sn1: SN, sn2: SN, class D(
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,
@@ -98,20 +103,21 @@ class D(sn1: SN, sn2: 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,
) { ) {
} }
} }
@@ -0,0 +1,278 @@
// SET_INT: CALL_PARAMETERS_WRAP = 4
// SET_TRUE: ALLOW_TRAILING_COMMA
fun foo() {
testtest(foofoo, foofoo, foofoo,
foofoo, bar)
testtest(
foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo,
bar
)
testtest(foofoo
)
testtest(
foofoo)
testtest(
foofoo
)
testtest(
foofoo,
)
testtest(foofoo, testtest(testtest(foofoo)))
testtest(
foofoo, fososos, testtest(testtest(foofoo)),
)
testtest(foofoo,
testtest(testtest(
foofoo,
)),
testsa)
testtest(foofoo,
seee,
testtest(testtest(
foofoo,
)),
testsa)
useCallable("A", Callable { println("Hello world") })
useCallable("B", "C", Callable {
println("Hello world")
}, Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") })
useCallable(
Callable { println("Hello world") },
)
useCallable(Callable { println("Hello world") }
)
useCallable(Callable { println("Hello world") }) {
}
useCallable(
Callable { println("Hello world") })
useCallable("A", { println("Hello world") })
useCallable("B", "C", {
println("Hello world")
}, {
println("Hello world")
})
useCallable({ println("Hello world") })
useCallable(
{ println("Hello world") },
)
useCallable({ println("Hello world") }
)
useCallable({ println("Hello world") }) {
}
useCallable(
{ println("Hello world") })
useCallable("A", foo() { println("Hello world") })
useCallable("B", "C", foo() {
println("Hello world")
}, foo() {
println("Hello world")
})
useCallable(foo() { println("Hello world") })
useCallable(
foo() { println("Hello world") },
)
useCallable(foo() { println("Hello world") }
)
useCallable(foo() { println("Hello world") }) {
}
useCallable(
foo() { println("Hello world") })
useCallable("A", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable("A", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable("B", "C", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
}, foo() {
println("Hello world")
})
useCallable(object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(object : Callable<Unit> {
override fun call() {
println("Hello world")
}
}
)
useCallable(object : Callable<Unit> {
override fun call() {
println("Hello world")
}
}) {
}
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
testtest(
foofoo, foofoo, foofoo, foofoo,
bar /*
*/, /* */ foo
)
testtest(/*
*/foofoo, foofoo, foofoo, /*
*/
foofoo, bar)
testtest(foofoo, foofoo, foofoo, foofoo, bar/*
*/)
testtest(foofoo, foofoo, foofoo, foofoo, bar // awdawda
)
testtest(foofoo, foofoo, foofoo, foofoo, /*
*/
bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(
foofoo,/**/
)
testtest(foofoo, foofoo, foofoo, foofoo/*
*/, /* */ bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(
foofoo,/**/
)
testtest(
foofoo, fososos,/*
*/
testtest(testtest(foofoo)),
)
testtest(foofoo,
testtest(testtest(
foofoo,
)), /**/
testsa)
testtest(foofoo,
testtest(testtest(
foofoo,
))/* */, /**/
testsa)
testtest(foofoo,
testtest(testtest(
foofoo,
))/*
*/,
testsa)
testtest(foofoo,
seee,
testtest(testtest(
foofoo,
)), /**/
testsa)
testtest(foofoo,
seee,
testtest(testtest(
foofoo,
)), /*
*/
testsa)
useCallable("B", "C", Callable {
println("Hello world")
}, /* */ Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") } // ffd
)
}
@@ -0,0 +1,367 @@
// SET_INT: CALL_PARAMETERS_WRAP = 4
// SET_TRUE: ALLOW_TRAILING_COMMA
fun foo() {
testtest(
foofoo, foofoo, foofoo,
foofoo, bar,
)
testtest(
foofoo, foofoo, foofoo, foofoo, bar,
)
testtest(
foofoo, foofoo, foofoo, foofoo, bar,
)
testtest(
foofoo, foofoo, foofoo, foofoo,
bar,
)
testtest(
foofoo,
)
testtest(
foofoo,
)
testtest(
foofoo,
)
testtest(
foofoo,
)
testtest(foofoo, testtest(testtest(foofoo)))
testtest(
foofoo, fososos, testtest(testtest(foofoo)),
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),
testsa,
)
testtest(
foofoo,
seee,
testtest(
testtest(
foofoo,
),
),
testsa,
)
useCallable("A", Callable { println("Hello world") })
useCallable(
"B", "C",
Callable {
println("Hello world")
},
Callable {
println("Hello world")
},
)
useCallable(Callable { println("Hello world") })
useCallable(
Callable { println("Hello world") },
)
useCallable(
Callable { println("Hello world") },
)
useCallable(Callable { println("Hello world") }) {
}
useCallable(
Callable { println("Hello world") },
)
useCallable("A", { println("Hello world") })
useCallable(
"B", "C",
{
println("Hello world")
},
{
println("Hello world")
},
)
useCallable({ println("Hello world") })
useCallable(
{ println("Hello world") },
)
useCallable(
{ println("Hello world") },
)
useCallable({ println("Hello world") }) {
}
useCallable(
{ println("Hello world") },
)
useCallable("A", foo() { println("Hello world") })
useCallable(
"B", "C",
foo() {
println("Hello world")
},
foo() {
println("Hello world")
},
)
useCallable(foo() { println("Hello world") })
useCallable(
foo() { println("Hello world") },
)
useCallable(
foo() { println("Hello world") },
)
useCallable(foo() { println("Hello world") }) {
}
useCallable(
foo() { println("Hello world") },
)
useCallable(
"A",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
"A",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
"B", "C",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
foo() {
println("Hello world")
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
) {
}
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
testtest(
foofoo, foofoo, foofoo, foofoo,
bar, /*
*/ /* */
foo,
)
testtest(
/*
*/
foofoo, foofoo, foofoo, /*
*/
foofoo, bar,
)
testtest(
foofoo, foofoo, foofoo, foofoo,
bar,/*
*/
)
testtest(
foofoo, foofoo, foofoo, foofoo, bar, // awdawda
)
testtest(
foofoo, foofoo, foofoo, foofoo, /*
*/
bar,
)
testtest(
foofoo, // fd
)
testtest(
/**/
foofoo,
)
testtest(
foofoo,/**/
)
testtest(
foofoo, foofoo, foofoo,
foofoo,/*
*/ /* */
bar,
)
testtest(
foofoo, // fd
)
testtest(
/**/
foofoo,
)
testtest(
foofoo,/**/
)
testtest(
foofoo, fososos,/*
*/
testtest(testtest(foofoo)),
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
), /**/
testsa,
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),/* */ /**/
testsa,
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),/*
*/
testsa,
)
testtest(
foofoo,
seee,
testtest(
testtest(
foofoo,
),
), /**/
testsa,
)
testtest(
foofoo,
seee,
testtest(
testtest(
foofoo,
),
), /*
*/
testsa,
)
useCallable(
"B", "C",
Callable {
println("Hello world")
}, /* */
Callable {
println("Hello world")
},
)
useCallable(
Callable { println("Hello world") }, // ffd
)
}
@@ -0,0 +1,200 @@
// SET_INT: CALL_PARAMETERS_WRAP = 4
// SET_TRUE: ALLOW_TRAILING_COMMA
fun foo() {
testtest(foofoo, foofoo, foofoo,
foofoo, bar)
testtest(
foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo,
bar
)
testtest(foofoo
)
testtest(
foofoo)
testtest(
foofoo
)
testtest(foofoo,)
testtest(foofoo, testtest(testtest(foofoo)))
testtest(foofoo, fososos, testtest(testtest(foofoo)),)
testtest(foofoo, testtest(testtest(foofoo,)), testsa)
testtest(foofoo, seee, testtest(testtest(foofoo,)), testsa)
useCallable("A", Callable { println("Hello world") })
useCallable("B", "C", Callable {
println("Hello world")
}, Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") })
useCallable(Callable { println("Hello world") },)
useCallable(Callable { println("Hello world") }
)
useCallable(Callable { println("Hello world") }){
}
useCallable(
Callable { println("Hello world") })
useCallable("A", { println("Hello world") })
useCallable("B", "C", {
println("Hello world")
}, {
println("Hello world")
})
useCallable({ println("Hello world") })
useCallable({ println("Hello world") },)
useCallable({ println("Hello world") }
)
useCallable({ println("Hello world") }){
}
useCallable(
{ println("Hello world") })
useCallable("A", foo() { println("Hello world") })
useCallable("B", "C", foo() {
println("Hello world")
}, foo() {
println("Hello world")
})
useCallable(foo() { println("Hello world") })
useCallable(foo() { println("Hello world") },)
useCallable(foo() { println("Hello world") }
)
useCallable(foo() { println("Hello world") }) {
}
useCallable(
foo() { println("Hello world") })
useCallable("A", object : Callable<Unit> { override fun call() { println("Hello world") } })
useCallable("A", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable("B", "C", object : Callable<Unit> { override fun call() { println("Hello world") } }, foo() {
println("Hello world")
})
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } })
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } },)
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } }
)
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } }) {
}
useCallable(
object : Callable<Unit> { override fun call() { println("Hello world") } })
testtest(
foofoo, foofoo, foofoo, foofoo,
bar /*
*/, /* */ foo
)
testtest(/*
*/foofoo, foofoo, foofoo, /*
*/
foofoo, bar)
testtest(foofoo, foofoo, foofoo, foofoo, bar/*
*/)
testtest(foofoo, foofoo, foofoo, foofoo, bar // awdawda
)
testtest(foofoo, foofoo, foofoo, foofoo, /*
*/
bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(foofoo,/**/)
testtest(foofoo, foofoo, foofoo, foofoo/*
*/ , /* */ bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(foofoo,/**/)
testtest(foofoo, fososos,/*
*/ testtest(testtest(foofoo)),)
testtest(foofoo, testtest(testtest(foofoo,)), /**/testsa)
testtest(foofoo, testtest(testtest(foofoo,))/* */ , /**/testsa)
testtest(foofoo, testtest(testtest(foofoo,))/*
*/ ,testsa)
testtest(foofoo, seee, testtest(testtest(foofoo,)), /**/testsa)
testtest(foofoo, seee, testtest(testtest(foofoo,)), /*
*/testsa)
useCallable("B", "C", Callable {
println("Hello world")
}, /* */ Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") } // ffd
)
}
@@ -0,0 +1,261 @@
// SET_INT: CALL_PARAMETERS_WRAP = 0
// SET_TRUE: ALLOW_TRAILING_COMMA
fun foo() {
testtest(foofoo, foofoo, foofoo,
foofoo, bar)
testtest(
foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo,
bar
)
testtest(foofoo
)
testtest(
foofoo)
testtest(
foofoo
)
testtest(
foofoo,
)
testtest(foofoo, testtest(testtest(foofoo)))
testtest(
foofoo, fososos, testtest(testtest(foofoo)),
)
testtest(foofoo, testtest(testtest(
foofoo,
)), testsa)
testtest(foofoo, seee, testtest(testtest(
foofoo,
)), testsa)
useCallable("A", Callable { println("Hello world") })
useCallable("B", "C", Callable {
println("Hello world")
}, Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") })
useCallable(
Callable { println("Hello world") },
)
useCallable(Callable { println("Hello world") }
)
useCallable(Callable { println("Hello world") }) {
}
useCallable(
Callable { println("Hello world") })
useCallable("A", { println("Hello world") })
useCallable("B", "C", {
println("Hello world")
}, {
println("Hello world")
})
useCallable({ println("Hello world") })
useCallable(
{ println("Hello world") },
)
useCallable({ println("Hello world") }
)
useCallable({ println("Hello world") }) {
}
useCallable(
{ println("Hello world") })
useCallable("A", foo() { println("Hello world") })
useCallable("B", "C", foo() {
println("Hello world")
}, foo() {
println("Hello world")
})
useCallable(foo() { println("Hello world") })
useCallable(
foo() { println("Hello world") },
)
useCallable(foo() { println("Hello world") }
)
useCallable(foo() { println("Hello world") }) {
}
useCallable(
foo() { println("Hello world") })
useCallable("A", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable("A", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable("B", "C", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
}, foo() {
println("Hello world")
})
useCallable(object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(object : Callable<Unit> {
override fun call() {
println("Hello world")
}
}
)
useCallable(object : Callable<Unit> {
override fun call() {
println("Hello world")
}
}) {
}
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
testtest(
foofoo, foofoo, foofoo, foofoo,
bar /*
*/, /* */ foo
)
testtest(/*
*/foofoo, foofoo, foofoo, /*
*/
foofoo, bar)
testtest(foofoo, foofoo, foofoo, foofoo, bar/*
*/)
testtest(foofoo, foofoo, foofoo, foofoo, bar // awdawda
)
testtest(foofoo, foofoo, foofoo, foofoo, /*
*/
bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(
foofoo,/**/
)
testtest(foofoo, foofoo, foofoo, foofoo/*
*/, /* */ bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(
foofoo,/**/
)
testtest(
foofoo, fososos,/*
*/
testtest(testtest(foofoo)),
)
testtest(foofoo, testtest(testtest(
foofoo,
)), /**/testsa)
testtest(foofoo, testtest(testtest(
foofoo,
))/* */, /**/testsa)
testtest(foofoo, testtest(testtest(
foofoo,
))/*
*/, testsa)
testtest(foofoo, seee, testtest(testtest(
foofoo,
)), /**/testsa)
testtest(foofoo, seee, testtest(testtest(
foofoo,
)), /*
*/testsa)
useCallable("B", "C", Callable {
println("Hello world")
}, /* */ Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") } // ffd
)
}
@@ -0,0 +1,364 @@
// SET_INT: CALL_PARAMETERS_WRAP = 0
// SET_TRUE: ALLOW_TRAILING_COMMA
fun foo() {
testtest(
foofoo, foofoo, foofoo,
foofoo, bar,
)
testtest(
foofoo, foofoo, foofoo, foofoo, bar,
)
testtest(
foofoo, foofoo, foofoo, foofoo, bar,
)
testtest(
foofoo, foofoo, foofoo, foofoo,
bar,
)
testtest(
foofoo,
)
testtest(
foofoo,
)
testtest(
foofoo,
)
testtest(
foofoo,
)
testtest(foofoo, testtest(testtest(foofoo)))
testtest(
foofoo, fososos, testtest(testtest(foofoo)),
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),
testsa,
)
testtest(
foofoo, seee,
testtest(
testtest(
foofoo,
),
),
testsa,
)
useCallable("A", Callable { println("Hello world") })
useCallable(
"B", "C",
Callable {
println("Hello world")
},
Callable {
println("Hello world")
},
)
useCallable(Callable { println("Hello world") })
useCallable(
Callable { println("Hello world") },
)
useCallable(
Callable { println("Hello world") },
)
useCallable(Callable { println("Hello world") }) {
}
useCallable(
Callable { println("Hello world") },
)
useCallable("A", { println("Hello world") })
useCallable(
"B", "C",
{
println("Hello world")
},
{
println("Hello world")
},
)
useCallable({ println("Hello world") })
useCallable(
{ println("Hello world") },
)
useCallable(
{ println("Hello world") },
)
useCallable({ println("Hello world") }) {
}
useCallable(
{ println("Hello world") },
)
useCallable("A", foo() { println("Hello world") })
useCallable(
"B", "C",
foo() {
println("Hello world")
},
foo() {
println("Hello world")
},
)
useCallable(foo() { println("Hello world") })
useCallable(
foo() { println("Hello world") },
)
useCallable(
foo() { println("Hello world") },
)
useCallable(foo() { println("Hello world") }) {
}
useCallable(
foo() { println("Hello world") },
)
useCallable(
"A",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
"A",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
"B", "C",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
foo() {
println("Hello world")
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
) {
}
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
testtest(
foofoo, foofoo, foofoo, foofoo,
bar, /*
*/ /* */
foo,
)
testtest(
/*
*/
foofoo, foofoo, foofoo, /*
*/
foofoo, bar,
)
testtest(
foofoo, foofoo, foofoo, foofoo,
bar,/*
*/
)
testtest(
foofoo, foofoo, foofoo, foofoo, bar, // awdawda
)
testtest(
foofoo, foofoo, foofoo, foofoo, /*
*/
bar,
)
testtest(
foofoo, // fd
)
testtest(
/**/
foofoo,
)
testtest(
foofoo,/**/
)
testtest(
foofoo, foofoo, foofoo,
foofoo,/*
*/ /* */
bar,
)
testtest(
foofoo, // fd
)
testtest(
/**/
foofoo,
)
testtest(
foofoo,/**/
)
testtest(
foofoo, fososos,/*
*/
testtest(testtest(foofoo)),
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
), /**/
testsa,
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),/* */ /**/
testsa,
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),/*
*/
testsa,
)
testtest(
foofoo, seee,
testtest(
testtest(
foofoo,
),
), /**/
testsa,
)
testtest(
foofoo, seee,
testtest(
testtest(
foofoo,
),
), /*
*/
testsa,
)
useCallable(
"B", "C",
Callable {
println("Hello world")
}, /* */
Callable {
println("Hello world")
},
)
useCallable(
Callable { println("Hello world") }, // ffd
)
}
@@ -0,0 +1,200 @@
// SET_INT: CALL_PARAMETERS_WRAP = 0
// SET_TRUE: ALLOW_TRAILING_COMMA
fun foo() {
testtest(foofoo, foofoo, foofoo,
foofoo, bar)
testtest(
foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo,
bar
)
testtest(foofoo
)
testtest(
foofoo)
testtest(
foofoo
)
testtest(foofoo,)
testtest(foofoo, testtest(testtest(foofoo)))
testtest(foofoo, fososos, testtest(testtest(foofoo)),)
testtest(foofoo, testtest(testtest(foofoo,)), testsa)
testtest(foofoo, seee, testtest(testtest(foofoo,)), testsa)
useCallable("A", Callable { println("Hello world") })
useCallable("B", "C", Callable {
println("Hello world")
}, Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") })
useCallable(Callable { println("Hello world") },)
useCallable(Callable { println("Hello world") }
)
useCallable(Callable { println("Hello world") }){
}
useCallable(
Callable { println("Hello world") })
useCallable("A", { println("Hello world") })
useCallable("B", "C", {
println("Hello world")
}, {
println("Hello world")
})
useCallable({ println("Hello world") })
useCallable({ println("Hello world") },)
useCallable({ println("Hello world") }
)
useCallable({ println("Hello world") }){
}
useCallable(
{ println("Hello world") })
useCallable("A", foo() { println("Hello world") })
useCallable("B", "C", foo() {
println("Hello world")
}, foo() {
println("Hello world")
})
useCallable(foo() { println("Hello world") })
useCallable(foo() { println("Hello world") },)
useCallable(foo() { println("Hello world") }
)
useCallable(foo() { println("Hello world") }) {
}
useCallable(
foo() { println("Hello world") })
useCallable("A", object : Callable<Unit> { override fun call() { println("Hello world") } })
useCallable("A", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable("B", "C", object : Callable<Unit> { override fun call() { println("Hello world") } }, foo() {
println("Hello world")
})
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } })
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } },)
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } }
)
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } }) {
}
useCallable(
object : Callable<Unit> { override fun call() { println("Hello world") } })
testtest(
foofoo, foofoo, foofoo, foofoo,
bar /*
*/, /* */ foo
)
testtest(/*
*/foofoo, foofoo, foofoo, /*
*/
foofoo, bar)
testtest(foofoo, foofoo, foofoo, foofoo, bar/*
*/)
testtest(foofoo, foofoo, foofoo, foofoo, bar // awdawda
)
testtest(foofoo, foofoo, foofoo, foofoo, /*
*/
bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(foofoo,/**/)
testtest(foofoo, foofoo, foofoo, foofoo/*
*/ , /* */ bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(foofoo,/**/)
testtest(foofoo, fososos,/*
*/ testtest(testtest(foofoo)),)
testtest(foofoo, testtest(testtest(foofoo,)), /**/testsa)
testtest(foofoo, testtest(testtest(foofoo,))/* */ , /**/testsa)
testtest(foofoo, testtest(testtest(foofoo,))/*
*/ ,testsa)
testtest(foofoo, seee, testtest(testtest(foofoo,)), /**/testsa)
testtest(foofoo, seee, testtest(testtest(foofoo,)), /*
*/testsa)
useCallable("B", "C", Callable {
println("Hello world")
}, /* */ Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") } // ffd
)
}
@@ -0,0 +1,348 @@
// SET_INT: CALL_PARAMETERS_WRAP = 2
// SET_TRUE: ALLOW_TRAILING_COMMA
fun foo() {
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),
testsa,
)
testtest(foofoo,
foofoo,
foofoo,
foofoo,
bar)
testtest(
foofoo,
foofoo,
foofoo,
foofoo,
bar
)
testtest(foofoo,
foofoo,
foofoo,
foofoo,
bar
)
testtest(foofoo,
foofoo,
foofoo,
foofoo,
bar
)
testtest(foofoo
)
testtest(
foofoo)
testtest(
foofoo
)
testtest(
foofoo,
)
testtest(foofoo,
testtest(testtest(foofoo)))
testtest(
foofoo,
fososos,
testtest(testtest(foofoo)),
)
testtest(foofoo,
testtest(testtest(
foofoo,
)),
testsa)
testtest(foofoo,
seee,
testtest(testtest(
foofoo,
)),
testsa)
useCallable("A",
Callable { println("Hello world") })
useCallable("B",
"C",
Callable {
println("Hello world")
},
Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") })
useCallable(
Callable { println("Hello world") },
)
useCallable(Callable { println("Hello world") }
)
useCallable(Callable { println("Hello world") }) {
}
useCallable(
Callable { println("Hello world") })
useCallable("A",
{ println("Hello world") })
useCallable("B",
"C",
{
println("Hello world")
},
{
println("Hello world")
})
useCallable({ println("Hello world") })
useCallable(
{ println("Hello world") },
)
useCallable({ println("Hello world") }
)
useCallable({ println("Hello world") }) {
}
useCallable(
{ println("Hello world") })
useCallable("A",
foo() { println("Hello world") })
useCallable("B",
"C",
foo() {
println("Hello world")
},
foo() {
println("Hello world")
})
useCallable(foo() { println("Hello world") })
useCallable(
foo() { println("Hello world") },
)
useCallable(foo() { println("Hello world") }
)
useCallable(foo() { println("Hello world") }) {
}
useCallable(
foo() { println("Hello world") })
useCallable("A",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable("A",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable("B",
"C",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
foo() {
println("Hello world")
})
useCallable(object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(object : Callable<Unit> {
override fun call() {
println("Hello world")
}
}
)
useCallable(object : Callable<Unit> {
override fun call() {
println("Hello world")
}
}) {
}
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
testtest(
foofoo,
foofoo,
foofoo,
foofoo,
bar /*
*/, /* */
foo
)
testtest(/*
*/foofoo,
foofoo,
foofoo, /*
*/
foofoo,
bar)
testtest(foofoo,
foofoo,
foofoo,
foofoo,
bar/*
*/)
testtest(foofoo,
foofoo,
foofoo,
foofoo,
bar // awdawda
)
testtest(foofoo,
foofoo,
foofoo,
foofoo, /*
*/
bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(
foofoo,/**/
)
testtest(foofoo,
foofoo,
foofoo,
foofoo/*
*/, /* */
bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(
foofoo,/**/
)
testtest(
foofoo,
fososos,/*
*/
testtest(testtest(foofoo)),
)
testtest(foofoo,
testtest(testtest(
foofoo,
)), /**/
testsa)
testtest(foofoo,
testtest(testtest(
foofoo,
))/* */, /**/
testsa)
testtest(foofoo,
testtest(testtest(
foofoo,
))/*
*/,
testsa)
testtest(foofoo,
seee,
testtest(testtest(
foofoo,
)), /**/
testsa)
testtest(foofoo,
seee,
testtest(testtest(
foofoo,
)), /*
*/
testsa)
useCallable("B",
"C",
Callable {
println("Hello world")
}, /* */
Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") } // ffd
)
}
@@ -0,0 +1,429 @@
// SET_INT: CALL_PARAMETERS_WRAP = 2
// SET_TRUE: ALLOW_TRAILING_COMMA
fun foo() {
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),
testsa,
)
testtest(
foofoo,
foofoo,
foofoo,
foofoo,
bar,
)
testtest(
foofoo,
foofoo,
foofoo,
foofoo,
bar,
)
testtest(
foofoo,
foofoo,
foofoo,
foofoo,
bar,
)
testtest(
foofoo,
foofoo,
foofoo,
foofoo,
bar,
)
testtest(
foofoo,
)
testtest(
foofoo,
)
testtest(
foofoo,
)
testtest(
foofoo,
)
testtest(
foofoo,
testtest(testtest(foofoo)),
)
testtest(
foofoo,
fososos,
testtest(testtest(foofoo)),
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),
testsa,
)
testtest(
foofoo,
seee,
testtest(
testtest(
foofoo,
),
),
testsa,
)
useCallable(
"A",
Callable { println("Hello world") },
)
useCallable(
"B",
"C",
Callable {
println("Hello world")
},
Callable {
println("Hello world")
},
)
useCallable(Callable { println("Hello world") })
useCallable(
Callable { println("Hello world") },
)
useCallable(
Callable { println("Hello world") },
)
useCallable(Callable { println("Hello world") }) {
}
useCallable(
Callable { println("Hello world") },
)
useCallable(
"A",
{ println("Hello world") },
)
useCallable(
"B",
"C",
{
println("Hello world")
},
{
println("Hello world")
},
)
useCallable({ println("Hello world") })
useCallable(
{ println("Hello world") },
)
useCallable(
{ println("Hello world") },
)
useCallable({ println("Hello world") }) {
}
useCallable(
{ println("Hello world") },
)
useCallable(
"A",
foo() { println("Hello world") },
)
useCallable(
"B",
"C",
foo() {
println("Hello world")
},
foo() {
println("Hello world")
},
)
useCallable(foo() { println("Hello world") })
useCallable(
foo() { println("Hello world") },
)
useCallable(
foo() { println("Hello world") },
)
useCallable(foo() { println("Hello world") }) {
}
useCallable(
foo() { println("Hello world") },
)
useCallable(
"A",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
"A",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
"B",
"C",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
foo() {
println("Hello world")
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
) {
}
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
testtest(
foofoo,
foofoo,
foofoo,
foofoo,
bar, /*
*/ /* */
foo,
)
testtest(
/*
*/
foofoo,
foofoo,
foofoo, /*
*/
foofoo,
bar,
)
testtest(
foofoo,
foofoo,
foofoo,
foofoo,
bar,/*
*/
)
testtest(
foofoo,
foofoo,
foofoo,
foofoo,
bar, // awdawda
)
testtest(
foofoo,
foofoo,
foofoo,
foofoo, /*
*/
bar,
)
testtest(
foofoo, // fd
)
testtest(
/**/
foofoo,
)
testtest(
foofoo,/**/
)
testtest(
foofoo,
foofoo,
foofoo,
foofoo,/*
*/ /* */
bar,
)
testtest(
foofoo, // fd
)
testtest(
/**/
foofoo,
)
testtest(
foofoo,/**/
)
testtest(
foofoo,
fososos,/*
*/
testtest(testtest(foofoo)),
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
), /**/
testsa,
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),/* */ /**/
testsa,
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),/*
*/
testsa,
)
testtest(
foofoo,
seee,
testtest(
testtest(
foofoo,
),
), /**/
testsa,
)
testtest(
foofoo,
seee,
testtest(
testtest(
foofoo,
),
), /*
*/
testsa,
)
useCallable(
"B",
"C",
Callable {
println("Hello world")
}, /* */
Callable {
println("Hello world")
},
)
useCallable(
Callable { println("Hello world") }, // ffd
)
}
@@ -0,0 +1,208 @@
// SET_INT: CALL_PARAMETERS_WRAP = 2
// SET_TRUE: ALLOW_TRAILING_COMMA
fun foo() {
testtest(foofoo,
testtest(testtest(
foofoo,
),
),
testsa,
)
testtest(foofoo, foofoo, foofoo,
foofoo, bar)
testtest(
foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo,
bar
)
testtest(foofoo
)
testtest(
foofoo)
testtest(
foofoo
)
testtest(foofoo,)
testtest(foofoo, testtest(testtest(foofoo)))
testtest(foofoo, fososos, testtest(testtest(foofoo)),)
testtest(foofoo, testtest(testtest(foofoo,)), testsa)
testtest(foofoo, seee, testtest(testtest(foofoo,)), testsa)
useCallable("A", Callable { println("Hello world") })
useCallable("B", "C", Callable {
println("Hello world")
}, Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") })
useCallable(Callable { println("Hello world") },)
useCallable(Callable { println("Hello world") }
)
useCallable(Callable { println("Hello world") }){
}
useCallable(
Callable { println("Hello world") })
useCallable("A", { println("Hello world") })
useCallable("B", "C", {
println("Hello world")
}, {
println("Hello world")
})
useCallable({ println("Hello world") })
useCallable({ println("Hello world") },)
useCallable({ println("Hello world") }
)
useCallable({ println("Hello world") }){
}
useCallable(
{ println("Hello world") })
useCallable("A", foo() { println("Hello world") })
useCallable("B", "C", foo() {
println("Hello world")
}, foo() {
println("Hello world")
})
useCallable(foo() { println("Hello world") })
useCallable(foo() { println("Hello world") },)
useCallable(foo() { println("Hello world") }
)
useCallable(foo() { println("Hello world") }) {
}
useCallable(
foo() { println("Hello world") })
useCallable("A", object : Callable<Unit> { override fun call() { println("Hello world") } })
useCallable("A", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable("B", "C", object : Callable<Unit> { override fun call() { println("Hello world") } }, foo() {
println("Hello world")
})
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } })
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } },)
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } }
)
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } }) {
}
useCallable(
object : Callable<Unit> { override fun call() { println("Hello world") } })
testtest(
foofoo, foofoo, foofoo, foofoo,
bar /*
*/, /* */ foo
)
testtest(/*
*/foofoo, foofoo, foofoo, /*
*/
foofoo, bar)
testtest(foofoo, foofoo, foofoo, foofoo, bar/*
*/)
testtest(foofoo, foofoo, foofoo, foofoo, bar // awdawda
)
testtest(foofoo, foofoo, foofoo, foofoo, /*
*/
bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(foofoo,/**/)
testtest(foofoo, foofoo, foofoo, foofoo/*
*/ , /* */ bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(foofoo,/**/)
testtest(foofoo, fososos,/*
*/ testtest(testtest(foofoo)),)
testtest(foofoo, testtest(testtest(foofoo,)), /**/testsa)
testtest(foofoo, testtest(testtest(foofoo,))/* */ , /**/testsa)
testtest(foofoo, testtest(testtest(foofoo,))/*
*/ ,testsa)
testtest(foofoo, seee, testtest(testtest(foofoo,)), /**/testsa)
testtest(foofoo, seee, testtest(testtest(foofoo,)), /*
*/testsa)
useCallable("B", "C", Callable {
println("Hello world")
}, /* */ Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") } // ffd
)
}
@@ -0,0 +1,261 @@
// SET_INT: CALL_PARAMETERS_WRAP = 1
// SET_TRUE: ALLOW_TRAILING_COMMA
fun foo() {
testtest(foofoo, foofoo, foofoo,
foofoo, bar)
testtest(
foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo,
bar
)
testtest(foofoo
)
testtest(
foofoo)
testtest(
foofoo
)
testtest(
foofoo,
)
testtest(foofoo, testtest(testtest(foofoo)))
testtest(
foofoo, fososos, testtest(testtest(foofoo)),
)
testtest(foofoo, testtest(testtest(
foofoo,
)), testsa)
testtest(foofoo, seee, testtest(testtest(
foofoo,
)), testsa)
useCallable("A", Callable { println("Hello world") })
useCallable("B", "C", Callable {
println("Hello world")
}, Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") })
useCallable(
Callable { println("Hello world") },
)
useCallable(Callable { println("Hello world") }
)
useCallable(Callable { println("Hello world") }) {
}
useCallable(
Callable { println("Hello world") })
useCallable("A", { println("Hello world") })
useCallable("B", "C", {
println("Hello world")
}, {
println("Hello world")
})
useCallable({ println("Hello world") })
useCallable(
{ println("Hello world") },
)
useCallable({ println("Hello world") }
)
useCallable({ println("Hello world") }) {
}
useCallable(
{ println("Hello world") })
useCallable("A", foo() { println("Hello world") })
useCallable("B", "C", foo() {
println("Hello world")
}, foo() {
println("Hello world")
})
useCallable(foo() { println("Hello world") })
useCallable(
foo() { println("Hello world") },
)
useCallable(foo() { println("Hello world") }
)
useCallable(foo() { println("Hello world") }) {
}
useCallable(
foo() { println("Hello world") })
useCallable("A", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable("A", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable("B", "C", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
}, foo() {
println("Hello world")
})
useCallable(object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(object : Callable<Unit> {
override fun call() {
println("Hello world")
}
}
)
useCallable(object : Callable<Unit> {
override fun call() {
println("Hello world")
}
}) {
}
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
testtest(
foofoo, foofoo, foofoo, foofoo,
bar /*
*/, /* */ foo
)
testtest(/*
*/foofoo, foofoo, foofoo, /*
*/
foofoo, bar)
testtest(foofoo, foofoo, foofoo, foofoo, bar/*
*/)
testtest(foofoo, foofoo, foofoo, foofoo, bar // awdawda
)
testtest(foofoo, foofoo, foofoo, foofoo, /*
*/
bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(
foofoo,/**/
)
testtest(foofoo, foofoo, foofoo, foofoo/*
*/, /* */ bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(
foofoo,/**/
)
testtest(
foofoo, fososos,/*
*/
testtest(testtest(foofoo)),
)
testtest(foofoo, testtest(testtest(
foofoo,
)), /**/testsa)
testtest(foofoo, testtest(testtest(
foofoo,
))/* */, /**/testsa)
testtest(foofoo, testtest(testtest(
foofoo,
))/*
*/, testsa)
testtest(foofoo, seee, testtest(testtest(
foofoo,
)), /**/testsa)
testtest(foofoo, seee, testtest(testtest(
foofoo,
)), /*
*/testsa)
useCallable("B", "C", Callable {
println("Hello world")
}, /* */ Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") } // ffd
)
}
@@ -0,0 +1,364 @@
// SET_INT: CALL_PARAMETERS_WRAP = 1
// SET_TRUE: ALLOW_TRAILING_COMMA
fun foo() {
testtest(
foofoo, foofoo, foofoo,
foofoo, bar,
)
testtest(
foofoo, foofoo, foofoo, foofoo, bar,
)
testtest(
foofoo, foofoo, foofoo, foofoo, bar,
)
testtest(
foofoo, foofoo, foofoo, foofoo,
bar,
)
testtest(
foofoo,
)
testtest(
foofoo,
)
testtest(
foofoo,
)
testtest(
foofoo,
)
testtest(foofoo, testtest(testtest(foofoo)))
testtest(
foofoo, fososos, testtest(testtest(foofoo)),
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),
testsa,
)
testtest(
foofoo, seee,
testtest(
testtest(
foofoo,
),
),
testsa,
)
useCallable("A", Callable { println("Hello world") })
useCallable(
"B", "C",
Callable {
println("Hello world")
},
Callable {
println("Hello world")
},
)
useCallable(Callable { println("Hello world") })
useCallable(
Callable { println("Hello world") },
)
useCallable(
Callable { println("Hello world") },
)
useCallable(Callable { println("Hello world") }) {
}
useCallable(
Callable { println("Hello world") },
)
useCallable("A", { println("Hello world") })
useCallable(
"B", "C",
{
println("Hello world")
},
{
println("Hello world")
},
)
useCallable({ println("Hello world") })
useCallable(
{ println("Hello world") },
)
useCallable(
{ println("Hello world") },
)
useCallable({ println("Hello world") }) {
}
useCallable(
{ println("Hello world") },
)
useCallable("A", foo() { println("Hello world") })
useCallable(
"B", "C",
foo() {
println("Hello world")
},
foo() {
println("Hello world")
},
)
useCallable(foo() { println("Hello world") })
useCallable(
foo() { println("Hello world") },
)
useCallable(
foo() { println("Hello world") },
)
useCallable(foo() { println("Hello world") }) {
}
useCallable(
foo() { println("Hello world") },
)
useCallable(
"A",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
"A",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
"B", "C",
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
foo() {
println("Hello world")
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
) {
}
useCallable(
object : Callable<Unit> {
override fun call() {
println("Hello world")
}
},
)
testtest(
foofoo, foofoo, foofoo, foofoo,
bar, /*
*/ /* */
foo,
)
testtest(
/*
*/
foofoo, foofoo, foofoo, /*
*/
foofoo, bar,
)
testtest(
foofoo, foofoo, foofoo, foofoo,
bar,/*
*/
)
testtest(
foofoo, foofoo, foofoo, foofoo, bar, // awdawda
)
testtest(
foofoo, foofoo, foofoo, foofoo, /*
*/
bar,
)
testtest(
foofoo, // fd
)
testtest(
/**/
foofoo,
)
testtest(
foofoo,/**/
)
testtest(
foofoo, foofoo, foofoo,
foofoo,/*
*/ /* */
bar,
)
testtest(
foofoo, // fd
)
testtest(
/**/
foofoo,
)
testtest(
foofoo,/**/
)
testtest(
foofoo, fososos,/*
*/
testtest(testtest(foofoo)),
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
), /**/
testsa,
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),/* */ /**/
testsa,
)
testtest(
foofoo,
testtest(
testtest(
foofoo,
),
),/*
*/
testsa,
)
testtest(
foofoo, seee,
testtest(
testtest(
foofoo,
),
), /**/
testsa,
)
testtest(
foofoo, seee,
testtest(
testtest(
foofoo,
),
), /*
*/
testsa,
)
useCallable(
"B", "C",
Callable {
println("Hello world")
}, /* */
Callable {
println("Hello world")
},
)
useCallable(
Callable { println("Hello world") }, // ffd
)
}
@@ -0,0 +1,200 @@
// SET_INT: CALL_PARAMETERS_WRAP = 1
// SET_TRUE: ALLOW_TRAILING_COMMA
fun foo() {
testtest(foofoo, foofoo, foofoo,
foofoo, bar)
testtest(
foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo, bar
)
testtest(foofoo, foofoo, foofoo, foofoo,
bar
)
testtest(foofoo
)
testtest(
foofoo)
testtest(
foofoo
)
testtest(foofoo,)
testtest(foofoo, testtest(testtest(foofoo)))
testtest(foofoo, fososos, testtest(testtest(foofoo)),)
testtest(foofoo, testtest(testtest(foofoo,)), testsa)
testtest(foofoo, seee, testtest(testtest(foofoo,)), testsa)
useCallable("A", Callable { println("Hello world") })
useCallable("B", "C", Callable {
println("Hello world")
}, Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") })
useCallable(Callable { println("Hello world") },)
useCallable(Callable { println("Hello world") }
)
useCallable(Callable { println("Hello world") }){
}
useCallable(
Callable { println("Hello world") })
useCallable("A", { println("Hello world") })
useCallable("B", "C", {
println("Hello world")
}, {
println("Hello world")
})
useCallable({ println("Hello world") })
useCallable({ println("Hello world") },)
useCallable({ println("Hello world") }
)
useCallable({ println("Hello world") }){
}
useCallable(
{ println("Hello world") })
useCallable("A", foo() { println("Hello world") })
useCallable("B", "C", foo() {
println("Hello world")
}, foo() {
println("Hello world")
})
useCallable(foo() { println("Hello world") })
useCallable(foo() { println("Hello world") },)
useCallable(foo() { println("Hello world") }
)
useCallable(foo() { println("Hello world") }) {
}
useCallable(
foo() { println("Hello world") })
useCallable("A", object : Callable<Unit> { override fun call() { println("Hello world") } })
useCallable("A", object : Callable<Unit> {
override fun call() {
println("Hello world")
}
})
useCallable("B", "C", object : Callable<Unit> { override fun call() { println("Hello world") } }, foo() {
println("Hello world")
})
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } })
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } },)
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } }
)
useCallable(object : Callable<Unit> { override fun call() { println("Hello world") } }) {
}
useCallable(
object : Callable<Unit> { override fun call() { println("Hello world") } })
testtest(
foofoo, foofoo, foofoo, foofoo,
bar /*
*/, /* */ foo
)
testtest(/*
*/foofoo, foofoo, foofoo, /*
*/
foofoo, bar)
testtest(foofoo, foofoo, foofoo, foofoo, bar/*
*/)
testtest(foofoo, foofoo, foofoo, foofoo, bar // awdawda
)
testtest(foofoo, foofoo, foofoo, foofoo, /*
*/
bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(foofoo,/**/)
testtest(foofoo, foofoo, foofoo, foofoo/*
*/ , /* */ bar
)
testtest(foofoo // fd
)
testtest( /**/
foofoo
)
testtest(foofoo,/**/)
testtest(foofoo, fososos,/*
*/ testtest(testtest(foofoo)),)
testtest(foofoo, testtest(testtest(foofoo,)), /**/testsa)
testtest(foofoo, testtest(testtest(foofoo,))/* */ , /**/testsa)
testtest(foofoo, testtest(testtest(foofoo,))/*
*/ ,testsa)
testtest(foofoo, seee, testtest(testtest(foofoo,)), /**/testsa)
testtest(foofoo, seee, testtest(testtest(foofoo,)), /*
*/testsa)
useCallable("B", "C", Callable {
println("Hello world")
}, /* */ Callable {
println("Hello world")
})
useCallable(Callable { println("Hello world") } // ffd
)
}
@@ -1,85 +0,0 @@
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String
) = Unit
fun c1(
x: String,
y: String,
) = Unit
fun d1(
x: String,
y: String,
) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String
) = Unit
fun c2(
x: String,
y: String,
z: String,
) = Unit
fun d2(
x: String,
y: String,
z: String,
) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String
) = Unit
fun c3(
x: String,
) = Unit
fun d3(
x: String,
) = Unit
fun a4(
x: String,
y: String,
z: String,
) = Unit
fun b4(
x: String,
y: String,
z: String
) = Unit
fun c4(
x: String,
y: String,
z: String,
) = Unit
fun d4(
x: String,
y: String,
z: String,
) = Unit
// SET_TRUE: ALLOW_TRAILING_COMMA
@@ -1,85 +0,0 @@
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String,
) = Unit
fun c1(
x: String,
y: String,
) = Unit
fun d1(
x: String,
y: String,
) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String,
) = Unit
fun c2(
x: String,
y: String,
z: String,
) = Unit
fun d2(
x: String,
y: String,
z: String,
) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String,
) = Unit
fun c3(
x: String,
) = Unit
fun d3(
x: String,
) = Unit
fun a4(
x: String,
y: String,
z: String,
) = Unit
fun b4(
x: String,
y: String,
z: String,
) = Unit
fun c4(
x: String,
y: String,
z: String,
) = Unit
fun d4(
x: String,
y: String,
z: String,
) = Unit
// SET_TRUE: ALLOW_TRAILING_COMMA
@@ -1,81 +0,0 @@
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String
) = Unit
fun c1(
x: String,
y: String,) = Unit
fun d1(
x: String,
y: String
,) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String
) = Unit
fun c2(
x: String,
y: String,
z: String,) = Unit
fun d2(
x: String,
y: String,
z: String
,) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String
) = Unit
fun c3(
x: String,) = Unit
fun d3(
x: String
,) = Unit
fun a4(
x: String
,
y: String,
z: String ,
) = Unit
fun b4(
x: String,
y: String,
z: String
) = Unit
fun c4(x: String,
y: String,
z: String ,) = Unit
fun d4(
x: String,
y: String,
z: String
, ) = Unit
// SET_TRUE: ALLOW_TRAILING_COMMA
@@ -1,75 +0,0 @@
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x
): Int = 42
val foo6: (Int) -> Int = fun(
x,
): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun(
x, y: Int, z,
): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z: Int
): Int = 43
val foo10 = fun(
x: Int,
y: Int,
z: Int
): Int = 43
val foo11 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun(
x: Int, y: Int, z: Int,
): Int = 43
// SET_TRUE: ALLOW_TRAILING_COMMA
@@ -1,75 +0,0 @@
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y,
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x,
): Int = 42
val foo6: (Int) -> Int = fun(
x,
): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun(
x, y: Int, z,
): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z: Int,
): Int = 43
val foo10 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo11 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun(
x: Int, y: Int, z: Int,
): Int = 43
// SET_TRUE: ALLOW_TRAILING_COMMA
@@ -1,69 +0,0 @@
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x
): Int = 42
val foo6: (Int) -> Int = fun(x,): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun (x, y: Int, z,): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun (
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun (
x,
y: Int,
z: Int
): Int = 43
val foo10 = fun (
x: Int,
y: Int,
z: Int
): Int = 43
val foo11 = fun (
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun (
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun (x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun (x: Int, y: Int, z: Int
,): Int = 43
// SET_TRUE: ALLOW_TRAILING_COMMA
@@ -0,0 +1,485 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String) {
this.x = x
this.y = y
this.z = z
}
}
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String
)
class C1(
val x: String,
val y: String,
)
class D1(
val x: String,
val y: String,
)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String
)
class C2(
val x: String,
val y: String,
val z: String,
)
class D2(
val x: String,
val y: String,
val z: String,
)
class A3(
val x: String,
)
class B3(
val x: String
)
class C3(
val x: String,
)
class D3(
val x: String,
)
class A4(
val x: String,
val y: String,
val z: String,
)
class B4(
val x: String,
val y: String,
val z: String
)
class C4(
val x: String,
val y: String,
val z: String,
)
class D4(
val x: String,
val y: String,
val z: String,
)
class E1(
val x: String, val y: String,
val z: String,
)
class E2(
val x: String, val y: String, val z: String
)
class C(
z: String, val v: Int, val x: Int =
42, val y: Int =
42
)
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x
): Int = 42
val foo6: (Int) -> Int = fun(
x,
): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun(
x, y: Int, z,
): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z: Int
): Int = 43
val foo10 = fun(
x: Int,
y: Int,
z: Int
): Int = 43
val foo11 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun(
x: Int, y: Int, z: Int,
): Int = 43
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String
) = Unit
fun c1(
x: String,
y: String,
) = Unit
fun d1(
x: String,
y: String,
) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String
) = Unit
fun c2(
x: String,
y: String,
z: String,
) = Unit
fun d2(
x: String,
y: String,
z: String,
) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String
) = Unit
fun c3(
x: String,
) = Unit
fun d3(
x: String,
) = Unit
fun a4(
x: String,
y: String,
z: String,
) = Unit
fun b4(
x: String,
y: String,
z: String
) = Unit
fun c4(
x: String,
y: String,
z: String,
) = Unit
fun d4(
x: String,
y: String,
z: String,
) = Unit
fun foo(
x: Int =
42
) {
}
class C(
val x: Int =
42
)
class G(
val x: String, val y: String
= "", /* */ val z: String
)
class G(
val x: String, val y: String
= "" /* */, /* */ val z: String
)
class H(
val x: String, /*
*/
val y: String,
val z: String,
)
class J(
val x: String, val y: String,
val z: String /*
*/,
)
class K(
val x: String, val y: String,
val z: String,
)
class L(
val x: String, val y: String, val z: String
)
// SET_TRUE: ALLOW_TRAILING_COMMA
// SET_INT: METHOD_PARAMETERS_WRAP = 4
@@ -0,0 +1,492 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String,
)
class C1(
val x: String,
val y: String,
)
class D1(
val x: String,
val y: String,
)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String,
)
class C2(
val x: String,
val y: String,
val z: String,
)
class D2(
val x: String,
val y: String,
val z: String,
)
class A3(
val x: String,
)
class B3(
val x: String,
)
class C3(
val x: String,
)
class D3(
val x: String,
)
class A4(
val x: String,
val y: String,
val z: String,
)
class B4(
val x: String,
val y: String,
val z: String,
)
class C4(
val x: String,
val y: String,
val z: String,
)
class D4(
val x: String,
val y: String,
val z: String,
)
class E1(
val x: String, val y: String,
val z: String,
)
class E2(
val x: String, val y: String, val z: String,
)
class C(
z: String, val v: Int,
val x: Int =
42,
val y: Int =
42,
)
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y,
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x,
): Int = 42
val foo6: (Int) -> Int = fun(
x,
): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun(
x, y: Int, z,
): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z: Int,
): Int = 43
val foo10 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo11 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun(
x: Int, y: Int, z: Int,
): Int = 43
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String,
) = Unit
fun c1(
x: String,
y: String,
) = Unit
fun d1(
x: String,
y: String,
) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String,
) = Unit
fun c2(
x: String,
y: String,
z: String,
) = Unit
fun d2(
x: String,
y: String,
z: String,
) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String,
) = Unit
fun c3(
x: String,
) = Unit
fun d3(
x: String,
) = Unit
fun a4(
x: String,
y: String,
z: String,
) = Unit
fun b4(
x: String,
y: String,
z: String,
) = Unit
fun c4(
x: String,
y: String,
z: String,
) = Unit
fun d4(
x: String,
y: String,
z: String,
) = Unit
fun foo(
x: Int =
42,
) {
}
class C(
val x: Int =
42,
)
class G(
val x: String,
val y: String
= "", /* */
val z: String,
)
class G(
val x: String,
val y: String
= "" /* */, /* */
val z: String,
)
class H(
val x: String, /*
*/
val y: String,
val z: String,
)
class J(
val x: String, val y: String,
val z: String /*
*/,
)
class K(
val x: String, val y: String,
val z: String,
)
class L(
val x: String, val y: String, val z: String,
)
// SET_TRUE: ALLOW_TRAILING_COMMA
// SET_INT: METHOD_PARAMETERS_WRAP = 4
@@ -0,0 +1,461 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String
,) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
,) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(x: String,) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String
,) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String) {
this.x = x
this.y = y
this.z = z
}
}
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String
)
class C1(
val x: String,
val y: String,)
class D1(
val x: String,
val y: String
,)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String
)
class C2(
val x: String,
val y: String,
val z: String,)
class D2(
val x: String,
val y: String,
val z: String
,)
class A3(
val x: String,
)
class B3(
val x: String
)
class C3(
val x: String,)
class D3(
val x: String
,)
class A4(
val x: String ,
val y: String,
val z: String ,
)
class B4(
val x: String,
val y: String,
val z: String
)
class C4(
val x: String,
val y: String,
val z: String ,)
class D4(
val x: String,
val y: String,
val z: String
, )
class E1(
val x: String, val y: String,
val z: String
, )
class E2(
val x: String, val y: String, val z: String
)
class C(
z: String, val v: Int, val x: Int =
42, val y: Int =
42
)
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x
): Int = 42
val foo6: (Int) -> Int = fun(x,): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun (x, y: Int, z,): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun (
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun (
x,
y: Int,
z: Int
): Int = 43
val foo10 = fun (
x: Int,
y: Int,
z: Int
): Int = 43
val foo11 = fun (
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun (
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun (x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun (x: Int, y: Int, z: Int
,): Int = 43
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String
) = Unit
fun c1(
x: String,
y: String,) = Unit
fun d1(
x: String,
y: String
,) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String
) = Unit
fun c2(
x: String,
y: String,
z: String,) = Unit
fun d2(
x: String,
y: String,
z: String
,) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String
) = Unit
fun c3(
x: String,) = Unit
fun d3(
x: String
,) = Unit
fun a4(
x: String
,
y: String,
z: String ,
) = Unit
fun b4(
x: String,
y: String,
z: String
) = Unit
fun c4(x: String,
y: String,
z: String ,) = Unit
fun d4(
x: String,
y: String,
z: String
, ) = Unit
fun foo(
x: Int =
42
) {
}
class C(
val x: Int =
42
)
class G(
val x: String, val y: String
= "", /* */ val z: String
)
class G(
val x: String, val y: String
= "" /* */, /* */ val z: String
)
class H(
val x: String, /*
*/ val y: String,
val z: String ,)
class J(
val x: String, val y: String , val z: String /*
*/
, )
class K(
val x: String, val y: String,
val z: String
, )
class L(
val x: String, val y: String, val z: String
)
// SET_TRUE: ALLOW_TRAILING_COMMA
// SET_INT: METHOD_PARAMETERS_WRAP = 4
@@ -0,0 +1,485 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String) {
this.x = x
this.y = y
this.z = z
}
}
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String
)
class C1(
val x: String,
val y: String,
)
class D1(
val x: String,
val y: String,
)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String
)
class C2(
val x: String,
val y: String,
val z: String,
)
class D2(
val x: String,
val y: String,
val z: String,
)
class A3(
val x: String,
)
class B3(
val x: String
)
class C3(
val x: String,
)
class D3(
val x: String,
)
class A4(
val x: String,
val y: String,
val z: String,
)
class B4(
val x: String,
val y: String,
val z: String
)
class C4(
val x: String,
val y: String,
val z: String,
)
class D4(
val x: String,
val y: String,
val z: String,
)
class E1(
val x: String, val y: String,
val z: String,
)
class E2(
val x: String, val y: String, val z: String
)
class C(
z: String, val v: Int, val x: Int =
42, val y: Int =
42
)
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x
): Int = 42
val foo6: (Int) -> Int = fun(
x,
): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun(
x, y: Int, z,
): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z: Int
): Int = 43
val foo10 = fun(
x: Int,
y: Int,
z: Int
): Int = 43
val foo11 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun(
x: Int, y: Int, z: Int,
): Int = 43
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String
) = Unit
fun c1(
x: String,
y: String,
) = Unit
fun d1(
x: String,
y: String,
) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String
) = Unit
fun c2(
x: String,
y: String,
z: String,
) = Unit
fun d2(
x: String,
y: String,
z: String,
) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String
) = Unit
fun c3(
x: String,
) = Unit
fun d3(
x: String,
) = Unit
fun a4(
x: String,
y: String,
z: String,
) = Unit
fun b4(
x: String,
y: String,
z: String
) = Unit
fun c4(
x: String,
y: String,
z: String,
) = Unit
fun d4(
x: String,
y: String,
z: String,
) = Unit
fun foo(
x: Int =
42
) {
}
class C(
val x: Int =
42
)
class G(
val x: String, val y: String
= "", /* */ val z: String
)
class G(
val x: String, val y: String
= "" /* */, /* */ val z: String
)
class H(
val x: String, /*
*/
val y: String,
val z: String,
)
class J(
val x: String, val y: String,
val z: String /*
*/,
)
class K(
val x: String, val y: String,
val z: String,
)
class L(
val x: String, val y: String, val z: String
)
// SET_TRUE: ALLOW_TRAILING_COMMA
// SET_INT: METHOD_PARAMETERS_WRAP = 0
@@ -0,0 +1,492 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String,
)
class C1(
val x: String,
val y: String,
)
class D1(
val x: String,
val y: String,
)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String,
)
class C2(
val x: String,
val y: String,
val z: String,
)
class D2(
val x: String,
val y: String,
val z: String,
)
class A3(
val x: String,
)
class B3(
val x: String,
)
class C3(
val x: String,
)
class D3(
val x: String,
)
class A4(
val x: String,
val y: String,
val z: String,
)
class B4(
val x: String,
val y: String,
val z: String,
)
class C4(
val x: String,
val y: String,
val z: String,
)
class D4(
val x: String,
val y: String,
val z: String,
)
class E1(
val x: String, val y: String,
val z: String,
)
class E2(
val x: String, val y: String, val z: String,
)
class C(
z: String, val v: Int,
val x: Int =
42,
val y: Int =
42,
)
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y,
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x,
): Int = 42
val foo6: (Int) -> Int = fun(
x,
): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun(
x, y: Int, z,
): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z: Int,
): Int = 43
val foo10 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo11 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun(
x: Int, y: Int, z: Int,
): Int = 43
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String,
) = Unit
fun c1(
x: String,
y: String,
) = Unit
fun d1(
x: String,
y: String,
) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String,
) = Unit
fun c2(
x: String,
y: String,
z: String,
) = Unit
fun d2(
x: String,
y: String,
z: String,
) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String,
) = Unit
fun c3(
x: String,
) = Unit
fun d3(
x: String,
) = Unit
fun a4(
x: String,
y: String,
z: String,
) = Unit
fun b4(
x: String,
y: String,
z: String,
) = Unit
fun c4(
x: String,
y: String,
z: String,
) = Unit
fun d4(
x: String,
y: String,
z: String,
) = Unit
fun foo(
x: Int =
42,
) {
}
class C(
val x: Int =
42,
)
class G(
val x: String,
val y: String
= "", /* */
val z: String,
)
class G(
val x: String,
val y: String
= "" /* */, /* */
val z: String,
)
class H(
val x: String, /*
*/
val y: String,
val z: String,
)
class J(
val x: String, val y: String,
val z: String /*
*/,
)
class K(
val x: String, val y: String,
val z: String,
)
class L(
val x: String, val y: String, val z: String,
)
// SET_TRUE: ALLOW_TRAILING_COMMA
// SET_INT: METHOD_PARAMETERS_WRAP = 0
@@ -0,0 +1,461 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String
,) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
,) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(x: String,) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String
,) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String) {
this.x = x
this.y = y
this.z = z
}
}
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String
)
class C1(
val x: String,
val y: String,)
class D1(
val x: String,
val y: String
,)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String
)
class C2(
val x: String,
val y: String,
val z: String,)
class D2(
val x: String,
val y: String,
val z: String
,)
class A3(
val x: String,
)
class B3(
val x: String
)
class C3(
val x: String,)
class D3(
val x: String
,)
class A4(
val x: String ,
val y: String,
val z: String ,
)
class B4(
val x: String,
val y: String,
val z: String
)
class C4(
val x: String,
val y: String,
val z: String ,)
class D4(
val x: String,
val y: String,
val z: String
, )
class E1(
val x: String, val y: String,
val z: String
, )
class E2(
val x: String, val y: String, val z: String
)
class C(
z: String, val v: Int, val x: Int =
42, val y: Int =
42
)
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x
): Int = 42
val foo6: (Int) -> Int = fun(x,): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun (x, y: Int, z,): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun (
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun (
x,
y: Int,
z: Int
): Int = 43
val foo10 = fun (
x: Int,
y: Int,
z: Int
): Int = 43
val foo11 = fun (
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun (
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun (x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun (x: Int, y: Int, z: Int
,): Int = 43
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String
) = Unit
fun c1(
x: String,
y: String,) = Unit
fun d1(
x: String,
y: String
,) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String
) = Unit
fun c2(
x: String,
y: String,
z: String,) = Unit
fun d2(
x: String,
y: String,
z: String
,) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String
) = Unit
fun c3(
x: String,) = Unit
fun d3(
x: String
,) = Unit
fun a4(
x: String
,
y: String,
z: String ,
) = Unit
fun b4(
x: String,
y: String,
z: String
) = Unit
fun c4(x: String,
y: String,
z: String ,) = Unit
fun d4(
x: String,
y: String,
z: String
, ) = Unit
fun foo(
x: Int =
42
) {
}
class C(
val x: Int =
42
)
class G(
val x: String, val y: String
= "", /* */ val z: String
)
class G(
val x: String, val y: String
= "" /* */, /* */ val z: String
)
class H(
val x: String, /*
*/ val y: String,
val z: String ,)
class J(
val x: String, val y: String , val z: String /*
*/
, )
class K(
val x: String, val y: String,
val z: String
, )
class L(
val x: String, val y: String, val z: String
)
// SET_TRUE: ALLOW_TRAILING_COMMA
// SET_INT: METHOD_PARAMETERS_WRAP = 0
@@ -0,0 +1,510 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String) {
this.x = x
this.y = y
this.z = z
}
}
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String
)
class C1(
val x: String,
val y: String,
)
class D1(
val x: String,
val y: String,
)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String
)
class C2(
val x: String,
val y: String,
val z: String,
)
class D2(
val x: String,
val y: String,
val z: String,
)
class A3(
val x: String,
)
class B3(
val x: String
)
class C3(
val x: String,
)
class D3(
val x: String,
)
class A4(
val x: String,
val y: String,
val z: String,
)
class B4(
val x: String,
val y: String,
val z: String
)
class C4(
val x: String,
val y: String,
val z: String,
)
class D4(
val x: String,
val y: String,
val z: String,
)
class E1(
val x: String,
val y: String,
val z: String,
)
class E2(
val x: String,
val y: String,
val z: String
)
class C(
z: String,
val v: Int,
val x: Int =
42,
val y: Int =
42
)
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x,
y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x
): Int = 42
val foo6: (Int) -> Int = fun(
x,
): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z,
): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z: Int
): Int = 43
val foo10 = fun(
x: Int,
y: Int,
z: Int
): Int = 43
val foo11 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo13 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo14 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String
) = Unit
fun c1(
x: String,
y: String,
) = Unit
fun d1(
x: String,
y: String,
) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String
) = Unit
fun c2(
x: String,
y: String,
z: String,
) = Unit
fun d2(
x: String,
y: String,
z: String,
) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String
) = Unit
fun c3(
x: String,
) = Unit
fun d3(
x: String,
) = Unit
fun a4(
x: String,
y: String,
z: String,
) = Unit
fun b4(
x: String,
y: String,
z: String
) = Unit
fun c4(
x: String,
y: String,
z: String,
) = Unit
fun d4(
x: String,
y: String,
z: String,
) = Unit
fun foo(
x: Int =
42
) {
}
class C(
val x: Int =
42
)
class G(
val x: String,
val y: String
= "", /* */
val z: String
)
class G(
val x: String,
val y: String
= "" /* */, /* */
val z: String
)
class H(
val x: String, /*
*/
val y: String,
val z: String,
)
class J(
val x: String,
val y: String,
val z: String /*
*/,
)
class K(
val x: String,
val y: String,
val z: String,
)
class L(
val x: String,
val y: String,
val z: String
)
// SET_TRUE: ALLOW_TRAILING_COMMA
// SET_INT: METHOD_PARAMETERS_WRAP = 2
@@ -0,0 +1,511 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String,
)
class C1(
val x: String,
val y: String,
)
class D1(
val x: String,
val y: String,
)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String,
)
class C2(
val x: String,
val y: String,
val z: String,
)
class D2(
val x: String,
val y: String,
val z: String,
)
class A3(
val x: String,
)
class B3(
val x: String,
)
class C3(
val x: String,
)
class D3(
val x: String,
)
class A4(
val x: String,
val y: String,
val z: String,
)
class B4(
val x: String,
val y: String,
val z: String,
)
class C4(
val x: String,
val y: String,
val z: String,
)
class D4(
val x: String,
val y: String,
val z: String,
)
class E1(
val x: String,
val y: String,
val z: String,
)
class E2(
val x: String,
val y: String,
val z: String,
)
class C(
z: String,
val v: Int,
val x: Int =
42,
val y: Int =
42,
)
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y,
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x,
y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x,
): Int = 42
val foo6: (Int) -> Int = fun(
x,
): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z,
): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z: Int,
): Int = 43
val foo10 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo11 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo13 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo14 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String,
) = Unit
fun c1(
x: String,
y: String,
) = Unit
fun d1(
x: String,
y: String,
) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String,
) = Unit
fun c2(
x: String,
y: String,
z: String,
) = Unit
fun d2(
x: String,
y: String,
z: String,
) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String,
) = Unit
fun c3(
x: String,
) = Unit
fun d3(
x: String,
) = Unit
fun a4(
x: String,
y: String,
z: String,
) = Unit
fun b4(
x: String,
y: String,
z: String,
) = Unit
fun c4(
x: String,
y: String,
z: String,
) = Unit
fun d4(
x: String,
y: String,
z: String,
) = Unit
fun foo(
x: Int =
42,
) {
}
class C(
val x: Int =
42,
)
class G(
val x: String,
val y: String
= "", /* */
val z: String,
)
class G(
val x: String,
val y: String
= "" /* */, /* */
val z: String,
)
class H(
val x: String, /*
*/
val y: String,
val z: String,
)
class J(
val x: String,
val y: String,
val z: String /*
*/,
)
class K(
val x: String,
val y: String,
val z: String,
)
class L(
val x: String,
val y: String,
val z: String,
)
// SET_TRUE: ALLOW_TRAILING_COMMA
// SET_INT: METHOD_PARAMETERS_WRAP = 2
@@ -0,0 +1,461 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String
,) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
,) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(x: String,) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String
,) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String) {
this.x = x
this.y = y
this.z = z
}
}
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String
)
class C1(
val x: String,
val y: String,)
class D1(
val x: String,
val y: String
,)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String
)
class C2(
val x: String,
val y: String,
val z: String,)
class D2(
val x: String,
val y: String,
val z: String
,)
class A3(
val x: String,
)
class B3(
val x: String
)
class C3(
val x: String,)
class D3(
val x: String
,)
class A4(
val x: String ,
val y: String,
val z: String ,
)
class B4(
val x: String,
val y: String,
val z: String
)
class C4(
val x: String,
val y: String,
val z: String ,)
class D4(
val x: String,
val y: String,
val z: String
, )
class E1(
val x: String, val y: String,
val z: String
, )
class E2(
val x: String, val y: String, val z: String
)
class C(
z: String, val v: Int, val x: Int =
42, val y: Int =
42
)
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x
): Int = 42
val foo6: (Int) -> Int = fun(x,): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun (x, y: Int, z,): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun (
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun (
x,
y: Int,
z: Int
): Int = 43
val foo10 = fun (
x: Int,
y: Int,
z: Int
): Int = 43
val foo11 = fun (
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun (
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun (x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun (x: Int, y: Int, z: Int
,): Int = 43
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String
) = Unit
fun c1(
x: String,
y: String,) = Unit
fun d1(
x: String,
y: String
,) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String
) = Unit
fun c2(
x: String,
y: String,
z: String,) = Unit
fun d2(
x: String,
y: String,
z: String
,) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String
) = Unit
fun c3(
x: String,) = Unit
fun d3(
x: String
,) = Unit
fun a4(
x: String
,
y: String,
z: String ,
) = Unit
fun b4(
x: String,
y: String,
z: String
) = Unit
fun c4(x: String,
y: String,
z: String ,) = Unit
fun d4(
x: String,
y: String,
z: String
, ) = Unit
fun foo(
x: Int =
42
) {
}
class C(
val x: Int =
42
)
class G(
val x: String, val y: String
= "", /* */ val z: String
)
class G(
val x: String, val y: String
= "" /* */, /* */ val z: String
)
class H(
val x: String, /*
*/ val y: String,
val z: String ,)
class J(
val x: String, val y: String , val z: String /*
*/
, )
class K(
val x: String, val y: String,
val z: String
, )
class L(
val x: String, val y: String, val z: String
)
// SET_TRUE: ALLOW_TRAILING_COMMA
// SET_INT: METHOD_PARAMETERS_WRAP = 2
@@ -0,0 +1,485 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String) {
this.x = x
this.y = y
this.z = z
}
}
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String
)
class C1(
val x: String,
val y: String,
)
class D1(
val x: String,
val y: String,
)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String
)
class C2(
val x: String,
val y: String,
val z: String,
)
class D2(
val x: String,
val y: String,
val z: String,
)
class A3(
val x: String,
)
class B3(
val x: String
)
class C3(
val x: String,
)
class D3(
val x: String,
)
class A4(
val x: String,
val y: String,
val z: String,
)
class B4(
val x: String,
val y: String,
val z: String
)
class C4(
val x: String,
val y: String,
val z: String,
)
class D4(
val x: String,
val y: String,
val z: String,
)
class E1(
val x: String, val y: String,
val z: String,
)
class E2(
val x: String, val y: String, val z: String
)
class C(
z: String, val v: Int, val x: Int =
42, val y: Int =
42
)
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x
): Int = 42
val foo6: (Int) -> Int = fun(
x,
): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun(
x, y: Int, z,
): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z: Int
): Int = 43
val foo10 = fun(
x: Int,
y: Int,
z: Int
): Int = 43
val foo11 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun(
x: Int, y: Int, z: Int,
): Int = 43
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String
) = Unit
fun c1(
x: String,
y: String,
) = Unit
fun d1(
x: String,
y: String,
) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String
) = Unit
fun c2(
x: String,
y: String,
z: String,
) = Unit
fun d2(
x: String,
y: String,
z: String,
) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String
) = Unit
fun c3(
x: String,
) = Unit
fun d3(
x: String,
) = Unit
fun a4(
x: String,
y: String,
z: String,
) = Unit
fun b4(
x: String,
y: String,
z: String
) = Unit
fun c4(
x: String,
y: String,
z: String,
) = Unit
fun d4(
x: String,
y: String,
z: String,
) = Unit
fun foo(
x: Int =
42
) {
}
class C(
val x: Int =
42
)
class G(
val x: String, val y: String
= "", /* */ val z: String
)
class G(
val x: String, val y: String
= "" /* */, /* */ val z: String
)
class H(
val x: String, /*
*/
val y: String,
val z: String,
)
class J(
val x: String, val y: String,
val z: String /*
*/,
)
class K(
val x: String, val y: String,
val z: String,
)
class L(
val x: String, val y: String, val z: String
)
// SET_TRUE: ALLOW_TRAILING_COMMA
// SET_INT: METHOD_PARAMETERS_WRAP = 1
@@ -0,0 +1,492 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String,
)
class C1(
val x: String,
val y: String,
)
class D1(
val x: String,
val y: String,
)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String,
)
class C2(
val x: String,
val y: String,
val z: String,
)
class D2(
val x: String,
val y: String,
val z: String,
)
class A3(
val x: String,
)
class B3(
val x: String,
)
class C3(
val x: String,
)
class D3(
val x: String,
)
class A4(
val x: String,
val y: String,
val z: String,
)
class B4(
val x: String,
val y: String,
val z: String,
)
class C4(
val x: String,
val y: String,
val z: String,
)
class D4(
val x: String,
val y: String,
val z: String,
)
class E1(
val x: String, val y: String,
val z: String,
)
class E2(
val x: String, val y: String, val z: String,
)
class C(
z: String, val v: Int,
val x: Int =
42,
val y: Int =
42,
)
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y,
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x,
): Int = 42
val foo6: (Int) -> Int = fun(
x,
): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun(
x, y: Int, z,
): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun(
x,
y: Int,
z: Int,
): Int = 43
val foo10 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo11 = fun(
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun(
x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun(
x: Int, y: Int, z: Int,
): Int = 43
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String,
) = Unit
fun c1(
x: String,
y: String,
) = Unit
fun d1(
x: String,
y: String,
) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String,
) = Unit
fun c2(
x: String,
y: String,
z: String,
) = Unit
fun d2(
x: String,
y: String,
z: String,
) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String,
) = Unit
fun c3(
x: String,
) = Unit
fun d3(
x: String,
) = Unit
fun a4(
x: String,
y: String,
z: String,
) = Unit
fun b4(
x: String,
y: String,
z: String,
) = Unit
fun c4(
x: String,
y: String,
z: String,
) = Unit
fun d4(
x: String,
y: String,
z: String,
) = Unit
fun foo(
x: Int =
42,
) {
}
class C(
val x: Int =
42,
)
class G(
val x: String,
val y: String
= "", /* */
val z: String,
)
class G(
val x: String,
val y: String
= "" /* */, /* */
val z: String,
)
class H(
val x: String, /*
*/
val y: String,
val z: String,
)
class J(
val x: String, val y: String,
val z: String /*
*/,
)
class K(
val x: String, val y: String,
val z: String,
)
class L(
val x: String, val y: String, val z: String,
)
// SET_TRUE: ALLOW_TRAILING_COMMA
// SET_INT: METHOD_PARAMETERS_WRAP = 1
@@ -0,0 +1,461 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String
,) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
,) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(x: String,) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String
,) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String) {
this.x = x
this.y = y
this.z = z
}
}
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String
)
class C1(
val x: String,
val y: String,)
class D1(
val x: String,
val y: String
,)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String
)
class C2(
val x: String,
val y: String,
val z: String,)
class D2(
val x: String,
val y: String,
val z: String
,)
class A3(
val x: String,
)
class B3(
val x: String
)
class C3(
val x: String,)
class D3(
val x: String
,)
class A4(
val x: String ,
val y: String,
val z: String ,
)
class B4(
val x: String,
val y: String,
val z: String
)
class C4(
val x: String,
val y: String,
val z: String ,)
class D4(
val x: String,
val y: String,
val z: String
, )
class E1(
val x: String, val y: String,
val z: String
, )
class E2(
val x: String, val y: String, val z: String
)
class C(
z: String, val v: Int, val x: Int =
42, val y: Int =
42
)
val foo1: (Int, Int) -> Int = fun(
x,
y,
): Int = 42
val foo2: (Int, Int) -> Int = fun(
x,
y
): Int {
return x + y
}
val foo3: (Int, Int) -> Int = fun(
x, y,
): Int {
return x + y
}
val foo4: (Int) -> Int = fun(
x,
): Int = 42
val foo5: (Int) -> Int = fun(
x
): Int = 42
val foo6: (Int) -> Int = fun(x,): Int = 42
val foo7: (Int) -> Int = fun(x): Int = 42
val foo8: (Int, Int, Int) -> Int = fun (x, y: Int, z,): Int {
return x + y
}
val foo9: (Int, Int, Int) -> Int = fun (
x,
y: Int,
z,
): Int = 42
val foo10: (Int, Int, Int) -> Int = fun (
x,
y: Int,
z: Int
): Int = 43
val foo10 = fun (
x: Int,
y: Int,
z: Int
): Int = 43
val foo11 = fun (
x: Int,
y: Int,
z: Int,
): Int = 43
val foo12 = fun (
x: Int, y: Int, z: Int,
): Int = 43
val foo13 = fun (x: Int, y: Int, z: Int,
): Int = 43
val foo14 = fun (x: Int, y: Int, z: Int
,): Int = 43
fun a1(
x: String,
y: String,
) = Unit
fun b1(
x: String,
y: String
) = Unit
fun c1(
x: String,
y: String,) = Unit
fun d1(
x: String,
y: String
,) = Unit
fun a2(
x: String,
y: String,
z: String,
) = Unit
fun b2(
x: String,
y: String,
z: String
) = Unit
fun c2(
x: String,
y: String,
z: String,) = Unit
fun d2(
x: String,
y: String,
z: String
,) = Unit
fun a3(
x: String,
) = Unit
fun b3(
x: String
) = Unit
fun c3(
x: String,) = Unit
fun d3(
x: String
,) = Unit
fun a4(
x: String
,
y: String,
z: String ,
) = Unit
fun b4(
x: String,
y: String,
z: String
) = Unit
fun c4(x: String,
y: String,
z: String ,) = Unit
fun d4(
x: String,
y: String,
z: String
, ) = Unit
fun foo(
x: Int =
42
) {
}
class C(
val x: Int =
42
)
class G(
val x: String, val y: String
= "", /* */ val z: String
)
class G(
val x: String, val y: String
= "" /* */, /* */ val z: String
)
class H(
val x: String, /*
*/ val y: String,
val z: String ,)
class J(
val x: String, val y: String , val z: String /*
*/
, )
class K(
val x: String, val y: String,
val z: String
, )
class L(
val x: String, val y: String, val z: String
)
// SET_TRUE: ALLOW_TRAILING_COMMA
// SET_INT: METHOD_PARAMETERS_WRAP = 1
@@ -1,94 +0,0 @@
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String
)
class C1(
val x: String,
val y: String,
)
class D1(
val x: String,
val y: String,
)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String
)
class C2(
val x: String,
val y: String,
val z: String,
)
class D2(
val x: String,
val y: String,
val z: String,
)
class A3(
val x: String,
)
class B3(
val x: String
)
class C3(
val x: String,
)
class D3(
val x: String,
)
class A4(
val x: String,
val y: String,
val z: String,
)
class B4(
val x: String,
val y: String,
val z: String
)
class C4(
val x: String,
val y: String,
val z: String,
)
class D4(
val x: String,
val y: String,
val z: String,
)
class E1(
val x: String, val y: String,
val z: String,
)
class E2(
val x: String, val y: String, val z: String
)
// SET_TRUE: ALLOW_TRAILING_COMMA
@@ -1,94 +0,0 @@
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String,
)
class C1(
val x: String,
val y: String,
)
class D1(
val x: String,
val y: String,
)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String,
)
class C2(
val x: String,
val y: String,
val z: String,
)
class D2(
val x: String,
val y: String,
val z: String,
)
class A3(
val x: String,
)
class B3(
val x: String,
)
class C3(
val x: String,
)
class D3(
val x: String,
)
class A4(
val x: String,
val y: String,
val z: String,
)
class B4(
val x: String,
val y: String,
val z: String,
)
class C4(
val x: String,
val y: String,
val z: String,
)
class D4(
val x: String,
val y: String,
val z: String,
)
class E1(
val x: String, val y: String,
val z: String,
)
class E2(
val x: String, val y: String, val z: String,
)
// SET_TRUE: ALLOW_TRAILING_COMMA
@@ -1,90 +0,0 @@
class A1(
val x: String,
y: String,
)
class B1(
val x: String,
val y: String
)
class C1(
val x: String,
val y: String,)
class D1(
val x: String,
val y: String
,)
class A2(
val x: String,
val y: String,
val z: String,
)
class B2(
val x: String,
val y: String,
val z: String
)
class C2(
val x: String,
val y: String,
val z: String,)
class D2(
val x: String,
val y: String,
val z: String
,)
class A3(
val x: String,
)
class B3(
val x: String
)
class C3(
val x: String,)
class D3(
val x: String
,)
class A4(
val x: String ,
val y: String,
val z: String ,
)
class B4(
val x: String,
val y: String,
val z: String
)
class C4(
val x: String,
val y: String,
val z: String ,)
class D4(
val x: String,
val y: String,
val z: String
, )
class E1(
val x: String, val y: String,
val z: String
, )
class E2(
val x: String, val y: String, val z: String
)
// SET_TRUE: ALLOW_TRAILING_COMMA
@@ -1,184 +0,0 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String) {
this.x = x
this.y = y
this.z = z
}
}
// SET_TRUE: ALLOW_TRAILING_COMMA
@@ -1,185 +0,0 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String,
) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
// SET_TRUE: ALLOW_TRAILING_COMMA
@@ -1,178 +0,0 @@
class A1 {
val x: String
val y: String
constructor(
x: String,
y: String,
) {
this.x = x
this.y = y
}
}
class B1 {
val x: String
val y: String
constructor(
x: String,
y: String
) {
this.x = x
this.y = y
}
}
class C1 {
val x: String
val y: String
constructor(
x: String,
y: String,) {
this.x = x
this.y = y
}
}
class D1 {
val x: String
val y: String
constructor(
x: String,
y: String
,) {
this.x = x
this.y = y
}
}
class A2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,
) {
this.x = x
this.y = y
this.z = z
}
}
class B2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
) {
this.x = x
this.y = y
this.z = z
}
}
class C2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String,) {
this.x = x
this.y = y
this.z = z
}
}
class D2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String,
z: String
,) {
this.x = x
this.y = y
this.z = z
}
}
class A3 {
val x: String
constructor(x: String,) {
this.x = x
}
}
class B3 {
val x: String
constructor(x: String) {
this.x = x
}
}
class C3 {
val x: String
constructor(
x: String,) {
this.x = x
}
}
class D3 {
val x: String
constructor(
x: String
,) {
this.x = x
}
}
class E1 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String,) {
this.x = x
this.y = y
this.z = z
}
}
class E2 {
val x: String
val y: String
val z: String
constructor(
x: String,
y: String, z: String) {
this.x = x
this.y = y
this.z = z
}
}
// SET_TRUE: ALLOW_TRAILING_COMMA
@@ -1164,6 +1164,39 @@ public class FormatterTestGenerated extends AbstractFormatterTest {
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/testData/formatter/trailingComma"), Pattern.compile("^([^\\.]+)\\.after\\.kt.*$"), null, true); KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/testData/formatter/trailingComma"), Pattern.compile("^([^\\.]+)\\.after\\.kt.*$"), null, true);
} }
@TestMetadata("idea/testData/formatter/trailingComma/valueArguments")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public static class ValueArguments extends AbstractFormatterTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doTest, this, testDataFilePath);
}
public void testAllFilesPresentInValueArguments() throws Exception {
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/testData/formatter/trailingComma/valueArguments"), Pattern.compile("^([^\\.]+)\\.after\\.kt.*$"), null, true);
}
@TestMetadata("ArgumentListChopAsNeeded.after.kt")
public void testArgumentListChopAsNeeded() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueArguments/ArgumentListChopAsNeeded.after.kt");
}
@TestMetadata("ArgumentListDoNotWrap.after.kt")
public void testArgumentListDoNotWrap() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueArguments/ArgumentListDoNotWrap.after.kt");
}
@TestMetadata("ArgumentListWrapAlways.after.kt")
public void testArgumentListWrapAlways() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueArguments/ArgumentListWrapAlways.after.kt");
}
@TestMetadata("ArgumentListWrapAsNeeded.after.kt")
public void testArgumentListWrapAsNeeded() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueArguments/ArgumentListWrapAsNeeded.after.kt");
}
}
@TestMetadata("idea/testData/formatter/trailingComma/valueParameters") @TestMetadata("idea/testData/formatter/trailingComma/valueParameters")
@TestDataPath("$PROJECT_ROOT") @TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class) @RunWith(JUnit3RunnerWithInners.class)
@@ -1176,24 +1209,24 @@ public class FormatterTestGenerated extends AbstractFormatterTest {
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/testData/formatter/trailingComma/valueParameters"), Pattern.compile("^([^\\.]+)\\.after\\.kt.*$"), null, true); KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/testData/formatter/trailingComma/valueParameters"), Pattern.compile("^([^\\.]+)\\.after\\.kt.*$"), null, true);
} }
@TestMetadata("Function.after.kt") @TestMetadata("ParameterListChopAsNeeded.after.kt")
public void testFunction() throws Exception { public void testParameterListChopAsNeeded() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueParameters/Function.after.kt"); runTest("idea/testData/formatter/trailingComma/valueParameters/ParameterListChopAsNeeded.after.kt");
} }
@TestMetadata("OptionalTypes.after.kt") @TestMetadata("ParameterListDoNotWrap.after.kt")
public void testOptionalTypes() throws Exception { public void testParameterListDoNotWrap() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueParameters/OptionalTypes.after.kt"); runTest("idea/testData/formatter/trailingComma/valueParameters/ParameterListDoNotWrap.after.kt");
} }
@TestMetadata("PrimaryConstructor.after.kt") @TestMetadata("ParameterListWrapAlways.after.kt")
public void testPrimaryConstructor() throws Exception { public void testParameterListWrapAlways() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueParameters/PrimaryConstructor.after.kt"); runTest("idea/testData/formatter/trailingComma/valueParameters/ParameterListWrapAlways.after.kt");
} }
@TestMetadata("SecondConstructor.after.kt") @TestMetadata("ParameterListWrapAsNeeded.after.kt")
public void testSecondConstructor() throws Exception { public void testParameterListWrapAsNeeded() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueParameters/SecondConstructor.after.kt"); runTest("idea/testData/formatter/trailingComma/valueParameters/ParameterListWrapAsNeeded.after.kt");
} }
} }
} }
@@ -1575,6 +1608,39 @@ public class FormatterTestGenerated extends AbstractFormatterTest {
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/testData/formatter/trailingComma"), Pattern.compile("^([^\\.]+)\\.after\\.inv\\.kt.*$"), null, true); KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/testData/formatter/trailingComma"), Pattern.compile("^([^\\.]+)\\.after\\.inv\\.kt.*$"), null, true);
} }
@TestMetadata("idea/testData/formatter/trailingComma/valueArguments")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public static class ValueArguments extends AbstractFormatterTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doTestInverted, this, testDataFilePath);
}
public void testAllFilesPresentInValueArguments() throws Exception {
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/testData/formatter/trailingComma/valueArguments"), Pattern.compile("^([^\\.]+)\\.after\\.inv\\.kt.*$"), null, true);
}
@TestMetadata("ArgumentListChopAsNeeded.after.inv.kt")
public void testArgumentListChopAsNeeded() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueArguments/ArgumentListChopAsNeeded.after.inv.kt");
}
@TestMetadata("ArgumentListDoNotWrap.after.inv.kt")
public void testArgumentListDoNotWrap() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueArguments/ArgumentListDoNotWrap.after.inv.kt");
}
@TestMetadata("ArgumentListWrapAlways.after.inv.kt")
public void testArgumentListWrapAlways() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueArguments/ArgumentListWrapAlways.after.inv.kt");
}
@TestMetadata("ArgumentListWrapAsNeeded.after.inv.kt")
public void testArgumentListWrapAsNeeded() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueArguments/ArgumentListWrapAsNeeded.after.inv.kt");
}
}
@TestMetadata("idea/testData/formatter/trailingComma/valueParameters") @TestMetadata("idea/testData/formatter/trailingComma/valueParameters")
@TestDataPath("$PROJECT_ROOT") @TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class) @RunWith(JUnit3RunnerWithInners.class)
@@ -1587,24 +1653,24 @@ public class FormatterTestGenerated extends AbstractFormatterTest {
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/testData/formatter/trailingComma/valueParameters"), Pattern.compile("^([^\\.]+)\\.after\\.inv\\.kt.*$"), null, true); KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/testData/formatter/trailingComma/valueParameters"), Pattern.compile("^([^\\.]+)\\.after\\.inv\\.kt.*$"), null, true);
} }
@TestMetadata("Function.after.inv.kt") @TestMetadata("ParameterListChopAsNeeded.after.inv.kt")
public void testFunction() throws Exception { public void testParameterListChopAsNeeded() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueParameters/Function.after.inv.kt"); runTest("idea/testData/formatter/trailingComma/valueParameters/ParameterListChopAsNeeded.after.inv.kt");
} }
@TestMetadata("OptionalTypes.after.inv.kt") @TestMetadata("ParameterListDoNotWrap.after.inv.kt")
public void testOptionalTypes() throws Exception { public void testParameterListDoNotWrap() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueParameters/OptionalTypes.after.inv.kt"); runTest("idea/testData/formatter/trailingComma/valueParameters/ParameterListDoNotWrap.after.inv.kt");
} }
@TestMetadata("PrimaryConstructor.after.inv.kt") @TestMetadata("ParameterListWrapAlways.after.inv.kt")
public void testPrimaryConstructor() throws Exception { public void testParameterListWrapAlways() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueParameters/PrimaryConstructor.after.inv.kt"); runTest("idea/testData/formatter/trailingComma/valueParameters/ParameterListWrapAlways.after.inv.kt");
} }
@TestMetadata("SecondConstructor.after.inv.kt") @TestMetadata("ParameterListWrapAsNeeded.after.inv.kt")
public void testSecondConstructor() throws Exception { public void testParameterListWrapAsNeeded() throws Exception {
runTest("idea/testData/formatter/trailingComma/valueParameters/SecondConstructor.after.inv.kt"); runTest("idea/testData/formatter/trailingComma/valueParameters/ParameterListWrapAsNeeded.after.inv.kt");
} }
} }
} }