Skip to content

Commit

Permalink
Revert "UPDATE_KOTLIN_VERSION: 1.9.0-dev-2695"
Browse files Browse the repository at this point in the history
This reverts commit 3b020dc.
  • Loading branch information
neetopia committed Mar 14, 2023
1 parent 97774aa commit 02d7eef
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,10 @@ import org.jetbrains.kotlin.cli.common.arguments.CommonCompilerArguments
import org.jetbrains.kotlin.cli.common.arguments.K2JSCompilerArguments
import org.jetbrains.kotlin.cli.common.arguments.K2JVMCompilerArguments
import org.jetbrains.kotlin.cli.common.arguments.K2MetadataCompilerArguments
import org.jetbrains.kotlin.gradle.dsl.*
import org.jetbrains.kotlin.gradle.dsl.KotlinCommonCompilerOptions
import org.jetbrains.kotlin.gradle.dsl.KotlinJsCompilerOptionsDefault
import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptionsDefault
import org.jetbrains.kotlin.gradle.dsl.KotlinMultiplatformCommonCompilerOptionsDefault
import org.jetbrains.kotlin.gradle.plugin.KotlinCompilation
import org.jetbrains.kotlin.gradle.plugin.KotlinCompilationInfo
import org.jetbrains.kotlin.gradle.plugin.SubpluginOption
Expand Down Expand Up @@ -260,14 +263,11 @@ abstract class KspTaskNative @Inject internal constructor(
objectFactory: ObjectFactory,
providerFactory: ProviderFactory,
execOperations: ExecOperations
) : KotlinNativeCompile(
compilation,
objectFactory.newInstance(KotlinNativeCompilerOptionsDefault::class.java),
objectFactory,
providerFactory,
execOperations
),
KspTask
) : KotlinNativeCompile(compilation, objectFactory, providerFactory, execOperations), KspTask {

override val compilerOptions: KotlinCommonCompilerOptions =
objectFactory.newInstance(KotlinMultiplatformCommonCompilerOptionsDefault::class.java)
}

internal fun SubpluginOption.toArg() = "plugin:${KspGradleSubplugin.KSP_PLUGIN_ID}:$key=$value"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -516,8 +516,6 @@ class KspGradleSubplugin @Inject internal constructor(private val registry: Tool
classpathCfg + kotlinCompileTask.compilerPluginClasspath!!
kspTask.compilerPluginOptions.addPluginArgument(kotlinCompileTask.compilerPluginOptions)
}
kspTask.compilerOptions.moduleName
.convention(kotlinCompileTask.compilerOptions.moduleName.map { "$it-ksp" })
kspTask.commonSources.from(kotlinCompileTask.commonSources)
kspTask.options.add(FilesSubpluginOption("apclasspath", processorClasspath.files.toList()))
val kspOptions = kspTask.options.get().flatMap { listOf("-P", it.toArg()) }
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copied from kotlinc
org.gradle.jvmargs=-Duser.country=US -Dkotlin.daemon.jvm.options=-Xmx2200m -Dfile.encoding=UTF-8

kotlinBaseVersion=1.9.0-dev-2695
kotlinBaseVersion=1.9.0-dev-1777
agpBaseVersion=7.0.0
intellijVersion=203.8084.24
junitVersion=4.12
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@ class KSPAATest : AbstractKSPAATest() {
runTest("../test-utils/testData/api/annotationInDependencies.kt")
}

@Disabled
@TestMetadata("annotationOnConstructorParameter.kt")
@Test
fun testAnnotationOnConstructorParameter() {
Expand Down

0 comments on commit 02d7eef

Please sign in to comment.