Fix indent of expressions following elvis operator
This commit is contained in:
+14
@@ -0,0 +1,14 @@
|
||||
fun foo() {
|
||||
val topLevelDeclaration =
|
||||
DescriptorUtils.getParentOfType(referencedDescriptor, PropertyDescriptor::class.java, false) as DeclarationDescriptor?
|
||||
?: DescriptorUtils.getParentOfType(
|
||||
referencedDescriptor,
|
||||
TypeAliasConstructorDescriptor::class.java,
|
||||
false
|
||||
)?.typeAliasDescriptor
|
||||
?: DescriptorUtils.getParentOfType(referencedDescriptor, FunctionDescriptor::class.java, false)
|
||||
?: return emptyList()
|
||||
}
|
||||
|
||||
// SET_FALSE: CONTINUATION_INDENT_IN_ARGUMENT_LISTS
|
||||
// SET_FALSE: CONTINUATION_INDENT_FOR_EXPRESSION_BODIES
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
fun foo() {
|
||||
val topLevelDeclaration =
|
||||
DescriptorUtils.getParentOfType(referencedDescriptor, PropertyDescriptor::class.java, false) as DeclarationDescriptor?
|
||||
?: DescriptorUtils.getParentOfType(
|
||||
referencedDescriptor,
|
||||
TypeAliasConstructorDescriptor::class.java,
|
||||
false
|
||||
)?.typeAliasDescriptor
|
||||
?: DescriptorUtils.getParentOfType(referencedDescriptor, FunctionDescriptor::class.java, false)
|
||||
?: return emptyList()
|
||||
}
|
||||
|
||||
// SET_FALSE: CONTINUATION_INDENT_IN_ARGUMENT_LISTS
|
||||
// SET_FALSE: CONTINUATION_INDENT_FOR_EXPRESSION_BODIES
|
||||
@@ -33,6 +33,14 @@ fun test3() {
|
||||
}
|
||||
}
|
||||
|
||||
fun test4() {
|
||||
val abc = ArrayList<Int>().mapTo(
|
||||
LinkedHashSet()
|
||||
) {
|
||||
it * 2
|
||||
}
|
||||
}
|
||||
|
||||
fun testWithComments() {
|
||||
val abc = ArrayList<Int>()
|
||||
// .map {
|
||||
|
||||
@@ -33,6 +33,14 @@ fun test3() {
|
||||
}
|
||||
}
|
||||
|
||||
fun test4() {
|
||||
val abc = ArrayList<Int>().mapTo(
|
||||
LinkedHashSet()
|
||||
) {
|
||||
it * 2
|
||||
}
|
||||
}
|
||||
|
||||
fun testWithComments() {
|
||||
val abc = ArrayList<Int>()
|
||||
// .map {
|
||||
|
||||
@@ -33,6 +33,14 @@ val abc = ArrayList<Int>().map {
|
||||
}
|
||||
}
|
||||
|
||||
fun test4() {
|
||||
val abc = ArrayList<Int>().mapTo(
|
||||
LinkedHashSet()
|
||||
) {
|
||||
it * 2
|
||||
}
|
||||
}
|
||||
|
||||
fun testWithComments() {
|
||||
val abc = ArrayList<Int>()
|
||||
// .map {
|
||||
|
||||
Reference in New Issue
Block a user