Drop all redundant kotlin-reflect, kotlin-reflect-api dependencies
Review: https://jetbrains.team/p/kt/reviews/6753 All redundant I managed to find, of course. Why: I'm going to process all reflect dependencies in the next commits. Cleanup reflect dependency before processing. They are redundant because: 1. if `compileOnly` then compilation didn't break after dropping the dependency 2. if `test*` then tests didn't break after dropping the dependency. 3. `analysis/analysis-api-fir/analysis-api-fir-generator/build.gradle.kts` `compiler/fir/checkers/checkers-component-generator/build.gradle.kts` Drop `implementation(project(":kotlin-reflect-api"))` because the module already depends on `implementation(project(":kotlin-reflect"))` 4. `compiler/daemon/daemon-client/build.gradle.kts`. Drop `runtimeOnly` because after dropping `compileOnly` compilation didn't break (so `runtimeOnly` looks suspicious). Less safe than 1-3
This commit is contained in:
@@ -16,7 +16,6 @@ dependencies {
|
||||
testApi(project(":compiler:frontend.java"))
|
||||
|
||||
testApi(kotlinStdlib())
|
||||
testApi(project(":kotlin-reflect"))
|
||||
testApi(projectTests(":compiler:tests-common"))
|
||||
testApi(commonDependency("junit:junit"))
|
||||
testApi(projectTests(":compiler:test-infrastructure"))
|
||||
|
||||
@@ -30,7 +30,6 @@ dependencies {
|
||||
testApi(project(":compiler:ir.tree")) // used for deepCopyWithSymbols call that is removed by proguard from the compiler TODO: make it more straightforward
|
||||
testApi(project(":kotlin-scripting-compiler"))
|
||||
testApi(project(":kotlin-script-util"))
|
||||
testCompileOnly(project(":kotlin-reflect-api"))
|
||||
|
||||
otherCompilerModules.forEach {
|
||||
testCompileOnly(project(it))
|
||||
|
||||
@@ -24,7 +24,6 @@ dependencies {
|
||||
compileOnly(project(":compiler:util"))
|
||||
compileOnly(project(":compiler:cli-common"))
|
||||
compileOnly(project(":daemon-common-new"))
|
||||
compileOnly(project(":kotlin-reflect-api"))
|
||||
compileOnly(project(":kotlin-daemon-client"))
|
||||
compileOnly(project(":js:js.frontend"))
|
||||
compileOnly(project(":daemon-common")) { isTransitive = false }
|
||||
|
||||
@@ -22,7 +22,6 @@ dependencies {
|
||||
compileOnly(project(":compiler:util"))
|
||||
compileOnly(project(":compiler:cli-common"))
|
||||
compileOnly(project(":daemon-common"))
|
||||
compileOnly(project(":kotlin-reflect-api"))
|
||||
compileOnly(project(":js:js.frontend"))
|
||||
compileOnly(commonDependency("net.rubygrapefruit", "native-platform"))
|
||||
|
||||
@@ -31,7 +30,6 @@ dependencies {
|
||||
nativePlatformVariants.forEach {
|
||||
embedded(commonDependency("net.rubygrapefruit", "native-platform", "-$it"))
|
||||
}
|
||||
runtimeOnly(project(":kotlin-reflect"))
|
||||
api(commonDependency("org.jetbrains.kotlinx", "kotlinx-coroutines-core")) {
|
||||
isTransitive = false
|
||||
}
|
||||
|
||||
@@ -27,8 +27,6 @@ dependencies {
|
||||
|
||||
testApiJUnit5()
|
||||
|
||||
testCompileOnly(project(":kotlin-reflect-api"))
|
||||
testRuntimeOnly(project(":kotlin-reflect"))
|
||||
testRuntimeOnly(project(":core:descriptors.runtime"))
|
||||
testRuntimeOnly(project(":compiler:fir:fir2ir:jvm-backend"))
|
||||
|
||||
|
||||
@@ -10,7 +10,6 @@ dependencies {
|
||||
implementation(project(":compiler:fir:tree:tree-generator"))
|
||||
implementation(project(":compiler:resolution.common"))
|
||||
implementation(project(":kotlin-reflect"))
|
||||
implementation(project(":kotlin-reflect-api"))
|
||||
|
||||
/*
|
||||
We do not need guava in the generator, but because of a bug in the IJ project importing, we need to have a dependency on intellijCore
|
||||
|
||||
@@ -15,7 +15,6 @@ dependencies {
|
||||
implementation(project(":compiler:frontend"))
|
||||
implementation(project(":compiler:psi"))
|
||||
|
||||
compileOnly(project(":kotlin-reflect-api"))
|
||||
compileOnly(intellijCore())
|
||||
}
|
||||
|
||||
|
||||
@@ -16,7 +16,6 @@ dependencies {
|
||||
implementation(project(":compiler:frontend"))
|
||||
implementation(project(":compiler:psi"))
|
||||
|
||||
compileOnly(project(":kotlin-reflect-api"))
|
||||
compileOnly(intellijCore())
|
||||
}
|
||||
|
||||
|
||||
@@ -25,7 +25,6 @@ dependencies {
|
||||
implementation(project(":compiler:ir.serialization.jvm"))
|
||||
implementation(project(":compiler:ir.tree"))
|
||||
|
||||
compileOnly(project(":kotlin-reflect-api"))
|
||||
compileOnly(intellijCore())
|
||||
}
|
||||
|
||||
|
||||
@@ -31,8 +31,6 @@ dependencies {
|
||||
|
||||
testApiJUnit5()
|
||||
|
||||
testCompileOnly(project(":kotlin-reflect-api"))
|
||||
testRuntimeOnly(project(":kotlin-reflect"))
|
||||
testRuntimeOnly(project(":core:deserialization"))
|
||||
testRuntimeOnly(project(":core:descriptors.runtime"))
|
||||
testRuntimeOnly(project(":core:descriptors.jvm"))
|
||||
|
||||
@@ -23,8 +23,6 @@ dependencies {
|
||||
testCompileOnly(project(":kotlin-test:kotlin-test-junit"))
|
||||
testApi(projectTests(":compiler:tests-common"))
|
||||
|
||||
testCompileOnly(project(":kotlin-reflect-api"))
|
||||
testRuntimeOnly(project(":kotlin-reflect"))
|
||||
testRuntimeOnly(project(":core:descriptors.runtime"))
|
||||
testApi(projectTests(":compiler:fir:analysis-tests:legacy-fir-tests"))
|
||||
testApi(project(":compiler:fir:resolve"))
|
||||
|
||||
@@ -10,7 +10,6 @@ dependencies {
|
||||
api(project(":compiler:fir:tree"))
|
||||
implementation(project(":core:util.runtime"))
|
||||
|
||||
compileOnly(project(":kotlin-reflect-api"))
|
||||
compileOnly(commonDependency("com.google.guava:guava"))
|
||||
}
|
||||
|
||||
|
||||
@@ -28,9 +28,7 @@ dependencies {
|
||||
|
||||
testCompileOnly(project(":kotlin-test:kotlin-test-jvm"))
|
||||
testCompileOnly(project(":kotlin-test:kotlin-test-junit"))
|
||||
testCompileOnly(project(":kotlin-reflect-api"))
|
||||
|
||||
testRuntimeOnly(project(":kotlin-reflect"))
|
||||
testRuntimeOnly(project(":core:descriptors.runtime"))
|
||||
|
||||
testCompileOnly(intellijCore())
|
||||
|
||||
@@ -8,7 +8,6 @@ dependencies {
|
||||
api(project(":compiler:fir:semantics"))
|
||||
implementation(project(":core:util.runtime"))
|
||||
|
||||
compileOnly(project(":kotlin-reflect-api"))
|
||||
compileOnly(commonDependency("com.google.guava:guava"))
|
||||
}
|
||||
|
||||
|
||||
@@ -7,7 +7,6 @@ dependencies {
|
||||
api(project(":compiler:fir:providers"))
|
||||
implementation(project(":core:util.runtime"))
|
||||
|
||||
compileOnly(project(":kotlin-reflect-api"))
|
||||
compileOnly(commonDependency("com.google.guava:guava"))
|
||||
}
|
||||
|
||||
|
||||
@@ -9,7 +9,6 @@ dependencies {
|
||||
api(project(":js:js.frontend"))
|
||||
|
||||
implementation(project(":compiler:ir.backend.common"))
|
||||
compileOnly(project(":kotlin-reflect-api"))
|
||||
|
||||
compileOnly(intellijCore())
|
||||
}
|
||||
|
||||
@@ -8,8 +8,6 @@ dependencies {
|
||||
testApi(project(":compiler:cli"))
|
||||
testApi(intellijCore())
|
||||
|
||||
testCompileOnly(project(":kotlin-reflect-api"))
|
||||
testRuntimeOnly(project(":kotlin-reflect"))
|
||||
testRuntimeOnly(project(":core:descriptors.runtime"))
|
||||
|
||||
testImplementation(projectTests(":compiler:test-infrastructure-utils"))
|
||||
|
||||
@@ -13,8 +13,6 @@ dependencies {
|
||||
testImplementation(project(":compiler:backend.jvm.lower"))
|
||||
testImplementation(intellijCore())
|
||||
|
||||
testCompileOnly(project(":kotlin-reflect-api"))
|
||||
testRuntimeOnly(project(":kotlin-reflect"))
|
||||
testRuntimeOnly(project(":core:descriptors.runtime"))
|
||||
|
||||
testImplementation(projectTests(":generators:test-generator"))
|
||||
|
||||
@@ -13,7 +13,6 @@ dependencies {
|
||||
testApiJUnit5(vintageEngine = true, runner = true, suiteApi = true)
|
||||
|
||||
testImplementation(intellijCore())
|
||||
testRuntimeOnly(project(":kotlin-reflect"))
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
|
||||
@@ -18,8 +18,6 @@ dependencies {
|
||||
testImplementation(projectTests(":compiler:visualizer"))
|
||||
testImplementation(projectTests(":js:js.tests"))
|
||||
testImplementation(projectTests(":generators:test-generator"))
|
||||
testCompileOnly(project(":kotlin-reflect-api"))
|
||||
testRuntimeOnly(project(":kotlin-reflect"))
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
|
||||
@@ -8,12 +8,7 @@ dependencies {
|
||||
testApi(projectTests(":compiler:tests-common"))
|
||||
testImplementation(intellijCore())
|
||||
testApi(projectTests(":generators:test-generator"))
|
||||
testRuntimeOnly(project(":kotlin-reflect"))
|
||||
testRuntimeOnly(toolsJar())
|
||||
|
||||
if (kotlinBuildProperties.isInJpsBuildIdeaSync) {
|
||||
testRuntimeOnly(files("${rootProject.projectDir}/dist/kotlinc/lib/kotlin-reflect.jar"))
|
||||
}
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
|
||||
@@ -15,11 +15,6 @@ dependencies {
|
||||
|
||||
api("org.jsoup:jsoup:1.14.2")
|
||||
|
||||
if (kotlinBuildProperties.isInJpsBuildIdeaSync) {
|
||||
testRuntimeOnly(files("${rootProject.projectDir}/dist/kotlinc/lib/kotlin-reflect.jar"))
|
||||
}
|
||||
|
||||
testRuntimeOnly(project(":kotlin-reflect"))
|
||||
testRuntimeOnly(project(":core:descriptors.runtime"))
|
||||
|
||||
testApiJUnit5(vintageEngine = true)
|
||||
|
||||
Reference in New Issue
Block a user