diff --git a/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/K2JVMCompilerArguments.kt b/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/K2JVMCompilerArguments.kt index acbc57204c4..98ee325153f 100644 --- a/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/K2JVMCompilerArguments.kt +++ b/compiler/cli/cli-common/src/org/jetbrains/kotlin/cli/common/arguments/K2JVMCompilerArguments.kt @@ -177,13 +177,17 @@ class K2JVMCompilerArguments : CommonCompilerArguments() { @Argument( value = "-Xjsr305", deprecatedName = "-Xjsr305-annotations", - valueDescription = "{ignore|strict|warn}" + - "|under-migration:{ignore-strict-warn}" + - "|@:{ignore|strict|warn}", - description = "Specify behaviors for JSR-305 nullability annotations for: " + - "global, annotated with @UnderMigration or custom annotation " + - "with specific value: ignore, treat as other supported nullability annotations, or report a warning. " + - "Note that strict value is experimental yet" + valueDescription = "{ignore/strict/warn}" + + "|under-migration:{ignore/strict/warn}" + + "|@:{ignore/strict/warn}", + description = "Specify behavior for JSR-305 nullability annotations:\n" + + "-Xjsr305={ignore/strict/warn} globally (all non-@UnderMigration annotations)\n" + + "-Xjsr305=under-migration:{ignore/strict/warn} all @UnderMigration annotations\n" + + "-Xjsr305=@:{ignore/strict/warn} annotation with the given fully qualified class name\n" + + "Modes:\n" + + " * ignore\n" + + " * strict (experimental; treat as other supported nullability annotations)\n" + + " * warn (report a warning)" ) var jsr305: Array? by FreezableVar(null) diff --git a/compiler/testData/cli/jvm/extraHelp.out b/compiler/testData/cli/jvm/extraHelp.out index 87d13fac3c2..c2d84955e4c 100644 --- a/compiler/testData/cli/jvm/extraHelp.out +++ b/compiler/testData/cli/jvm/extraHelp.out @@ -11,8 +11,15 @@ where advanced options include: -Xmultifile-parts-inherit Compile multifile classes as a hierarchy of parts and facade -Xmodule-path= Paths where to find Java 9+ modules -Xjavac-arguments= Java compiler arguments - -Xjsr305={ignore|strict|warn}|under-migration:{ignore-strict-warn}|@:{ignore|strict|warn} - Specify behaviors for JSR-305 nullability annotations for: global, annotated with @UnderMigration or custom annotation with specific value: ignore, treat as other supported nullability annotations, or report a warning. Note that strict value is experimental yet + -Xjsr305={ignore/strict/warn}|under-migration:{ignore/strict/warn}|@:{ignore/strict/warn} + Specify behavior for JSR-305 nullability annotations: + -Xjsr305={ignore/strict/warn} globally (all non-@UnderMigration annotations) + -Xjsr305=under-migration:{ignore/strict/warn} all @UnderMigration annotations + -Xjsr305=@:{ignore/strict/warn} annotation with the given fully qualified class name + Modes: + * ignore + * strict (experimental; treat as other supported nullability annotations) + * warn (report a warning) -Xload-builtins-from-dependencies Load definitions of built-in declarations from module dependencies, instead of from the compiler -Xno-call-assertions Don't generate not-null assertions for arguments of platform types