[Gradle] Rename KotlinTargetHierarchyBuilder.withAndroid to withAndroidTarget
... by deprecating .withAndroid in favor of 'withAndroidTarget' to make room for the Google maintained 'Android Target' ^KT-58710 Verification Pending
This commit is contained in:
committed by
Space Team
parent
ff7e4f7986
commit
e1d48847dc
+3
@@ -141,7 +141,10 @@ interface KotlinTargetHierarchyBuilder {
|
||||
fun withJs()
|
||||
fun withWasm()
|
||||
fun withJvm()
|
||||
|
||||
@Deprecated("Renamed to 'withAndroidTarget''", replaceWith = ReplaceWith("withAndroidTarget()"))
|
||||
fun withAndroid()
|
||||
fun withAndroidTarget()
|
||||
fun withAndroidNativeX64()
|
||||
fun withAndroidNativeX86()
|
||||
fun withAndroidNativeArm32()
|
||||
|
||||
+5
-2
@@ -56,7 +56,7 @@ private class KotlinTargetHierarchyBuilderImplContext(private val compilation: K
|
||||
}
|
||||
|
||||
private class KotlinTargetHierarchyBuilderRootImpl(
|
||||
private val builder: KotlinTargetHierarchyBuilderImpl
|
||||
private val builder: KotlinTargetHierarchyBuilderImpl,
|
||||
) : KotlinTargetHierarchyBuilder.Root, KotlinTargetHierarchyBuilder by builder {
|
||||
|
||||
|
||||
@@ -161,7 +161,10 @@ private class KotlinTargetHierarchyBuilderImpl(
|
||||
(it is KotlinWithJavaTarget<*, *> && it.platformType == KotlinPlatformType.jvm)
|
||||
}
|
||||
|
||||
override fun withAndroid() = withTargets { it is KotlinAndroidTarget }
|
||||
@Suppress("OVERRIDE_DEPRECATION")
|
||||
override fun withAndroid() = withAndroidTarget()
|
||||
|
||||
override fun withAndroidTarget() = withTargets { it is KotlinAndroidTarget }
|
||||
|
||||
override fun withAndroidNativeX64() = withTargets {
|
||||
it is KotlinNativeTarget && it.konanTarget == KonanTarget.ANDROID_X64
|
||||
|
||||
+1
-1
@@ -41,7 +41,7 @@ class IdeJvmAndAndroidDependencyResolutionTest {
|
||||
common {
|
||||
group("jvmAndAndroid") {
|
||||
withJvm()
|
||||
withAndroid()
|
||||
withAndroidTarget()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -175,7 +175,7 @@ class KotlinTargetHierarchyDslTest {
|
||||
common {
|
||||
group("jvmAndAndroid") {
|
||||
withJvm()
|
||||
withAndroid()
|
||||
withAndroidTarget()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user