Add -Xno-optimized-callable-references to disable KT-27362 optimization
This argument is useful in situations where the stdlib version which the code compiles against is different from the one which is available at runtime, such as the case of kotlin-gradle-plugin, which depends on the compiler/stdlib compiled by 1.4, but may be executed in Gradle where only 1.3.x is available. #KT-37435
This commit is contained in:
+6
@@ -323,6 +323,12 @@ class K2JVMCompilerArguments : CommonCompilerArguments() {
|
||||
)
|
||||
var klibLibraries: String? by NullableStringFreezableVar(null)
|
||||
|
||||
@Argument(
|
||||
value = "-Xno-optimized-callable-references",
|
||||
description = "Do not use optimized callable reference superclasses available from 1.4"
|
||||
)
|
||||
var noOptimizedCallableReferences: Boolean by FreezableVar(false)
|
||||
|
||||
override fun configureAnalysisFlags(collector: MessageCollector): MutableMap<AnalysisFlag<*>, Any> {
|
||||
val result = super.configureAnalysisFlags(collector)
|
||||
result[JvmAnalysisFlags.strictMetadataVersionSemantics] = strictMetadataVersionSemantics
|
||||
|
||||
Reference in New Issue
Block a user