[NI] Minor. Drop unused CommonSupertypeCalculator

This commit is contained in:
Stanislav Erokhin
2017-05-03 16:14:16 +03:00
parent 0404fbc092
commit ac06060260
3 changed files with 0 additions and 11 deletions
@@ -28,7 +28,6 @@ import org.jetbrains.kotlin.extensions.StorageComponentContainerContributor
import org.jetbrains.kotlin.incremental.components.LookupTracker
import org.jetbrains.kotlin.psi.KtFile
import org.jetbrains.kotlin.resolve.*
import org.jetbrains.kotlin.resolve.calls.tower.CommonSupertypeCalculatorImpl
import org.jetbrains.kotlin.resolve.calls.tower.IsDescriptorFromSourcePredicateImpl
import org.jetbrains.kotlin.resolve.lazy.*
import org.jetbrains.kotlin.resolve.lazy.declarations.DeclarationProviderFactory
@@ -62,7 +61,6 @@ fun StorageComponentContainer.configureModule(
private fun StorageComponentContainer.configurePlatformIndependentComponents() {
useImpl<SupertypeLoopCheckerImpl>()
useInstance(CommonSupertypeCalculatorImpl)
useInstance(IsDescriptorFromSourcePredicateImpl)
}
@@ -18,14 +18,7 @@ package org.jetbrains.kotlin.resolve.calls.tower
import org.jetbrains.kotlin.descriptors.CallableDescriptor
import org.jetbrains.kotlin.resolve.DescriptorToSourceUtils
import org.jetbrains.kotlin.resolve.calls.components.CommonSupertypeCalculator
import org.jetbrains.kotlin.resolve.calls.components.IsDescriptorFromSourcePredicate
import org.jetbrains.kotlin.types.CommonSupertypes
import org.jetbrains.kotlin.types.UnwrappedType
object CommonSupertypeCalculatorImpl : CommonSupertypeCalculator {
override fun invoke(p1: Collection<UnwrappedType>): UnwrappedType = CommonSupertypes.commonSupertype(p1).unwrap()
}
object IsDescriptorFromSourcePredicateImpl: IsDescriptorFromSourcePredicate {
override fun invoke(p1: CallableDescriptor) = DescriptorToSourceUtils.descriptorToDeclaration(p1) != null
@@ -23,8 +23,6 @@ import org.jetbrains.kotlin.types.UnwrappedType
interface IsDescriptorFromSourcePredicate: (CallableDescriptor) -> Boolean
interface CommonSupertypeCalculator: (Collection<UnwrappedType>) -> UnwrappedType
// This components hold state (trace). Work with this carefully.
interface KotlinResolutionCallbacks {
fun analyzeAndGetLambdaResultArguments(