Update binary-compatibility-validator to v0.9.0

KT-52045
This commit is contained in:
sebastian.sellmair
2022-05-02 10:03:51 +02:00
committed by Space
parent 9e591f3299
commit fd0645548d
3 changed files with 13 additions and 25 deletions
@@ -6,7 +6,7 @@ configurations {
}
dependencies {
api("org.jetbrains.kotlinx:binary-compatibility-validator:0.7.1")
api("org.jetbrains.kotlinx:binary-compatibility-validator:0.9.0")
api("org.jetbrains.kotlinx:kotlinx-metadata-jvm:0.4.1")
testApi project(':kotlin-test:kotlin-test-junit')
@@ -81,27 +81,3 @@ class RuntimePublicAPITest {
}
}
/*
Copied from `binary-compatibility-validator
Can be removed after:
https://github.com/Kotlin/binary-compatibility-validator/pull/75
*/
private fun List<ClassBinarySignature>.filterOutAnnotated(targetAnnotations: Set<String>): List<ClassBinarySignature> {
if (targetAnnotations.isEmpty()) return this
return filter {
it.annotations.all { ann -> !targetAnnotations.any { ann.refersToName(it) } }
}.map {
ClassBinarySignature(
it.name,
it.superName,
it.outerName,
it.supertypes,
it.memberSignatures.filter { it.annotations.all { ann -> !targetAnnotations.any { ann.refersToName(it) } } },
it.access,
it.isEffectivelyPublic,
it.isNotUsedWhenEmpty,
it.annotations
)
}
}