[Commonizer] Inline 'hasAnythingToCommonize'
This commit is contained in:
@@ -37,7 +37,4 @@ fun CommonizerParameters.getCommonModuleNames(): Set<String> {
|
||||
return allModuleNames.reduce { a, b -> a intersect b } // there are modules that are present in every target
|
||||
}
|
||||
|
||||
fun CommonizerParameters.hasAnythingToCommonize(): Boolean {
|
||||
return getCommonModuleNames().isNotEmpty()
|
||||
}
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ import org.jetbrains.kotlin.storage.LockBasedStorageManager
|
||||
import org.jetbrains.kotlin.storage.StorageManager
|
||||
|
||||
fun runCommonization(parameters: CommonizerParameters) {
|
||||
if (!parameters.hasAnythingToCommonize()) {
|
||||
if (parameters.getCommonModuleNames().isEmpty()) {
|
||||
parameters.resultsConsumer.allConsumed(Status.NOTHING_TO_DO)
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user