From 95fd91ae16072ee3e179dfed40834f21270a3f18 Mon Sep 17 00:00:00 2001 From: "Alexander.Likhachev" Date: Tue, 20 Feb 2024 20:21:16 +0100 Subject: [PATCH] [CLI, Gradle] Update `GradleDeprecatedOption.removeAfter` values The values updated to follow the deprecation cycle "warning -> error -> removed" ^KT-65986 In Progress --- .../cli/common/arguments/CommonCompilerArguments.kt | 4 ++-- .../kotlin/cli/common/arguments/K2JSCompilerArguments.kt | 8 ++++---- .../kotlin/cli/common/arguments/K2JSDceArguments.kt | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/CommonCompilerArguments.kt b/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/CommonCompilerArguments.kt index a5d00055c52..e3f8cb83ed7 100644 --- a/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/CommonCompilerArguments.kt +++ b/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/CommonCompilerArguments.kt @@ -453,8 +453,8 @@ They should be a subset of sources passed as free arguments.""" @GradleDeprecatedOption( message = "Compiler flag -Xuse-k2 is deprecated; please use language version 2.0 instead", - level = DeprecationLevel.WARNING, - removeAfter = LanguageVersion.KOTLIN_2_0, + level = DeprecationLevel.WARNING, // TODO: KT-65990 switch to ERROR in 2.1 + removeAfter = LanguageVersion.KOTLIN_2_1, ) @GradleOption( DefaultValue.BOOLEAN_FALSE_DEFAULT, diff --git a/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/K2JSCompilerArguments.kt b/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/K2JSCompilerArguments.kt index 095ecb7aaa2..affa21e59df 100644 --- a/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/K2JSCompilerArguments.kt +++ b/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/K2JSCompilerArguments.kt @@ -50,8 +50,8 @@ class K2JSCompilerArguments : CommonCompilerArguments() { ) @GradleDeprecatedOption( message = "Only for legacy backend.", - level = DeprecationLevel.WARNING, - removeAfter = LanguageVersion.KOTLIN_2_0, + level = DeprecationLevel.WARNING, // TODO: KT-65990 switch to ERROR in 2.1 + removeAfter = LanguageVersion.KOTLIN_2_1, ) @Argument(value = "-no-stdlib", description = "Don't automatically include the default Kotlin/JS stdlib in compilation dependencies.") var noStdlib = false @@ -150,8 +150,8 @@ class K2JSCompilerArguments : CommonCompilerArguments() { ) @GradleDeprecatedOption( message = "Only for legacy backend.", - level = DeprecationLevel.WARNING, - removeAfter = LanguageVersion.KOTLIN_2_0, + level = DeprecationLevel.WARNING, // TODO: KT-65990 switch to ERROR in 2.1 + removeAfter = LanguageVersion.KOTLIN_2_1, ) @Deprecated("It is senseless to use with IR compiler. Only for compatibility.") @Argument(value = "-meta-info", description = "Generate .meta.js and .kjsm files with metadata. Use this to create a library.") diff --git a/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/K2JSDceArguments.kt b/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/K2JSDceArguments.kt index c365b648ca1..09f310fc04f 100644 --- a/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/K2JSDceArguments.kt +++ b/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/K2JSDceArguments.kt @@ -21,8 +21,8 @@ class K2JSDceArguments : CommonToolArguments() { ) @GradleDeprecatedOption( message = "Use task 'destinationDirectory' to configure output directory", - level = DeprecationLevel.WARNING, - removeAfter = LanguageVersion.KOTLIN_1_9, + level = DeprecationLevel.ERROR, + removeAfter = LanguageVersion.KOTLIN_2_0, ) @Argument( value = "-output-dir",