Skip to content

Commit f5b65cc

Browse files
Support -Xsuppress-version-warnings (#1146)
* Support -Xsuppress-version-warnings * Fix * Docs update --------- Co-authored-by: Corbin McNeely-Smith <58151731+restingbull@users.noreply.github.com>
1 parent 973e16d commit f5b65cc

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

docs/kotlin.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -402,7 +402,8 @@ kt_kotlinc_options(<a href="#kt_kotlinc_options-name">name</a>, <a href="#kt_kot
402402
<a href="#kt_kotlinc_options-x_inline_classes">x_inline_classes</a>, <a href="#kt_kotlinc_options-x_jvm_default">x_jvm_default</a>, <a href="#kt_kotlinc_options-x_lambdas">x_lambdas</a>, <a href="#kt_kotlinc_options-x_multi_platform">x_multi_platform</a>, <a href="#kt_kotlinc_options-x_no_call_assertions">x_no_call_assertions</a>,
403403
<a href="#kt_kotlinc_options-x_no_optimize">x_no_optimize</a>, <a href="#kt_kotlinc_options-x_no_optimized_callable_references">x_no_optimized_callable_references</a>, <a href="#kt_kotlinc_options-x_no_param_assertions">x_no_param_assertions</a>,
404404
<a href="#kt_kotlinc_options-x_no_receiver_assertions">x_no_receiver_assertions</a>, <a href="#kt_kotlinc_options-x_no_source_debug_extension">x_no_source_debug_extension</a>, <a href="#kt_kotlinc_options-x_optin">x_optin</a>, <a href="#kt_kotlinc_options-x_report_perf">x_report_perf</a>,
405-
<a href="#kt_kotlinc_options-x_sam_conversions">x_sam_conversions</a>, <a href="#kt_kotlinc_options-x_skip_prerelease_check">x_skip_prerelease_check</a>, <a href="#kt_kotlinc_options-x_use_fir_lt">x_use_fir_lt</a>, <a href="#kt_kotlinc_options-x_use_k2">x_use_k2</a>)
405+
<a href="#kt_kotlinc_options-x_sam_conversions">x_sam_conversions</a>, <a href="#kt_kotlinc_options-x_skip_prerelease_check">x_skip_prerelease_check</a>, <a href="#kt_kotlinc_options-x_suppress_version_warnings">x_suppress_version_warnings</a>,
406+
<a href="#kt_kotlinc_options-x_use_fir_lt">x_use_fir_lt</a>, <a href="#kt_kotlinc_options-x_use_k2">x_use_k2</a>)
406407

407408
408409
Define kotlin compiler options.
@@ -438,6 +439,7 @@ kt_kotlinc_options(<a href="#kt_kotlinc_options-name">name</a>, <a href="#kt_kot
438439
|<a id="kt_kotlinc_options-x_report_perf"></a>x_report_perf | Report detailed performance statistics | Boolean | optional | False |
439440
|<a id="kt_kotlinc_options-x_sam_conversions"></a>x_sam_conversions | Change codegen behavior of SAM/functional interfaces | String | optional | "class" |
440441
|<a id="kt_kotlinc_options-x_skip_prerelease_check"></a>x_skip_prerelease_check | Suppress errors thrown when using pre-release classes. | Boolean | optional | False |
442+
|<a id="kt_kotlinc_options-x_suppress_version_warnings"></a>x_suppress_version_warnings | Suppress warnings about outdated, inconsistent, or experimental language or API versions. | Boolean | optional | False |
441443
|<a id="kt_kotlinc_options-x_use_fir_lt"></a>x_use_fir_lt | Compile using LightTree parser with Front-end IR. Warning: this feature is far from being production-ready | Boolean | optional | False |
442444
|<a id="kt_kotlinc_options-x_use_k2"></a>x_use_k2 | Compile using experimental K2. K2 is a new compiler pipeline, no compatibility guarantees are yet provided | Boolean | optional | False |
443445

src/main/starlark/core/options/opts.kotlinc.bzl

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,17 @@ _KOPTS_ALL = {
7777
True: ["-Xcontext-receivers"],
7878
},
7979
),
80+
"x_suppress_version_warnings": struct(
81+
flag = "-Xsuppress-version-warnings",
82+
args = dict(
83+
default = False,
84+
doc = "Suppress warnings about outdated, inconsistent, or experimental language or API versions.",
85+
),
86+
type = attr.bool,
87+
value_to_flag = {
88+
True: ["-Xsuppress-version-warnings"],
89+
},
90+
),
8091
"x_inline_classes": struct(
8192
flag = "-Xinline-classes",
8293
args = dict(

0 commit comments

Comments
 (0)