Parcelize: Use @Parcelize annotations from Android Extensions instead of the copied&deprecated ones (KT-42342, KT-43150)

Dex can't merge class files from both android-extensions-runtime and parcelize-runtime, so we have to keep only one copy of each class.
Instead of @Deprecated annotations, there are new diagnostics (without quick-fixes yet).
The goal is to allow simple usages (@Parcelize alone) but forbid kotlinx.android.synthetic.Parceler usage.
This commit is contained in:
Yan Zhulanow
2020-11-07 02:01:10 +09:00
parent fa42a6ba58
commit e83a3c3f27
36 changed files with 182 additions and 629 deletions
@@ -20,6 +20,7 @@ dependencies {
compileOnly(project(":compiler:backend.jvm"))
compileOnly(project(":compiler:ir.tree.impl"))
compileOnly(project(":plugins:parcelize:parcelize-runtime"))
compileOnly(project(":kotlin-android-extensions-runtime"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeJars("asm-all", rootProject = rootProject) }
@@ -29,6 +30,7 @@ dependencies {
testCompile(project(":compiler:backend.jvm"))
testCompile(project(":compiler:cli"))
testCompile(project(":plugins:parcelize:parcelize-runtime"))
testCompile(project(":kotlin-android-extensions-runtime"))
testCompile(projectTests(":compiler:tests-common"))
testCompile(project(":kotlin-test:kotlin-test-jvm"))
testCompile(commonDep("junit:junit"))
@@ -38,10 +40,13 @@ dependencies {
robolectricClasspath(commonDep("org.robolectric", "robolectric"))
robolectricClasspath("org.robolectric:android-all:4.4_r1-robolectric-1")
robolectricClasspath(project(":plugins:parcelize:parcelize-runtime")) { isTransitive = false }
robolectricClasspath(project(":kotlin-android-extensions-runtime")) { isTransitive = false }
embedded(project(":plugins:parcelize:parcelize-runtime")) { isTransitive = false }
embedded(project(":kotlin-android-extensions-runtime")) { isTransitive = false }
parcelizeRuntimeForTests(project(":plugins:parcelize:parcelize-runtime")) { isTransitive = false }
parcelizeRuntimeForTests(project(":kotlin-android-extensions-runtime")) { isTransitive = false }
}
sourceSets {