Remove :libraries:tools:stdlib-compiler-classpath project

It was used as a workaround to allow jvmTarget=1.6 in stdlib.
This commit is contained in:
Abduqodiri Qurbonzoda
2022-08-10 17:59:52 +03:00
parent de10a5b8fe
commit 983c7adb1e
7 changed files with 2 additions and 30 deletions
@@ -56,7 +56,7 @@ fun CompilerConfiguration.setupJvmSpecificArguments(arguments: K2JVMCompilerArgu
val jvmTarget = JvmTarget.fromString(jvmTargetValue)
if (jvmTarget != null) {
put(JVMConfigurationKeys.JVM_TARGET, jvmTarget)
if (jvmTarget == JvmTarget.JVM_1_6 && !isJvmTarget6Allowed()) {
if (jvmTarget == JvmTarget.JVM_1_6) {
messageCollector.report(
ERROR,
"JVM target 1.6 is no longer supported. Please migrate to JVM target 1.8 or above"
@@ -378,6 +378,3 @@ private val CompilerConfiguration.messageCollector: MessageCollector
private fun getJavaVersion(): Int =
System.getProperty("java.specification.version")?.substringAfter('.')?.toIntOrNull() ?: 6
private fun isJvmTarget6Allowed(): Boolean =
K2JVMCompiler::class.java.classLoader.getResource("META-INF/unsafe-allow-jvm6") != null