Deprecate -Xuse-k2 compiler flag in Gradle DSL
^KT-56239 Fixed
This commit is contained in:
committed by
Space Team
parent
efc957586d
commit
4523535545
+5
@@ -298,6 +298,11 @@ abstract class CommonCompilerArguments : CommonToolArguments() {
|
||||
)
|
||||
var checkStickyPhaseConditions: Boolean by FreezableVar(false)
|
||||
|
||||
@GradleDeprecatedOption(
|
||||
message = "Compiler flag -Xuse-k2 is deprecated; please use language version 2.0 instead",
|
||||
level = DeprecationLevel.WARNING,
|
||||
removeAfter = "2.0.0",
|
||||
)
|
||||
@GradleOption(
|
||||
DefaultValue.BOOLEAN_FALSE_DEFAULT,
|
||||
gradleInputType = GradleInputTypes.INPUT,
|
||||
|
||||
+1
@@ -29,6 +29,7 @@ interface KotlinCommonCompilerOptions : org.jetbrains.kotlin.gradle.dsl.KotlinCo
|
||||
* Compile using experimental K2. K2 is a new compiler pipeline, no compatibility guarantees are yet provided
|
||||
* Default value: false
|
||||
*/
|
||||
@Deprecated(message = "Compiler flag -Xuse-k2 is deprecated; please use language version 2.0 instead", level = DeprecationLevel.WARNING)
|
||||
@get:org.gradle.api.tasks.Input
|
||||
val useK2: org.gradle.api.provider.Property<kotlin.Boolean>
|
||||
}
|
||||
|
||||
+1
@@ -38,6 +38,7 @@ interface KotlinCommonOptions : org.jetbrains.kotlin.gradle.dsl.KotlinCommonTool
|
||||
* Compile using experimental K2. K2 is a new compiler pipeline, no compatibility guarantees are yet provided
|
||||
* Default value: false
|
||||
*/
|
||||
@Deprecated(message = "Compiler flag -Xuse-k2 is deprecated; please use language version 2.0 instead", level = DeprecationLevel.WARNING)
|
||||
var useK2: kotlin.Boolean
|
||||
get() = options.useK2.get()
|
||||
set(value) = options.useK2.set(value)
|
||||
|
||||
+1
@@ -15,6 +15,7 @@ internal abstract class KotlinCommonCompilerOptionsDefault @javax.inject.Inject
|
||||
override val languageVersion: org.gradle.api.provider.Property<org.jetbrains.kotlin.gradle.dsl.KotlinVersion> =
|
||||
objectFactory.property(org.jetbrains.kotlin.gradle.dsl.KotlinVersion::class.java)
|
||||
|
||||
@Deprecated(message = "Compiler flag -Xuse-k2 is deprecated; please use language version 2.0 instead", level = DeprecationLevel.WARNING)
|
||||
override val useK2: org.gradle.api.provider.Property<kotlin.Boolean> =
|
||||
objectFactory.property(kotlin.Boolean::class.java).convention(false)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user