Minor. Move local functions as a private to class
This commit is contained in:
@@ -229,15 +229,15 @@ object NewKotlinTypeChecker : KotlinTypeChecker {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private fun TypeCheckerContext.collectAndFilter(classType: SimpleType, constructor: TypeConstructor) =
|
||||||
|
selectOnlyPureKotlinSupertypes(collectAllSupertypesWithGivenTypeConstructor(classType, constructor))
|
||||||
|
|
||||||
// nullability was checked earlier via nullabilityChecker
|
// nullability was checked earlier via nullabilityChecker
|
||||||
// should be used only if you really sure that it is correct
|
// should be used only if you really sure that it is correct
|
||||||
fun TypeCheckerContext.findCorrespondingSupertypes(
|
fun TypeCheckerContext.findCorrespondingSupertypes(
|
||||||
baseType: SimpleType,
|
baseType: SimpleType,
|
||||||
constructor: TypeConstructor
|
constructor: TypeConstructor
|
||||||
): List<SimpleType> {
|
): List<SimpleType> {
|
||||||
fun TypeCheckerContext.collectAndFilter(classType: SimpleType, constructor: TypeConstructor) =
|
|
||||||
selectOnlyPureKotlinSupertypes(collectAllSupertypesWithGivenTypeConstructor(classType, constructor))
|
|
||||||
|
|
||||||
if (baseType.isClassType) {
|
if (baseType.isClassType) {
|
||||||
return collectAndFilter(baseType, constructor)
|
return collectAndFilter(baseType, constructor)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user