Cleanup: post-cleanup after deprecation cleanup in compiler
Replace `takeIf { !expr }` with `takeUnless { expr }`.
Cleanup redundant parethesis as in `listOf((expr))`.
Replace `listOf(expr)` with `expr.let(::listOf)` where the former caused significant indentation change.
This commit is contained in:
@@ -166,7 +166,7 @@ fun getFunctionTypeArgumentProjections(
|
||||
arguments.addIfNotNull(receiverType?.asTypeProjection())
|
||||
|
||||
parameterTypes.mapIndexedTo(arguments) { index, type ->
|
||||
val name = parameterNames?.get(index)?.takeIf { !it.isSpecial }
|
||||
val name = parameterNames?.get(index)?.takeUnless { it.isSpecial }
|
||||
val typeToUse = if (name != null) {
|
||||
val annotationClass = builtIns.getBuiltInClassByName(KotlinBuiltIns.FQ_NAMES.parameterName.shortName())
|
||||
val nameValue = ConstantValueFactory(builtIns).createStringValue(name.asString())
|
||||
|
||||
+1
-1
@@ -33,4 +33,4 @@ interface VariableDescriptorWithAccessors : VariableDescriptor {
|
||||
}
|
||||
|
||||
val VariableDescriptorWithAccessors.accessors: List<VariableAccessorDescriptor>
|
||||
get() = listOfNotNull(getter) + listOfNotNull(setter)
|
||||
get() = listOfNotNull(getter, setter)
|
||||
|
||||
Reference in New Issue
Block a user